diff options
author | Chris Lattner <sabre@nondot.org> | 2005-01-07 22:44:09 +0000 |
---|---|---|
committer | Chris Lattner <sabre@nondot.org> | 2005-01-07 22:44:09 +0000 |
commit | 4287d5e355c7dafcb8d674a236eabcccb895c892 (patch) | |
tree | 5540efef3ad2d0b69a56ab183cd530bba2084c39 /lib/CodeGen/SelectionDAG/SelectionDAG.cpp | |
parent | b00a6425de1ef8668b63f29927c38da8a19ce904 (diff) |
Fix a thinko in the reassociation code, fixing Generic/badlive.ll
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@19359 91177308-0d34-0410-b5e6-96231b3b80d8
Diffstat (limited to 'lib/CodeGen/SelectionDAG/SelectionDAG.cpp')
-rw-r--r-- | lib/CodeGen/SelectionDAG/SelectionDAG.cpp | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/lib/CodeGen/SelectionDAG/SelectionDAG.cpp b/lib/CodeGen/SelectionDAG/SelectionDAG.cpp index 25ec8ff052..6ab1d45957 100644 --- a/lib/CodeGen/SelectionDAG/SelectionDAG.cpp +++ b/lib/CodeGen/SelectionDAG/SelectionDAG.cpp @@ -599,7 +599,7 @@ SDOperand SelectionDAG::getNode(unsigned Opcode, MVT::ValueType VT, // Reassociate ((X op C1) op C2) if possible. if (N1.getOpcode() == Opcode && isAssociativeBinOp(Opcode)) if (ConstantSDNode *N3C = dyn_cast<ConstantSDNode>(N1.Val->getOperand(1))) - return getNode(Opcode, VT, N3C->getOperand(0), + return getNode(Opcode, VT, N1.Val->getOperand(0), getNode(Opcode, VT, N2, N1.Val->getOperand(1))); } |