mirror of
https://github.com/ldc-developers/ldc.git
synced 2025-05-03 08:30:47 +03:00
Predefine version D_HardFloat instead of D_SoftFloat for -float-abi=softfp (#2678)
Matching the D_HardFloat semantics: 'the target hardware has a floating point unit'.
This commit is contained in:
parent
7464d8449f
commit
0cd14bf80e
5 changed files with 59 additions and 21 deletions
|
@ -35,10 +35,11 @@ public:
|
|||
const bool is64 = global.params.is64bit;
|
||||
auto tripleString = is64 ? "nvptx64-nvidia-cuda" : "nvptx-nvidia-cuda";
|
||||
|
||||
auto floatABI = ::FloatABI::Hard;
|
||||
targetMachine = createTargetMachine(
|
||||
tripleString, is64 ? "nvptx64" : "nvptx",
|
||||
"sm_" + ldc::to_string(tversion / 10), {},
|
||||
is64 ? ExplicitBitness::M64 : ExplicitBitness::M32, ::FloatABI::Hard,
|
||||
is64 ? ExplicitBitness::M64 : ExplicitBitness::M32, floatABI,
|
||||
llvm::Reloc::Static, llvm::CodeModel::Medium, codeGenOptLevel(), false);
|
||||
|
||||
_ir = new IRState("dcomputeTargetCUDA", ctx);
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue