aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorScott Michel <scottm@aero.org>2008-11-25 04:03:47 +0000
committerScott Michel <scottm@aero.org>2008-11-25 04:03:47 +0000
commit50843c0741d242ab59e10ef88ebfbb88ce8f63ba (patch)
tree9c0cb8b71762fa55e8874d22574c945f38899b81
parent97d0a603e6266d496671dd8373ef5415fa821ec8 (diff)
CellSPU: Relax constraints on when to generate a X-form address, evidently
they were too tight according to bug 3126. Fix bug 3126. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@60006 91177308-0d34-0410-b5e6-96231b3b80d8
-rw-r--r--lib/Target/CellSPU/SPUISelDAGToDAG.cpp7
1 files changed, 7 insertions, 0 deletions
diff --git a/lib/Target/CellSPU/SPUISelDAGToDAG.cpp b/lib/Target/CellSPU/SPUISelDAGToDAG.cpp
index 4fbd5bb467..159da4639f 100644
--- a/lib/Target/CellSPU/SPUISelDAGToDAG.cpp
+++ b/lib/Target/CellSPU/SPUISelDAGToDAG.cpp
@@ -591,6 +591,7 @@ SPUDAGToDAGISel::SelectXFormAddr(SDValue Op, SDValue N, SDValue &Base,
SDValue &Index) {
if (!SelectAFormAddr(Op, N, Base, Index)
&& !SelectDFormAddr(Op, N, Base, Index)) {
+#if 0
// Default form of a X-form address is r(r) in operands 0 and 1:
SDValue Op0 = N.getOperand(0);
SDValue Op1 = N.getOperand(1);
@@ -611,6 +612,12 @@ SPUDAGToDAGISel::SelectXFormAddr(SDValue Op, SDValue N, SDValue &Base,
return true;
}
+#else
+ // All else fails, punt and use an X-form address:
+ Base = N.getOperand(0);
+ Index = N.getOperand(1);
+ return true;
+#endif
}
return false;