diff options
author | Evan Cheng <evan.cheng@apple.com> | 2008-01-31 09:59:15 +0000 |
---|---|---|
committer | Evan Cheng <evan.cheng@apple.com> | 2008-01-31 09:59:15 +0000 |
commit | 13d1c2965485bc5df76e0bb609fcc77d257caca7 (patch) | |
tree | 1b7fda6273344331e160122778fe96319e45d842 /utils | |
parent | 059c7c93405e64692bda72c4c986f9d51ce64918 (diff) | |
download | external_llvm-13d1c2965485bc5df76e0bb609fcc77d257caca7.zip external_llvm-13d1c2965485bc5df76e0bb609fcc77d257caca7.tar.gz external_llvm-13d1c2965485bc5df76e0bb609fcc77d257caca7.tar.bz2 |
Add an extra operand to LABEL nodes which distinguishes between debug, EH, or misc labels. This fixes the EH breakage. However I am not convinced this is *the* solution.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@46609 91177308-0d34-0410-b5e6-96231b3b80d8
Diffstat (limited to 'utils')
-rw-r--r-- | utils/TableGen/DAGISelEmitter.cpp | 11 |
1 files changed, 7 insertions, 4 deletions
diff --git a/utils/TableGen/DAGISelEmitter.cpp b/utils/TableGen/DAGISelEmitter.cpp index 1f568ad..05c27c4 100644 --- a/utils/TableGen/DAGISelEmitter.cpp +++ b/utils/TableGen/DAGISelEmitter.cpp @@ -1795,12 +1795,15 @@ void DAGISelEmitter::EmitInstructionSelector(std::ostream &OS) { OS << "SDNode *Select_LABEL(const SDOperand &N) {\n" << " SDOperand Chain = N.getOperand(0);\n" << " SDOperand N1 = N.getOperand(1);\n" - << " unsigned C = cast<ConstantSDNode>(N1)->getValue();\n" - << " SDOperand Tmp = CurDAG->getTargetConstant(C, MVT::i32);\n" + << " SDOperand N2 = N.getOperand(2);\n" + << " unsigned C1 = cast<ConstantSDNode>(N1)->getValue();\n" + << " unsigned C2 = cast<ConstantSDNode>(N2)->getValue();\n" + << " SDOperand Tmp1 = CurDAG->getTargetConstant(C1, MVT::i32);\n" + << " SDOperand Tmp2 = CurDAG->getTargetConstant(C2, MVT::i32);\n" << " AddToISelQueue(Chain);\n" - << " SDOperand Ops[] = { Tmp, Chain };\n" + << " SDOperand Ops[] = { Tmp1, Tmp2, Chain };\n" << " return CurDAG->getTargetNode(TargetInstrInfo::LABEL,\n" - << " MVT::Other, Ops, 2);\n" + << " MVT::Other, Ops, 3);\n" << "}\n\n"; OS << "SDNode *Select_EXTRACT_SUBREG(const SDOperand &N) {\n" |