Fix build failure introduced in 179591 when assertions are disabled.

llvm-svn: 179593
This commit is contained in:
Logan Chien 2013-04-16 14:02:30 +00:00
parent 9b59a39f42
commit 3d134ebb73
1 changed files with 4 additions and 0 deletions

View File

@ -428,7 +428,9 @@ void ARMELFStreamer::EmitSetFP(unsigned NewFPReg,
const MCRegisterInfo &MRI = getContext().getRegisterInfo();
uint16_t NewFPRegEncVal = MRI.getEncodingValue(NewFPReg);
#ifndef NDEBUG
uint16_t NewSPRegEncVal = MRI.getEncodingValue(NewSPReg);
#endif
assert((NewSPReg == ARM::SP || NewSPRegEncVal == FPReg) &&
"the operand of .setfp directive should be either $sp or $fp");
@ -446,7 +448,9 @@ void ARMELFStreamer::EmitRegSave(const SmallVectorImpl<unsigned> &RegList,
bool IsVector) {
const MCRegisterInfo &MRI = getContext().getRegisterInfo();
#ifndef NDEBUG
unsigned Max = IsVector ? 32 : 16;
#endif
uint32_t &RegMask = IsVector ? VFPRegSave : RegSave;
for (size_t i = 0; i < RegList.size(); ++i) {