[ARM XRay] Try to fix Thumb-only failure
authorRenato Golin <renato.golin@linaro.org>
Thu, 8 Sep 2016 13:45:10 +0000 (13:45 +0000)
committerRenato Golin <renato.golin@linaro.org>
Thu, 8 Sep 2016 13:45:10 +0000 (13:45 +0000)
I mised the check that it had to support ARM to work. This commit tries
to fix that, to make sure we don't emit ARM code in Thumb-only mode.

llvm-svn: 280935

llvm/lib/Target/ARM/ARMSubtarget.cpp

index 481aacd..a90b495 100644 (file)
@@ -103,7 +103,7 @@ ARMSubtarget::ARMSubtarget(const Triple &TT, const std::string &CPU,
 
 bool ARMSubtarget::isXRaySupported() const {
   // We don't currently suppport Thumb, but Windows requires Thumb.
-  return hasV6Ops() && !isTargetWindows();
+  return hasV6Ops() && hasARMOps() && !isTargetWindows();
 }
 
 void ARMSubtarget::initializeEnvironment() {