diff --git a/lib/Target/ARM/ARMFastISel.cpp b/lib/Target/ARM/ARMFastISel.cpp index cfe21c0df7b..df3fe1bc275 100644 --- a/lib/Target/ARM/ARMFastISel.cpp +++ b/lib/Target/ARM/ARMFastISel.cpp @@ -589,7 +589,9 @@ bool ARMFastISel::ARMComputeRegOffset(const Value *Obj, unsigned &Reg, default: break; case Instruction::Alloca: { - assert(false && "Alloca should have been handled earlier!"); + // Don't handle dynamic allocas. + if (FuncInfo.StaticAllocaMap.count(cast(Obj))) + assert(false && "Alloca should have been handled earlier!"); return false; } }