diff options
-rw-r--r-- | lib/Target/X86/X86ISelDAGToDAG.cpp | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/lib/Target/X86/X86ISelDAGToDAG.cpp b/lib/Target/X86/X86ISelDAGToDAG.cpp index 0bf036c227..a82904df01 100644 --- a/lib/Target/X86/X86ISelDAGToDAG.cpp +++ b/lib/Target/X86/X86ISelDAGToDAG.cpp @@ -640,7 +640,7 @@ bool X86DAGToDAGISel::TryFoldLoad(SDOperand P, SDOperand N, if (N.getOpcode() == ISD::LOAD && N.hasOneUse() && !CodeGenMap.count(N.getValue(0)) && - (P.getNumOperands() == 1 || !isNonImmUse(P.Val, N.Val))) + !IsFoldableBy(N.Val, P.Val)) return SelectAddr(N.getOperand(1), Base, Scale, Index, Disp); return false; } |