]> granicus.if.org Git - clang/commitdiff
Teach the driver to pass -fexceptions in Objective-C inputs on ARM.
authorJohn McCall <rjmccall@apple.com>
Wed, 6 Oct 2010 01:40:51 +0000 (01:40 +0000)
committerJohn McCall <rjmccall@apple.com>
Wed, 6 Oct 2010 01:40:51 +0000 (01:40 +0000)
I don't know when this stopped happening, but this seems to be the
right place to do it.

git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@115730 91177308-0d34-0410-b5e6-96231b3b80d8

lib/Driver/Tools.cpp

index 1662c375e6c3c701bdecb25e3a4d26a5dd0d0302..c3c224e9dbfab9f2f1f50c121af5aa3f9d07642c 100644 (file)
@@ -704,14 +704,15 @@ static bool needsExceptions(const ArgList &Args,  types::ID InputType,
     return true;
 
   // As do Objective-C non-fragile ABI inputs and all Objective-C inputs on
-  // x86_64 after SnowLeopard.
+  // x86_64 and ARM after SnowLeopard.
   if (types::isObjC(InputType)) {
     if (Args.hasArg(options::OPT_fobjc_nonfragile_abi))
       return true;
     if (Triple.getOS() != llvm::Triple::Darwin)
       return false;
     return (Triple.getDarwinMajorNumber() >= 9 &&
-            Triple.getArch() == llvm::Triple::x86_64);
+            (Triple.getArch() == llvm::Triple::x86_64 ||
+             Triple.getArch() == llvm::Triple::arm));
   }
 
   return false;