Debug info: Fix PR22296 by omitting the DW_AT_location if we lost the
authorAdrian Prantl <aprantl@apple.com>
Sun, 25 Jan 2015 19:04:08 +0000 (19:04 +0000)
committerAdrian Prantl <aprantl@apple.com>
Sun, 25 Jan 2015 19:04:08 +0000 (19:04 +0000)
commit40cb819c6f23cf58416798e3f39136b39a33f8e6
tree45057d91dd65c0f2aa947f76d4243509be7ced11
parent258ac3cc56a70ec9629aa9f2c38d75e9d97ec447
Debug info: Fix PR22296 by omitting the DW_AT_location if we lost the
physical register that is described in a DBG_VALUE.

In the testcase the DBG_VALUE describing "p5" becomes unavailable
because the register its address is in is clobbered and we (currently)
aren't smart enough to realize that the value is rematerialized immediately
after the DBG_VALUE and/or is actually a stack slot.

llvm-svn: 227056
llvm/lib/CodeGen/AsmPrinter/DwarfCompileUnit.cpp
llvm/lib/CodeGen/AsmPrinter/DwarfExpression.cpp
llvm/test/DebugInfo/X86/nophysreg.ll [new file with mode: 0644]