class
debugcontains some debug information, such as trace information, as well as utilities to debug.
types
classes
static member functions
Function documentation
static std::vector<trace_ info> utility:: debug:: trace(size_t offset = 0u,
size_t depth = 255u,
std::optional<std::thread::id> id = std::nullopt)
Brief
method to get trace information of the current callstack.
Parameters | |
---|---|
offset in | what height of the callstack to start from (0 being the bottom, not root of the callstack). |
depth in | how far up should we get information from (i.e. a depth of 1 would only get the current information, while 255 would likely get you to the root). |
id | |
Returns | an std::vector containing a struct of trace_ |
static std::vector<void*> utility:: debug:: raw_trace(size_t offset = 0u,
size_t depth = 255u)
Brief
method to get raw trace information of the current callstack.
Parameters | |
---|---|
offset in | what height of the callstack to start from (0 being the bottom, not root of the callstack). |
depth in | how far up should we get information from (i.e. a depth of 1 would only get the current information, while 255 would likely get you to the root). |
Returns | an std::vector containing void pointers pointing to the address of the current callstack (excluding this method). |
static void utility:: debug:: register_thread(const std::thread::id& id,
const psl:: string8_t& name)
Brief
helper method to give a name to a specific thread.
Parameters | |
---|---|
id in | thread::id that will be named. |
name in | the name to assign to the given thread::id. |
static void utility:: debug:: register_thread(const psl:: string8_t& name)
Brief
helper method to name the current (this) thread.
Parameters | |
---|---|
name in | the name to assign to std::this_thread. |
static const psl:: string8_t utility:: debug:: thread_name(const std::thread::id& id)
Brief
gets the name of the given thread::id.
Parameters | |
---|---|
id in | the id of the thread to look up. |
Returns | the name (if any) that is assigned to the given thread::id. |
static const psl:: string8_t utility:: debug:: thread_name()
Brief
gets the name of the current (this) thread.
Returns | the name (if any) that is assigned to the current thread. |
---|
static const psl:: string8_t utility:: debug:: func_to_class(const char* fullFuncName)
Brief
helper method to extract just the class from a trace.
Parameters | |
---|---|
fullFuncName in | the signature of the trace. |
Returns | the class name. |