[llvm-commits] [llvm] r98046 - /llvm/trunk/lib/CodeGen/AsmPrinter/DwarfDebug.cpp
Chris Lattner
sabre at nondot.org
Mon Mar 8 20:48:35 PST 2010
Author: lattner
Date: Mon Mar 8 22:48:35 2010
New Revision: 98046
URL: http://llvm.org/viewvc/llvm-project?rev=98046&view=rev
Log:
add some extra checks. I'm not sure why, but this does unbreak a
failure remaining on mainline.
Modified:
llvm/trunk/lib/CodeGen/AsmPrinter/DwarfDebug.cpp
Modified: llvm/trunk/lib/CodeGen/AsmPrinter/DwarfDebug.cpp
URL: http://llvm.org/viewvc/llvm-project/llvm/trunk/lib/CodeGen/AsmPrinter/DwarfDebug.cpp?rev=98046&r1=98045&r2=98046&view=diff
==============================================================================
--- llvm/trunk/lib/CodeGen/AsmPrinter/DwarfDebug.cpp (original)
+++ llvm/trunk/lib/CodeGen/AsmPrinter/DwarfDebug.cpp Mon Mar 8 22:48:35 2010
@@ -1365,6 +1365,7 @@
DIE *DwarfDebug::constructLexicalScopeDIE(DbgScope *Scope) {
MCSymbol *Start = Scope->getStartLabel();
MCSymbol *End = Scope->getEndLabel();
+ if (Start == 0) return 0;
assert(Start->isDefined() && "Invalid starting label for an inlined scope!");
assert(End->isDefined() && "Invalid end label for an inlined scope!");
@@ -1387,6 +1388,8 @@
DIE *DwarfDebug::constructInlinedScopeDIE(DbgScope *Scope) {
MCSymbol *StartLabel = Scope->getStartLabel();
MCSymbol *EndLabel = Scope->getEndLabel();
+ if (StartLabel == 0) return 0;
+
assert(StartLabel->isDefined() &&
"Invalid starting label for an inlined scope!");
assert(EndLabel->isDefined() &&
More information about the llvm-commits
mailing list