summaryrefslogtreecommitdiff
path: root/include/llvm/CodeGen/SelectionDAGISel.h
diff options
context:
space:
mode:
authorChris Lattner <sabre@nondot.org>2006-10-24 17:03:35 +0000
committerChris Lattner <sabre@nondot.org>2006-10-24 17:03:35 +0000
commit7b248d986670c214674c45d362950ec105668255 (patch)
treeb19f870b903599875daab020d698e15f0c042ed9 /include/llvm/CodeGen/SelectionDAGISel.h
parent578e64a041ab2c199d37fd6346eb34b9e9c2e9ed (diff)
downloadllvm-7b248d986670c214674c45d362950ec105668255.tar.gz
llvm-7b248d986670c214674c45d362950ec105668255.tar.bz2
llvm-7b248d986670c214674c45d362950ec105668255.tar.xz
generalize 'CaseBlock'. It really allows any comparison to be inserted.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@31161 91177308-0d34-0410-b5e6-96231b3b80d8
Diffstat (limited to 'include/llvm/CodeGen/SelectionDAGISel.h')
-rw-r--r--include/llvm/CodeGen/SelectionDAGISel.h15
1 files changed, 7 insertions, 8 deletions
diff --git a/include/llvm/CodeGen/SelectionDAGISel.h b/include/llvm/CodeGen/SelectionDAGISel.h
index f733d965fd..855febe2e4 100644
--- a/include/llvm/CodeGen/SelectionDAGISel.h
+++ b/include/llvm/CodeGen/SelectionDAGISel.h
@@ -82,20 +82,19 @@ public:
/// SDISel for the code generation of additional basic blocks needed by multi-
/// case switch statements.
struct CaseBlock {
- CaseBlock(ISD::CondCode cc, Value *s, Constant *c, MachineBasicBlock *lhs,
- MachineBasicBlock *rhs, MachineBasicBlock *me) :
- CC(cc), SwitchV(s), CaseC(c), LHSBB(lhs), RHSBB(rhs), ThisBB(me) {}
+ CaseBlock(ISD::CondCode cc, Value *cmplhs, Value *cmprhs,
+ MachineBasicBlock *lhs, MachineBasicBlock *rhs,
+ MachineBasicBlock *me) :
+ CC(cc), CmpLHS(cmplhs), CmpRHS(cmprhs), LHSBB(lhs), RHSBB(rhs), ThisBB(me){}
// CC - the condition code to use for the case block's setcc node
ISD::CondCode CC;
- // SwitchV - the value to be switched on, 'foo' in switch(foo)
- Value *SwitchV;
- // CaseC - the constant the setcc node will compare against SwitchV
- Constant *CaseC;
+ // CmpLHS/CmpRHS - The LHS/RHS of the comparison to emit.
+ Value *CmpLHS, *CmpRHS;
// LHSBB - the block to branch to if the setcc is true
MachineBasicBlock *LHSBB;
// RHSBB - the block to branch to if the setcc is false
MachineBasicBlock *RHSBB;
- // ThisBB - the blcok into which to emit the code for the setcc and branches
+ // ThisBB - the block into which to emit the code for the setcc and branches
MachineBasicBlock *ThisBB;
};
struct JumpTable {