[llvm-commits] [llvm] r134626 - in /llvm/trunk/lib/Target/ARM: ARM.td ARMSubtarget.cpp ARMSubtarget.h MCTargetDesc/ARMMCTargetDesc.cpp
Evan Cheng
evan.cheng at apple.com
Thu Jul 7 12:05:13 PDT 2011
Author: evancheng
Date: Thu Jul 7 14:05:12 2011
New Revision: 134626
URL: http://llvm.org/viewvc/llvm-project?rev=134626&view=rev
Log:
Rename attribute 'thumb' to a more descriptive 'thumb-mode'.
Modified:
llvm/trunk/lib/Target/ARM/ARM.td
llvm/trunk/lib/Target/ARM/ARMSubtarget.cpp
llvm/trunk/lib/Target/ARM/ARMSubtarget.h
llvm/trunk/lib/Target/ARM/MCTargetDesc/ARMMCTargetDesc.cpp
Modified: llvm/trunk/lib/Target/ARM/ARM.td
URL: http://llvm.org/viewvc/llvm-project/llvm/trunk/lib/Target/ARM/ARM.td?rev=134626&r1=134625&r2=134626&view=diff
==============================================================================
--- llvm/trunk/lib/Target/ARM/ARM.td (original)
+++ llvm/trunk/lib/Target/ARM/ARM.td Thu Jul 7 14:05:12 2011
@@ -20,7 +20,7 @@
// ARM Subtarget state.
//
-def ModeThumb : SubtargetFeature<"thumb", "IsThumb", "true",
+def ModeThumb : SubtargetFeature<"thumb-mode", "InThumbMode", "true",
"Thumb mode">;
//===----------------------------------------------------------------------===//
Modified: llvm/trunk/lib/Target/ARM/ARMSubtarget.cpp
URL: http://llvm.org/viewvc/llvm-project/llvm/trunk/lib/Target/ARM/ARMSubtarget.cpp?rev=134626&r1=134625&r2=134626&view=diff
==============================================================================
--- llvm/trunk/lib/Target/ARM/ARMSubtarget.cpp (original)
+++ llvm/trunk/lib/Target/ARM/ARMSubtarget.cpp Thu Jul 7 14:05:12 2011
@@ -53,7 +53,7 @@
, SlowFPVMLx(false)
, HasVMLxForwarding(false)
, SlowFPBrcc(false)
- , IsThumb(false)
+ , InThumbMode(false)
, HasThumb2(false)
, NoARM(false)
, PostRAScheduler(false)
Modified: llvm/trunk/lib/Target/ARM/ARMSubtarget.h
URL: http://llvm.org/viewvc/llvm-project/llvm/trunk/lib/Target/ARM/ARMSubtarget.h?rev=134626&r1=134625&r2=134626&view=diff
==============================================================================
--- llvm/trunk/lib/Target/ARM/ARMSubtarget.h (original)
+++ llvm/trunk/lib/Target/ARM/ARMSubtarget.h Thu Jul 7 14:05:12 2011
@@ -67,8 +67,8 @@
/// SlowFPBrcc - True if floating point compare + branch is slow.
bool SlowFPBrcc;
- /// IsThumb - True if we are in thumb mode, false if in ARM mode.
- bool IsThumb;
+ /// InThumbMode - True if we are in thumb mode, false if in ARM mode.
+ bool InThumbMode;
/// HasThumb2 - True if Thumb2 instructions are supported.
bool HasThumb2;
@@ -214,9 +214,9 @@
bool isAPCS_ABI() const { return TargetABI == ARM_ABI_APCS; }
bool isAAPCS_ABI() const { return TargetABI == ARM_ABI_AAPCS; }
- bool isThumb() const { return IsThumb; }
- bool isThumb1Only() const { return IsThumb && !HasThumb2; }
- bool isThumb2() const { return IsThumb && HasThumb2; }
+ bool isThumb() const { return InThumbMode; }
+ bool isThumb1Only() const { return InThumbMode && !HasThumb2; }
+ bool isThumb2() const { return InThumbMode && HasThumb2; }
bool hasThumb2() const { return HasThumb2; }
bool isR9Reserved() const { return IsR9Reserved; }
Modified: llvm/trunk/lib/Target/ARM/MCTargetDesc/ARMMCTargetDesc.cpp
URL: http://llvm.org/viewvc/llvm-project/llvm/trunk/lib/Target/ARM/MCTargetDesc/ARMMCTargetDesc.cpp?rev=134626&r1=134625&r2=134626&view=diff
==============================================================================
--- llvm/trunk/lib/Target/ARM/MCTargetDesc/ARMMCTargetDesc.cpp (original)
+++ llvm/trunk/lib/Target/ARM/MCTargetDesc/ARMMCTargetDesc.cpp Thu Jul 7 14:05:12 2011
@@ -88,6 +88,7 @@
unsigned Len = TT.size();
unsigned Idx = 0;
+ // FIXME: Enahnce Triple helper class to extract ARM version.
bool isThumb = false;
if (Len >= 5 && TT.substr(0, 4) == "armv")
Idx = 4;
@@ -127,9 +128,9 @@
if (isThumb) {
if (ARMArchFeature.empty())
- ARMArchFeature = "+thumb";
+ ARMArchFeature = "+thumb-mode";
else
- ARMArchFeature += ",+thumb";
+ ARMArchFeature += ",+thumb-mode";
}
return ARMArchFeature;
More information about the llvm-commits
mailing list