From 3c27f69b1352ed138e5a3b5ca708e098826043a9 Mon Sep 17 00:00:00 2001 From: denehoffman Date: Fri, 6 Dec 2024 17:56:32 -0500 Subject: [PATCH] feat: add perf commands to justfile --- .gitignore | 2 ++ .justfile | 14 ++++++++++++++ src/amplitudes/mod.rs | 1 + 3 files changed, 17 insertions(+) diff --git a/.gitignore b/.gitignore index a495fbb..680ee25 100644 --- a/.gitignore +++ b/.gitignore @@ -190,3 +190,5 @@ Cargo.lock # Others demos/ src/main.rs +*.perf.* +perf.* diff --git a/.justfile b/.justfile index e8f3033..fb68345 100644 --- a/.justfile +++ b/.justfile @@ -16,3 +16,17 @@ makedocs: odoc: firefox ./docs/build/html/index.html + +clean: + cargo clean + +profile: + RUSTFLAGS='-C force-frame-pointers=y' cargo build --profile perf + perf record -g target/perf/laddu + perf annotate -v --asm-raw --stdio + perf report -g graph,0.5,caller + +popen: + mv firefox.perf.data firefox.perf.data.old + perf script --input=perf.data -F +pid > firefox.perf.data + firefox https://profiler.firefox.com diff --git a/src/amplitudes/mod.rs b/src/amplitudes/mod.rs index 7a0df65..77a2153 100644 --- a/src/amplitudes/mod.rs +++ b/src/amplitudes/mod.rs @@ -782,3 +782,4 @@ mod tests { assert!(manager.register(amp2).is_err()); } } +