From 4156756a4f9f1dd160a6eca67dc8458562b450f2 Mon Sep 17 00:00:00 2001 From: Jonathan Flueren Date: Sat, 4 Jun 2022 13:51:32 +0200 Subject: [PATCH] flamegraph analysis --- .gitignore | 2 ++ README.md | 6 ++++++ src/main.rs | 2 +- 3 files changed, 9 insertions(+), 1 deletion(-) diff --git a/.gitignore b/.gitignore index a6ff48c..80942b8 100644 --- a/.gitignore +++ b/.gitignore @@ -1,2 +1,4 @@ /target *.ppm +flamegraph.svg +perf.data* \ No newline at end of file diff --git a/README.md b/README.md index d90402a..2f4d805 100644 --- a/README.md +++ b/README.md @@ -1 +1,7 @@ # Renderer - Grafik-AG + +*** +### Performance analysis with Flamegraph +https://github.com/flamegraph-rs/flamegraph + +If installed (`cargo install flamegraph`), run `cargo-flamegraph flamegraph` and `firefox flamegraph.svg` afterwards. \ No newline at end of file diff --git a/src/main.rs b/src/main.rs index 2fb40dc..54d96b4 100644 --- a/src/main.rs +++ b/src/main.rs @@ -43,7 +43,7 @@ fn main() { let aspect_ratio = 16.0 / 9.0; let image_width = 1000; let image_height = (image_width as f64 / aspect_ratio) as u32; - let samples_per_pixel = 50_u32; + let samples_per_pixel = 100_u32; let max_depth = 50; // World