It would be great to have the following features added to Divan. If you have ideas to expand this list, please find or create a discussion first.
-
Async benchmarks
-
Baseline benchmark
- Should match baselines across equal generic types and constants
- Idea:
#[divan::bench] fn old() { ... } #[divan::bench(baseline = old)] fn new() { ... }
-
Cross-device: run benchmarks on other devices and report the data on the local device
-
HTML output
-
CSV output
-
Custom counters
-
Time complexity of counters
- Also space complexity when measuring heap allocation
-
Measure heap allocations
- Custom
GlobalAllocthat wraps anotherGlobalAlloc, defaulting toSystem
- Custom
-
Custom timers
-
Timer for kernel/user mode
- Unix:
getrusage(2)- Per-thread:
- Linux/FreeBSD/OpenBSD:
RUSAGE_THREAD - macOS/iOS:
thread_info(mach_thread_self(), ...)
- Linux/FreeBSD/OpenBSD:
- Windows:
- Unix: