|
mlpack
master
|
Provides a backtrace. More...
Classes | |
| struct | Frames |
| Backtrace datastructure. More... | |
Public Member Functions | |
| Backtrace () | |
| Constructor initialize fields and call GetAddress to retrieve addresses for each frame of backtrace. More... | |
| std::string | ToString () |
| Returns string of backtrace. More... | |
Static Private Member Functions | |
| static void | DecodeAddress (long address) |
| Decodes file name, function & line number. More... | |
| static void | DemangleFunction () |
| Demangles function name. More... | |
| static void | GetAddress (int maxDepth) |
| Gets addresses of each called function from the stack. More... | |
Private Attributes | |
| struct mlpack::Backtrace::Frames | frame |
Static Private Attributes | |
| static std::vector< Frames > | stack |
| A vector for all the backtrace information. More... | |
Provides a backtrace.
The Backtrace class retrieve addresses of each called function from the stack and decode file name, function & line number. Retrieved information can be printed in form:
Backtrace is printed always when Log::Assert failed. An example is given below.
Definition at line 46 of file backtrace.hpp.
| mlpack::Backtrace::Backtrace | ( | ) |
Constructor initialize fields and call GetAddress to retrieve addresses for each frame of backtrace.
| maxDepth | Maximum depth of backtrace. Default 32 steps. |
|
staticprivate |
Decodes file name, function & line number.
| address | Address of traced frame. |
|
staticprivate |
Demangles function name.
|
staticprivate |
Gets addresses of each called function from the stack.
| maxDepth | Maximum depth of backtrace. Default 32 steps. |
| std::string mlpack::Backtrace::ToString | ( | ) |
Returns string of backtrace.
|
private |
|
staticprivate |
A vector for all the backtrace information.
Definition at line 91 of file backtrace.hpp.
1.8.11