| ... | @@ -68,7 +68,14 @@ pub fn classifyType(ty: Type, target: std.Target, ctx: Context) Class { | ... | @@ -68,7 +68,14 @@ pub fn classifyType(ty: Type, target: std.Target, ctx: Context) Class { |
| 68 | return Class.arrSize(bit_size, 32); | 68 | return Class.arrSize(bit_size, 32); |
| 69 | }, | 69 | }, |
| 70 | .Bool, .Float => return .byval, | 70 | .Bool, .Float => return .byval, |
| 71 | .Int, .Enum, .ErrorSet => { | 71 | .Int => { |
| | 72 | // TODO this is incorrect for _BitInt(128) but implementing |
| | 73 | // this correctly makes implementing compiler-rt impossible. |
| | 74 | // const bit_size = ty.bitSize(target); |
| | 75 | // if (bit_size > 64) return .memory; |
| | 76 | return .byval; |
| | 77 | }, |
| | 78 | .Enum, .ErrorSet => { |
| 72 | const bit_size = ty.bitSize(target); | 79 | const bit_size = ty.bitSize(target); |
| 73 | if (bit_size > 64) return .memory; | 80 | if (bit_size > 64) return .memory; |
| 74 | return .byval; | 81 | return .byval; |