DIEInfo Struct Reference#
|
ROCprofiler-SDK developer API 1.0.0
ROCm Profiling API and tools
|
Extracts inlined function call stack information for a given address. More...
#include <rocprofiler-sdk/cxx/codeobj/code_printing.hpp>
Collaboration diagram for rocprofiler::sdk::codeobj::disassembly::DIEInfo:Public Member Functions | |
| DIEInfo (Dwarf_Die *die) | |
| bool | getCallStackRecursive (Dwarf_Addr addr, std::vector< std::string > &call_stack) |
| Recursively traverses all children DIEInfos to find inlined functions at a specific address. | |
| void | addRange (const DRange &range) |
Data Fields | |
| std::vector< DRange > | all_ranges {} |
| std::vector< std::unique_ptr< DIEInfo > > | children {} |
| DRange | total_range {} |
| DRange | children_range {} |
| std::string | file_and_line {} |
Detailed Description
Extracts inlined function call stack information for a given address.
This struct is used to recursively search through DWARF debug information to find all inlined functions that contain the specified address, building a complete call stack from the outermost function down to the innermost inlined function.
Definition at line 79 of file code_printing.hpp.
Constructor & Destructor Documentation
◆ DIEInfo()
|
inline |
Definition at line 526 of file code_printing.hpp.
Member Function Documentation
◆ addRange()
|
inline |
Definition at line 130 of file code_printing.hpp.
◆ getCallStackRecursive()
|
inline |
Recursively traverses all children DIEInfos to find inlined functions at a specific address.
This function performs a depth-first traversal of the DWARF debug information tree, checking each DIE for inlined function information that covers the specified address. It processes both the current DIE and all its children (including siblings at each level) to ensure comprehensive coverage of all possible inlined function contexts.
The traversal is necessary because inlined functions can be nested (function A inlines function B which inlines function C) and multiple inlined functions can exist at the same scope level as siblings in the DWARF tree.
- Parameters
-
addr The address to search for inlined function information call_stack Reference to vector that accumulates the call stack information
- Returns
- True if either this instance or one of the children added an entry to the stack
Definition at line 598 of file code_printing.hpp.
Field Documentation
◆ all_ranges
| std::vector<DRange> rocprofiler::sdk::codeobj::disassembly::DIEInfo::all_ranges {} |
Definition at line 120 of file code_printing.hpp.
◆ children
| std::vector<std::unique_ptr<DIEInfo> > rocprofiler::sdk::codeobj::disassembly::DIEInfo::children {} |
Definition at line 121 of file code_printing.hpp.
◆ children_range
| DRange rocprofiler::sdk::codeobj::disassembly::DIEInfo::children_range {} |
Definition at line 126 of file code_printing.hpp.
◆ file_and_line
| std::string rocprofiler::sdk::codeobj::disassembly::DIEInfo::file_and_line {} |
Definition at line 128 of file code_printing.hpp.
◆ total_range
| DRange rocprofiler::sdk::codeobj::disassembly::DIEInfo::total_range {} |
Definition at line 124 of file code_printing.hpp.
The documentation for this struct was generated from the following file:
- rocprofiler-sdk/cxx/codeobj/code_printing.hpp
Generated by