llvm: Set float ABI based on std.Target.floatAbi().

This commit is contained in:
Alex Rønne Petersen 2024-08-25 00:45:38 +02:00
parent af370a69cd
commit 92517fbd62
No known key found for this signature in database

View File

@ -1284,8 +1284,7 @@ pub const Object = struct {
.large => .Large,
};
// TODO handle float ABI better- it should depend on the ABI portion of std.Target
const float_abi: llvm.ABIType = .Default;
const float_abi: llvm.ABIType = if (comp.root_mod.resolved_target.result.floatAbi() == .hard) .Hard else .Soft;
var target_machine = llvm.TargetMachine.create(
target,