summaryrefslogtreecommitdiffstats
path: root/clang/lib
diff options
context:
space:
mode:
authorTim Northover <tnorthover@apple.com>2016-04-13 17:08:51 +0000
committerTim Northover <tnorthover@apple.com>2016-04-13 17:08:51 +0000
commit99694feca5aea5e7e7e8d9edfbf858c2a63d5e69 (patch)
tree546c8d0ff5744d4a90c4867bd2a7360f9e3a54e1 /clang/lib
parentc05b767df1a4942907dc81d3279b5156e6aeef1f (diff)
downloadbcm5719-llvm-99694feca5aea5e7e7e8d9edfbf858c2a63d5e69.tar.gz
bcm5719-llvm-99694feca5aea5e7e7e8d9edfbf858c2a63d5e69.zip
ARM: make Darwin's "-arch armv7em" default to hard-float.
We've already paid the price for separate "armv7m" and "armv7em" slices (support in other tools), it's silly to make them identical other than the default CPU. rdar://23055688 llvm-svn: 266211
Diffstat (limited to 'clang/lib')
-rw-r--r--clang/lib/Driver/Tools.cpp7
1 files changed, 6 insertions, 1 deletions
diff --git a/clang/lib/Driver/Tools.cpp b/clang/lib/Driver/Tools.cpp
index 74bfc6ebde5..75424e87006 100644
--- a/clang/lib/Driver/Tools.cpp
+++ b/clang/lib/Driver/Tools.cpp
@@ -803,7 +803,12 @@ arm::FloatABI arm::getARMFloatABI(const ToolChain &TC, const ArgList &Args) {
break;
default:
// Assume "soft", but warn the user we are guessing.
- ABI = FloatABI::Soft;
+ if (Triple.isOSBinFormatMachO() &&
+ Triple.getSubArch() == llvm::Triple::ARMSubArch_v7em)
+ ABI = FloatABI::Hard;
+ else
+ ABI = FloatABI::Soft;
+
if (Triple.getOS() != llvm::Triple::UnknownOS ||
!Triple.isOSBinFormatMachO())
D.Diag(diag::warn_drv_assuming_mfloat_abi_is) << "soft";
OpenPOWER on IntegriCloud