diff options
| author | Chris Lattner <sabre@nondot.org> | 2005-05-12 02:02:21 +0000 |
|---|---|---|
| committer | Chris Lattner <sabre@nondot.org> | 2005-05-12 02:02:21 +0000 |
| commit | 515f53d4faeffbe938b019bbbe90fe3d6f18041e (patch) | |
| tree | f4a25e70f4d35b1add20ab75009f1cf8b4cd7a10 /llvm | |
| parent | 8005e9143292d078cc2e06e25364195aa7fd4600 (diff) | |
| download | bcm5719-llvm-515f53d4faeffbe938b019bbbe90fe3d6f18041e.tar.gz bcm5719-llvm-515f53d4faeffbe938b019bbbe90fe3d6f18041e.zip | |
Add a little hook
llvm-svn: 21883
Diffstat (limited to 'llvm')
| -rw-r--r-- | llvm/include/llvm/Target/TargetLowering.h | 14 |
1 files changed, 14 insertions, 0 deletions
diff --git a/llvm/include/llvm/Target/TargetLowering.h b/llvm/include/llvm/Target/TargetLowering.h index 5aa8ae1a606..96305c2b6a2 100644 --- a/llvm/include/llvm/Target/TargetLowering.h +++ b/llvm/include/llvm/Target/TargetLowering.h @@ -76,6 +76,10 @@ public: MVT::ValueType getShiftAmountTy() const { return ShiftAmountTy; } OutOfRangeShiftAmount getShiftAmountFlavor() const {return ShiftAmtHandling; } + /// isSetCCExpensive - Return true if the setcc operation is expensive for + /// this target. + bool isSetCCExpensive() const { return SetCCIsExpensive; } + /// getSetCCResultTy - Return the ValueType of the result of setcc operations. /// MVT::ValueType getSetCCResultTy() const { return SetCCResultTy; } @@ -207,6 +211,11 @@ protected: ShiftAmtHandling = OORSA; } + /// setSetCCIxExpensive - This is a short term hack for targets that codegen + /// setcc as a conditional branch. This encourages the code generator to fold + /// setcc operations into other operations if possible. + void setSetCCIsExpensive() { SetCCIsExpensive = true; } + /// addRegisterClass - Add the specified register class as an available /// regclass for the specified value type. This indicates the selector can /// handle values of that class natively. @@ -310,6 +319,11 @@ private: OutOfRangeShiftAmount ShiftAmtHandling; + /// SetCCIsExpensive - This is a short term hack for targets that codegen + /// setcc as a conditional branch. This encourages the code generator to fold + /// setcc operations into other operations if possible. + bool SetCCIsExpensive; + /// SetCCResultTy - The type that SetCC operations use. This defaults to the /// PointerTy. MVT::ValueType SetCCResultTy; |

