zig

fork of https://codeberg.org/ziglang/zig
Log | Files | Refs | README | LICENSE

commit 546c75ca46eff73e5f038e2b894ff96c65cd8960 (tree)
parent 4624c818991f161fc6a7021119e4d071b6e40e6c
Author: Andrew Kelley <andrew@ziglang.org>
Date:   Sun, 24 Jul 2022 12:28:08 -0700

LLVM: notice the soft_float CPU feature

when deciding whether to lower to x86_fp80 instructions, or softfloat
instructions.

Closes #10847
Closes #12090

Diffstat:
Msrc/codegen/llvm.zig | 2+-
1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/src/codegen/llvm.zig b/src/codegen/llvm.zig @@ -9514,7 +9514,7 @@ fn isByRef(ty: Type) bool { /// and false if we expect LLVM to crash if it counters an x86_fp80 type. fn backendSupportsF80(target: std.Target) bool { return switch (target.cpu.arch) { - .x86_64, .i386 => true, + .x86_64, .i386 => !std.Target.x86.featureSetHas(target.cpu.features, .soft_float), else => false, }; }