diff options
author | Devang Patel <dpatel@apple.com> | 2010-05-07 23:19:07 +0000 |
---|---|---|
committer | Devang Patel <dpatel@apple.com> | 2010-05-07 23:19:07 +0000 |
commit | a49d8772902c2a72c298952f633ab4224cf33add (patch) | |
tree | c72952a7f66a18ca559a47e8ca9ebdff3523d990 /lib | |
parent | 09e7a1722afc554962053cf33f9a3c317ea7897f (diff) |
Remove DIGlobal.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@103325 91177308-0d34-0410-b5e6-96231b3b80d8
Diffstat (limited to 'lib')
-rw-r--r-- | lib/Analysis/DebugInfo.cpp | 28 | ||||
-rw-r--r-- | lib/CodeGen/AsmPrinter/DwarfDebug.cpp | 2 | ||||
-rw-r--r-- | lib/CodeGen/AsmPrinter/DwarfDebug.h | 2 |
3 files changed, 10 insertions, 22 deletions
diff --git a/lib/Analysis/DebugInfo.cpp b/lib/Analysis/DebugInfo.cpp index 7bbae59b87..717c7fb514 100644 --- a/lib/Analysis/DebugInfo.cpp +++ b/lib/Analysis/DebugInfo.cpp @@ -527,8 +527,8 @@ void DICompositeType::print(raw_ostream &OS) const { OS << " [" << A.getNumElements() << " elements]"; } -/// print - Print global. -void DIGlobal::print(raw_ostream &OS) const { +/// print - Print subprogram. +void DISubprogram::print(raw_ostream &OS) const { StringRef Res = getName(); if (!Res.empty()) OS << " [" << Res << "] "; @@ -546,14 +546,12 @@ void DIGlobal::print(raw_ostream &OS) const { if (isDefinition()) OS << " [def] "; - if (isGlobalVariable()) - DIGlobalVariable(DbgNode).print(OS); - OS << "\n"; } -/// print - Print subprogram. -void DISubprogram::print(raw_ostream &OS) const { +/// print - Print global variable. +void DIGlobalVariable::print(raw_ostream &OS) const { + OS << " ["; StringRef Res = getName(); if (!Res.empty()) OS << " [" << Res << "] "; @@ -571,14 +569,9 @@ void DISubprogram::print(raw_ostream &OS) const { if (isDefinition()) OS << " [def] "; - OS << "\n"; -} - -/// print - Print global variable. -void DIGlobalVariable::print(raw_ostream &OS) const { - OS << " ["; - getGlobal()->print(OS); - OS << "] "; + if (isGlobalVariable()) + DIGlobalVariable(DbgNode).print(OS); + OS << "]\n"; } /// print - Print variable. @@ -625,11 +618,6 @@ void DICompositeType::dump() const { print(dbgs()); dbgs() << '\n'; } -/// dump - Print global to dbgs() with a newline. -void DIGlobal::dump() const { - print(dbgs()); dbgs() << '\n'; -} - /// dump - Print subprogram to dbgs() with a newline. void DISubprogram::dump() const { print(dbgs()); dbgs() << '\n'; diff --git a/lib/CodeGen/AsmPrinter/DwarfDebug.cpp b/lib/CodeGen/AsmPrinter/DwarfDebug.cpp index 9e5472b2f9..e319c28932 100644 --- a/lib/CodeGen/AsmPrinter/DwarfDebug.cpp +++ b/lib/CodeGen/AsmPrinter/DwarfDebug.cpp @@ -462,7 +462,7 @@ void DwarfDebug::addSourceLine(DIE *Die, const DIVariable *V) { /// addSourceLine - Add location information to specified debug information /// entry. -void DwarfDebug::addSourceLine(DIE *Die, const DIGlobal *G) { +void DwarfDebug::addSourceLine(DIE *Die, const DIGlobalVariable *G) { // If there is no compile unit specified, don't add a line #. if (!G->getCompileUnit().Verify()) return; diff --git a/lib/CodeGen/AsmPrinter/DwarfDebug.h b/lib/CodeGen/AsmPrinter/DwarfDebug.h index 5915c6f66c..f3d64070f9 100644 --- a/lib/CodeGen/AsmPrinter/DwarfDebug.h +++ b/lib/CodeGen/AsmPrinter/DwarfDebug.h @@ -295,7 +295,7 @@ private: /// addSourceLine - Add location information to specified debug information /// entry. void addSourceLine(DIE *Die, const DIVariable *V); - void addSourceLine(DIE *Die, const DIGlobal *G); + void addSourceLine(DIE *Die, const DIGlobalVariable *G); void addSourceLine(DIE *Die, const DISubprogram *SP); void addSourceLine(DIE *Die, const DIType *Ty); void addSourceLine(DIE *Die, const DINameSpace *NS); |