From: Jakob Stoklund Olesen Date: Wed, 12 Jan 2011 21:27:45 +0000 (+0000) Subject: Assert if anybody tries to put a slot index on a DBG_VALUE instruction. X-Git-Url: http://plrg.eecs.uci.edu/git/?a=commitdiff_plain;h=a5f1a900df66178608d728708e0753015681d4c7;p=oota-llvm.git Assert if anybody tries to put a slot index on a DBG_VALUE instruction. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@123323 91177308-0d34-0410-b5e6-96231b3b80d8 --- diff --git a/include/llvm/CodeGen/SlotIndexes.h b/include/llvm/CodeGen/SlotIndexes.h index 312ce0380fe..1da1e91be14 100644 --- a/include/llvm/CodeGen/SlotIndexes.h +++ b/include/llvm/CodeGen/SlotIndexes.h @@ -625,6 +625,9 @@ namespace llvm { SlotIndex insertMachineInstrInMaps(MachineInstr *mi, bool *deferredRenumber = 0) { assert(mi2iMap.find(mi) == mi2iMap.end() && "Instr already indexed."); + // Numbering DBG_VALUE instructions could cause code generation to be + // affected by debug information. + assert(!mi->isDebugValue() && "Cannot number DBG_VALUE instructions."); MachineBasicBlock *mbb = mi->getParent();