Add assertion to humor the paranoid.
[oota-llvm.git] / lib / Target / X86 / X86FastISel.cpp
index 94dec7ce355dd09c7ee88058db0b477f36108acf..d466ce0d4fb0d07e9eba4c5940ee8ff60e1a62dd 100644 (file)
@@ -1156,6 +1156,7 @@ bool X86FastISel::X86VisitIntrinsicCall(IntrinsicInst &I) {
   case Intrinsic::dbg_declare: {
     DbgDeclareInst *DI = cast<DbgDeclareInst>(&I);
     X86AddressMode AM;
+    assert(DI->getAddress() && "Null address should be checked earlier!");
     if (!X86SelectAddress(DI->getAddress(), AM))
       return false;
     const TargetInstrDesc &II = TII.get(TargetInstrInfo::DEBUG_VALUE);