diff options
| author | Eric Christopher <echristo@apple.com> | 2010-11-12 22:52:32 +0000 |
|---|---|---|
| committer | Eric Christopher <echristo@apple.com> | 2010-11-12 22:52:32 +0000 |
| commit | 49a66f7d712a62d51e111823556a39f39002c1a0 (patch) | |
| tree | 49bad254e2f98dbd9983f6d4f38bed755de78283 /llvm/lib | |
| parent | 0fc8084a64e5fd76b7ccdf390a11ad81b5f84f66 (diff) | |
| download | bcm5719-llvm-49a66f7d712a62d51e111823556a39f39002c1a0.tar.gz bcm5719-llvm-49a66f7d712a62d51e111823556a39f39002c1a0.zip | |
Make this happen for ARM like x86. Don't entirely bail out when
an address is in a different block, get it into a register and go
from there.
llvm-svn: 118936
Diffstat (limited to 'llvm/lib')
| -rw-r--r-- | llvm/lib/Target/ARM/ARMFastISel.cpp | 9 |
1 files changed, 5 insertions, 4 deletions
diff --git a/llvm/lib/Target/ARM/ARMFastISel.cpp b/llvm/lib/Target/ARM/ARMFastISel.cpp index 58f72f6c159..f0413a38ec4 100644 --- a/llvm/lib/Target/ARM/ARMFastISel.cpp +++ b/llvm/lib/Target/ARM/ARMFastISel.cpp @@ -590,10 +590,11 @@ bool ARMFastISel::ARMComputeRegOffset(const Value *Obj, unsigned &Base, // Don't walk into other basic blocks; it's possible we haven't // visited them yet, so the instructions may not yet be assigned // virtual registers. - if (FuncInfo.MBBMap[I->getParent()] != FuncInfo.MBB) - return false; - Opcode = I->getOpcode(); - U = I; + if (FuncInfo.StaticAllocaMap.count(static_cast<const AllocaInst *>(Obj)) || + FuncInfo.MBBMap[I->getParent()] == FuncInfo.MBB) { + Opcode = I->getOpcode(); + U = I; + } } else if (const ConstantExpr *C = dyn_cast<ConstantExpr>(Obj)) { Opcode = C->getOpcode(); U = C; |

