Don't need to save piecemeal now.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@119862 91177308-0d34-0410-b5e6-96231b3b80d8
This commit is contained in:
Eric Christopher 2010-11-19 22:39:56 +00:00
parent 2d630d7bc9
commit b371658083

View File

@ -647,8 +647,7 @@ bool ARMFastISel::ARMComputeAddress(const Value *Obj, Address &Addr) {
break;
}
case Instruction::GetElementPtr: {
int SavedOffset = Addr.Offset;
unsigned SavedBase = Addr.Base.Reg;
Address SavedAddr = Addr;
int TmpOffset = Addr.Offset;
// Iterate through the GEP folding the constants into offsets where
@ -689,8 +688,7 @@ bool ARMFastISel::ARMComputeAddress(const Value *Obj, Address &Addr) {
if (ARMComputeAddress(U->getOperand(0), Addr)) return true;
// We failed, restore everything and try the other options.
Addr.Offset = SavedOffset;
Addr.Base.Reg = SavedBase;
Addr = SavedAddr;
unsupported_gep:
break;