authorgravatar for alex@alexrp.comAlex Rønne Petersen <alex@alexrp.com> 2025-08-02 21:17:38+02:00
committergravatar for alex@alexrp.comAlex Rønne Petersen <alex@alexrp.com> 2025-08-30 06:36:41+02:00
loge4f38a611f1ba669434d52e753ae2c729911eead
tree155adc7d3bd3443b3d2dfb2a01553f2a9cf2a8bf
parent1c858ba7e302c2e0bcff1e54c599865eae4c3578
signaturebadge-check Signed by SSH key SHA256:7B/LJ7bpR1eX8aCXSr4mtd5M45VMPKcx9zY8e95b5QM

llvm: switch to native f16 IR type for all hexagon targets

This was fixed in LLVM 21, in particular for targets older than v68.

2 files changed, 1 insertions(+), 3 deletions(-)

lib/compiler_rt/common.zig+1-1
......@@ -123,6 +123,7 @@ pub fn F16T(comptime OtherType: type) type {
123123 .thumbeb,
124124 .aarch64,
125125 .aarch64_be,
126 .hexagon,
126127 .loongarch32,
127128 .loongarch64,
128129 .nvptx,
......@@ -135,7 +136,6 @@ pub fn F16T(comptime OtherType: type) type {
135136 .spirv32,
136137 .spirv64,
137138 => f16,
138 .hexagon => if (builtin.target.cpu.has(.hexagon, .v68)) f16 else u16,
139139 .x86, .x86_64 => if (builtin.target.os.tag.isDarwin()) switch (OtherType) {
140140 // Starting with LLVM 16, Darwin uses different abi for f16
141141 // depending on the type of the other return/argument..???
src/codegen/llvm.zig-2
......@@ -12852,8 +12852,6 @@ fn backendSupportsF16(target: *const std.Target) bool {
1285212852 // https://github.com/llvm/llvm-project/issues/97981
1285312853 .csky,
1285412854 // https://github.com/llvm/llvm-project/issues/97981
12855 .hexagon,
12856 // https://github.com/llvm/llvm-project/issues/97981
1285712855 .powerpc,
1285812856 .powerpcle,
1285912857 .powerpc64,