diff options
author | Alexey Samsonov <samsonov@google.com> | 2012-07-17 15:28:35 +0000 |
---|---|---|
committer | Alexey Samsonov <samsonov@google.com> | 2012-07-17 15:28:35 +0000 |
commit | 9d26b0ba06479d9debadebce19344169f72407dd (patch) | |
tree | 45245cc51de114c3919becf1b93ac1447d8483c1 /lib/DebugInfo/DWARFDebugInfoEntry.h | |
parent | 4f0c69623c10a3a49f6926fd53694ee532e06a85 (diff) | |
download | external_llvm-9d26b0ba06479d9debadebce19344169f72407dd.zip external_llvm-9d26b0ba06479d9debadebce19344169f72407dd.tar.gz external_llvm-9d26b0ba06479d9debadebce19344169f72407dd.tar.bz2 |
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.h | 6 |
1 files changed, 4 insertions, 2 deletions
diff --git a/lib/DebugInfo/DWARFDebugInfoEntry.h b/lib/DebugInfo/DWARFDebugInfoEntry.h index 1a040a5..d5d86b9 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; }; |