Rietveld Code Review Tool
Help | Bug tracker | Discussion group | Source code | Sign in
(275)

Unified Diff: lib/DebugInfo/DWARFContext.h

Issue 6500047: [DebugInfo] refactor getLineInfoForAddress (Closed) Base URL: https://llvm.org/svn/llvm-project/llvm/trunk/
Patch Set: z Created 12 years, 6 months ago
Use n/p to move between diff chunks; N/P to move between comments. Please Sign in to add in-line comments.
Jump to:
View side-by-side diff with in-line comments
Download patch
« no previous file with comments | « no previous file | lib/DebugInfo/DWARFContext.cpp » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: lib/DebugInfo/DWARFContext.h
===================================================================
--- lib/DebugInfo/DWARFContext.h (revision 162836)
+++ lib/DebugInfo/DWARFContext.h (working copy)
@@ -54,9 +54,6 @@
return &CUs[index];
}
- /// Return the compile unit that includes an offset (relative to .debug_info).
- DWARFCompileUnit *getCompileUnitForOffset(uint32_t offset);
-
/// Get a pointer to the parsed DebugAbbrev object.
const DWARFDebugAbbrev *getDebugAbbrev();
@@ -67,8 +64,8 @@
const DWARFDebugLine::LineTable *
getLineTableForCompileUnit(DWARFCompileUnit *cu);
- virtual DILineInfo getLineInfoForAddress(uint64_t address,
- DILineInfoSpecifier specifier = DILineInfoSpecifier());
+ virtual DILineInfo getLineInfoForAddress(uint64_t Address,
+ DILineInfoSpecifier Specifier = DILineInfoSpecifier());
bool isLittleEndian() const { return IsLittleEndian; }
@@ -82,9 +79,23 @@
static bool isSupportedVersion(unsigned version) {
return version == 2 || version == 3;
}
+private:
+ /// Return the compile unit that includes an offset (relative to .debug_info).
+ DWARFCompileUnit *getCompileUnitForOffset(uint32_t Offset);
+
+ /// Return the compile unit which contains instruction with provided
+ /// address.
+ DWARFCompileUnit *getCompileUnitForAddress(uint64_t Address);
+
+ /// Fetches filename, line and column number for given address and
+ /// compile unit. Returns true on success.
+ bool getFileLineInfoForCompileUnit(DWARFCompileUnit *CU,
+ uint64_t Address,
+ bool NeedsAbsoluteFilePath,
+ std::string &FileName,
+ uint32_t &Line, uint32_t &Column);
};
-
/// DWARFContextInMemory is the simplest possible implementation of a
/// DWARFContext. It assumes all content is available in memory and stores
/// pointers to it.
« no previous file with comments | « no previous file | lib/DebugInfo/DWARFContext.cpp » ('j') | no next file with comments »

Powered by Google App Engine
RSS Feeds Recent Issues | This issue
This is Rietveld f62528b