summaryrefslogtreecommitdiff
path: root/lib/DebugInfo/DWARFDebugInfoEntry.h
diff options
context:
space:
mode:
authorAlexey Samsonov <samsonov@google.com>2012-07-17 15:28:35 +0000
committerAlexey Samsonov <samsonov@google.com>2012-07-17 15:28:35 +0000
commit9d26b0ba06479d9debadebce19344169f72407dd (patch)
tree45245cc51de114c3919becf1b93ac1447d8483c1 /lib/DebugInfo/DWARFDebugInfoEntry.h
parent4f0c69623c10a3a49f6926fd53694ee532e06a85 (diff)
downloadllvm-9d26b0ba06479d9debadebce19344169f72407dd.tar.gz
llvm-9d26b0ba06479d9debadebce19344169f72407dd.tar.bz2
llvm-9d26b0ba06479d9debadebce19344169f72407dd.tar.xz
Improve behavior of DebugInfoEntryMinimal::getSubprogramName() introduced in r159512.
To fetch a subprogram name we should not only inspect the DIE for this subprogram, but optionally inspect its specification, or its abstract origin (even if there is no inlining), or even specification of an abstract origin. Reviewed by Benjamin Kramer. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@160365 91177308-0d34-0410-b5e6-96231b3b80d8
Diffstat (limited to 'lib/DebugInfo/DWARFDebugInfoEntry.h')
-rw-r--r--lib/DebugInfo/DWARFDebugInfoEntry.h6
1 files changed, 4 insertions, 2 deletions
diff --git a/lib/DebugInfo/DWARFDebugInfoEntry.h b/lib/DebugInfo/DWARFDebugInfoEntry.h
index 1a040a53a3..d5d86b9ec0 100644
--- a/lib/DebugInfo/DWARFDebugInfoEntry.h
+++ b/lib/DebugInfo/DWARFDebugInfoEntry.h
@@ -132,8 +132,10 @@ public:
bool addressRangeContainsAddress(const DWARFCompileUnit *cu,
const uint64_t address) const;
- // If a DIE represents a subroutine, returns its mangled name
- // (or short name, if mangled is missing). Otherwise returns null.
+ // If a DIE represents a subprogram, returns its mangled name
+ // (or short name, if mangled is missing). This name may be fetched
+ // from specification or abstract origin for this subprogram.
+ // Returns null if no name is found.
const char* getSubprogramName(const DWARFCompileUnit *cu) const;
};