diff options
author | Tim Northover <tnorthover@apple.com> | 2018-07-18 12:36:25 +0000 |
---|---|---|
committer | Tim Northover <tnorthover@apple.com> | 2018-07-18 12:36:25 +0000 |
commit | 097a3e3d957f1539c7ccb7c417300e9f838f4b28 (patch) | |
tree | 0fa030ec07de24d06470579e9e2d0b0bf99784b7 /llvm/lib/Target/ARM/ARMTargetMachine.cpp | |
parent | 330d887d72f4a298bef86c4d3fd6f628e5bc9e2c (diff) | |
download | bcm5719-llvm-097a3e3d957f1539c7ccb7c417300e9f838f4b28.tar.gz bcm5719-llvm-097a3e3d957f1539c7ccb7c417300e9f838f4b28.zip |
ARM: deduplicate hard-float detection code. NFC.
ARMSubtarget had a copy/pasted block to determine whether the target was
hard-float, but it just delegated to triple features anyway so it's better at
the TargetMachine level.
llvm-svn: 337384
Diffstat (limited to 'llvm/lib/Target/ARM/ARMTargetMachine.cpp')
-rw-r--r-- | llvm/lib/Target/ARM/ARMTargetMachine.cpp | 6 |
1 files changed, 1 insertions, 5 deletions
diff --git a/llvm/lib/Target/ARM/ARMTargetMachine.cpp b/llvm/lib/Target/ARM/ARMTargetMachine.cpp index bc2525b6b42..3189e85b8ca 100644 --- a/llvm/lib/Target/ARM/ARMTargetMachine.cpp +++ b/llvm/lib/Target/ARM/ARMTargetMachine.cpp @@ -215,11 +215,7 @@ ARMBaseTargetMachine::ARMBaseTargetMachine(const Target &T, const Triple &TT, // Default to triple-appropriate float ABI if (Options.FloatABIType == FloatABI::Default) { - if (TargetTriple.getEnvironment() == Triple::GNUEABIHF || - TargetTriple.getEnvironment() == Triple::MuslEABIHF || - TargetTriple.getEnvironment() == Triple::EABIHF || - TargetTriple.isOSWindows() || - TargetABI == ARMBaseTargetMachine::ARM_ABI_AAPCS16) + if (isTargetHardFloat()) this->Options.FloatABIType = FloatABI::Hard; else this->Options.FloatABIType = FloatABI::Soft; |