diff options
| author | Veikka Tuominen <git@vexu.eu> | 2022-10-22 19:32:56 +0300 |
|---|---|---|
| committer | Veikka Tuominen <git@vexu.eu> | 2022-10-22 19:32:56 +0300 |
| commit | be10f95994d077f9b8137bb58d0349f78f408219 (patch) | |
| tree | 563c96e8655c8d7b66bd57f0673d5258eb409fb2 /src | |
| parent | 3f4197906190fe39d75f5e9bee2d9a7e5813f800 (diff) | |
| download | zig-be10f95994d077f9b8137bb58d0349f78f408219.tar.gz zig-be10f95994d077f9b8137bb58d0349f78f408219.zip | |
ARM C ABI: workaround i128 issues
Diffstat (limited to 'src')
| -rw-r--r-- | src/arch/arm/abi.zig | 9 |
1 files changed, 8 insertions, 1 deletions
diff --git a/src/arch/arm/abi.zig b/src/arch/arm/abi.zig index d8bbc5d1d1..9659ca13d7 100644 --- a/src/arch/arm/abi.zig +++ b/src/arch/arm/abi.zig @@ -68,7 +68,14 @@ pub fn classifyType(ty: Type, target: std.Target, ctx: Context) Class { return Class.arrSize(bit_size, 32); }, .Bool, .Float => return .byval, - .Int, .Enum, .ErrorSet => { + .Int => { + // TODO this is incorrect for _BitInt(128) but implementing + // this correctly makes implementing compiler-rt impossible. + // const bit_size = ty.bitSize(target); + // if (bit_size > 64) return .memory; + return .byval; + }, + .Enum, .ErrorSet => { const bit_size = ty.bitSize(target); if (bit_size > 64) return .memory; return .byval; |
