how run TritonVM profiler log?

⚓ Neptune    📅 2025-03-06    👤 marco    👁️ 95      

marco

https://github.com/TritonVM/triton-vm/blob/master/triton-vm/Cargo.toml#L63 has a profile features. Do you know how to turn on this flags?

🏷️ triton-vm

jfs    2025-03-06 👍 2 👎

In your Cargo.toml, use:

triton-vm = { version = "0.48.0", default-features = false }

Then, in your code, you can

triton_vm::profiler::start("Triton VM – Prove");
let (/* … */) = triton_vm::prove_program(/* … */)?;
let profile = triton_vm::profiler::finish();
println!("{profile}");

See also the documentation of the profiler and, for an example of how to use it, the run function of the Triton CLI.

1