pub fn dump() -> StringExpand description
Dumps the profiler data as a JSON string.
This function exports all profiling data in a structured JSON format. The output includes timing information, thread identification, custom annotations, and special event types (transactions, commits).
§Returns
String- A pretty-printed JSON string containing all profiling data
§Examples
use altius_benchtools::profiler;
// ... perform profiling ...
let json_data = profiler::dump();
println!("Profile data: {}", json_data);§Output Format
The output JSON has the following structure:
{
"title": {},
"details": [
[
{
"type": "transaction",
"tx": "task_name",
"runtime": 1234567,
"start": 1000000,
"end": 2234567,
"status": "success",
"detail": { ... }
}
]
]
}