mirror of
https://github.com/c64scene-ar/llvm-6502.git
synced 2025-03-04 05:31:51 +00:00
Fix a dag combiner bug exposed by my recent instcombine patch. This fixes
CodeGen/Generic/2006-11-10-DAGCombineMiscompile.ll and PPC gsm/toast git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@31644 91177308-0d34-0410-b5e6-96231b3b80d8
This commit is contained in:
parent
6832780bda
commit
734c91d250
@ -1723,7 +1723,7 @@ SDOperand DAGCombiner::visitXOR(SDNode *N) {
|
|||||||
abort();
|
abort();
|
||||||
}
|
}
|
||||||
// fold !(x or y) -> (!x and !y) iff x or y are setcc
|
// fold !(x or y) -> (!x and !y) iff x or y are setcc
|
||||||
if (N1C && N1C->getValue() == 1 &&
|
if (N1C && N1C->getValue() == 1 && VT == MVT::i1 &&
|
||||||
(N0.getOpcode() == ISD::OR || N0.getOpcode() == ISD::AND)) {
|
(N0.getOpcode() == ISD::OR || N0.getOpcode() == ISD::AND)) {
|
||||||
SDOperand LHS = N0.getOperand(0), RHS = N0.getOperand(1);
|
SDOperand LHS = N0.getOperand(0), RHS = N0.getOperand(1);
|
||||||
if (isOneUseSetCC(RHS) || isOneUseSetCC(LHS)) {
|
if (isOneUseSetCC(RHS) || isOneUseSetCC(LHS)) {
|
||||||
|
Loading…
x
Reference in New Issue
Block a user