[llvm-branch-commits] [llvm-branch] r86262 - in /llvm/branches/Apple/Leela: lib/Analysis/DebugInfo.cpp lib/CodeGen/AsmPrinter/DwarfDebug.cpp test/DebugInfo/2009-11-06-NamelessGlobalVariable.ll
Devang Patel
dpatel at apple.com
Fri Nov 6 10:03:19 PST 2009
Author: dpatel
Date: Fri Nov 6 12:03:19 2009
New Revision: 86262
URL: http://llvm.org/viewvc/llvm-project?rev=86262&view=rev
Log:
Integrate r86259 from trunk.
Added:
llvm/branches/Apple/Leela/test/DebugInfo/2009-11-06-NamelessGlobalVariable.ll
- copied unchanged from r86259, llvm/trunk/test/DebugInfo/2009-11-06-NamelessGlobalVariable.ll
Modified:
llvm/branches/Apple/Leela/lib/Analysis/DebugInfo.cpp
llvm/branches/Apple/Leela/lib/CodeGen/AsmPrinter/DwarfDebug.cpp
Modified: llvm/branches/Apple/Leela/lib/Analysis/DebugInfo.cpp
URL: http://llvm.org/viewvc/llvm-project/llvm/branches/Apple/Leela/lib/Analysis/DebugInfo.cpp?rev=86262&r1=86261&r2=86262&view=diff
==============================================================================
--- llvm/branches/Apple/Leela/lib/Analysis/DebugInfo.cpp (original)
+++ llvm/branches/Apple/Leela/lib/Analysis/DebugInfo.cpp Fri Nov 6 12:03:19 2009
@@ -366,6 +366,9 @@
if (isNull())
return false;
+ if (!getDisplayName())
+ return false;
+
if (getContext().isNull())
return false;
Modified: llvm/branches/Apple/Leela/lib/CodeGen/AsmPrinter/DwarfDebug.cpp
URL: http://llvm.org/viewvc/llvm-project/llvm/branches/Apple/Leela/lib/CodeGen/AsmPrinter/DwarfDebug.cpp?rev=86262&r1=86261&r2=86262&view=diff
==============================================================================
--- llvm/branches/Apple/Leela/lib/CodeGen/AsmPrinter/DwarfDebug.cpp (original)
+++ llvm/branches/Apple/Leela/lib/CodeGen/AsmPrinter/DwarfDebug.cpp Fri Nov 6 12:03:19 2009
@@ -1098,8 +1098,8 @@
DIE *DwarfDebug::CreateGlobalVariableDIE(CompileUnit *DW_Unit,
const DIGlobalVariable &GV) {
// If the global variable was optmized out then no need to create debug info entry.
- if (!GV.getGlobal())
- return NULL;
+ if (!GV.getGlobal()) return NULL;
+ if (!GV.getDisplayName()) return NULL;
DIE *GVDie = new DIE(dwarf::DW_TAG_variable);
AddString(GVDie, dwarf::DW_AT_name, dwarf::DW_FORM_string,
More information about the llvm-branch-commits
mailing list