summaryrefslogtreecommitdiffstats
path: root/llvm/lib/Target/CellSPU/SPUISelDAGToDAG.cpp
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
commit8e17d02a1e5f0c9532746aa8743c9fe2a02e7b1b (patch)
tree06e589a6ddb078c9a8b27ad5d8e031a87242d553 /llvm/lib/Target/CellSPU/SPUISelDAGToDAG.cpp
parent2afd0be069e87664b64bea0229f266fd8192ebf1 (diff)
downloadbcm5719-llvm-8e17d02a1e5f0c9532746aa8743c9fe2a02e7b1b.tar.gz
bcm5719-llvm-8e17d02a1e5f0c9532746aa8743c9fe2a02e7b1b.zip
CellSPU: Relax constraints on when to generate a X-form address, evidently
they were too tight according to bug 3126. Fix bug 3126. llvm-svn: 60006
Diffstat (limited to 'llvm/lib/Target/CellSPU/SPUISelDAGToDAG.cpp')
-rw-r--r--llvm/lib/Target/CellSPU/SPUISelDAGToDAG.cpp7
1 files changed, 7 insertions, 0 deletions
diff --git a/llvm/lib/Target/CellSPU/SPUISelDAGToDAG.cpp b/llvm/lib/Target/CellSPU/SPUISelDAGToDAG.cpp
index 4fbd5bb467a..159da4639f2 100644
--- a/llvm/lib/Target/CellSPU/SPUISelDAGToDAG.cpp
+++ b/llvm/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;
OpenPOWER on IntegriCloud