diff options
author | Nick Lewycky <nicholas@mxc.ca> | 2011-08-14 04:51:49 +0000 |
---|---|---|
committer | Nick Lewycky <nicholas@mxc.ca> | 2011-08-14 04:51:49 +0000 |
commit | 28b84ff4cec5bf2de4c1f85b85d613818175c4d4 (patch) | |
tree | ffa54ff9e9492723486fdfb44c85f56fc6380528 /lib/Transforms/InstCombine | |
parent | 7f0170c1975fe55c58f6f2a968e1fc2248732fbe (diff) | |
download | llvm-28b84ff4cec5bf2de4c1f85b85d613818175c4d4.tar.gz llvm-28b84ff4cec5bf2de4c1f85b85d613818175c4d4.tar.bz2 llvm-28b84ff4cec5bf2de4c1f85b85d613818175c4d4.tar.xz |
This transform is not safe. Thanks to Eli for pointing that out!
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@137575 91177308-0d34-0410-b5e6-96231b3b80d8
Diffstat (limited to 'lib/Transforms/InstCombine')
-rw-r--r-- | lib/Transforms/InstCombine/InstructionCombining.cpp | 9 |
1 files changed, 1 insertions, 8 deletions
diff --git a/lib/Transforms/InstCombine/InstructionCombining.cpp b/lib/Transforms/InstCombine/InstructionCombining.cpp index 4166636114..41d542af68 100644 --- a/lib/Transforms/InstCombine/InstructionCombining.cpp +++ b/lib/Transforms/InstCombine/InstructionCombining.cpp @@ -294,14 +294,7 @@ bool InstCombiner::SimplifyAssociativeOrCommutative(BinaryOperator &I) { I.setOperand(1, Folded); // Conservatively clear the optional flags, since they may not be // preserved by the reassociation. - if (MaintainNoSignedWrap(I, C1, C2) && Op0->hasNoSignedWrap() && - Op1->hasNoSignedWrap()) { - New->setHasNoSignedWrap(true); - I.clearSubclassOptionalData(); - I.setHasNoSignedWrap(true); - } else { - I.clearSubclassOptionalData(); - } + I.clearSubclassOptionalData(); Changed = true; continue; |