diff options
| author | Jim Grosbach <grosbach@apple.com> | 2010-07-19 17:18:28 +0000 |
|---|---|---|
| committer | Jim Grosbach <grosbach@apple.com> | 2010-07-19 17:18:28 +0000 |
| commit | c685756cfbf56cc643032a6ca4089689e93754fd (patch) | |
| tree | dc619552e7765ff1eaefbe50f47c827030035c36 /llvm/lib/Target | |
| parent | 1432699cb23962c97cc7063124d2dac42e23fc4a (diff) | |
| download | bcm5719-llvm-c685756cfbf56cc643032a6ca4089689e93754fd.tar.gz bcm5719-llvm-c685756cfbf56cc643032a6ca4089689e93754fd.zip | |
Since ARM emits inline jump tables as part of the ConstantIsland pass,
it should set the jump table encloding the EK_Inline. This prevents
a second, unused, copy of the table from being emitted after the function
body. PR7499.
llvm-svn: 108722
Diffstat (limited to 'llvm/lib/Target')
| -rw-r--r-- | llvm/lib/Target/ARM/ARMISelLowering.cpp | 4 | ||||
| -rw-r--r-- | llvm/lib/Target/ARM/ARMISelLowering.h | 2 |
2 files changed, 6 insertions, 0 deletions
diff --git a/llvm/lib/Target/ARM/ARMISelLowering.cpp b/llvm/lib/Target/ARM/ARMISelLowering.cpp index 2cba4bf0cad..9b6db1d2336 100644 --- a/llvm/lib/Target/ARM/ARMISelLowering.cpp +++ b/llvm/lib/Target/ARM/ARMISelLowering.cpp @@ -1628,6 +1628,10 @@ static SDValue LowerConstantPool(SDValue Op, SelectionDAG &DAG) { return DAG.getNode(ARMISD::Wrapper, dl, MVT::i32, Res); } +unsigned ARMTargetLowering::getJumpTableEncoding() const { + return MachineJumpTableInfo::EK_Inline; +} + SDValue ARMTargetLowering::LowerBlockAddress(SDValue Op, SelectionDAG &DAG) const { MachineFunction &MF = DAG.getMachineFunction(); diff --git a/llvm/lib/Target/ARM/ARMISelLowering.h b/llvm/lib/Target/ARM/ARMISelLowering.h index 1c178b37fab..7f37e20724e 100644 --- a/llvm/lib/Target/ARM/ARMISelLowering.h +++ b/llvm/lib/Target/ARM/ARMISelLowering.h @@ -175,6 +175,8 @@ namespace llvm { public: explicit ARMTargetLowering(TargetMachine &TM); + virtual unsigned getJumpTableEncoding(void) const; + virtual SDValue LowerOperation(SDValue Op, SelectionDAG &DAG) const; /// ReplaceNodeResults - Replace the results of node with an illegal result |

