From 8b9f40cc57519b55749412ac0bef8d2bb23d6fac Mon Sep 17 00:00:00 2001 From: Maksym Arutyunyan Date: Fri, 9 May 2025 17:30:03 +0200 Subject: [PATCH 01/37] ci: post only canbench summary as github comment --- scripts/ci_download_canbench_artifacts.sh | 30 +++++++++--------- scripts/ci_run_benchmark.sh | 38 +++++++++++------------ 2 files changed, 34 insertions(+), 34 deletions(-) diff --git a/scripts/ci_download_canbench_artifacts.sh b/scripts/ci_download_canbench_artifacts.sh index 6b5d2b46..d1ed554f 100644 --- a/scripts/ci_download_canbench_artifacts.sh +++ b/scripts/ci_download_canbench_artifacts.sh @@ -1,29 +1,29 @@ #!/usr/bin/env bash set -Eexuo pipefail -# Identifies the benchmarks provided in the artifacts and outputs them. +# Collects benchmark results from artifact files and outputs them as a JSON array +# to be used in a GitHub Actions matrix. json_array="[" -# Loop through each file with prefix "canbench_result_" in the current directory + +# Loop through each directory matching the prefix "canbench_result_" for file in canbench_result_*; do -if [ -e "$file" ]; then # Check if the file exists. - # Read the content of the file, escaping double quotes and adding escaped newlines - content=$(<"$file/$file" sed 's/"/\\"/g' | awk '{printf "%s\\n", $0}' | sed '$ s/\\n$//') + if [ -e "$file" ]; then + # Read the contents of the result file, escape double quotes, and format with escaped newlines + content=$(<"$file/$file" sed 's/"/\\"/g' | awk '{printf "%s\\n", $0}' | sed '$ s/\\n$//') - # Construct a JSON object for the current file with "title" and "result" keys - json_object="{\"title\":\"$file\",\"result\":\"$content\"}," + # Construct a JSON object for the current result + json_object="{\"title\":\"$file\",\"result\":\"$content\"}," - # Append the JSON object to the array string - json_array+="$json_object" -fi + # Append it to the array + json_array+="$json_object" + fi done -# Remove the trailing comma from the JSON array string +# Remove the trailing comma and close the JSON array json_array=${json_array%,} - -# Close the JSON array string json_array+="]" -# Output the benchmarks and PR number to be used by the next job. +# Output the benchmark matrix and PR number to be used by the next job echo "matrix={\"benchmark\": $json_array}" >> "$GITHUB_OUTPUT" -echo "pr_number=$(cat ./pr_number/pr_number)" >> "$GITHUB_OUTPUT" +echo "pr_number=$(cat ./pr_number/pr_number)" >> "$GITHUB_OUTPUT" \ No newline at end of file diff --git a/scripts/ci_run_benchmark.sh b/scripts/ci_run_benchmark.sh index 4e1c74cd..25f6d550 100644 --- a/scripts/ci_run_benchmark.sh +++ b/scripts/ci_run_benchmark.sh @@ -1,19 +1,19 @@ #!/usr/bin/env bash set -Eexuo pipefail -# Script that runs `canbench` at a given directory and outputs a comment -# that is intended to be posted on the pull request. +# This script runs `canbench` in a given directory and outputs a comment +# intended to be posted on the pull request. # Path to run `canbench` from. CANISTER_PATH=$1 -# The name of the job in CI +# The name of the CI job. CANBENCH_JOB_NAME=$2 -# Must match the file specified in the github action. +# Must match the file path specified in the GitHub Action. COMMENT_MESSAGE_PATH=/tmp/canbench_result_${CANBENCH_JOB_NAME} -# Github CI is expected to have the main branch checked out in this folder. +# GitHub CI is expected to have the main branch checked out in this folder. MAIN_BRANCH_DIR=_canbench_main_branch CANBENCH_OUTPUT=/tmp/canbench_output.txt @@ -24,25 +24,25 @@ MAIN_BRANCH_RESULTS_FILE="$MAIN_BRANCH_DIR/$CANBENCH_RESULTS_FILE" # Install canbench cargo install canbench -# Verify that canbench results are available. +# Verify that the canbench results file exists. if [ ! -f "$CANBENCH_RESULTS_FILE" ]; then - echo "$CANBENCH_RESULTS_FILE not found. Did you forget to run \`canbench --persist\`?"; + echo "$CANBENCH_RESULTS_FILE not found. Did you forget to run \`canbench --persist\`?" exit 1 fi -# Detect if canbench results file is up to date. +# Check if the canbench results file is up to date. pushd "$CANISTER_PATH" -canbench --less-verbose > $CANBENCH_OUTPUT +canbench --less-verbose --hide-results --show-summary > $CANBENCH_OUTPUT if grep -q "(regress\|(improved by \|(new)" "$CANBENCH_OUTPUT"; then UPDATED_MSG="**❌ \`$CANBENCH_RESULTS_FILE\` is not up to date** - If the performance change is expected, run \`canbench --persist\` to save the updated benchmark results."; + If the performance change is expected, run \`canbench --persist\` to update the benchmark results." - # canbench results file not up to date. Fail the job. + # Results are outdated; fail the job. echo "EXIT_STATUS=1" >> "$GITHUB_ENV" else UPDATED_MSG="**✅ \`$CANBENCH_RESULTS_FILE\` is up to date**"; - # canbench results file is up to date. The job succeeds. + # Results are up to date; job succeeds. echo "EXIT_STATUS=0" >> "$GITHUB_ENV" fi popd @@ -54,17 +54,17 @@ time=$(date -u +"%Y-%m-%d %H:%M:%S UTC") # Print output with correct formatting echo "# \`canbench\` 🏋 (dir: $CANISTER_PATH) $commit_hash $time" > "$COMMENT_MESSAGE_PATH" -# Detect if there are performance changes relative to the main branch. +# Check for performance changes relative to the main branch. if [ -f "$MAIN_BRANCH_RESULTS_FILE" ]; then - # Move the results of the main branch into the current branch. + # Replace the current results with the main branch results. mv "$MAIN_BRANCH_RESULTS_FILE" "$CANBENCH_RESULTS_FILE" - # Run canbench to compare result to main branch. + # Run canbench to compare results with the main branch. pushd "$CANISTER_PATH" - canbench --less-verbose > "$CANBENCH_OUTPUT" + canbench --less-verbose --show-summary > "$CANBENCH_OUTPUT" popd - # Add emojis for visualization (as of December 2024, Github does not support colored text) + # Append markers to individual benchmark results awk ' /\(improved / { print $0, "đŸŸĸ"; next } /\(regressed / { print $0, "🔴"; next } @@ -79,7 +79,7 @@ if [ -f "$MAIN_BRANCH_RESULTS_FILE" ]; then echo -e "${MESSAGE:-**â„šī¸ No significant performance changes detected 👍**}" >> "$COMMENT_MESSAGE_PATH" fi -## Add the output of canbench to the file. +# Append the update status and benchmark output to the comment. { echo "$UPDATED_MSG" echo "" @@ -89,4 +89,4 @@ fi } >> "$COMMENT_MESSAGE_PATH" # Output the comment to stdout. -cat "$COMMENT_MESSAGE_PATH" +cat "$COMMENT_MESSAGE_PATH" \ No newline at end of file From 20682c94531f1b767ad56da66ec60c8be056576d Mon Sep 17 00:00:00 2001 From: Maksym Arutyunyan Date: Fri, 9 May 2025 17:32:05 +0200 Subject: [PATCH 02/37] csv --- scripts/ci_run_benchmark.sh | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/scripts/ci_run_benchmark.sh b/scripts/ci_run_benchmark.sh index 25f6d550..3e467114 100644 --- a/scripts/ci_run_benchmark.sh +++ b/scripts/ci_run_benchmark.sh @@ -32,7 +32,7 @@ fi # Check if the canbench results file is up to date. pushd "$CANISTER_PATH" -canbench --less-verbose --hide-results --show-summary > $CANBENCH_OUTPUT +canbench --less-verbose --hide-results --show-summary --csv > $CANBENCH_OUTPUT if grep -q "(regress\|(improved by \|(new)" "$CANBENCH_OUTPUT"; then UPDATED_MSG="**❌ \`$CANBENCH_RESULTS_FILE\` is not up to date** If the performance change is expected, run \`canbench --persist\` to update the benchmark results." From 7c96a61acd0525565f9b6122b509b18df7483703 Mon Sep 17 00:00:00 2001 From: Maksym Arutyunyan Date: Fri, 9 May 2025 17:32:31 +0200 Subject: [PATCH 03/37] rm csv from benchmark run --- scripts/ci_run_benchmark.sh | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/scripts/ci_run_benchmark.sh b/scripts/ci_run_benchmark.sh index 3e467114..25f6d550 100644 --- a/scripts/ci_run_benchmark.sh +++ b/scripts/ci_run_benchmark.sh @@ -32,7 +32,7 @@ fi # Check if the canbench results file is up to date. pushd "$CANISTER_PATH" -canbench --less-verbose --hide-results --show-summary --csv > $CANBENCH_OUTPUT +canbench --less-verbose --hide-results --show-summary > $CANBENCH_OUTPUT if grep -q "(regress\|(improved by \|(new)" "$CANBENCH_OUTPUT"; then UPDATED_MSG="**❌ \`$CANBENCH_RESULTS_FILE\` is not up to date** If the performance change is expected, run \`canbench --persist\` to update the benchmark results." From 19688144398261e09249f0531259fa4e85c85dac Mon Sep 17 00:00:00 2001 From: Maksym Arutyunyan Date: Fri, 9 May 2025 17:33:12 +0200 Subject: [PATCH 04/37] canbench 0.1.12 --- Cargo.lock | 194 ++++++++++++++++++++++++++++++++++++++++++++--------- Cargo.toml | 2 +- 2 files changed, 162 insertions(+), 34 deletions(-) diff --git a/Cargo.lock b/Cargo.lock index f1286f1b..4ac83aed 100644 --- a/Cargo.lock +++ b/Cargo.lock @@ -26,8 +26,8 @@ version = "0.1.0" dependencies = [ "canbench-rs", "candid", - "ic-cdk", - "ic-cdk-macros", + "ic-cdk 0.12.1", + "ic-cdk-macros 0.8.4", "ic-stable-structures", "maplit", "serde", @@ -101,21 +101,21 @@ checksum = "1fd0f2584146f6f2ef48085050886acf353beff7305ebd1ae69500e27c67f64b" [[package]] name = "canbench-rs" -version = "0.1.7" +version = "0.1.12" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "e85a8f1ee95044a770b3d5166a12f55814283cb3aed71b81439dc59960ab76c1" +checksum = "f7e8af63a2bb70a1906ba8aa6f6990e48f14fdb028500e59062caf127fb200b9" dependencies = [ "canbench-rs-macros", "candid", - "ic-cdk", + "ic-cdk 0.18.0", "serde", ] [[package]] name = "canbench-rs-macros" -version = "0.1.7" +version = "0.1.12" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "37aa9dbb190b03569ab14aadf669884a331712d54462c5a6c5b86c9867fe4e65" +checksum = "dd4d630972468fcd844c0ce285d0f385fc925104e0f2cb38c9810c4d49259f9c" dependencies = [ "proc-macro2", "quote", @@ -124,9 +124,9 @@ dependencies = [ [[package]] name = "candid" -version = "0.10.3" +version = "0.10.13" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "182543fbc03b4ad0bfc384e6b68346e0b0aad0b11d075b71b4fcaa5d07f8862c" +checksum = "a253bab4a9be502c82332b60cbeee6202ad0692834efeec95fae9f29db33d692" dependencies = [ "anyhow", "binread", @@ -142,19 +142,19 @@ dependencies = [ "serde", "serde_bytes", "stacker", - "thiserror", + "thiserror 1.0.56", ] [[package]] name = "candid_derive" -version = "0.6.5" +version = "0.6.6" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "970c220da8aa2fa6f7ef5dbbf3ea5b620a59eb3ac107cfb95ae8c6eebdfb7a08" +checksum = "3de398570c386726e7a59d9887b68763c481477f9a043fb998a2e09d428df1a9" dependencies = [ "lazy_static", "proc-macro2", "quote", - "syn 2.0.48", + "syn 2.0.101", ] [[package]] @@ -265,6 +265,12 @@ dependencies = [ "wasi", ] +[[package]] +name = "heck" +version = "0.5.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "2304e00983f87ffb38b55b444b5e3b60a884b5d30c0fca7d82fe33449bbe55ea" + [[package]] name = "hex" version = "0.4.3" @@ -278,10 +284,27 @@ source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "9f3d204af0b11c45715169c997858edb58fa8407d08f4fae78a6b415dd39a362" dependencies = [ "candid", - "ic-cdk-macros", - "ic0", + "ic-cdk-macros 0.8.4", + "ic0 0.21.1", + "serde", + "serde_bytes", +] + +[[package]] +name = "ic-cdk" +version = "0.18.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "b11cc255410be6a7e47e1a756ea94c1f31a2397a79e696f6f7d207d5ebd3e144" +dependencies = [ + "candid", + "ic-cdk-macros 0.18.0", + "ic-error-types", + "ic-management-canister-types", + "ic0 0.24.0", "serde", "serde_bytes", + "slotmap", + "thiserror 2.0.12", ] [[package]] @@ -294,10 +317,46 @@ dependencies = [ "proc-macro2", "quote", "serde", - "serde_tokenstream", + "serde_tokenstream 0.1.7", "syn 1.0.109", ] +[[package]] +name = "ic-cdk-macros" +version = "0.18.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "30bab0b748bc4059f19abbd2c2609761ca6d6c731979f01148b49afcc4fe7a9f" +dependencies = [ + "candid", + "proc-macro2", + "quote", + "serde", + "serde_tokenstream 0.2.2", + "syn 2.0.101", +] + +[[package]] +name = "ic-error-types" +version = "0.1.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "be844216781d6f4a0853b5a8d63dee8d1b6ee0b9aef310d8c0cb82a6796d7072" +dependencies = [ + "serde", + "strum", + "strum_macros", +] + +[[package]] +name = "ic-management-canister-types" +version = "0.3.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "90253c6ac92f9a0b548a53a02c2d29dfa0f04a6c1ae919b86a6f54d4767d78b9" +dependencies = [ + "candid", + "serde", + "serde_bytes", +] + [[package]] name = "ic-stable-structures" version = "0.6.8" @@ -305,8 +364,8 @@ dependencies = [ "canbench-rs", "candid", "hex", - "ic-cdk", - "ic-cdk-macros", + "ic-cdk 0.12.1", + "ic-cdk-macros 0.8.4", "ic_principal", "maplit", "proptest", @@ -320,6 +379,12 @@ version = "0.21.1" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "a54b5297861c651551676e8c43df805dad175cc33bc97dbd992edbbb85dcbcdf" +[[package]] +name = "ic0" +version = "0.24.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "673a6b846467547f3fc61f95d246aadff03e368b53c931655300b9d1bd05a55a" + [[package]] name = "ic_principal" version = "0.1.1" @@ -330,7 +395,7 @@ dependencies = [ "data-encoding", "serde", "sha2", - "thiserror", + "thiserror 1.0.56", ] [[package]] @@ -426,9 +491,9 @@ dependencies = [ [[package]] name = "proc-macro2" -version = "1.0.78" +version = "1.0.95" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "e2422ad645d89c99f8f3e6b88a9fdeca7fabeac836b1002371c4367c8f984aae" +checksum = "02b3e5e68a3a1a02aad3ec490a98007cbc13c37cbe84a3cd7b8e406d76e7f778" dependencies = [ "unicode-ident", ] @@ -564,9 +629,9 @@ dependencies = [ [[package]] name = "serde" -version = "1.0.195" +version = "1.0.219" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "63261df402c67811e9ac6def069e4786148c4563f4b50fd4bf30aa370d626b02" +checksum = "5f0e2c6ed6606019b4e29e69dbaba95b11854410e5347d525002456dbbb786b6" dependencies = [ "serde_derive", ] @@ -582,13 +647,13 @@ dependencies = [ [[package]] name = "serde_derive" -version = "1.0.195" +version = "1.0.219" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "46fe8f8603d81ba86327b23a2e9cdf49e1255fb94a4c5f297f6ee0547178ea2c" +checksum = "5b0276cf7f2c73365f7157c8123c21cd9a50fbbd844757af28ca1f5925fc2a00" dependencies = [ "proc-macro2", "quote", - "syn 2.0.48", + "syn 2.0.101", ] [[package]] @@ -602,6 +667,18 @@ dependencies = [ "syn 1.0.109", ] +[[package]] +name = "serde_tokenstream" +version = "0.2.2" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "64060d864397305347a78851c51588fd283767e7e7589829e8121d65512340f1" +dependencies = [ + "proc-macro2", + "quote", + "serde", + "syn 2.0.101", +] + [[package]] name = "sha2" version = "0.10.8" @@ -613,6 +690,15 @@ dependencies = [ "digest", ] +[[package]] +name = "slotmap" +version = "1.0.7" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "dbff4acf519f630b3a3ddcfaea6c06b42174d9a44bc70c620e9ed1649d58b82a" +dependencies = [ + "version_check", +] + [[package]] name = "stacker" version = "0.1.15" @@ -635,7 +721,7 @@ dependencies = [ "proc-macro2", "quote", "structmeta-derive", - "syn 2.0.48", + "syn 2.0.101", ] [[package]] @@ -646,7 +732,29 @@ checksum = "a60bcaff7397072dca0017d1db428e30d5002e00b6847703e2e42005c95fbe00" dependencies = [ "proc-macro2", "quote", - "syn 2.0.48", + "syn 2.0.101", +] + +[[package]] +name = "strum" +version = "0.26.3" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "8fec0f0aef304996cf250b31b5a10dee7980c85da9d759361292b8bca5a18f06" +dependencies = [ + "strum_macros", +] + +[[package]] +name = "strum_macros" +version = "0.26.4" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "4c6bee85a5a24955dc440386795aa378cd9cf82acd5f764469152d2270e581be" +dependencies = [ + "heck", + "proc-macro2", + "quote", + "rustversion", + "syn 2.0.101", ] [[package]] @@ -662,9 +770,9 @@ dependencies = [ [[package]] name = "syn" -version = "2.0.48" +version = "2.0.101" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "0f3531638e407dfc0814761abb7c00a5b54992b849452a0646b7f65c9f770f3f" +checksum = "8ce2b7fc941b3a24138a0a7cf8e858bfc6a992e7978a068a5c760deb0ed43caf" dependencies = [ "proc-macro2", "quote", @@ -693,7 +801,7 @@ dependencies = [ "proc-macro2", "quote", "structmeta", - "syn 2.0.48", + "syn 2.0.101", ] [[package]] @@ -702,7 +810,16 @@ version = "1.0.56" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "d54378c645627613241d077a3a79db965db602882668f9136ac42af9ecb730ad" dependencies = [ - "thiserror-impl", + "thiserror-impl 1.0.56", +] + +[[package]] +name = "thiserror" +version = "2.0.12" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "567b8a2dae586314f7be2a752ec7474332959c6460e02bde30d702a66d488708" +dependencies = [ + "thiserror-impl 2.0.12", ] [[package]] @@ -713,7 +830,18 @@ checksum = "fa0faa943b50f3db30a20aa7e265dbc66076993efed8463e8de414e5d06d3471" dependencies = [ "proc-macro2", "quote", - "syn 2.0.48", + "syn 2.0.101", +] + +[[package]] +name = "thiserror-impl" +version = "2.0.12" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "7f7cf42b4507d8ea322120659672cf1b9dbb93f8f2d4ecfd6e51350ff5b17a1d" +dependencies = [ + "proc-macro2", + "quote", + "syn 2.0.101", ] [[package]] diff --git a/Cargo.toml b/Cargo.toml index 7a4c0ab8..c9b6f79b 100644 --- a/Cargo.toml +++ b/Cargo.toml @@ -14,7 +14,7 @@ version = "0.6.8" [dependencies] ic_principal = { version = "0.1.1", default-features = false } # An optional dependency to benchmark parts of the code. -canbench-rs = { version = "0.1.7", optional = true } +canbench-rs = { version = "0.1.12", optional = true } [dev-dependencies] candid.workspace = true From 95a970a13f56ccad2a3b13c817c3a305c26c2428 Mon Sep 17 00:00:00 2001 From: Maksym Arutyunyan Date: Fri, 9 May 2025 17:41:58 +0200 Subject: [PATCH 05/37] persist --- canbench_results.csv | 125 +++++++++++++++++++++ canbench_results.yml | 252 +++++++++++++++++++++---------------------- 2 files changed, 251 insertions(+), 126 deletions(-) create mode 100644 canbench_results.csv diff --git a/canbench_results.csv b/canbench_results.csv new file mode 100644 index 00000000..265bc85f --- /dev/null +++ b/canbench_results.csv @@ -0,0 +1,125 @@ +status,name,instructions,instructions %,heap_increase,heap_increase %,stable_memory_increase,stable_memory_increase % +,btreemap_contains_key_blob_4_1024,164495877,-0.91%,0,,0, +,btreemap_contains_key_blob_4_1024_v2,248921977,0.94%,0,,0, +,btreemap_get_blob_128_1024,876676182,0.61%,0,,0, +,btreemap_get_blob_128_1024_v2,953199881,0.08%,0,,0, +,btreemap_get_blob_16_1024,241470994,-2.18%,0,,0, +,btreemap_get_blob_16_1024_v2,320086039,-0.87%,0,,0, +,btreemap_get_blob_256_1024,1440152578,0.12%,0,,0, +,btreemap_get_blob_256_1024_v2,1524516290,0.13%,0,,0, +,btreemap_get_blob_32_1024,275141698,-1.77%,0,,0, +,btreemap_get_blob_32_1024_v2,353756221,-1.20%,0,,0, +,btreemap_get_blob_4_1024,182139496,-0.95%,0,,0, +,btreemap_get_blob_4_1024_v2,267339946,-0.40%,0,,0, +,btreemap_get_blob_512_1024,2573387979,-0.02%,0,,0, +,btreemap_get_blob_512_1024_v2,2653499228,0.02%,0,,0, +,btreemap_get_blob_512_1024_v2_mem_manager,2759852247,0.03%,0,,0, +,btreemap_get_blob_64_1024,521344804,-0.21%,0,,0, +,btreemap_get_blob_64_1024_v2,603758767,0.21%,0,,0, +,btreemap_get_blob_8_1024,212618950,-2.20%,0,,0, +,btreemap_get_blob_8_1024_v2,294121282,-1.86%,0,,0, +,btreemap_get_blob_8_u64,199845052,-0.66%,0,,0, +,btreemap_get_blob_8_u64_v2,289664167,-2.82%,0,,0, +,btreemap_get_u64_blob_8,173627473,-1.15%,0,,0, +,btreemap_get_u64_blob_8_v2,245312213,-1.86%,0,,0, +,btreemap_get_u64_u64,176661272,0.17%,0,,0, +,btreemap_get_u64_u64_v2,249218649,-2.90%,0,,0, +,btreemap_get_u64_u64_v2_mem_manager,329730573,-1.92%,0,,0, +,btreemap_insert_10mib_values,5235962440,-0.07%,0,,3613,0.00% +,btreemap_insert_blob_1024_128,5098352751,-0.24%,0,,262,0.00% +,btreemap_insert_blob_1024_128_v2,5199218550,-0.05%,0,,196,0.00% +,btreemap_insert_blob_1024_16,5080607598,-0.64%,0,,241,0.00% +,btreemap_insert_blob_1024_16_v2,5187794378,-0.24%,0,,181,0.00% +,btreemap_insert_blob_1024_256,5125958119,-0.12%,0,,292,0.00% +,btreemap_insert_blob_1024_256_v2,5224501040,-0.02%,0,,219,0.00% +,btreemap_insert_blob_1024_32,5075547429,-0.41%,0,,239,0.00% +,btreemap_insert_blob_1024_32_v2,5185065640,-0.19%,0,,180,0.00% +,btreemap_insert_blob_1024_4,4977775085,-0.83%,0,,235,0.00% +,btreemap_insert_blob_1024_4_v2,5084891041,-0.26%,0,,176,0.00% +,btreemap_insert_blob_1024_512,5200292029,-0.12%,1,,348,0.00% +,btreemap_insert_blob_1024_512_v2,5299421985,-0.12%,0,,261,0.00% +,btreemap_insert_blob_1024_512_v2_mem_manager,5469551996,-0.10%,0,,256,0.00% +,btreemap_insert_blob_1024_64,5133691382,-0.32%,0,,250,0.00% +,btreemap_insert_blob_1024_64_v2,5242140512,-0.13%,0,,188,0.00% +,btreemap_insert_blob_1024_8,5065686056,-0.39%,0,,237,0.00% +,btreemap_insert_blob_1024_8_v2,5174504738,-0.25%,0,,178,0.00% +,btreemap_insert_blob_128_1024,1276472811,0.25%,0,,260,0.00% +,btreemap_insert_blob_128_1024_v2,1378788105,0.40%,0,,195,0.00% +,btreemap_insert_blob_16_1024,634307113,-0.55%,0,,215,0.00% +,btreemap_insert_blob_16_1024_v2,733723555,0.17%,0,,161,0.00% +,btreemap_insert_blob_256_1024,1860540926,0.04%,0,,292,0.00% +,btreemap_insert_blob_256_1024_v2,1967548428,0.50%,0,,219,0.00% +,btreemap_insert_blob_32_1024,670121076,-0.41%,0,,230,0.00% +,btreemap_insert_blob_32_1024_v2,773022814,0.37%,0,,173,0.00% +,btreemap_insert_blob_4_1024,494994994,-0.46%,0,,123,0.00% +,btreemap_insert_blob_4_1024_v2,592951465,-0.15%,0,,92,0.00% +,btreemap_insert_blob_512_1024,3002862489,-0.26%,0,,351,0.00% +,btreemap_insert_blob_512_1024_v2,3105965075,0.04%,0,,263,0.00% +,btreemap_insert_blob_64_1024,919414593,-0.06%,0,,245,0.00% +,btreemap_insert_blob_64_1024_v2,1020998986,0.50%,0,,183,0.00% +,btreemap_insert_blob_8_1024,605636927,-0.36%,0,,183,0.00% +,btreemap_insert_blob_8_1024_v2,708696031,-0.12%,0,,138,0.00% +,btreemap_insert_blob_8_u64,330055088,-0.07%,0,,6,0.00% +,btreemap_insert_blob_8_u64_v2,440988930,-0.03%,0,,4,0.00% +,btreemap_insert_u64_blob_8,339864719,-0.02%,0,,7,0.00% +,btreemap_insert_u64_blob_8_v2,422835585,0.60%,0,,5,0.00% +,btreemap_insert_u64_u64,345025209,-0.13%,0,,7,0.00% +,btreemap_insert_u64_u64_v2,431645530,0.64%,0,,6,0.00% +,btreemap_insert_u64_u64_v2_mem_manager,560976863,0.51%,0,,0, +,btreemap_iter_10mib_values,11407368,-0.00%,0,,0, +,btreemap_iter_count_10mib_values,491365,2.95%,0,,0, +,btreemap_iter_count_small_values,9443266,0.01%,0,,0, +,btreemap_iter_rev_10mib_values,11404353,-0.00%,0,,0, +,btreemap_iter_rev_small_values,14975879,0.00%,0,,0, +,btreemap_iter_small_values,15000850,0.15%,0,,0, +,btreemap_keys_10mib_values,464540,-0.09%,0,,0, +,btreemap_keys_rev_10mib_values,464165,-0.09%,0,,0, +,btreemap_keys_rev_small_values,9654062,-0.20%,0,,0, +,btreemap_keys_small_values,9528327,0.02%,0,,0, +,btreemap_read_every_third_value_from_range,84833060,0.78%,0,,0, +,btreemap_read_keys_from_range,84873064,0.78%,0,,0, +,btreemap_remove_blob_128_1024,1575050534,0.02%,0,,0, +,btreemap_remove_blob_128_1024_v2,1721504123,0.22%,0,,0, +,btreemap_remove_blob_16_1024,755252791,-0.38%,0,,0, +,btreemap_remove_blob_16_1024_v2,895690307,-0.03%,0,,0, +,btreemap_remove_blob_256_1024,2279810995,0.03%,0,,0, +,btreemap_remove_blob_256_1024_v2,2427184450,0.38%,0,,0, +,btreemap_remove_blob_32_1024,825632231,-0.24%,0,,0, +,btreemap_remove_blob_32_1024_v2,965884147,-0.09%,0,,0, +,btreemap_remove_blob_4_1024,485805538,-0.14%,0,,0, +,btreemap_remove_blob_4_1024_v2,600161724,0.01%,0,,0, +,btreemap_remove_blob_512_1024,3738145419,-0.29%,0,,0, +,btreemap_remove_blob_512_1024_v2,3883681704,0.14%,0,,0, +,btreemap_remove_blob_64_1024,1139970828,-0.09%,0,,0, +,btreemap_remove_blob_64_1024_v2,1283145072,0.17%,0,,0, +,btreemap_remove_blob_8_1024,642836148,-0.29%,0,,0, +,btreemap_remove_blob_8_1024_v2,775037862,-0.22%,0,,0, +,btreemap_remove_blob_8_u64,433944769,-0.25%,0,,0, +,btreemap_remove_blob_8_u64_v2,579958230,-0.70%,0,,0, +,btreemap_remove_u64_blob_8,485913516,0.03%,0,,0, +,btreemap_remove_u64_blob_8_v2,597538858,-0.58%,0,,0, +,btreemap_remove_u64_u64,499266505,0.07%,0,,0, +,btreemap_remove_u64_u64_v2,619109964,-0.70%,0,,0, +,btreemap_values_10mib_values,11406848,-0.00%,0,,0, +,btreemap_values_rev_10mib_values,11403833,-0.00%,0,,0, +,btreemap_values_rev_small_values,14949875,0.00%,0,,0, +,btreemap_values_small_values,14974846,0.15%,0,,0, +,memory_manager_baseline,1176577076,0.00%,0,,8000,0.00% +,memory_manager_grow,346537961,-0.02%,2,0.00%,32000,0.00% +,memory_manager_overhead,1181962837,0.00%,0,,8320,0.00% +,vec_get_blob_128,19246658,-0.31%,0,,0, +,vec_get_blob_16,6345942,-0.88%,0,,0, +,vec_get_blob_32,7063501,-0.82%,0,,0, +,vec_get_blob_4,4804323,-0.93%,0,,0, +,vec_get_blob_4_mem_manager,7171673,-0.63%,0,,0, +,vec_get_blob_64,11310940,-0.52%,0,,0, +,vec_get_blob_64_mem_manager,13651088,-0.43%,0,,0, +,vec_get_blob_8,5620865,-0.93%,0,,0, +,vec_get_u64,5270302,-1.13%,0,,0, +,vec_insert_blob_128,4131421,-0.48%,0,,19,0.00% +,vec_insert_blob_16,3296224,-0.60%,0,,2,0.00% +,vec_insert_blob_32,3415464,-0.58%,0,,5,0.00% +,vec_insert_blob_4,3207465,-0.62%,0,,0, +,vec_insert_blob_64,3655801,-0.54%,0,,9,0.00% +,vec_insert_blob_8,3236886,-0.61%,0,,1,0.00% +,vec_insert_u64,5859516,-1.18%,0,,1,0.00% diff --git a/canbench_results.yml b/canbench_results.yml index fd1265e1..855a6a71 100644 --- a/canbench_results.yml +++ b/canbench_results.yml @@ -1,746 +1,746 @@ benches: btreemap_contains_key_blob_4_1024: total: - instructions: 166001914 + instructions: 164495877 heap_increase: 0 stable_memory_increase: 0 scopes: {} btreemap_contains_key_blob_4_1024_v2: total: - instructions: 246601950 + instructions: 248921977 heap_increase: 0 stable_memory_increase: 0 scopes: {} btreemap_get_blob_128_1024: total: - instructions: 871377876 + instructions: 876676182 heap_increase: 0 stable_memory_increase: 0 scopes: {} btreemap_get_blob_128_1024_v2: total: - instructions: 952392232 + instructions: 953199881 heap_increase: 0 stable_memory_increase: 0 scopes: {} btreemap_get_blob_16_1024: total: - instructions: 246862999 + instructions: 241470994 heap_increase: 0 stable_memory_increase: 0 scopes: {} btreemap_get_blob_16_1024_v2: total: - instructions: 322886246 + instructions: 320086039 heap_increase: 0 stable_memory_increase: 0 scopes: {} btreemap_get_blob_256_1024: total: - instructions: 1438374032 + instructions: 1440152578 heap_increase: 0 stable_memory_increase: 0 scopes: {} btreemap_get_blob_256_1024_v2: total: - instructions: 1522510073 + instructions: 1524516290 heap_increase: 0 stable_memory_increase: 0 scopes: {} btreemap_get_blob_32_1024: total: - instructions: 280106753 + instructions: 275141698 heap_increase: 0 stable_memory_increase: 0 scopes: {} btreemap_get_blob_32_1024_v2: total: - instructions: 358059333 + instructions: 353756221 heap_increase: 0 stable_memory_increase: 0 scopes: {} btreemap_get_blob_4_1024: total: - instructions: 183878301 + instructions: 182139496 heap_increase: 0 stable_memory_increase: 0 scopes: {} btreemap_get_blob_4_1024_v2: total: - instructions: 268405509 + instructions: 267339946 heap_increase: 0 stable_memory_increase: 0 scopes: {} btreemap_get_blob_512_1024: total: - instructions: 2574022258 + instructions: 2573387979 heap_increase: 0 stable_memory_increase: 0 scopes: {} btreemap_get_blob_512_1024_v2: total: - instructions: 2652896326 + instructions: 2653499228 heap_increase: 0 stable_memory_increase: 0 scopes: {} btreemap_get_blob_512_1024_v2_mem_manager: total: - instructions: 2758935791 + instructions: 2759852247 heap_increase: 0 stable_memory_increase: 0 scopes: {} btreemap_get_blob_64_1024: total: - instructions: 522452995 + instructions: 521344804 heap_increase: 0 stable_memory_increase: 0 scopes: {} btreemap_get_blob_64_1024_v2: total: - instructions: 602470701 + instructions: 603758767 heap_increase: 0 stable_memory_increase: 0 scopes: {} btreemap_get_blob_8_1024: total: - instructions: 217400958 + instructions: 212618950 heap_increase: 0 stable_memory_increase: 0 scopes: {} btreemap_get_blob_8_1024_v2: total: - instructions: 299709230 + instructions: 294121282 heap_increase: 0 stable_memory_increase: 0 scopes: {} btreemap_get_blob_8_u64: total: - instructions: 201178258 + instructions: 199845052 heap_increase: 0 stable_memory_increase: 0 scopes: {} btreemap_get_blob_8_u64_v2: total: - instructions: 298067608 + instructions: 289664167 heap_increase: 0 stable_memory_increase: 0 scopes: {} btreemap_get_u64_blob_8: total: - instructions: 175651041 + instructions: 173627473 heap_increase: 0 stable_memory_increase: 0 scopes: {} btreemap_get_u64_blob_8_v2: total: - instructions: 249967569 + instructions: 245312213 heap_increase: 0 stable_memory_increase: 0 scopes: {} btreemap_get_u64_u64: total: - instructions: 176359016 + instructions: 176661272 heap_increase: 0 stable_memory_increase: 0 scopes: {} btreemap_get_u64_u64_v2: total: - instructions: 256656270 + instructions: 249218649 heap_increase: 0 stable_memory_increase: 0 scopes: {} btreemap_get_u64_u64_v2_mem_manager: total: - instructions: 336179948 + instructions: 329730573 heap_increase: 0 stable_memory_increase: 0 scopes: {} btreemap_insert_10mib_values: total: - instructions: 5239421355 + instructions: 5235962440 heap_increase: 0 stable_memory_increase: 3613 scopes: {} btreemap_insert_blob_1024_128: total: - instructions: 5110664101 + instructions: 5098352751 heap_increase: 0 stable_memory_increase: 262 scopes: {} btreemap_insert_blob_1024_128_v2: total: - instructions: 5201936582 + instructions: 5199218550 heap_increase: 0 stable_memory_increase: 196 scopes: {} btreemap_insert_blob_1024_16: total: - instructions: 5113272660 + instructions: 5080607598 heap_increase: 0 stable_memory_increase: 241 scopes: {} btreemap_insert_blob_1024_16_v2: total: - instructions: 5200160649 + instructions: 5187794378 heap_increase: 0 stable_memory_increase: 181 scopes: {} btreemap_insert_blob_1024_256: total: - instructions: 5132006019 + instructions: 5125958119 heap_increase: 0 stable_memory_increase: 292 scopes: {} btreemap_insert_blob_1024_256_v2: total: - instructions: 5225716019 + instructions: 5224501040 heap_increase: 0 stable_memory_increase: 219 scopes: {} btreemap_insert_blob_1024_32: total: - instructions: 5096510160 + instructions: 5075547429 heap_increase: 0 stable_memory_increase: 239 scopes: {} btreemap_insert_blob_1024_32_v2: total: - instructions: 5194736210 + instructions: 5185065640 heap_increase: 0 stable_memory_increase: 180 scopes: {} btreemap_insert_blob_1024_4: total: - instructions: 5019310618 + instructions: 4977775085 heap_increase: 0 stable_memory_increase: 235 scopes: {} btreemap_insert_blob_1024_4_v2: total: - instructions: 5098222305 + instructions: 5084891041 heap_increase: 0 stable_memory_increase: 176 scopes: {} btreemap_insert_blob_1024_512: total: - instructions: 5206323531 - heap_increase: 0 + instructions: 5200292029 + heap_increase: 1 stable_memory_increase: 348 scopes: {} btreemap_insert_blob_1024_512_v2: total: - instructions: 5305867254 + instructions: 5299421985 heap_increase: 0 stable_memory_increase: 261 scopes: {} btreemap_insert_blob_1024_512_v2_mem_manager: total: - instructions: 5474908000 + instructions: 5469551996 heap_increase: 0 stable_memory_increase: 256 scopes: {} btreemap_insert_blob_1024_64: total: - instructions: 5150175789 + instructions: 5133691382 heap_increase: 0 stable_memory_increase: 250 scopes: {} btreemap_insert_blob_1024_64_v2: total: - instructions: 5249105297 + instructions: 5242140512 heap_increase: 0 stable_memory_increase: 188 scopes: {} btreemap_insert_blob_1024_8: total: - instructions: 5085348900 + instructions: 5065686056 heap_increase: 0 stable_memory_increase: 237 scopes: {} btreemap_insert_blob_1024_8_v2: total: - instructions: 5187558037 + instructions: 5174504738 heap_increase: 0 stable_memory_increase: 178 scopes: {} btreemap_insert_blob_128_1024: total: - instructions: 1273227463 + instructions: 1276472811 heap_increase: 0 stable_memory_increase: 260 scopes: {} btreemap_insert_blob_128_1024_v2: total: - instructions: 1373313309 + instructions: 1378788105 heap_increase: 0 stable_memory_increase: 195 scopes: {} btreemap_insert_blob_16_1024: total: - instructions: 637805470 + instructions: 634307113 heap_increase: 0 stable_memory_increase: 215 scopes: {} btreemap_insert_blob_16_1024_v2: total: - instructions: 732455990 + instructions: 733723555 heap_increase: 0 stable_memory_increase: 161 scopes: {} btreemap_insert_blob_256_1024: total: - instructions: 1859840193 + instructions: 1860540926 heap_increase: 0 stable_memory_increase: 292 scopes: {} btreemap_insert_blob_256_1024_v2: total: - instructions: 1957855803 + instructions: 1967548428 heap_increase: 0 stable_memory_increase: 219 scopes: {} btreemap_insert_blob_32_1024: total: - instructions: 672870979 + instructions: 670121076 heap_increase: 0 stable_memory_increase: 230 scopes: {} btreemap_insert_blob_32_1024_v2: total: - instructions: 770164792 + instructions: 773022814 heap_increase: 0 stable_memory_increase: 173 scopes: {} btreemap_insert_blob_4_1024: total: - instructions: 497280451 + instructions: 494994994 heap_increase: 0 stable_memory_increase: 123 scopes: {} btreemap_insert_blob_4_1024_v2: total: - instructions: 593852839 + instructions: 592951465 heap_increase: 0 stable_memory_increase: 92 scopes: {} btreemap_insert_blob_512_1024: total: - instructions: 3010795691 + instructions: 3002862489 heap_increase: 0 stable_memory_increase: 351 scopes: {} btreemap_insert_blob_512_1024_v2: total: - instructions: 3104696455 + instructions: 3105965075 heap_increase: 0 stable_memory_increase: 263 scopes: {} btreemap_insert_blob_64_1024: total: - instructions: 919935850 + instructions: 919414593 heap_increase: 0 stable_memory_increase: 245 scopes: {} btreemap_insert_blob_64_1024_v2: total: - instructions: 1015903332 + instructions: 1020998986 heap_increase: 0 stable_memory_increase: 183 scopes: {} btreemap_insert_blob_8_1024: total: - instructions: 607806777 + instructions: 605636927 heap_increase: 0 stable_memory_increase: 183 scopes: {} btreemap_insert_blob_8_1024_v2: total: - instructions: 709530767 + instructions: 708696031 heap_increase: 0 stable_memory_increase: 138 scopes: {} btreemap_insert_blob_8_u64: total: - instructions: 330300136 + instructions: 330055088 heap_increase: 0 stable_memory_increase: 6 scopes: {} btreemap_insert_blob_8_u64_v2: total: - instructions: 441129700 + instructions: 440988930 heap_increase: 0 stable_memory_increase: 4 scopes: {} btreemap_insert_u64_blob_8: total: - instructions: 339919034 + instructions: 339864719 heap_increase: 0 stable_memory_increase: 7 scopes: {} btreemap_insert_u64_blob_8_v2: total: - instructions: 420318618 + instructions: 422835585 heap_increase: 0 stable_memory_increase: 5 scopes: {} btreemap_insert_u64_u64: total: - instructions: 345460000 + instructions: 345025209 heap_increase: 0 stable_memory_increase: 7 scopes: {} btreemap_insert_u64_u64_v2: total: - instructions: 428895247 + instructions: 431645530 heap_increase: 0 stable_memory_increase: 6 scopes: {} btreemap_insert_u64_u64_v2_mem_manager: total: - instructions: 558130823 + instructions: 560976863 heap_increase: 0 stable_memory_increase: 0 scopes: {} btreemap_iter_10mib_values: total: - instructions: 11407378 + instructions: 11407368 heap_increase: 0 stable_memory_increase: 0 scopes: {} btreemap_iter_count_10mib_values: total: - instructions: 477294 + instructions: 491365 heap_increase: 0 stable_memory_increase: 0 scopes: {} btreemap_iter_count_small_values: total: - instructions: 9442536 + instructions: 9443266 heap_increase: 0 stable_memory_increase: 0 scopes: {} btreemap_iter_rev_10mib_values: total: - instructions: 11404381 + instructions: 11404353 heap_increase: 0 stable_memory_increase: 0 scopes: {} btreemap_iter_rev_small_values: total: - instructions: 14975521 + instructions: 14975879 heap_increase: 0 stable_memory_increase: 0 scopes: {} btreemap_iter_small_values: total: - instructions: 14978614 + instructions: 15000850 heap_increase: 0 stable_memory_increase: 0 scopes: {} btreemap_keys_10mib_values: total: - instructions: 464952 + instructions: 464540 heap_increase: 0 stable_memory_increase: 0 scopes: {} btreemap_keys_rev_10mib_values: total: - instructions: 464595 + instructions: 464165 heap_increase: 0 stable_memory_increase: 0 scopes: {} btreemap_keys_rev_small_values: total: - instructions: 9673706 + instructions: 9654062 heap_increase: 0 stable_memory_increase: 0 scopes: {} btreemap_keys_small_values: total: - instructions: 9526093 + instructions: 9528327 heap_increase: 0 stable_memory_increase: 0 scopes: {} btreemap_read_every_third_value_from_range: total: - instructions: 84178476 + instructions: 84833060 heap_increase: 0 stable_memory_increase: 0 scopes: {} btreemap_read_keys_from_range: total: - instructions: 84218480 + instructions: 84873064 heap_increase: 0 stable_memory_increase: 0 scopes: {} btreemap_remove_blob_128_1024: total: - instructions: 1574675940 + instructions: 1575050534 heap_increase: 0 stable_memory_increase: 0 scopes: {} btreemap_remove_blob_128_1024_v2: total: - instructions: 1717684218 + instructions: 1721504123 heap_increase: 0 stable_memory_increase: 0 scopes: {} btreemap_remove_blob_16_1024: total: - instructions: 758136944 + instructions: 755252791 heap_increase: 0 stable_memory_increase: 0 scopes: {} btreemap_remove_blob_16_1024_v2: total: - instructions: 895985762 + instructions: 895690307 heap_increase: 0 stable_memory_increase: 0 scopes: {} btreemap_remove_blob_256_1024: total: - instructions: 2279163553 + instructions: 2279810995 heap_increase: 0 stable_memory_increase: 0 scopes: {} btreemap_remove_blob_256_1024_v2: total: - instructions: 2417905594 + instructions: 2427184450 heap_increase: 0 stable_memory_increase: 0 scopes: {} btreemap_remove_blob_32_1024: total: - instructions: 827599093 + instructions: 825632231 heap_increase: 0 stable_memory_increase: 0 scopes: {} btreemap_remove_blob_32_1024_v2: total: - instructions: 966757633 + instructions: 965884147 heap_increase: 0 stable_memory_increase: 0 scopes: {} btreemap_remove_blob_4_1024: total: - instructions: 486469240 + instructions: 485805538 heap_increase: 0 stable_memory_increase: 0 scopes: {} btreemap_remove_blob_4_1024_v2: total: - instructions: 600093407 + instructions: 600161724 heap_increase: 0 stable_memory_increase: 0 scopes: {} btreemap_remove_blob_512_1024: total: - instructions: 3748993388 + instructions: 3738145419 heap_increase: 0 stable_memory_increase: 0 scopes: {} btreemap_remove_blob_512_1024_v2: total: - instructions: 3878241779 + instructions: 3883681704 heap_increase: 0 stable_memory_increase: 0 scopes: {} btreemap_remove_blob_64_1024: total: - instructions: 1141008090 + instructions: 1139970828 heap_increase: 0 stable_memory_increase: 0 scopes: {} btreemap_remove_blob_64_1024_v2: total: - instructions: 1280920638 + instructions: 1283145072 heap_increase: 0 stable_memory_increase: 0 scopes: {} btreemap_remove_blob_8_1024: total: - instructions: 644735138 + instructions: 642836148 heap_increase: 0 stable_memory_increase: 0 scopes: {} btreemap_remove_blob_8_1024_v2: total: - instructions: 776768069 + instructions: 775037862 heap_increase: 0 stable_memory_increase: 0 scopes: {} btreemap_remove_blob_8_u64: total: - instructions: 435032682 + instructions: 433944769 heap_increase: 0 stable_memory_increase: 0 scopes: {} btreemap_remove_blob_8_u64_v2: total: - instructions: 584053097 + instructions: 579958230 heap_increase: 0 stable_memory_increase: 0 scopes: {} btreemap_remove_u64_blob_8: total: - instructions: 485748982 + instructions: 485913516 heap_increase: 0 stable_memory_increase: 0 scopes: {} btreemap_remove_u64_blob_8_v2: total: - instructions: 601012747 + instructions: 597538858 heap_increase: 0 stable_memory_increase: 0 scopes: {} btreemap_remove_u64_u64: total: - instructions: 498934285 + instructions: 499266505 heap_increase: 0 stable_memory_increase: 0 scopes: {} btreemap_remove_u64_u64_v2: total: - instructions: 623495817 + instructions: 619109964 heap_increase: 0 stable_memory_increase: 0 scopes: {} btreemap_values_10mib_values: total: - instructions: 11406858 + instructions: 11406848 heap_increase: 0 stable_memory_increase: 0 scopes: {} btreemap_values_rev_10mib_values: total: - instructions: 11403861 + instructions: 11403833 heap_increase: 0 stable_memory_increase: 0 scopes: {} btreemap_values_rev_small_values: total: - instructions: 14949517 + instructions: 14949875 heap_increase: 0 stable_memory_increase: 0 scopes: {} btreemap_values_small_values: total: - instructions: 14952610 + instructions: 14974846 heap_increase: 0 stable_memory_increase: 0 scopes: {} memory_manager_baseline: total: - instructions: 1176576907 + instructions: 1176577076 heap_increase: 0 stable_memory_increase: 8000 scopes: {} memory_manager_grow: total: - instructions: 346600495 + instructions: 346537961 heap_increase: 2 stable_memory_increase: 32000 scopes: {} memory_manager_overhead: total: - instructions: 1181961433 + instructions: 1181962837 heap_increase: 0 stable_memory_increase: 8320 scopes: {} vec_get_blob_128: total: - instructions: 19306242 + instructions: 19246658 heap_increase: 0 stable_memory_increase: 0 scopes: {} vec_get_blob_16: total: - instructions: 6402226 + instructions: 6345942 heap_increase: 0 stable_memory_increase: 0 scopes: {} vec_get_blob_32: total: - instructions: 7121657 + instructions: 7063501 heap_increase: 0 stable_memory_increase: 0 scopes: {} vec_get_blob_4: total: - instructions: 4849627 + instructions: 4804323 heap_increase: 0 stable_memory_increase: 0 scopes: {} vec_get_blob_4_mem_manager: total: - instructions: 7216977 + instructions: 7171673 heap_increase: 0 stable_memory_increase: 0 scopes: {} vec_get_blob_64: total: - instructions: 11370056 + instructions: 11310940 heap_increase: 0 stable_memory_increase: 0 scopes: {} vec_get_blob_64_mem_manager: total: - instructions: 13710204 + instructions: 13651088 heap_increase: 0 stable_memory_increase: 0 scopes: {} vec_get_blob_8: total: - instructions: 5673873 + instructions: 5620865 heap_increase: 0 stable_memory_increase: 0 scopes: {} vec_get_u64: total: - instructions: 5330306 + instructions: 5270302 heap_increase: 0 stable_memory_increase: 0 scopes: {} vec_insert_blob_128: total: - instructions: 4151425 + instructions: 4131421 heap_increase: 0 stable_memory_increase: 19 scopes: {} vec_insert_blob_16: total: - instructions: 3316228 + instructions: 3296224 heap_increase: 0 stable_memory_increase: 2 scopes: {} vec_insert_blob_32: total: - instructions: 3435468 + instructions: 3415464 heap_increase: 0 stable_memory_increase: 5 scopes: {} vec_insert_blob_4: total: - instructions: 3227469 + instructions: 3207465 heap_increase: 0 stable_memory_increase: 0 scopes: {} vec_insert_blob_64: total: - instructions: 3675805 + instructions: 3655801 heap_increase: 0 stable_memory_increase: 9 scopes: {} vec_insert_blob_8: total: - instructions: 3256890 + instructions: 3236886 heap_increase: 0 stable_memory_increase: 1 scopes: {} vec_insert_u64: total: - instructions: 5929433 + instructions: 5859516 heap_increase: 0 stable_memory_increase: 1 scopes: {} -version: 0.1.11 +version: 0.1.12 From 5abcd38da3306b28ffc59290c92c255b26bcfe9b Mon Sep 17 00:00:00 2001 From: Maksym Arutyunyan Date: Fri, 9 May 2025 18:11:36 +0200 Subject: [PATCH 06/37] --hide-results --- scripts/ci_run_benchmark.sh | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/scripts/ci_run_benchmark.sh b/scripts/ci_run_benchmark.sh index 25f6d550..f2891f43 100644 --- a/scripts/ci_run_benchmark.sh +++ b/scripts/ci_run_benchmark.sh @@ -32,7 +32,7 @@ fi # Check if the canbench results file is up to date. pushd "$CANISTER_PATH" -canbench --less-verbose --hide-results --show-summary > $CANBENCH_OUTPUT +canbench --less-verbose > $CANBENCH_OUTPUT if grep -q "(regress\|(improved by \|(new)" "$CANBENCH_OUTPUT"; then UPDATED_MSG="**❌ \`$CANBENCH_RESULTS_FILE\` is not up to date** If the performance change is expected, run \`canbench --persist\` to update the benchmark results." @@ -61,7 +61,7 @@ if [ -f "$MAIN_BRANCH_RESULTS_FILE" ]; then # Run canbench to compare results with the main branch. pushd "$CANISTER_PATH" - canbench --less-verbose --show-summary > "$CANBENCH_OUTPUT" + canbench --less-verbose --hide-results --show-summary > "$CANBENCH_OUTPUT" popd # Append markers to individual benchmark results From ba7bf0f245d9bc60c65547fd0ce092c3d409e34a Mon Sep 17 00:00:00 2001 From: Maksym Arutyunyan Date: Mon, 12 May 2025 13:34:47 +0200 Subject: [PATCH 07/37] rm status from run script --- scripts/ci_run_benchmark.sh | 16 +--------------- 1 file changed, 1 insertion(+), 15 deletions(-) diff --git a/scripts/ci_run_benchmark.sh b/scripts/ci_run_benchmark.sh index f2891f43..c4d9a4bc 100644 --- a/scripts/ci_run_benchmark.sh +++ b/scripts/ci_run_benchmark.sh @@ -61,22 +61,8 @@ if [ -f "$MAIN_BRANCH_RESULTS_FILE" ]; then # Run canbench to compare results with the main branch. pushd "$CANISTER_PATH" - canbench --less-verbose --hide-results --show-summary > "$CANBENCH_OUTPUT" + canbench --less-verbose --hide-results --show-summary --csv > "$CANBENCH_OUTPUT" popd - - # Append markers to individual benchmark results - awk ' - /\(improved / { print $0, "đŸŸĸ"; next } - /\(regressed / { print $0, "🔴"; next } - /\(new\)/ { print $0, "🟡"; next } - { print } - ' "$CANBENCH_OUTPUT" > "${CANBENCH_OUTPUT}.tmp" && mv "${CANBENCH_OUTPUT}.tmp" "$CANBENCH_OUTPUT" - - # Add a top-level summary of detected performance changes - MESSAGE="" - grep -q "(improved " "${CANBENCH_OUTPUT}" && MESSAGE+="**đŸŸĸ Performance improvements detected! 🎉**\n" - grep -q "(regressed " "${CANBENCH_OUTPUT}" && MESSAGE+="**🔴 Performance regressions detected! 😱**\n" - echo -e "${MESSAGE:-**â„šī¸ No significant performance changes detected 👍**}" >> "$COMMENT_MESSAGE_PATH" fi # Append the update status and benchmark output to the comment. From f9f5d267d65b009110289a7678c642e072edc9bf Mon Sep 17 00:00:00 2001 From: Maksym Arutyunyan Date: Mon, 12 May 2025 13:41:20 +0200 Subject: [PATCH 08/37] csv results url in summary --- .github/workflows/canbench-post-comment.yml | 7 ++++++- scripts/ci_run_benchmark.sh | 6 ++++++ 2 files changed, 12 insertions(+), 1 deletion(-) diff --git a/.github/workflows/canbench-post-comment.yml b/.github/workflows/canbench-post-comment.yml index 53f88a1c..35942613 100644 --- a/.github/workflows/canbench-post-comment.yml +++ b/.github/workflows/canbench-post-comment.yml @@ -22,6 +22,12 @@ jobs: - id: set-benchmarks run: bash ./scripts/ci_download_canbench_artifacts.sh + - name: Upload canbench CSV results + uses: actions/upload-artifact@v4 + with: + name: canbench_results + path: ./canbench_results.csv + post-comment: runs-on: ubuntu-latest needs: [download-results] @@ -35,4 +41,3 @@ jobs: ${{ matrix.benchmark.result }} comment-tag: ${{ matrix.benchmark.title }} pr-number: ${{ needs.download-results.outputs.pr_number }} - diff --git a/scripts/ci_run_benchmark.sh b/scripts/ci_run_benchmark.sh index c4d9a4bc..fd815fe7 100644 --- a/scripts/ci_run_benchmark.sh +++ b/scripts/ci_run_benchmark.sh @@ -20,6 +20,7 @@ CANBENCH_OUTPUT=/tmp/canbench_output.txt CANBENCH_RESULTS_FILE="$CANISTER_PATH/canbench_results.yml" MAIN_BRANCH_RESULTS_FILE="$MAIN_BRANCH_DIR/$CANBENCH_RESULTS_FILE" +CANBENCH_CSV_RESULTS_FILE="$CANISTER_PATH/canbench_results.csv" # Install canbench cargo install canbench @@ -63,11 +64,16 @@ if [ -f "$MAIN_BRANCH_RESULTS_FILE" ]; then pushd "$CANISTER_PATH" canbench --less-verbose --hide-results --show-summary --csv > "$CANBENCH_OUTPUT" popd + + CSV_RESULTS_FILE_MSG="[$CANBENCH_CSV_RESULTS_FILE]((${{ + github.server_url + }}/${{ github.repository }}/actions/runs/${{ github.run_id }}))"; fi # Append the update status and benchmark output to the comment. { echo "$UPDATED_MSG" + echo "$CSV_RESULTS_FILE_MSG" echo "" echo "\`\`\`" cat "$CANBENCH_OUTPUT" From 6c547440ee6e7f52ed51173c89f9bbd1678b60f7 Mon Sep 17 00:00:00 2001 From: Maksym Arutyunyan Date: Mon, 12 May 2025 13:44:21 +0200 Subject: [PATCH 09/37] test from branch --- scripts/ci_run_benchmark.sh | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/scripts/ci_run_benchmark.sh b/scripts/ci_run_benchmark.sh index fd815fe7..cd25d65c 100644 --- a/scripts/ci_run_benchmark.sh +++ b/scripts/ci_run_benchmark.sh @@ -23,7 +23,8 @@ MAIN_BRANCH_RESULTS_FILE="$MAIN_BRANCH_DIR/$CANBENCH_RESULTS_FILE" CANBENCH_CSV_RESULTS_FILE="$CANISTER_PATH/canbench_results.csv" # Install canbench -cargo install canbench +#cargo install canbench +cargo install --git https://github.com/dfinity/canbench --branch maksym/summary-fix # Verify that the canbench results file exists. if [ ! -f "$CANBENCH_RESULTS_FILE" ]; then From ea41ae3b4e61bd418adcbe08ef84b51a76fa267e Mon Sep 17 00:00:00 2001 From: Maksym Arutyunyan Date: Mon, 12 May 2025 13:53:12 +0200 Subject: [PATCH 10/37] canbench-rs --- scripts/ci_run_benchmark.sh | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/scripts/ci_run_benchmark.sh b/scripts/ci_run_benchmark.sh index cd25d65c..cda1a12e 100644 --- a/scripts/ci_run_benchmark.sh +++ b/scripts/ci_run_benchmark.sh @@ -24,7 +24,7 @@ CANBENCH_CSV_RESULTS_FILE="$CANISTER_PATH/canbench_results.csv" # Install canbench #cargo install canbench -cargo install --git https://github.com/dfinity/canbench --branch maksym/summary-fix +cargo install --git https://github.com/dfinity/canbench --branch maksym/summary-fix canbench-rs # Verify that the canbench results file exists. if [ ! -f "$CANBENCH_RESULTS_FILE" ]; then From 643a20f330f7b3dedd806859d1956590d9d90658 Mon Sep 17 00:00:00 2001 From: Maksym Arutyunyan Date: Mon, 12 May 2025 13:58:52 +0200 Subject: [PATCH 11/37] canbench-bin --- scripts/ci_run_benchmark.sh | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/scripts/ci_run_benchmark.sh b/scripts/ci_run_benchmark.sh index cda1a12e..dae90626 100644 --- a/scripts/ci_run_benchmark.sh +++ b/scripts/ci_run_benchmark.sh @@ -24,7 +24,7 @@ CANBENCH_CSV_RESULTS_FILE="$CANISTER_PATH/canbench_results.csv" # Install canbench #cargo install canbench -cargo install --git https://github.com/dfinity/canbench --branch maksym/summary-fix canbench-rs +cargo install --git https://github.com/dfinity/canbench --branch maksym/summary-fix canbench-bin # Verify that the canbench results file exists. if [ ! -f "$CANBENCH_RESULTS_FILE" ]; then From cc7ec3790571fc7061d50ba8f10f1a4e9dd283b7 Mon Sep 17 00:00:00 2001 From: Maksym Arutyunyan Date: Mon, 12 May 2025 13:59:52 +0200 Subject: [PATCH 12/37] canbench --- scripts/ci_run_benchmark.sh | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/scripts/ci_run_benchmark.sh b/scripts/ci_run_benchmark.sh index dae90626..5b22bf79 100644 --- a/scripts/ci_run_benchmark.sh +++ b/scripts/ci_run_benchmark.sh @@ -24,7 +24,7 @@ CANBENCH_CSV_RESULTS_FILE="$CANISTER_PATH/canbench_results.csv" # Install canbench #cargo install canbench -cargo install --git https://github.com/dfinity/canbench --branch maksym/summary-fix canbench-bin +cargo install --git https://github.com/dfinity/canbench --branch maksym/summary-fix canbench # Verify that the canbench results file exists. if [ ! -f "$CANBENCH_RESULTS_FILE" ]; then From 782f28240f9d0ce60617c18dabdc56806466ec3b Mon Sep 17 00:00:00 2001 From: Maksym Arutyunyan Date: Mon, 12 May 2025 14:09:55 +0200 Subject: [PATCH 13/37] fix script --- scripts/ci_run_benchmark.sh | 4 +--- 1 file changed, 1 insertion(+), 3 deletions(-) diff --git a/scripts/ci_run_benchmark.sh b/scripts/ci_run_benchmark.sh index 5b22bf79..9e3c2dc3 100644 --- a/scripts/ci_run_benchmark.sh +++ b/scripts/ci_run_benchmark.sh @@ -66,9 +66,7 @@ if [ -f "$MAIN_BRANCH_RESULTS_FILE" ]; then canbench --less-verbose --hide-results --show-summary --csv > "$CANBENCH_OUTPUT" popd - CSV_RESULTS_FILE_MSG="[$CANBENCH_CSV_RESULTS_FILE]((${{ - github.server_url - }}/${{ github.repository }}/actions/runs/${{ github.run_id }}))"; + CSV_RESULTS_FILE_MSG="[$CANBENCH_CSV_RESULTS_FILE](${GITHUB_SERVER_URL}/${GITHUB_REPOSITORY}/actions/runs/${GITHUB_RUN_ID})" fi # Append the update status and benchmark output to the comment. From ace851fb41b0c303b5dd53cf4debd209e18460ea Mon Sep 17 00:00:00 2001 From: Maksym Arutyunyan Date: Mon, 12 May 2025 14:26:48 +0200 Subject: [PATCH 14/37] fix attaching csv file --- .github/workflows/canbench-post-comment.yml | 6 ------ .github/workflows/ci.yml | 11 ++++++++--- scripts/ci_run_benchmark.sh | 4 ++-- 3 files changed, 10 insertions(+), 11 deletions(-) diff --git a/.github/workflows/canbench-post-comment.yml b/.github/workflows/canbench-post-comment.yml index 35942613..980612da 100644 --- a/.github/workflows/canbench-post-comment.yml +++ b/.github/workflows/canbench-post-comment.yml @@ -22,12 +22,6 @@ jobs: - id: set-benchmarks run: bash ./scripts/ci_download_canbench_artifacts.sh - - name: Upload canbench CSV results - uses: actions/upload-artifact@v4 - with: - name: canbench_results - path: ./canbench_results.csv - post-comment: runs-on: ubuntu-latest needs: [download-results] diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index afd4f2c6..391a8af5 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -6,7 +6,7 @@ jobs: runs-on: ubuntu-latest strategy: matrix: - rust: [ 1.84.0 ] + rust: [1.84.0] steps: - uses: actions/checkout@v4 @@ -40,7 +40,7 @@ jobs: run: cargo test env: RUST_BACKTRACE: 1 - + - name: Build Fuzzers run: | cargo install cargo-fuzz @@ -74,7 +74,7 @@ jobs: rm install-dfx.sh dfx cache install echo "$HOME/bin" >> $GITHUB_PATH - + - name: Run test run: | bash examples/test.sh @@ -126,6 +126,11 @@ jobs: name: pr_number path: /tmp/pr_number + - uses: actions/upload-artifact@v4 + with: + name: canbench_results.csv + path: /tmp/canbench_results.csv + - name: Pass or fail run: | bash ./scripts/ci_post_run_benchmark.sh diff --git a/scripts/ci_run_benchmark.sh b/scripts/ci_run_benchmark.sh index 9e3c2dc3..596dc3bf 100644 --- a/scripts/ci_run_benchmark.sh +++ b/scripts/ci_run_benchmark.sh @@ -66,17 +66,17 @@ if [ -f "$MAIN_BRANCH_RESULTS_FILE" ]; then canbench --less-verbose --hide-results --show-summary --csv > "$CANBENCH_OUTPUT" popd - CSV_RESULTS_FILE_MSG="[$CANBENCH_CSV_RESULTS_FILE](${GITHUB_SERVER_URL}/${GITHUB_REPOSITORY}/actions/runs/${GITHUB_RUN_ID})" + CSV_RESULTS_FILE_MSG="Go to the [Artifacts section of this workflow run](${GITHUB_SERVER_URL}/${GITHUB_REPOSITORY}/actions/runs/${GITHUB_RUN_ID}) to download \`$CANBENCH_CSV_RESULTS_FILE\`" fi # Append the update status and benchmark output to the comment. { echo "$UPDATED_MSG" - echo "$CSV_RESULTS_FILE_MSG" echo "" echo "\`\`\`" cat "$CANBENCH_OUTPUT" echo "\`\`\`" + echo "$CSV_RESULTS_FILE_MSG" } >> "$COMMENT_MESSAGE_PATH" # Output the comment to stdout. From ddef45b7dbf0c7aeb690d2ddd7589824cebb5aaf Mon Sep 17 00:00:00 2001 From: Maksym Arutyunyan Date: Mon, 12 May 2025 14:32:55 +0200 Subject: [PATCH 15/37] . --- scripts/ci_run_benchmark.sh | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/scripts/ci_run_benchmark.sh b/scripts/ci_run_benchmark.sh index 596dc3bf..7bb88368 100644 --- a/scripts/ci_run_benchmark.sh +++ b/scripts/ci_run_benchmark.sh @@ -72,11 +72,11 @@ fi # Append the update status and benchmark output to the comment. { echo "$UPDATED_MSG" + echo "$CSV_RESULTS_FILE_MSG" echo "" echo "\`\`\`" cat "$CANBENCH_OUTPUT" echo "\`\`\`" - echo "$CSV_RESULTS_FILE_MSG" } >> "$COMMENT_MESSAGE_PATH" # Output the comment to stdout. From ccae6156ca2ebf72f5da1fd797d6ffdbf7e40867 Mon Sep 17 00:00:00 2001 From: Maksym Arutyunyan Date: Mon, 12 May 2025 14:43:12 +0200 Subject: [PATCH 16/37] fix csv path --- .github/workflows/ci.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index 391a8af5..10d070bd 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -129,7 +129,7 @@ jobs: - uses: actions/upload-artifact@v4 with: name: canbench_results.csv - path: /tmp/canbench_results.csv + path: /canbench_results.csv - name: Pass or fail run: | From 307a3ee3c393dac29cbeba7f12c93472ccd5214a Mon Sep 17 00:00:00 2001 From: Maksym Arutyunyan Date: Mon, 12 May 2025 14:57:25 +0200 Subject: [PATCH 17/37] . --- .github/workflows/ci.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index 10d070bd..fa227946 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -129,7 +129,7 @@ jobs: - uses: actions/upload-artifact@v4 with: name: canbench_results.csv - path: /canbench_results.csv + path: $PROJECT_DIR/canbench_results.csv - name: Pass or fail run: | From 5c78acaba280e33cdb2d81076b8314d20d7a7ae3 Mon Sep 17 00:00:00 2001 From: Maksym Arutyunyan Date: Mon, 12 May 2025 15:05:51 +0200 Subject: [PATCH 18/37] . --- scripts/ci_run_benchmark.sh | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/scripts/ci_run_benchmark.sh b/scripts/ci_run_benchmark.sh index 7bb88368..e4ab95ab 100644 --- a/scripts/ci_run_benchmark.sh +++ b/scripts/ci_run_benchmark.sh @@ -66,7 +66,7 @@ if [ -f "$MAIN_BRANCH_RESULTS_FILE" ]; then canbench --less-verbose --hide-results --show-summary --csv > "$CANBENCH_OUTPUT" popd - CSV_RESULTS_FILE_MSG="Go to the [Artifacts section of this workflow run](${GITHUB_SERVER_URL}/${GITHUB_REPOSITORY}/actions/runs/${GITHUB_RUN_ID}) to download \`$CANBENCH_CSV_RESULTS_FILE\`" + CSV_RESULTS_FILE_MSG="đŸ“Ļ CSV available in [artifacts](${GITHUB_SERVER_URL}/${GITHUB_REPOSITORY}/actions/runs/${GITHUB_RUN_ID}): \`$CANBENCH_CSV_RESULTS_FILE\`" fi # Append the update status and benchmark output to the comment. From 22c8d089ab9329dd110bad049467a6fe029755a6 Mon Sep 17 00:00:00 2001 From: Maksym Arutyunyan Date: Mon, 12 May 2025 15:07:02 +0200 Subject: [PATCH 19/37] . --- scripts/ci_run_benchmark.sh | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/scripts/ci_run_benchmark.sh b/scripts/ci_run_benchmark.sh index e4ab95ab..9e2d77fd 100644 --- a/scripts/ci_run_benchmark.sh +++ b/scripts/ci_run_benchmark.sh @@ -66,7 +66,7 @@ if [ -f "$MAIN_BRANCH_RESULTS_FILE" ]; then canbench --less-verbose --hide-results --show-summary --csv > "$CANBENCH_OUTPUT" popd - CSV_RESULTS_FILE_MSG="đŸ“Ļ CSV available in [artifacts](${GITHUB_SERVER_URL}/${GITHUB_REPOSITORY}/actions/runs/${GITHUB_RUN_ID}): \`$CANBENCH_CSV_RESULTS_FILE\`" + CSV_RESULTS_FILE_MSG="đŸ“Ļ \`$CANBENCH_CSV_RESULTS_FILE\` available in [artifacts](${GITHUB_SERVER_URL}/${GITHUB_REPOSITORY}/actions/runs/${GITHUB_RUN_ID})" fi # Append the update status and benchmark output to the comment. From 42fe13c252118e73b6a65c361ae512c0674345d5 Mon Sep 17 00:00:00 2001 From: Maksym Arutyunyan Date: Mon, 12 May 2025 15:08:01 +0200 Subject: [PATCH 20/37] fix path --- .github/workflows/ci.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index fa227946..cf4ca4fd 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -129,7 +129,7 @@ jobs: - uses: actions/upload-artifact@v4 with: name: canbench_results.csv - path: $PROJECT_DIR/canbench_results.csv + path: ${{ env.PROJECT_DIR }}/canbench_results.csv - name: Pass or fail run: | From 3b4486528f325ef39278fd4ae20479483854fc55 Mon Sep 17 00:00:00 2001 From: Maksym Arutyunyan Date: Mon, 12 May 2025 15:18:56 +0200 Subject: [PATCH 21/37] . --- scripts/ci_run_benchmark.sh | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/scripts/ci_run_benchmark.sh b/scripts/ci_run_benchmark.sh index 9e2d77fd..18d76d47 100644 --- a/scripts/ci_run_benchmark.sh +++ b/scripts/ci_run_benchmark.sh @@ -42,7 +42,7 @@ if grep -q "(regress\|(improved by \|(new)" "$CANBENCH_OUTPUT"; then # Results are outdated; fail the job. echo "EXIT_STATUS=1" >> "$GITHUB_ENV" else - UPDATED_MSG="**✅ \`$CANBENCH_RESULTS_FILE\` is up to date**"; + UPDATED_MSG="✅ \`$CANBENCH_RESULTS_FILE\` is up to date"; # Results are up to date; job succeeds. echo "EXIT_STATUS=0" >> "$GITHUB_ENV" From b5e20a96765cfbbeb39c5c748291881576ba93b7 Mon Sep 17 00:00:00 2001 From: Maksym Arutyunyan Date: Mon, 12 May 2025 15:21:08 +0200 Subject: [PATCH 22/37] . --- .github/workflows/canbench-post-comment.yml | 1 + 1 file changed, 1 insertion(+) diff --git a/.github/workflows/canbench-post-comment.yml b/.github/workflows/canbench-post-comment.yml index 980612da..53f88a1c 100644 --- a/.github/workflows/canbench-post-comment.yml +++ b/.github/workflows/canbench-post-comment.yml @@ -35,3 +35,4 @@ jobs: ${{ matrix.benchmark.result }} comment-tag: ${{ matrix.benchmark.title }} pr-number: ${{ needs.download-results.outputs.pr_number }} + From e6681a20ef4837f17e8dfec102d63c9b15746ced Mon Sep 17 00:00:00 2001 From: Maksym Arutyunyan Date: Mon, 12 May 2025 15:26:52 +0200 Subject: [PATCH 23/37] . --- .github/workflows/ci.yml | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index cf4ca4fd..1415b112 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -117,6 +117,11 @@ jobs: name: canbench_result_${{github.job}} path: /tmp/canbench_result_${{ github.job }} + - uses: actions/upload-artifact@v4 + with: + name: canbench_results.csv + path: ${{ env.PROJECT_DIR }}/canbench_results.csv + - name: Save PR number run: | echo ${{ github.event.number }} > /tmp/pr_number @@ -126,11 +131,6 @@ jobs: name: pr_number path: /tmp/pr_number - - uses: actions/upload-artifact@v4 - with: - name: canbench_results.csv - path: ${{ env.PROJECT_DIR }}/canbench_results.csv - - name: Pass or fail run: | bash ./scripts/ci_post_run_benchmark.sh From 375db845d4e060e949c2c2ff30912e5ec3755d42 Mon Sep 17 00:00:00 2001 From: Maksym Arutyunyan Date: Mon, 12 May 2025 15:37:56 +0200 Subject: [PATCH 24/37] . --- scripts/ci_download_canbench_artifacts.sh | 2 +- scripts/ci_run_benchmark.sh | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/scripts/ci_download_canbench_artifacts.sh b/scripts/ci_download_canbench_artifacts.sh index d1ed554f..d866fc9d 100644 --- a/scripts/ci_download_canbench_artifacts.sh +++ b/scripts/ci_download_canbench_artifacts.sh @@ -26,4 +26,4 @@ json_array+="]" # Output the benchmark matrix and PR number to be used by the next job echo "matrix={\"benchmark\": $json_array}" >> "$GITHUB_OUTPUT" -echo "pr_number=$(cat ./pr_number/pr_number)" >> "$GITHUB_OUTPUT" \ No newline at end of file +echo "pr_number=$(cat ./pr_number/pr_number)" >> "$GITHUB_OUTPUT" diff --git a/scripts/ci_run_benchmark.sh b/scripts/ci_run_benchmark.sh index 18d76d47..61fac7ce 100644 --- a/scripts/ci_run_benchmark.sh +++ b/scripts/ci_run_benchmark.sh @@ -80,4 +80,4 @@ fi } >> "$COMMENT_MESSAGE_PATH" # Output the comment to stdout. -cat "$COMMENT_MESSAGE_PATH" \ No newline at end of file +cat "$COMMENT_MESSAGE_PATH" From 5347927e8e1c772a96b444c296be6b1ff5d07e23 Mon Sep 17 00:00:00 2001 From: Maksym Arutyunyan Date: Mon, 12 May 2025 15:40:40 +0200 Subject: [PATCH 25/37] fix upload file name --- .github/workflows/ci.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index 1415b112..9ab7f65f 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -119,7 +119,7 @@ jobs: - uses: actions/upload-artifact@v4 with: - name: canbench_results.csv + name: canbench_results_${{github.job}}.csv path: ${{ env.PROJECT_DIR }}/canbench_results.csv - name: Save PR number From 0acee82dba12d6d381fb37a0cb1282abaa5ef122 Mon Sep 17 00:00:00 2001 From: Maksym Arutyunyan Date: Mon, 12 May 2025 15:42:55 +0200 Subject: [PATCH 26/37] . --- scripts/ci_run_benchmark.sh | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/scripts/ci_run_benchmark.sh b/scripts/ci_run_benchmark.sh index 61fac7ce..f0a49886 100644 --- a/scripts/ci_run_benchmark.sh +++ b/scripts/ci_run_benchmark.sh @@ -66,7 +66,7 @@ if [ -f "$MAIN_BRANCH_RESULTS_FILE" ]; then canbench --less-verbose --hide-results --show-summary --csv > "$CANBENCH_OUTPUT" popd - CSV_RESULTS_FILE_MSG="đŸ“Ļ \`$CANBENCH_CSV_RESULTS_FILE\` available in [artifacts](${GITHUB_SERVER_URL}/${GITHUB_REPOSITORY}/actions/runs/${GITHUB_RUN_ID})" + CSV_RESULTS_FILE_MSG="đŸ“Ļ \`canbench_results_$CANBENCH_JOB_NAME.csv\` available in [artifacts](${GITHUB_SERVER_URL}/${GITHUB_REPOSITORY}/actions/runs/${GITHUB_RUN_ID})" fi # Append the update status and benchmark output to the comment. From 74cca4f343854a149840213242ad261b6296ec3d Mon Sep 17 00:00:00 2001 From: Maksym Arutyunyan Date: Mon, 12 May 2025 15:53:52 +0200 Subject: [PATCH 27/37] shell check --- scripts/ci_run_benchmark.sh | 1 - 1 file changed, 1 deletion(-) diff --git a/scripts/ci_run_benchmark.sh b/scripts/ci_run_benchmark.sh index f0a49886..48634515 100644 --- a/scripts/ci_run_benchmark.sh +++ b/scripts/ci_run_benchmark.sh @@ -20,7 +20,6 @@ CANBENCH_OUTPUT=/tmp/canbench_output.txt CANBENCH_RESULTS_FILE="$CANISTER_PATH/canbench_results.yml" MAIN_BRANCH_RESULTS_FILE="$MAIN_BRANCH_DIR/$CANBENCH_RESULTS_FILE" -CANBENCH_CSV_RESULTS_FILE="$CANISTER_PATH/canbench_results.csv" # Install canbench #cargo install canbench From 7dd1af94a8e84760596bdbb7e435194d66cadd11 Mon Sep 17 00:00:00 2001 From: Maksym Arutyunyan Date: Mon, 12 May 2025 16:03:14 +0200 Subject: [PATCH 28/37] cp /tmp/csv --- .github/workflows/ci.yml | 2 +- scripts/ci_run_benchmark.sh | 3 +++ 2 files changed, 4 insertions(+), 1 deletion(-) diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index 9ab7f65f..1a779059 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -120,7 +120,7 @@ jobs: - uses: actions/upload-artifact@v4 with: name: canbench_results_${{github.job}}.csv - path: ${{ env.PROJECT_DIR }}/canbench_results.csv + path: /tmp/canbench_results_${{ github.job }}.csv - name: Save PR number run: | diff --git a/scripts/ci_run_benchmark.sh b/scripts/ci_run_benchmark.sh index 48634515..d0bf2ee6 100644 --- a/scripts/ci_run_benchmark.sh +++ b/scripts/ci_run_benchmark.sh @@ -21,6 +21,8 @@ CANBENCH_OUTPUT=/tmp/canbench_output.txt CANBENCH_RESULTS_FILE="$CANISTER_PATH/canbench_results.yml" MAIN_BRANCH_RESULTS_FILE="$MAIN_BRANCH_DIR/$CANBENCH_RESULTS_FILE" +CANBENCH_RESULTS_CSV_FILE="/tmp/canbench_results_${CANBENCH_JOB_NAME}.csv" + # Install canbench #cargo install canbench cargo install --git https://github.com/dfinity/canbench --branch maksym/summary-fix canbench @@ -63,6 +65,7 @@ if [ -f "$MAIN_BRANCH_RESULTS_FILE" ]; then # Run canbench to compare results with the main branch. pushd "$CANISTER_PATH" canbench --less-verbose --hide-results --show-summary --csv > "$CANBENCH_OUTPUT" + cp "./canbench_results.csv" "$CANBENCH_RESULTS_CSV_FILE" popd CSV_RESULTS_FILE_MSG="đŸ“Ļ \`canbench_results_$CANBENCH_JOB_NAME.csv\` available in [artifacts](${GITHUB_SERVER_URL}/${GITHUB_REPOSITORY}/actions/runs/${GITHUB_RUN_ID})" From 2eb1ec47d38035681cf216cace072bffaad4f074 Mon Sep 17 00:00:00 2001 From: Maksym Arutyunyan Date: Mon, 12 May 2025 16:11:04 +0200 Subject: [PATCH 29/37] _csv --- .github/workflows/ci.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index 1a779059..81480cbf 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -119,7 +119,7 @@ jobs: - uses: actions/upload-artifact@v4 with: - name: canbench_results_${{github.job}}.csv + name: canbench_results_${{github.job}}_csv path: /tmp/canbench_results_${{ github.job }}.csv - name: Save PR number From 441723e3da9d6ecaa92ff104a4760e9869e6fd2c Mon Sep 17 00:00:00 2001 From: Maksym Arutyunyan Date: Mon, 12 May 2025 16:16:27 +0200 Subject: [PATCH 30/37] no tmp/csv --- .github/workflows/ci.yml | 2 +- scripts/ci_run_benchmark.sh | 3 --- 2 files changed, 1 insertion(+), 4 deletions(-) diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index 81480cbf..b681943f 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -120,7 +120,7 @@ jobs: - uses: actions/upload-artifact@v4 with: name: canbench_results_${{github.job}}_csv - path: /tmp/canbench_results_${{ github.job }}.csv + path: ${{ env.PROJECT_DIR }}/canbench_results.csv - name: Save PR number run: | diff --git a/scripts/ci_run_benchmark.sh b/scripts/ci_run_benchmark.sh index d0bf2ee6..48634515 100644 --- a/scripts/ci_run_benchmark.sh +++ b/scripts/ci_run_benchmark.sh @@ -21,8 +21,6 @@ CANBENCH_OUTPUT=/tmp/canbench_output.txt CANBENCH_RESULTS_FILE="$CANISTER_PATH/canbench_results.yml" MAIN_BRANCH_RESULTS_FILE="$MAIN_BRANCH_DIR/$CANBENCH_RESULTS_FILE" -CANBENCH_RESULTS_CSV_FILE="/tmp/canbench_results_${CANBENCH_JOB_NAME}.csv" - # Install canbench #cargo install canbench cargo install --git https://github.com/dfinity/canbench --branch maksym/summary-fix canbench @@ -65,7 +63,6 @@ if [ -f "$MAIN_BRANCH_RESULTS_FILE" ]; then # Run canbench to compare results with the main branch. pushd "$CANISTER_PATH" canbench --less-verbose --hide-results --show-summary --csv > "$CANBENCH_OUTPUT" - cp "./canbench_results.csv" "$CANBENCH_RESULTS_CSV_FILE" popd CSV_RESULTS_FILE_MSG="đŸ“Ļ \`canbench_results_$CANBENCH_JOB_NAME.csv\` available in [artifacts](${GITHUB_SERVER_URL}/${GITHUB_REPOSITORY}/actions/runs/${GITHUB_RUN_ID})" From 930556b852d6c96b17883d4c4f56732dde40a51d Mon Sep 17 00:00:00 2001 From: Maksym Arutyunyan Date: Mon, 12 May 2025 16:21:04 +0200 Subject: [PATCH 31/37] add /tmp/csv --- .github/workflows/ci.yml | 2 +- scripts/ci_run_benchmark.sh | 3 +++ 2 files changed, 4 insertions(+), 1 deletion(-) diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index b681943f..81480cbf 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -120,7 +120,7 @@ jobs: - uses: actions/upload-artifact@v4 with: name: canbench_results_${{github.job}}_csv - path: ${{ env.PROJECT_DIR }}/canbench_results.csv + path: /tmp/canbench_results_${{ github.job }}.csv - name: Save PR number run: | diff --git a/scripts/ci_run_benchmark.sh b/scripts/ci_run_benchmark.sh index 48634515..d0bf2ee6 100644 --- a/scripts/ci_run_benchmark.sh +++ b/scripts/ci_run_benchmark.sh @@ -21,6 +21,8 @@ CANBENCH_OUTPUT=/tmp/canbench_output.txt CANBENCH_RESULTS_FILE="$CANISTER_PATH/canbench_results.yml" MAIN_BRANCH_RESULTS_FILE="$MAIN_BRANCH_DIR/$CANBENCH_RESULTS_FILE" +CANBENCH_RESULTS_CSV_FILE="/tmp/canbench_results_${CANBENCH_JOB_NAME}.csv" + # Install canbench #cargo install canbench cargo install --git https://github.com/dfinity/canbench --branch maksym/summary-fix canbench @@ -63,6 +65,7 @@ if [ -f "$MAIN_BRANCH_RESULTS_FILE" ]; then # Run canbench to compare results with the main branch. pushd "$CANISTER_PATH" canbench --less-verbose --hide-results --show-summary --csv > "$CANBENCH_OUTPUT" + cp "./canbench_results.csv" "$CANBENCH_RESULTS_CSV_FILE" popd CSV_RESULTS_FILE_MSG="đŸ“Ļ \`canbench_results_$CANBENCH_JOB_NAME.csv\` available in [artifacts](${GITHUB_SERVER_URL}/${GITHUB_REPOSITORY}/actions/runs/${GITHUB_RUN_ID})" From d0c9ec48be12f2891fa9055e1d2e4df6d30ba96b Mon Sep 17 00:00:00 2001 From: Maksym Arutyunyan Date: Mon, 12 May 2025 16:51:14 +0200 Subject: [PATCH 32/37] recalc csv --- canbench_results.csv | 250 +++++++++++++++++++++---------------------- 1 file changed, 125 insertions(+), 125 deletions(-) diff --git a/canbench_results.csv b/canbench_results.csv index 265bc85f..0b90a62d 100644 --- a/canbench_results.csv +++ b/canbench_results.csv @@ -1,125 +1,125 @@ -status,name,instructions,instructions %,heap_increase,heap_increase %,stable_memory_increase,stable_memory_increase % -,btreemap_contains_key_blob_4_1024,164495877,-0.91%,0,,0, -,btreemap_contains_key_blob_4_1024_v2,248921977,0.94%,0,,0, -,btreemap_get_blob_128_1024,876676182,0.61%,0,,0, -,btreemap_get_blob_128_1024_v2,953199881,0.08%,0,,0, -,btreemap_get_blob_16_1024,241470994,-2.18%,0,,0, -,btreemap_get_blob_16_1024_v2,320086039,-0.87%,0,,0, -,btreemap_get_blob_256_1024,1440152578,0.12%,0,,0, -,btreemap_get_blob_256_1024_v2,1524516290,0.13%,0,,0, -,btreemap_get_blob_32_1024,275141698,-1.77%,0,,0, -,btreemap_get_blob_32_1024_v2,353756221,-1.20%,0,,0, -,btreemap_get_blob_4_1024,182139496,-0.95%,0,,0, -,btreemap_get_blob_4_1024_v2,267339946,-0.40%,0,,0, -,btreemap_get_blob_512_1024,2573387979,-0.02%,0,,0, -,btreemap_get_blob_512_1024_v2,2653499228,0.02%,0,,0, -,btreemap_get_blob_512_1024_v2_mem_manager,2759852247,0.03%,0,,0, -,btreemap_get_blob_64_1024,521344804,-0.21%,0,,0, -,btreemap_get_blob_64_1024_v2,603758767,0.21%,0,,0, -,btreemap_get_blob_8_1024,212618950,-2.20%,0,,0, -,btreemap_get_blob_8_1024_v2,294121282,-1.86%,0,,0, -,btreemap_get_blob_8_u64,199845052,-0.66%,0,,0, -,btreemap_get_blob_8_u64_v2,289664167,-2.82%,0,,0, -,btreemap_get_u64_blob_8,173627473,-1.15%,0,,0, -,btreemap_get_u64_blob_8_v2,245312213,-1.86%,0,,0, -,btreemap_get_u64_u64,176661272,0.17%,0,,0, -,btreemap_get_u64_u64_v2,249218649,-2.90%,0,,0, -,btreemap_get_u64_u64_v2_mem_manager,329730573,-1.92%,0,,0, -,btreemap_insert_10mib_values,5235962440,-0.07%,0,,3613,0.00% -,btreemap_insert_blob_1024_128,5098352751,-0.24%,0,,262,0.00% -,btreemap_insert_blob_1024_128_v2,5199218550,-0.05%,0,,196,0.00% -,btreemap_insert_blob_1024_16,5080607598,-0.64%,0,,241,0.00% -,btreemap_insert_blob_1024_16_v2,5187794378,-0.24%,0,,181,0.00% -,btreemap_insert_blob_1024_256,5125958119,-0.12%,0,,292,0.00% -,btreemap_insert_blob_1024_256_v2,5224501040,-0.02%,0,,219,0.00% -,btreemap_insert_blob_1024_32,5075547429,-0.41%,0,,239,0.00% -,btreemap_insert_blob_1024_32_v2,5185065640,-0.19%,0,,180,0.00% -,btreemap_insert_blob_1024_4,4977775085,-0.83%,0,,235,0.00% -,btreemap_insert_blob_1024_4_v2,5084891041,-0.26%,0,,176,0.00% -,btreemap_insert_blob_1024_512,5200292029,-0.12%,1,,348,0.00% -,btreemap_insert_blob_1024_512_v2,5299421985,-0.12%,0,,261,0.00% -,btreemap_insert_blob_1024_512_v2_mem_manager,5469551996,-0.10%,0,,256,0.00% -,btreemap_insert_blob_1024_64,5133691382,-0.32%,0,,250,0.00% -,btreemap_insert_blob_1024_64_v2,5242140512,-0.13%,0,,188,0.00% -,btreemap_insert_blob_1024_8,5065686056,-0.39%,0,,237,0.00% -,btreemap_insert_blob_1024_8_v2,5174504738,-0.25%,0,,178,0.00% -,btreemap_insert_blob_128_1024,1276472811,0.25%,0,,260,0.00% -,btreemap_insert_blob_128_1024_v2,1378788105,0.40%,0,,195,0.00% -,btreemap_insert_blob_16_1024,634307113,-0.55%,0,,215,0.00% -,btreemap_insert_blob_16_1024_v2,733723555,0.17%,0,,161,0.00% -,btreemap_insert_blob_256_1024,1860540926,0.04%,0,,292,0.00% -,btreemap_insert_blob_256_1024_v2,1967548428,0.50%,0,,219,0.00% -,btreemap_insert_blob_32_1024,670121076,-0.41%,0,,230,0.00% -,btreemap_insert_blob_32_1024_v2,773022814,0.37%,0,,173,0.00% -,btreemap_insert_blob_4_1024,494994994,-0.46%,0,,123,0.00% -,btreemap_insert_blob_4_1024_v2,592951465,-0.15%,0,,92,0.00% -,btreemap_insert_blob_512_1024,3002862489,-0.26%,0,,351,0.00% -,btreemap_insert_blob_512_1024_v2,3105965075,0.04%,0,,263,0.00% -,btreemap_insert_blob_64_1024,919414593,-0.06%,0,,245,0.00% -,btreemap_insert_blob_64_1024_v2,1020998986,0.50%,0,,183,0.00% -,btreemap_insert_blob_8_1024,605636927,-0.36%,0,,183,0.00% -,btreemap_insert_blob_8_1024_v2,708696031,-0.12%,0,,138,0.00% -,btreemap_insert_blob_8_u64,330055088,-0.07%,0,,6,0.00% -,btreemap_insert_blob_8_u64_v2,440988930,-0.03%,0,,4,0.00% -,btreemap_insert_u64_blob_8,339864719,-0.02%,0,,7,0.00% -,btreemap_insert_u64_blob_8_v2,422835585,0.60%,0,,5,0.00% -,btreemap_insert_u64_u64,345025209,-0.13%,0,,7,0.00% -,btreemap_insert_u64_u64_v2,431645530,0.64%,0,,6,0.00% -,btreemap_insert_u64_u64_v2_mem_manager,560976863,0.51%,0,,0, -,btreemap_iter_10mib_values,11407368,-0.00%,0,,0, -,btreemap_iter_count_10mib_values,491365,2.95%,0,,0, -,btreemap_iter_count_small_values,9443266,0.01%,0,,0, -,btreemap_iter_rev_10mib_values,11404353,-0.00%,0,,0, -,btreemap_iter_rev_small_values,14975879,0.00%,0,,0, -,btreemap_iter_small_values,15000850,0.15%,0,,0, -,btreemap_keys_10mib_values,464540,-0.09%,0,,0, -,btreemap_keys_rev_10mib_values,464165,-0.09%,0,,0, -,btreemap_keys_rev_small_values,9654062,-0.20%,0,,0, -,btreemap_keys_small_values,9528327,0.02%,0,,0, -,btreemap_read_every_third_value_from_range,84833060,0.78%,0,,0, -,btreemap_read_keys_from_range,84873064,0.78%,0,,0, -,btreemap_remove_blob_128_1024,1575050534,0.02%,0,,0, -,btreemap_remove_blob_128_1024_v2,1721504123,0.22%,0,,0, -,btreemap_remove_blob_16_1024,755252791,-0.38%,0,,0, -,btreemap_remove_blob_16_1024_v2,895690307,-0.03%,0,,0, -,btreemap_remove_blob_256_1024,2279810995,0.03%,0,,0, -,btreemap_remove_blob_256_1024_v2,2427184450,0.38%,0,,0, -,btreemap_remove_blob_32_1024,825632231,-0.24%,0,,0, -,btreemap_remove_blob_32_1024_v2,965884147,-0.09%,0,,0, -,btreemap_remove_blob_4_1024,485805538,-0.14%,0,,0, -,btreemap_remove_blob_4_1024_v2,600161724,0.01%,0,,0, -,btreemap_remove_blob_512_1024,3738145419,-0.29%,0,,0, -,btreemap_remove_blob_512_1024_v2,3883681704,0.14%,0,,0, -,btreemap_remove_blob_64_1024,1139970828,-0.09%,0,,0, -,btreemap_remove_blob_64_1024_v2,1283145072,0.17%,0,,0, -,btreemap_remove_blob_8_1024,642836148,-0.29%,0,,0, -,btreemap_remove_blob_8_1024_v2,775037862,-0.22%,0,,0, -,btreemap_remove_blob_8_u64,433944769,-0.25%,0,,0, -,btreemap_remove_blob_8_u64_v2,579958230,-0.70%,0,,0, -,btreemap_remove_u64_blob_8,485913516,0.03%,0,,0, -,btreemap_remove_u64_blob_8_v2,597538858,-0.58%,0,,0, -,btreemap_remove_u64_u64,499266505,0.07%,0,,0, -,btreemap_remove_u64_u64_v2,619109964,-0.70%,0,,0, -,btreemap_values_10mib_values,11406848,-0.00%,0,,0, -,btreemap_values_rev_10mib_values,11403833,-0.00%,0,,0, -,btreemap_values_rev_small_values,14949875,0.00%,0,,0, -,btreemap_values_small_values,14974846,0.15%,0,,0, -,memory_manager_baseline,1176577076,0.00%,0,,8000,0.00% -,memory_manager_grow,346537961,-0.02%,2,0.00%,32000,0.00% -,memory_manager_overhead,1181962837,0.00%,0,,8320,0.00% -,vec_get_blob_128,19246658,-0.31%,0,,0, -,vec_get_blob_16,6345942,-0.88%,0,,0, -,vec_get_blob_32,7063501,-0.82%,0,,0, -,vec_get_blob_4,4804323,-0.93%,0,,0, -,vec_get_blob_4_mem_manager,7171673,-0.63%,0,,0, -,vec_get_blob_64,11310940,-0.52%,0,,0, -,vec_get_blob_64_mem_manager,13651088,-0.43%,0,,0, -,vec_get_blob_8,5620865,-0.93%,0,,0, -,vec_get_u64,5270302,-1.13%,0,,0, -,vec_insert_blob_128,4131421,-0.48%,0,,19,0.00% -,vec_insert_blob_16,3296224,-0.60%,0,,2,0.00% -,vec_insert_blob_32,3415464,-0.58%,0,,5,0.00% -,vec_insert_blob_4,3207465,-0.62%,0,,0, -,vec_insert_blob_64,3655801,-0.54%,0,,9,0.00% -,vec_insert_blob_8,3236886,-0.61%,0,,1,0.00% -,vec_insert_u64,5859516,-1.18%,0,,1,0.00% +status,name,instructions,instructions change %,heap_increase,heap_increase change %,stable_memory_increase,stable_memory_increase change % +,btreemap_contains_key_blob_4_1024,164495877,0.00%,0,0.00%,0,0.00% +,btreemap_contains_key_blob_4_1024_v2,248921977,0.00%,0,0.00%,0,0.00% +,btreemap_get_blob_128_1024,876676182,0.00%,0,0.00%,0,0.00% +,btreemap_get_blob_128_1024_v2,953199881,0.00%,0,0.00%,0,0.00% +,btreemap_get_blob_16_1024,241470994,0.00%,0,0.00%,0,0.00% +,btreemap_get_blob_16_1024_v2,320086039,0.00%,0,0.00%,0,0.00% +,btreemap_get_blob_256_1024,1440152578,0.00%,0,0.00%,0,0.00% +,btreemap_get_blob_256_1024_v2,1524516290,0.00%,0,0.00%,0,0.00% +,btreemap_get_blob_32_1024,275141698,0.00%,0,0.00%,0,0.00% +,btreemap_get_blob_32_1024_v2,353756221,0.00%,0,0.00%,0,0.00% +,btreemap_get_blob_4_1024,182139496,0.00%,0,0.00%,0,0.00% +,btreemap_get_blob_4_1024_v2,267339946,0.00%,0,0.00%,0,0.00% +,btreemap_get_blob_512_1024,2573387979,0.00%,0,0.00%,0,0.00% +,btreemap_get_blob_512_1024_v2,2653499228,0.00%,0,0.00%,0,0.00% +,btreemap_get_blob_512_1024_v2_mem_manager,2759852247,0.00%,0,0.00%,0,0.00% +,btreemap_get_blob_64_1024,521344804,0.00%,0,0.00%,0,0.00% +,btreemap_get_blob_64_1024_v2,603758767,0.00%,0,0.00%,0,0.00% +,btreemap_get_blob_8_1024,212618950,0.00%,0,0.00%,0,0.00% +,btreemap_get_blob_8_1024_v2,294121282,0.00%,0,0.00%,0,0.00% +,btreemap_get_blob_8_u64,199845052,0.00%,0,0.00%,0,0.00% +,btreemap_get_blob_8_u64_v2,289664167,0.00%,0,0.00%,0,0.00% +,btreemap_get_u64_blob_8,173627473,0.00%,0,0.00%,0,0.00% +,btreemap_get_u64_blob_8_v2,245312213,0.00%,0,0.00%,0,0.00% +,btreemap_get_u64_u64,176661272,0.00%,0,0.00%,0,0.00% +,btreemap_get_u64_u64_v2,249218649,0.00%,0,0.00%,0,0.00% +,btreemap_get_u64_u64_v2_mem_manager,329730573,0.00%,0,0.00%,0,0.00% +,btreemap_insert_10mib_values,5235962440,0.00%,0,0.00%,3613,0.00% +,btreemap_insert_blob_1024_128,5098352751,0.00%,0,0.00%,262,0.00% +,btreemap_insert_blob_1024_128_v2,5199218550,0.00%,0,0.00%,196,0.00% +,btreemap_insert_blob_1024_16,5080607598,0.00%,0,0.00%,241,0.00% +,btreemap_insert_blob_1024_16_v2,5187794378,0.00%,0,0.00%,181,0.00% +,btreemap_insert_blob_1024_256,5125958119,0.00%,0,0.00%,292,0.00% +,btreemap_insert_blob_1024_256_v2,5224501040,0.00%,0,0.00%,219,0.00% +,btreemap_insert_blob_1024_32,5075547429,0.00%,0,0.00%,239,0.00% +,btreemap_insert_blob_1024_32_v2,5185065640,0.00%,0,0.00%,180,0.00% +,btreemap_insert_blob_1024_4,4977775085,0.00%,0,0.00%,235,0.00% +,btreemap_insert_blob_1024_4_v2,5084891041,0.00%,0,0.00%,176,0.00% +,btreemap_insert_blob_1024_512,5200292029,0.00%,1,0.00%,348,0.00% +,btreemap_insert_blob_1024_512_v2,5299421985,0.00%,0,0.00%,261,0.00% +,btreemap_insert_blob_1024_512_v2_mem_manager,5469551996,0.00%,0,0.00%,256,0.00% +,btreemap_insert_blob_1024_64,5133691382,0.00%,0,0.00%,250,0.00% +,btreemap_insert_blob_1024_64_v2,5242140512,0.00%,0,0.00%,188,0.00% +,btreemap_insert_blob_1024_8,5065686056,0.00%,0,0.00%,237,0.00% +,btreemap_insert_blob_1024_8_v2,5174504738,0.00%,0,0.00%,178,0.00% +,btreemap_insert_blob_128_1024,1276472811,0.00%,0,0.00%,260,0.00% +,btreemap_insert_blob_128_1024_v2,1378788105,0.00%,0,0.00%,195,0.00% +,btreemap_insert_blob_16_1024,634307113,0.00%,0,0.00%,215,0.00% +,btreemap_insert_blob_16_1024_v2,733723555,0.00%,0,0.00%,161,0.00% +,btreemap_insert_blob_256_1024,1860540926,0.00%,0,0.00%,292,0.00% +,btreemap_insert_blob_256_1024_v2,1967548428,0.00%,0,0.00%,219,0.00% +,btreemap_insert_blob_32_1024,670121076,0.00%,0,0.00%,230,0.00% +,btreemap_insert_blob_32_1024_v2,773022814,0.00%,0,0.00%,173,0.00% +,btreemap_insert_blob_4_1024,494994994,0.00%,0,0.00%,123,0.00% +,btreemap_insert_blob_4_1024_v2,592951465,0.00%,0,0.00%,92,0.00% +,btreemap_insert_blob_512_1024,3002862489,0.00%,0,0.00%,351,0.00% +,btreemap_insert_blob_512_1024_v2,3105965075,0.00%,0,0.00%,263,0.00% +,btreemap_insert_blob_64_1024,919414593,0.00%,0,0.00%,245,0.00% +,btreemap_insert_blob_64_1024_v2,1020998986,0.00%,0,0.00%,183,0.00% +,btreemap_insert_blob_8_1024,605636927,0.00%,0,0.00%,183,0.00% +,btreemap_insert_blob_8_1024_v2,708696031,0.00%,0,0.00%,138,0.00% +,btreemap_insert_blob_8_u64,330055088,0.00%,0,0.00%,6,0.00% +,btreemap_insert_blob_8_u64_v2,440988930,0.00%,0,0.00%,4,0.00% +,btreemap_insert_u64_blob_8,339864719,0.00%,0,0.00%,7,0.00% +,btreemap_insert_u64_blob_8_v2,422835585,0.00%,0,0.00%,5,0.00% +,btreemap_insert_u64_u64,345025209,0.00%,0,0.00%,7,0.00% +,btreemap_insert_u64_u64_v2,431645530,0.00%,0,0.00%,6,0.00% +,btreemap_insert_u64_u64_v2_mem_manager,560976863,0.00%,0,0.00%,0,0.00% +,btreemap_iter_10mib_values,11407368,0.00%,0,0.00%,0,0.00% +,btreemap_iter_count_10mib_values,491365,0.00%,0,0.00%,0,0.00% +,btreemap_iter_count_small_values,9443266,0.00%,0,0.00%,0,0.00% +,btreemap_iter_rev_10mib_values,11404353,0.00%,0,0.00%,0,0.00% +,btreemap_iter_rev_small_values,14975879,0.00%,0,0.00%,0,0.00% +,btreemap_iter_small_values,15000850,0.00%,0,0.00%,0,0.00% +,btreemap_keys_10mib_values,464540,0.00%,0,0.00%,0,0.00% +,btreemap_keys_rev_10mib_values,464165,0.00%,0,0.00%,0,0.00% +,btreemap_keys_rev_small_values,9654062,0.00%,0,0.00%,0,0.00% +,btreemap_keys_small_values,9528327,0.00%,0,0.00%,0,0.00% +,btreemap_read_every_third_value_from_range,84833060,0.00%,0,0.00%,0,0.00% +,btreemap_read_keys_from_range,84873064,0.00%,0,0.00%,0,0.00% +,btreemap_remove_blob_128_1024,1575050534,0.00%,0,0.00%,0,0.00% +,btreemap_remove_blob_128_1024_v2,1721504123,0.00%,0,0.00%,0,0.00% +,btreemap_remove_blob_16_1024,755252791,0.00%,0,0.00%,0,0.00% +,btreemap_remove_blob_16_1024_v2,895690307,0.00%,0,0.00%,0,0.00% +,btreemap_remove_blob_256_1024,2279810995,0.00%,0,0.00%,0,0.00% +,btreemap_remove_blob_256_1024_v2,2427184450,0.00%,0,0.00%,0,0.00% +,btreemap_remove_blob_32_1024,825632231,0.00%,0,0.00%,0,0.00% +,btreemap_remove_blob_32_1024_v2,965884147,0.00%,0,0.00%,0,0.00% +,btreemap_remove_blob_4_1024,485805538,0.00%,0,0.00%,0,0.00% +,btreemap_remove_blob_4_1024_v2,600161724,0.00%,0,0.00%,0,0.00% +,btreemap_remove_blob_512_1024,3738145419,0.00%,0,0.00%,0,0.00% +,btreemap_remove_blob_512_1024_v2,3883681704,0.00%,0,0.00%,0,0.00% +,btreemap_remove_blob_64_1024,1139970828,0.00%,0,0.00%,0,0.00% +,btreemap_remove_blob_64_1024_v2,1283145072,0.00%,0,0.00%,0,0.00% +,btreemap_remove_blob_8_1024,642836148,0.00%,0,0.00%,0,0.00% +,btreemap_remove_blob_8_1024_v2,775037862,0.00%,0,0.00%,0,0.00% +,btreemap_remove_blob_8_u64,433944769,0.00%,0,0.00%,0,0.00% +,btreemap_remove_blob_8_u64_v2,579958230,0.00%,0,0.00%,0,0.00% +,btreemap_remove_u64_blob_8,485913516,0.00%,0,0.00%,0,0.00% +,btreemap_remove_u64_blob_8_v2,597538858,0.00%,0,0.00%,0,0.00% +,btreemap_remove_u64_u64,499266505,0.00%,0,0.00%,0,0.00% +,btreemap_remove_u64_u64_v2,619109964,0.00%,0,0.00%,0,0.00% +,btreemap_values_10mib_values,11406848,0.00%,0,0.00%,0,0.00% +,btreemap_values_rev_10mib_values,11403833,0.00%,0,0.00%,0,0.00% +,btreemap_values_rev_small_values,14949875,0.00%,0,0.00%,0,0.00% +,btreemap_values_small_values,14974846,0.00%,0,0.00%,0,0.00% +,memory_manager_baseline,1176577076,0.00%,0,0.00%,8000,0.00% +,memory_manager_grow,346537961,0.00%,2,0.00%,32000,0.00% +,memory_manager_overhead,1181962837,0.00%,0,0.00%,8320,0.00% +,vec_get_blob_128,19246658,0.00%,0,0.00%,0,0.00% +,vec_get_blob_16,6345942,0.00%,0,0.00%,0,0.00% +,vec_get_blob_32,7063501,0.00%,0,0.00%,0,0.00% +,vec_get_blob_4,4804323,0.00%,0,0.00%,0,0.00% +,vec_get_blob_4_mem_manager,7171673,0.00%,0,0.00%,0,0.00% +,vec_get_blob_64,11310940,0.00%,0,0.00%,0,0.00% +,vec_get_blob_64_mem_manager,13651088,0.00%,0,0.00%,0,0.00% +,vec_get_blob_8,5620865,0.00%,0,0.00%,0,0.00% +,vec_get_u64,5270302,0.00%,0,0.00%,0,0.00% +,vec_insert_blob_128,4131421,0.00%,0,0.00%,19,0.00% +,vec_insert_blob_16,3296224,0.00%,0,0.00%,2,0.00% +,vec_insert_blob_32,3415464,0.00%,0,0.00%,5,0.00% +,vec_insert_blob_4,3207465,0.00%,0,0.00%,0,0.00% +,vec_insert_blob_64,3655801,0.00%,0,0.00%,9,0.00% +,vec_insert_blob_8,3236886,0.00%,0,0.00%,1,0.00% +,vec_insert_u64,5859516,0.00%,0,0.00%,1,0.00% From e624b9c13ec5ce1357666acc08ca640a80bef808 Mon Sep 17 00:00:00 2001 From: Maksym Arutyunyan Date: Tue, 13 May 2025 11:49:01 +0200 Subject: [PATCH 33/37] canbench main branch --- scripts/ci_run_benchmark.sh | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/scripts/ci_run_benchmark.sh b/scripts/ci_run_benchmark.sh index d3b6d455..9048f253 100644 --- a/scripts/ci_run_benchmark.sh +++ b/scripts/ci_run_benchmark.sh @@ -25,7 +25,7 @@ CANBENCH_RESULTS_CSV_FILE="/tmp/canbench_results_${CANBENCH_JOB_NAME}.csv" # Install canbench #cargo install --version 0.1.11 canbench -cargo install --git https://github.com/dfinity/canbench --branch maksym/summary-fix canbench +cargo install --git https://github.com/dfinity/canbench --branch main canbench # Verify that the canbench results file exists. if [ ! -f "$CANBENCH_RESULTS_FILE" ]; then From 77546d02d4d25435853511bac9d55855b97c0cf6 Mon Sep 17 00:00:00 2001 From: Maksym Arutyunyan Date: Tue, 13 May 2025 11:49:56 +0200 Subject: [PATCH 34/37] canbench 0.1.12 --- scripts/ci_run_benchmark.sh | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/scripts/ci_run_benchmark.sh b/scripts/ci_run_benchmark.sh index 9048f253..aa62a254 100644 --- a/scripts/ci_run_benchmark.sh +++ b/scripts/ci_run_benchmark.sh @@ -24,8 +24,8 @@ MAIN_BRANCH_RESULTS_FILE="$MAIN_BRANCH_DIR/$CANBENCH_RESULTS_FILE" CANBENCH_RESULTS_CSV_FILE="/tmp/canbench_results_${CANBENCH_JOB_NAME}.csv" # Install canbench -#cargo install --version 0.1.11 canbench -cargo install --git https://github.com/dfinity/canbench --branch main canbench +cargo install --version 0.1.12 canbench +#cargo install --git https://github.com/dfinity/canbench --branch main canbench # Verify that the canbench results file exists. if [ ! -f "$CANBENCH_RESULTS_FILE" ]; then From de918e07152f004203e676819b8d5934c78de074 Mon Sep 17 00:00:00 2001 From: Maksym Arutyunyan Date: Tue, 13 May 2025 12:51:35 +0200 Subject: [PATCH 35/37] --persist --- canbench_results.csv | 248 +++++++++++++++++++++---------------------- canbench_results.yml | 238 ++++++++++++++++++++--------------------- 2 files changed, 243 insertions(+), 243 deletions(-) diff --git a/canbench_results.csv b/canbench_results.csv index 0b90a62d..dbf8034a 100644 --- a/canbench_results.csv +++ b/canbench_results.csv @@ -1,125 +1,125 @@ -status,name,instructions,instructions change %,heap_increase,heap_increase change %,stable_memory_increase,stable_memory_increase change % -,btreemap_contains_key_blob_4_1024,164495877,0.00%,0,0.00%,0,0.00% -,btreemap_contains_key_blob_4_1024_v2,248921977,0.00%,0,0.00%,0,0.00% -,btreemap_get_blob_128_1024,876676182,0.00%,0,0.00%,0,0.00% -,btreemap_get_blob_128_1024_v2,953199881,0.00%,0,0.00%,0,0.00% -,btreemap_get_blob_16_1024,241470994,0.00%,0,0.00%,0,0.00% -,btreemap_get_blob_16_1024_v2,320086039,0.00%,0,0.00%,0,0.00% -,btreemap_get_blob_256_1024,1440152578,0.00%,0,0.00%,0,0.00% -,btreemap_get_blob_256_1024_v2,1524516290,0.00%,0,0.00%,0,0.00% -,btreemap_get_blob_32_1024,275141698,0.00%,0,0.00%,0,0.00% -,btreemap_get_blob_32_1024_v2,353756221,0.00%,0,0.00%,0,0.00% -,btreemap_get_blob_4_1024,182139496,0.00%,0,0.00%,0,0.00% -,btreemap_get_blob_4_1024_v2,267339946,0.00%,0,0.00%,0,0.00% -,btreemap_get_blob_512_1024,2573387979,0.00%,0,0.00%,0,0.00% -,btreemap_get_blob_512_1024_v2,2653499228,0.00%,0,0.00%,0,0.00% -,btreemap_get_blob_512_1024_v2_mem_manager,2759852247,0.00%,0,0.00%,0,0.00% -,btreemap_get_blob_64_1024,521344804,0.00%,0,0.00%,0,0.00% -,btreemap_get_blob_64_1024_v2,603758767,0.00%,0,0.00%,0,0.00% -,btreemap_get_blob_8_1024,212618950,0.00%,0,0.00%,0,0.00% -,btreemap_get_blob_8_1024_v2,294121282,0.00%,0,0.00%,0,0.00% -,btreemap_get_blob_8_u64,199845052,0.00%,0,0.00%,0,0.00% -,btreemap_get_blob_8_u64_v2,289664167,0.00%,0,0.00%,0,0.00% -,btreemap_get_u64_blob_8,173627473,0.00%,0,0.00%,0,0.00% -,btreemap_get_u64_blob_8_v2,245312213,0.00%,0,0.00%,0,0.00% -,btreemap_get_u64_u64,176661272,0.00%,0,0.00%,0,0.00% -,btreemap_get_u64_u64_v2,249218649,0.00%,0,0.00%,0,0.00% -,btreemap_get_u64_u64_v2_mem_manager,329730573,0.00%,0,0.00%,0,0.00% -,btreemap_insert_10mib_values,5235962440,0.00%,0,0.00%,3613,0.00% -,btreemap_insert_blob_1024_128,5098352751,0.00%,0,0.00%,262,0.00% -,btreemap_insert_blob_1024_128_v2,5199218550,0.00%,0,0.00%,196,0.00% -,btreemap_insert_blob_1024_16,5080607598,0.00%,0,0.00%,241,0.00% -,btreemap_insert_blob_1024_16_v2,5187794378,0.00%,0,0.00%,181,0.00% -,btreemap_insert_blob_1024_256,5125958119,0.00%,0,0.00%,292,0.00% -,btreemap_insert_blob_1024_256_v2,5224501040,0.00%,0,0.00%,219,0.00% -,btreemap_insert_blob_1024_32,5075547429,0.00%,0,0.00%,239,0.00% -,btreemap_insert_blob_1024_32_v2,5185065640,0.00%,0,0.00%,180,0.00% -,btreemap_insert_blob_1024_4,4977775085,0.00%,0,0.00%,235,0.00% -,btreemap_insert_blob_1024_4_v2,5084891041,0.00%,0,0.00%,176,0.00% -,btreemap_insert_blob_1024_512,5200292029,0.00%,1,0.00%,348,0.00% -,btreemap_insert_blob_1024_512_v2,5299421985,0.00%,0,0.00%,261,0.00% -,btreemap_insert_blob_1024_512_v2_mem_manager,5469551996,0.00%,0,0.00%,256,0.00% -,btreemap_insert_blob_1024_64,5133691382,0.00%,0,0.00%,250,0.00% -,btreemap_insert_blob_1024_64_v2,5242140512,0.00%,0,0.00%,188,0.00% -,btreemap_insert_blob_1024_8,5065686056,0.00%,0,0.00%,237,0.00% -,btreemap_insert_blob_1024_8_v2,5174504738,0.00%,0,0.00%,178,0.00% -,btreemap_insert_blob_128_1024,1276472811,0.00%,0,0.00%,260,0.00% -,btreemap_insert_blob_128_1024_v2,1378788105,0.00%,0,0.00%,195,0.00% -,btreemap_insert_blob_16_1024,634307113,0.00%,0,0.00%,215,0.00% -,btreemap_insert_blob_16_1024_v2,733723555,0.00%,0,0.00%,161,0.00% -,btreemap_insert_blob_256_1024,1860540926,0.00%,0,0.00%,292,0.00% -,btreemap_insert_blob_256_1024_v2,1967548428,0.00%,0,0.00%,219,0.00% -,btreemap_insert_blob_32_1024,670121076,0.00%,0,0.00%,230,0.00% -,btreemap_insert_blob_32_1024_v2,773022814,0.00%,0,0.00%,173,0.00% -,btreemap_insert_blob_4_1024,494994994,0.00%,0,0.00%,123,0.00% -,btreemap_insert_blob_4_1024_v2,592951465,0.00%,0,0.00%,92,0.00% -,btreemap_insert_blob_512_1024,3002862489,0.00%,0,0.00%,351,0.00% -,btreemap_insert_blob_512_1024_v2,3105965075,0.00%,0,0.00%,263,0.00% -,btreemap_insert_blob_64_1024,919414593,0.00%,0,0.00%,245,0.00% -,btreemap_insert_blob_64_1024_v2,1020998986,0.00%,0,0.00%,183,0.00% -,btreemap_insert_blob_8_1024,605636927,0.00%,0,0.00%,183,0.00% -,btreemap_insert_blob_8_1024_v2,708696031,0.00%,0,0.00%,138,0.00% -,btreemap_insert_blob_8_u64,330055088,0.00%,0,0.00%,6,0.00% -,btreemap_insert_blob_8_u64_v2,440988930,0.00%,0,0.00%,4,0.00% -,btreemap_insert_u64_blob_8,339864719,0.00%,0,0.00%,7,0.00% -,btreemap_insert_u64_blob_8_v2,422835585,0.00%,0,0.00%,5,0.00% -,btreemap_insert_u64_u64,345025209,0.00%,0,0.00%,7,0.00% -,btreemap_insert_u64_u64_v2,431645530,0.00%,0,0.00%,6,0.00% -,btreemap_insert_u64_u64_v2_mem_manager,560976863,0.00%,0,0.00%,0,0.00% -,btreemap_iter_10mib_values,11407368,0.00%,0,0.00%,0,0.00% -,btreemap_iter_count_10mib_values,491365,0.00%,0,0.00%,0,0.00% -,btreemap_iter_count_small_values,9443266,0.00%,0,0.00%,0,0.00% -,btreemap_iter_rev_10mib_values,11404353,0.00%,0,0.00%,0,0.00% -,btreemap_iter_rev_small_values,14975879,0.00%,0,0.00%,0,0.00% -,btreemap_iter_small_values,15000850,0.00%,0,0.00%,0,0.00% -,btreemap_keys_10mib_values,464540,0.00%,0,0.00%,0,0.00% -,btreemap_keys_rev_10mib_values,464165,0.00%,0,0.00%,0,0.00% -,btreemap_keys_rev_small_values,9654062,0.00%,0,0.00%,0,0.00% -,btreemap_keys_small_values,9528327,0.00%,0,0.00%,0,0.00% -,btreemap_read_every_third_value_from_range,84833060,0.00%,0,0.00%,0,0.00% -,btreemap_read_keys_from_range,84873064,0.00%,0,0.00%,0,0.00% -,btreemap_remove_blob_128_1024,1575050534,0.00%,0,0.00%,0,0.00% -,btreemap_remove_blob_128_1024_v2,1721504123,0.00%,0,0.00%,0,0.00% -,btreemap_remove_blob_16_1024,755252791,0.00%,0,0.00%,0,0.00% -,btreemap_remove_blob_16_1024_v2,895690307,0.00%,0,0.00%,0,0.00% -,btreemap_remove_blob_256_1024,2279810995,0.00%,0,0.00%,0,0.00% -,btreemap_remove_blob_256_1024_v2,2427184450,0.00%,0,0.00%,0,0.00% -,btreemap_remove_blob_32_1024,825632231,0.00%,0,0.00%,0,0.00% -,btreemap_remove_blob_32_1024_v2,965884147,0.00%,0,0.00%,0,0.00% -,btreemap_remove_blob_4_1024,485805538,0.00%,0,0.00%,0,0.00% -,btreemap_remove_blob_4_1024_v2,600161724,0.00%,0,0.00%,0,0.00% -,btreemap_remove_blob_512_1024,3738145419,0.00%,0,0.00%,0,0.00% -,btreemap_remove_blob_512_1024_v2,3883681704,0.00%,0,0.00%,0,0.00% -,btreemap_remove_blob_64_1024,1139970828,0.00%,0,0.00%,0,0.00% -,btreemap_remove_blob_64_1024_v2,1283145072,0.00%,0,0.00%,0,0.00% -,btreemap_remove_blob_8_1024,642836148,0.00%,0,0.00%,0,0.00% -,btreemap_remove_blob_8_1024_v2,775037862,0.00%,0,0.00%,0,0.00% -,btreemap_remove_blob_8_u64,433944769,0.00%,0,0.00%,0,0.00% -,btreemap_remove_blob_8_u64_v2,579958230,0.00%,0,0.00%,0,0.00% -,btreemap_remove_u64_blob_8,485913516,0.00%,0,0.00%,0,0.00% -,btreemap_remove_u64_blob_8_v2,597538858,0.00%,0,0.00%,0,0.00% -,btreemap_remove_u64_u64,499266505,0.00%,0,0.00%,0,0.00% -,btreemap_remove_u64_u64_v2,619109964,0.00%,0,0.00%,0,0.00% -,btreemap_values_10mib_values,11406848,0.00%,0,0.00%,0,0.00% -,btreemap_values_rev_10mib_values,11403833,0.00%,0,0.00%,0,0.00% -,btreemap_values_rev_small_values,14949875,0.00%,0,0.00%,0,0.00% -,btreemap_values_small_values,14974846,0.00%,0,0.00%,0,0.00% -,memory_manager_baseline,1176577076,0.00%,0,0.00%,8000,0.00% +status,name,instructions,instructions %,heap_increase,heap_increase %,stable_memory_increase,stable_memory_increase % +,btreemap_contains_key_blob_4_1024,164495877,-0.91%,0,,0, +,btreemap_contains_key_blob_4_1024_v2,248921977,0.94%,0,,0, +,btreemap_get_blob_128_1024,876676182,0.61%,0,,0, +,btreemap_get_blob_128_1024_v2,953199881,0.08%,0,,0, +,btreemap_get_blob_16_1024,241470994,-2.18%,0,,0, +,btreemap_get_blob_16_1024_v2,320086039,-0.87%,0,,0, +,btreemap_get_blob_256_1024,1440152578,0.12%,0,,0, +,btreemap_get_blob_256_1024_v2,1524516290,0.13%,0,,0, +,btreemap_get_blob_32_1024,275141698,-1.77%,0,,0, +,btreemap_get_blob_32_1024_v2,353756221,-1.20%,0,,0, +,btreemap_get_blob_4_1024,182139496,-0.95%,0,,0, +,btreemap_get_blob_4_1024_v2,267339946,-0.40%,0,,0, +,btreemap_get_blob_512_1024,2573387979,-0.02%,0,,0, +,btreemap_get_blob_512_1024_v2,2653499228,0.02%,0,,0, +,btreemap_get_blob_512_1024_v2_mem_manager,2759852247,0.03%,0,,0, +,btreemap_get_blob_64_1024,521344804,-0.21%,0,,0, +,btreemap_get_blob_64_1024_v2,603758767,0.21%,0,,0, +,btreemap_get_blob_8_1024,212618950,-2.20%,0,,0, +,btreemap_get_blob_8_1024_v2,294121282,-1.86%,0,,0, +,btreemap_get_blob_8_u64,199845052,-0.66%,0,,0, +,btreemap_get_blob_8_u64_v2,289664167,-2.82%,0,,0, +,btreemap_get_u64_blob_8,173627473,-1.15%,0,,0, +,btreemap_get_u64_blob_8_v2,245312213,-1.86%,0,,0, +,btreemap_get_u64_u64,176661272,0.17%,0,,0, +,btreemap_get_u64_u64_v2,249218649,-2.90%,0,,0, +,btreemap_get_u64_u64_v2_mem_manager,329730573,-1.92%,0,,0, +,btreemap_insert_10mib_values,5235962440,0.00%,0,,3613,0.00% +,btreemap_insert_blob_1024_128,5098352751,-0.23%,0,,262,0.00% +,btreemap_insert_blob_1024_128_v2,5199218550,-0.04%,0,,196,0.00% +,btreemap_insert_blob_1024_16,5080607598,-0.63%,0,,241,0.00% +,btreemap_insert_blob_1024_16_v2,5187794378,-0.23%,0,,181,0.00% +,btreemap_insert_blob_1024_256,5125958119,-0.11%,0,,292,0.00% +,btreemap_insert_blob_1024_256_v2,5224501040,-0.01%,0,,219,0.00% +,btreemap_insert_blob_1024_32,5075547429,-0.40%,0,,239,0.00% +,btreemap_insert_blob_1024_32_v2,5185065640,-0.18%,0,,180,0.00% +,btreemap_insert_blob_1024_4,4977775085,-0.82%,0,,235,0.00% +,btreemap_insert_blob_1024_4_v2,5084891041,-0.25%,0,,176,0.00% +,btreemap_insert_blob_1024_512,5200292029,-0.11%,1,,348,0.00% +,btreemap_insert_blob_1024_512_v2,5299421985,-0.11%,0,,261,0.00% +,btreemap_insert_blob_1024_512_v2_mem_manager,5469551996,-0.10%,0,,256,0.00% +,btreemap_insert_blob_1024_64,5133691382,-0.31%,0,,250,0.00% +,btreemap_insert_blob_1024_64_v2,5242140512,-0.12%,0,,188,0.00% +,btreemap_insert_blob_1024_8,5065686056,-0.38%,0,,237,0.00% +,btreemap_insert_blob_1024_8_v2,5174504738,-0.24%,0,,178,0.00% +,btreemap_insert_blob_128_1024,1276472811,0.29%,0,,260,0.00% +,btreemap_insert_blob_128_1024_v2,1378788105,0.43%,0,,195,0.00% +,btreemap_insert_blob_16_1024,634307113,-0.48%,0,,215,0.00% +,btreemap_insert_blob_16_1024_v2,733723555,0.24%,0,,161,0.00% +,btreemap_insert_blob_256_1024,1860540926,0.06%,0,,292,0.00% +,btreemap_insert_blob_256_1024_v2,1967548428,0.52%,0,,219,0.00% +,btreemap_insert_blob_32_1024,670121076,-0.34%,0,,230,0.00% +,btreemap_insert_blob_32_1024_v2,773022814,0.43%,0,,173,0.00% +,btreemap_insert_blob_4_1024,494994994,-0.38%,0,,123,0.00% +,btreemap_insert_blob_4_1024_v2,592951465,-0.08%,0,,92,0.00% +,btreemap_insert_blob_512_1024,3002862489,-0.25%,0,,351,0.00% +,btreemap_insert_blob_512_1024_v2,3105965075,0.06%,0,,263,0.00% +,btreemap_insert_blob_64_1024,919414593,-0.01%,0,,245,0.00% +,btreemap_insert_blob_64_1024_v2,1020998986,0.55%,0,,183,0.00% +,btreemap_insert_blob_8_1024,605636927,-0.29%,0,,183,0.00% +,btreemap_insert_blob_8_1024_v2,708696031,-0.05%,0,,138,0.00% +,btreemap_insert_blob_8_u64,330055088,0.06%,0,,6,0.00% +,btreemap_insert_blob_8_u64_v2,440988930,0.07%,0,,4,0.00% +,btreemap_insert_u64_blob_8,339864719,0.12%,0,,7,0.00% +,btreemap_insert_u64_blob_8_v2,422835585,0.69%,0,,5,0.00% +,btreemap_insert_u64_u64,345025209,0.01%,0,,7,0.00% +,btreemap_insert_u64_u64_v2,431645530,0.73%,0,,6,0.00% +,btreemap_insert_u64_u64_v2_mem_manager,560976863,0.50%,0,,0, +,btreemap_iter_10mib_values,11407368,-0.00%,0,,0, +,btreemap_iter_count_10mib_values,491365,2.95%,0,,0, +,btreemap_iter_count_small_values,9443266,0.01%,0,,0, +,btreemap_iter_rev_10mib_values,11404353,-0.00%,0,,0, +,btreemap_iter_rev_small_values,14975879,0.00%,0,,0, +,btreemap_iter_small_values,15000850,0.15%,0,,0, +,btreemap_keys_10mib_values,464540,-0.00%,0,,0, +,btreemap_keys_rev_10mib_values,464165,-0.01%,0,,0, +,btreemap_keys_rev_small_values,9654062,0.00%,0,,0, +,btreemap_keys_small_values,9528327,0.23%,0,,0, +,btreemap_read_every_third_value_from_range,84833060,0.78%,0,,0, +,btreemap_read_keys_from_range,84873064,0.78%,0,,0, +,btreemap_remove_blob_128_1024,1575050534,0.08%,0,,0, +,btreemap_remove_blob_128_1024_v2,1721504123,0.28%,0,,0, +,btreemap_remove_blob_16_1024,755252791,-0.27%,0,,0, +,btreemap_remove_blob_16_1024_v2,895690307,0.06%,0,,0, +,btreemap_remove_blob_256_1024,2279810995,0.07%,0,,0, +,btreemap_remove_blob_256_1024_v2,2427184450,0.42%,0,,0, +,btreemap_remove_blob_32_1024,825632231,-0.14%,0,,0, +,btreemap_remove_blob_32_1024_v2,965884147,0.00%,0,,0, +,btreemap_remove_blob_4_1024,485805538,-0.03%,0,,0, +,btreemap_remove_blob_4_1024_v2,600161724,0.10%,0,,0, +,btreemap_remove_blob_512_1024,3738145419,-0.27%,0,,0, +,btreemap_remove_blob_512_1024_v2,3883681704,0.16%,0,,0, +,btreemap_remove_blob_64_1024,1139970828,-0.01%,0,,0, +,btreemap_remove_blob_64_1024_v2,1283145072,0.25%,0,,0, +,btreemap_remove_blob_8_1024,642836148,-0.19%,0,,0, +,btreemap_remove_blob_8_1024_v2,775037862,-0.13%,0,,0, +,btreemap_remove_blob_8_u64,433944769,-0.08%,0,,0, +,btreemap_remove_blob_8_u64_v2,579958230,-0.57%,0,,0, +,btreemap_remove_u64_blob_8,485913516,0.21%,0,,0, +,btreemap_remove_u64_blob_8_v2,597538858,-0.46%,0,,0, +,btreemap_remove_u64_u64,499266505,0.24%,0,,0, +,btreemap_remove_u64_u64_v2,619109964,-0.59%,0,,0, +,btreemap_values_10mib_values,11406848,-0.00%,0,,0, +,btreemap_values_rev_10mib_values,11403833,-0.00%,0,,0, +,btreemap_values_rev_small_values,14949875,0.00%,0,,0, +,btreemap_values_small_values,14974846,0.15%,0,,0, +,memory_manager_baseline,1176577076,0.00%,0,,8000,0.00% ,memory_manager_grow,346537961,0.00%,2,0.00%,32000,0.00% -,memory_manager_overhead,1181962837,0.00%,0,0.00%,8320,0.00% -,vec_get_blob_128,19246658,0.00%,0,0.00%,0,0.00% -,vec_get_blob_16,6345942,0.00%,0,0.00%,0,0.00% -,vec_get_blob_32,7063501,0.00%,0,0.00%,0,0.00% -,vec_get_blob_4,4804323,0.00%,0,0.00%,0,0.00% -,vec_get_blob_4_mem_manager,7171673,0.00%,0,0.00%,0,0.00% -,vec_get_blob_64,11310940,0.00%,0,0.00%,0,0.00% -,vec_get_blob_64_mem_manager,13651088,0.00%,0,0.00%,0,0.00% -,vec_get_blob_8,5620865,0.00%,0,0.00%,0,0.00% -,vec_get_u64,5270302,0.00%,0,0.00%,0,0.00% -,vec_insert_blob_128,4131421,0.00%,0,0.00%,19,0.00% -,vec_insert_blob_16,3296224,0.00%,0,0.00%,2,0.00% -,vec_insert_blob_32,3415464,0.00%,0,0.00%,5,0.00% -,vec_insert_blob_4,3207465,0.00%,0,0.00%,0,0.00% -,vec_insert_blob_64,3655801,0.00%,0,0.00%,9,0.00% -,vec_insert_blob_8,3236886,0.00%,0,0.00%,1,0.00% -,vec_insert_u64,5859516,0.00%,0,0.00%,1,0.00% +,memory_manager_overhead,1181962837,0.00%,0,,8320,0.00% +,vec_get_blob_128,19246658,-0.31%,0,,0, +,vec_get_blob_16,6345942,-0.88%,0,,0, +,vec_get_blob_32,7063501,-0.82%,0,,0, +,vec_get_blob_4,4804323,-0.93%,0,,0, +,vec_get_blob_4_mem_manager,7171673,-0.63%,0,,0, +,vec_get_blob_64,11310940,-0.52%,0,,0, +,vec_get_blob_64_mem_manager,13651088,-0.43%,0,,0, +,vec_get_blob_8,5620865,-0.93%,0,,0, +,vec_get_u64,5270302,-1.13%,0,,0, +,vec_insert_blob_128,4131421,0.00%,0,,19,0.00% +,vec_insert_blob_16,3296224,0.00%,0,,2,0.00% +,vec_insert_blob_32,3415464,0.00%,0,,5,0.00% +,vec_insert_blob_4,3207465,0.00%,0,,0, +,vec_insert_blob_64,3655801,0.00%,0,,9,0.00% +,vec_insert_blob_8,3236886,0.00%,0,,1,0.00% +,vec_insert_u64,5859516,-1.01%,0,,1,0.00% diff --git a/canbench_results.yml b/canbench_results.yml index 2ad468d5..855a6a71 100644 --- a/canbench_results.yml +++ b/canbench_results.yml @@ -1,631 +1,631 @@ benches: btreemap_contains_key_blob_4_1024: total: - instructions: 166001911 + instructions: 164495877 heap_increase: 0 stable_memory_increase: 0 scopes: {} btreemap_contains_key_blob_4_1024_v2: total: - instructions: 246601947 + instructions: 248921977 heap_increase: 0 stable_memory_increase: 0 scopes: {} btreemap_get_blob_128_1024: total: - instructions: 871377872 + instructions: 876676182 heap_increase: 0 stable_memory_increase: 0 scopes: {} btreemap_get_blob_128_1024_v2: total: - instructions: 952392228 + instructions: 953199881 heap_increase: 0 stable_memory_increase: 0 scopes: {} btreemap_get_blob_16_1024: total: - instructions: 246862995 + instructions: 241470994 heap_increase: 0 stable_memory_increase: 0 scopes: {} btreemap_get_blob_16_1024_v2: total: - instructions: 322886242 + instructions: 320086039 heap_increase: 0 stable_memory_increase: 0 scopes: {} btreemap_get_blob_256_1024: total: - instructions: 1438374028 + instructions: 1440152578 heap_increase: 0 stable_memory_increase: 0 scopes: {} btreemap_get_blob_256_1024_v2: total: - instructions: 1522510069 + instructions: 1524516290 heap_increase: 0 stable_memory_increase: 0 scopes: {} btreemap_get_blob_32_1024: total: - instructions: 280106749 + instructions: 275141698 heap_increase: 0 stable_memory_increase: 0 scopes: {} btreemap_get_blob_32_1024_v2: total: - instructions: 358059329 + instructions: 353756221 heap_increase: 0 stable_memory_increase: 0 scopes: {} btreemap_get_blob_4_1024: total: - instructions: 183878297 + instructions: 182139496 heap_increase: 0 stable_memory_increase: 0 scopes: {} btreemap_get_blob_4_1024_v2: total: - instructions: 268405505 + instructions: 267339946 heap_increase: 0 stable_memory_increase: 0 scopes: {} btreemap_get_blob_512_1024: total: - instructions: 2574022254 + instructions: 2573387979 heap_increase: 0 stable_memory_increase: 0 scopes: {} btreemap_get_blob_512_1024_v2: total: - instructions: 2652896322 + instructions: 2653499228 heap_increase: 0 stable_memory_increase: 0 scopes: {} btreemap_get_blob_512_1024_v2_mem_manager: total: - instructions: 2758935787 + instructions: 2759852247 heap_increase: 0 stable_memory_increase: 0 scopes: {} btreemap_get_blob_64_1024: total: - instructions: 522452991 + instructions: 521344804 heap_increase: 0 stable_memory_increase: 0 scopes: {} btreemap_get_blob_64_1024_v2: total: - instructions: 602470697 + instructions: 603758767 heap_increase: 0 stable_memory_increase: 0 scopes: {} btreemap_get_blob_8_1024: total: - instructions: 217400954 + instructions: 212618950 heap_increase: 0 stable_memory_increase: 0 scopes: {} btreemap_get_blob_8_1024_v2: total: - instructions: 299709226 + instructions: 294121282 heap_increase: 0 stable_memory_increase: 0 scopes: {} btreemap_get_blob_8_u64: total: - instructions: 201178254 + instructions: 199845052 heap_increase: 0 stable_memory_increase: 0 scopes: {} btreemap_get_blob_8_u64_v2: total: - instructions: 298067604 + instructions: 289664167 heap_increase: 0 stable_memory_increase: 0 scopes: {} btreemap_get_u64_blob_8: total: - instructions: 175651037 + instructions: 173627473 heap_increase: 0 stable_memory_increase: 0 scopes: {} btreemap_get_u64_blob_8_v2: total: - instructions: 249967565 + instructions: 245312213 heap_increase: 0 stable_memory_increase: 0 scopes: {} btreemap_get_u64_u64: total: - instructions: 176359012 + instructions: 176661272 heap_increase: 0 stable_memory_increase: 0 scopes: {} btreemap_get_u64_u64_v2: total: - instructions: 256656266 + instructions: 249218649 heap_increase: 0 stable_memory_increase: 0 scopes: {} btreemap_get_u64_u64_v2_mem_manager: total: - instructions: 336201045 + instructions: 329730573 heap_increase: 0 stable_memory_increase: 0 scopes: {} btreemap_insert_10mib_values: total: - instructions: 5235943961 + instructions: 5235962440 heap_increase: 0 stable_memory_increase: 3613 scopes: {} btreemap_insert_blob_1024_128: total: - instructions: 5110208593 + instructions: 5098352751 heap_increase: 0 stable_memory_increase: 262 scopes: {} btreemap_insert_blob_1024_128_v2: total: - instructions: 5201453100 + instructions: 5199218550 heap_increase: 0 stable_memory_increase: 196 scopes: {} btreemap_insert_blob_1024_16: total: - instructions: 5112815038 + instructions: 5080607598 heap_increase: 0 stable_memory_increase: 241 scopes: {} btreemap_insert_blob_1024_16_v2: total: - instructions: 5199674897 + instructions: 5187794378 heap_increase: 0 stable_memory_increase: 181 scopes: {} btreemap_insert_blob_1024_256: total: - instructions: 5131549882 + instructions: 5125958119 heap_increase: 0 stable_memory_increase: 292 scopes: {} btreemap_insert_blob_1024_256_v2: total: - instructions: 5225231848 + instructions: 5224501040 heap_increase: 0 stable_memory_increase: 219 scopes: {} btreemap_insert_blob_1024_32: total: - instructions: 5096055369 + instructions: 5075547429 heap_increase: 0 stable_memory_increase: 239 scopes: {} btreemap_insert_blob_1024_32_v2: total: - instructions: 5194253455 + instructions: 5185065640 heap_increase: 0 stable_memory_increase: 180 scopes: {} btreemap_insert_blob_1024_4: total: - instructions: 5018854334 + instructions: 4977775085 heap_increase: 0 stable_memory_increase: 235 scopes: {} btreemap_insert_blob_1024_4_v2: total: - instructions: 5097737990 + instructions: 5084891041 heap_increase: 0 stable_memory_increase: 176 scopes: {} btreemap_insert_blob_1024_512: total: - instructions: 5205867924 - heap_increase: 0 + instructions: 5200292029 + heap_increase: 1 stable_memory_increase: 348 scopes: {} btreemap_insert_blob_1024_512_v2: total: - instructions: 5305383655 + instructions: 5299421985 heap_increase: 0 stable_memory_increase: 261 scopes: {} btreemap_insert_blob_1024_512_v2_mem_manager: total: - instructions: 5474930162 + instructions: 5469551996 heap_increase: 0 stable_memory_increase: 256 scopes: {} btreemap_insert_blob_1024_64: total: - instructions: 5149718328 + instructions: 5133691382 heap_increase: 0 stable_memory_increase: 250 scopes: {} btreemap_insert_blob_1024_64_v2: total: - instructions: 5248619760 + instructions: 5242140512 heap_increase: 0 stable_memory_increase: 188 scopes: {} btreemap_insert_blob_1024_8: total: - instructions: 5084892193 + instructions: 5065686056 heap_increase: 0 stable_memory_increase: 237 scopes: {} btreemap_insert_blob_1024_8_v2: total: - instructions: 5187073263 + instructions: 5174504738 heap_increase: 0 stable_memory_increase: 178 scopes: {} btreemap_insert_blob_128_1024: total: - instructions: 1272772874 + instructions: 1276472811 heap_increase: 0 stable_memory_increase: 260 scopes: {} btreemap_insert_blob_128_1024_v2: total: - instructions: 1372830782 + instructions: 1378788105 heap_increase: 0 stable_memory_increase: 195 scopes: {} btreemap_insert_blob_16_1024: total: - instructions: 637364736 + instructions: 634307113 heap_increase: 0 stable_memory_increase: 215 scopes: {} btreemap_insert_blob_16_1024_v2: total: - instructions: 731987999 + instructions: 733723555 heap_increase: 0 stable_memory_increase: 161 scopes: {} btreemap_insert_blob_256_1024: total: - instructions: 1859383657 + instructions: 1860540926 heap_increase: 0 stable_memory_increase: 292 scopes: {} btreemap_insert_blob_256_1024_v2: total: - instructions: 1957371233 + instructions: 1967548428 heap_increase: 0 stable_memory_increase: 219 scopes: {} btreemap_insert_blob_32_1024: total: - instructions: 672421095 + instructions: 670121076 heap_increase: 0 stable_memory_increase: 230 scopes: {} btreemap_insert_blob_32_1024_v2: total: - instructions: 769687258 + instructions: 773022814 heap_increase: 0 stable_memory_increase: 173 scopes: {} btreemap_insert_blob_4_1024: total: - instructions: 496883691 + instructions: 494994994 heap_increase: 0 stable_memory_increase: 123 scopes: {} btreemap_insert_blob_4_1024_v2: total: - instructions: 593431891 + instructions: 592951465 heap_increase: 0 stable_memory_increase: 92 scopes: {} btreemap_insert_blob_512_1024: total: - instructions: 3010338686 + instructions: 3002862489 heap_increase: 0 stable_memory_increase: 351 scopes: {} btreemap_insert_blob_512_1024_v2: total: - instructions: 3104211392 + instructions: 3105965075 heap_increase: 0 stable_memory_increase: 263 scopes: {} btreemap_insert_blob_64_1024: total: - instructions: 919481835 + instructions: 919414593 heap_increase: 0 stable_memory_increase: 245 scopes: {} btreemap_insert_blob_64_1024_v2: total: - instructions: 1015421433 + instructions: 1020998986 heap_increase: 0 stable_memory_increase: 183 scopes: {} btreemap_insert_blob_8_1024: total: - instructions: 607378396 + instructions: 605636927 heap_increase: 0 stable_memory_increase: 183 scopes: {} btreemap_insert_blob_8_1024_v2: total: - instructions: 709076144 + instructions: 708696031 heap_increase: 0 stable_memory_increase: 138 scopes: {} btreemap_insert_blob_8_u64: total: - instructions: 329873548 + instructions: 330055088 heap_increase: 0 stable_memory_increase: 6 scopes: {} btreemap_insert_blob_8_u64_v2: total: - instructions: 440675672 + instructions: 440988930 heap_increase: 0 stable_memory_increase: 4 scopes: {} btreemap_insert_u64_blob_8: total: - instructions: 339462674 + instructions: 339864719 heap_increase: 0 stable_memory_increase: 7 scopes: {} btreemap_insert_u64_blob_8_v2: total: - instructions: 419939410 + instructions: 422835585 heap_increase: 0 stable_memory_increase: 5 scopes: {} btreemap_insert_u64_u64: total: - instructions: 345002937 + instructions: 345025209 heap_increase: 0 stable_memory_increase: 7 scopes: {} btreemap_insert_u64_u64_v2: total: - instructions: 428515075 + instructions: 431645530 heap_increase: 0 stable_memory_increase: 6 scopes: {} btreemap_insert_u64_u64_v2_mem_manager: total: - instructions: 558164116 + instructions: 560976863 heap_increase: 0 stable_memory_increase: 0 scopes: {} btreemap_iter_10mib_values: total: - instructions: 11407375 + instructions: 11407368 heap_increase: 0 stable_memory_increase: 0 scopes: {} btreemap_iter_count_10mib_values: total: - instructions: 477290 + instructions: 491365 heap_increase: 0 stable_memory_increase: 0 scopes: {} btreemap_iter_count_small_values: total: - instructions: 9442534 + instructions: 9443266 heap_increase: 0 stable_memory_increase: 0 scopes: {} btreemap_iter_rev_10mib_values: total: - instructions: 11404378 + instructions: 11404353 heap_increase: 0 stable_memory_increase: 0 scopes: {} btreemap_iter_rev_small_values: total: - instructions: 14975518 + instructions: 14975879 heap_increase: 0 stable_memory_increase: 0 scopes: {} btreemap_iter_small_values: total: - instructions: 14978611 + instructions: 15000850 heap_increase: 0 stable_memory_increase: 0 scopes: {} btreemap_keys_10mib_values: total: - instructions: 464547 + instructions: 464540 heap_increase: 0 stable_memory_increase: 0 scopes: {} btreemap_keys_rev_10mib_values: total: - instructions: 464190 + instructions: 464165 heap_increase: 0 stable_memory_increase: 0 scopes: {} btreemap_keys_rev_small_values: total: - instructions: 9653701 + instructions: 9654062 heap_increase: 0 stable_memory_increase: 0 scopes: {} btreemap_keys_small_values: total: - instructions: 9506088 + instructions: 9528327 heap_increase: 0 stable_memory_increase: 0 scopes: {} btreemap_read_every_third_value_from_range: total: - instructions: 84178399 + instructions: 84833060 heap_increase: 0 stable_memory_increase: 0 scopes: {} btreemap_read_keys_from_range: total: - instructions: 84218403 + instructions: 84873064 heap_increase: 0 stable_memory_increase: 0 scopes: {} btreemap_remove_blob_128_1024: total: - instructions: 1573792197 + instructions: 1575050534 heap_increase: 0 stable_memory_increase: 0 scopes: {} btreemap_remove_blob_128_1024_v2: total: - instructions: 1716743733 + instructions: 1721504123 heap_increase: 0 stable_memory_increase: 0 scopes: {} btreemap_remove_blob_16_1024: total: - instructions: 757326757 + instructions: 755252791 heap_increase: 0 stable_memory_increase: 0 scopes: {} btreemap_remove_blob_16_1024_v2: total: - instructions: 895123689 + instructions: 895690307 heap_increase: 0 stable_memory_increase: 0 scopes: {} btreemap_remove_blob_256_1024: total: - instructions: 2278298539 + instructions: 2279810995 heap_increase: 0 stable_memory_increase: 0 scopes: {} btreemap_remove_blob_256_1024_v2: total: - instructions: 2416985342 + instructions: 2427184450 heap_increase: 0 stable_memory_increase: 0 scopes: {} btreemap_remove_blob_32_1024: total: - instructions: 826755312 + instructions: 825632231 heap_increase: 0 stable_memory_increase: 0 scopes: {} btreemap_remove_blob_32_1024_v2: total: - instructions: 965860173 + instructions: 965884147 heap_increase: 0 stable_memory_increase: 0 scopes: {} btreemap_remove_blob_4_1024: total: - instructions: 485954031 + instructions: 485805538 heap_increase: 0 stable_memory_increase: 0 scopes: {} btreemap_remove_blob_4_1024_v2: total: - instructions: 599544997 + instructions: 600161724 heap_increase: 0 stable_memory_increase: 0 scopes: {} btreemap_remove_blob_512_1024: total: - instructions: 3748097651 + instructions: 3738145419 heap_increase: 0 stable_memory_increase: 0 scopes: {} btreemap_remove_blob_512_1024_v2: total: - instructions: 3877288521 + instructions: 3883681704 heap_increase: 0 stable_memory_increase: 0 scopes: {} btreemap_remove_blob_64_1024: total: - instructions: 1140140271 + instructions: 1139970828 heap_increase: 0 stable_memory_increase: 0 scopes: {} btreemap_remove_blob_64_1024_v2: total: - instructions: 1279997559 + instructions: 1283145072 heap_increase: 0 stable_memory_increase: 0 scopes: {} btreemap_remove_blob_8_1024: total: - instructions: 644037223 + instructions: 642836148 heap_increase: 0 stable_memory_increase: 0 scopes: {} btreemap_remove_blob_8_1024_v2: total: - instructions: 776025357 + instructions: 775037862 heap_increase: 0 stable_memory_increase: 0 scopes: {} btreemap_remove_blob_8_u64: total: - instructions: 434301327 + instructions: 433944769 heap_increase: 0 stable_memory_increase: 0 scopes: {} btreemap_remove_blob_8_u64_v2: total: - instructions: 583272060 + instructions: 579958230 heap_increase: 0 stable_memory_increase: 0 scopes: {} btreemap_remove_u64_blob_8: total: - instructions: 484889535 + instructions: 485913516 heap_increase: 0 stable_memory_increase: 0 scopes: {} btreemap_remove_u64_blob_8_v2: total: - instructions: 600284021 + instructions: 597538858 heap_increase: 0 stable_memory_increase: 0 scopes: {} btreemap_remove_u64_u64: total: - instructions: 498062638 + instructions: 499266505 heap_increase: 0 stable_memory_increase: 0 scopes: {} btreemap_remove_u64_u64_v2: total: - instructions: 622756309 + instructions: 619109964 heap_increase: 0 stable_memory_increase: 0 scopes: {} btreemap_values_10mib_values: total: - instructions: 11406855 + instructions: 11406848 heap_increase: 0 stable_memory_increase: 0 scopes: {} btreemap_values_rev_10mib_values: total: - instructions: 11403858 + instructions: 11403833 heap_increase: 0 stable_memory_increase: 0 scopes: {} btreemap_values_rev_small_values: total: - instructions: 14949514 + instructions: 14949875 heap_increase: 0 stable_memory_increase: 0 scopes: {} btreemap_values_small_values: total: - instructions: 14952607 + instructions: 14974846 heap_increase: 0 stable_memory_increase: 0 scopes: {} @@ -637,67 +637,67 @@ benches: scopes: {} memory_manager_grow: total: - instructions: 346536492 + instructions: 346537961 heap_increase: 2 stable_memory_increase: 32000 scopes: {} memory_manager_overhead: total: - instructions: 1181962535 + instructions: 1181962837 heap_increase: 0 stable_memory_increase: 8320 scopes: {} vec_get_blob_128: total: - instructions: 19306238 + instructions: 19246658 heap_increase: 0 stable_memory_increase: 0 scopes: {} vec_get_blob_16: total: - instructions: 6402222 + instructions: 6345942 heap_increase: 0 stable_memory_increase: 0 scopes: {} vec_get_blob_32: total: - instructions: 7121653 + instructions: 7063501 heap_increase: 0 stable_memory_increase: 0 scopes: {} vec_get_blob_4: total: - instructions: 4849623 + instructions: 4804323 heap_increase: 0 stable_memory_increase: 0 scopes: {} vec_get_blob_4_mem_manager: total: - instructions: 7216973 + instructions: 7171673 heap_increase: 0 stable_memory_increase: 0 scopes: {} vec_get_blob_64: total: - instructions: 11370052 + instructions: 11310940 heap_increase: 0 stable_memory_increase: 0 scopes: {} vec_get_blob_64_mem_manager: total: - instructions: 13710200 + instructions: 13651088 heap_increase: 0 stable_memory_increase: 0 scopes: {} vec_get_blob_8: total: - instructions: 5673869 + instructions: 5620865 heap_increase: 0 stable_memory_increase: 0 scopes: {} vec_get_u64: total: - instructions: 5330302 + instructions: 5270302 heap_increase: 0 stable_memory_increase: 0 scopes: {} @@ -739,8 +739,8 @@ benches: scopes: {} vec_insert_u64: total: - instructions: 5919429 + instructions: 5859516 heap_increase: 0 stable_memory_increase: 1 scopes: {} -version: 0.1.11 +version: 0.1.12 From 991bc2bc222ae8b56d9dc4bc685305f8975f2110 Mon Sep 17 00:00:00 2001 From: Maksym Arutyunyan Date: Tue, 13 May 2025 12:59:19 +0200 Subject: [PATCH 36/37] canbench 0.1.12 --- .github/workflows/ci.yml | 5 ----- scripts/ci_run_benchmark.sh | 25 ++++++++++++++++--------- 2 files changed, 16 insertions(+), 14 deletions(-) diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index 81480cbf..b938c7a5 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -117,11 +117,6 @@ jobs: name: canbench_result_${{github.job}} path: /tmp/canbench_result_${{ github.job }} - - uses: actions/upload-artifact@v4 - with: - name: canbench_results_${{github.job}}_csv - path: /tmp/canbench_results_${{ github.job }}.csv - - name: Save PR number run: | echo ${{ github.event.number }} > /tmp/pr_number diff --git a/scripts/ci_run_benchmark.sh b/scripts/ci_run_benchmark.sh index aa62a254..3f9631c0 100644 --- a/scripts/ci_run_benchmark.sh +++ b/scripts/ci_run_benchmark.sh @@ -21,11 +21,8 @@ CANBENCH_OUTPUT=/tmp/canbench_output.txt CANBENCH_RESULTS_FILE="$CANISTER_PATH/canbench_results.yml" MAIN_BRANCH_RESULTS_FILE="$MAIN_BRANCH_DIR/$CANBENCH_RESULTS_FILE" -CANBENCH_RESULTS_CSV_FILE="/tmp/canbench_results_${CANBENCH_JOB_NAME}.csv" - -# Install canbench +# Install canbench. cargo install --version 0.1.12 canbench -#cargo install --git https://github.com/dfinity/canbench --branch main canbench # Verify that the canbench results file exists. if [ ! -f "$CANBENCH_RESULTS_FILE" ]; then @@ -43,7 +40,7 @@ if grep -q "(regress\|(improved by \|(new)" "$CANBENCH_OUTPUT"; then # Results are outdated; fail the job. echo "EXIT_STATUS=1" >> "$GITHUB_ENV" else - UPDATED_MSG="✅ \`$CANBENCH_RESULTS_FILE\` is up to date"; + UPDATED_MSG="**✅ \`$CANBENCH_RESULTS_FILE\` is up to date**"; # Results are up to date; job succeeds. echo "EXIT_STATUS=0" >> "$GITHUB_ENV" @@ -64,17 +61,27 @@ if [ -f "$MAIN_BRANCH_RESULTS_FILE" ]; then # Run canbench to compare results with the main branch. pushd "$CANISTER_PATH" - canbench --less-verbose --hide-results --show-summary --csv > "$CANBENCH_OUTPUT" - cp "./canbench_results.csv" "$CANBENCH_RESULTS_CSV_FILE" + canbench --less-verbose --show-summary > "$CANBENCH_OUTPUT" popd - CSV_RESULTS_FILE_MSG="đŸ“Ļ \`canbench_results_$CANBENCH_JOB_NAME.csv\` available in [artifacts](${GITHUB_SERVER_URL}/${GITHUB_REPOSITORY}/actions/runs/${GITHUB_RUN_ID})" + # Append markers to individual benchmark results + awk ' + /\(improved / { print $0, "đŸŸĸ"; next } + /\(regressed / { print $0, "🔴"; next } + /\(new\)/ { print $0, "🟡"; next } + { print } + ' "$CANBENCH_OUTPUT" > "${CANBENCH_OUTPUT}.tmp" && mv "${CANBENCH_OUTPUT}.tmp" "$CANBENCH_OUTPUT" + + # Add a top-level summary of detected performance changes + MESSAGE="" + grep -q "(improved " "${CANBENCH_OUTPUT}" && MESSAGE+="**đŸŸĸ Performance improvements detected! 🎉**\n" + grep -q "(regressed " "${CANBENCH_OUTPUT}" && MESSAGE+="**🔴 Performance regressions detected! 😱**\n" + echo -e "${MESSAGE:-**â„šī¸ No significant performance changes detected 👍**}" >> "$COMMENT_MESSAGE_PATH" fi # Append the update status and benchmark output to the comment. { echo "$UPDATED_MSG" - echo "$CSV_RESULTS_FILE_MSG" echo "" echo "\`\`\`" cat "$CANBENCH_OUTPUT" From 068b0158eb9d4c443ae771de5d520efce1161554 Mon Sep 17 00:00:00 2001 From: Maksym Arutyunyan Date: Tue, 13 May 2025 13:40:14 +0200 Subject: [PATCH 37/37] --hide-results --- scripts/ci_run_benchmark.sh | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/scripts/ci_run_benchmark.sh b/scripts/ci_run_benchmark.sh index 3f9631c0..ac8dbc53 100644 --- a/scripts/ci_run_benchmark.sh +++ b/scripts/ci_run_benchmark.sh @@ -61,7 +61,7 @@ if [ -f "$MAIN_BRANCH_RESULTS_FILE" ]; then # Run canbench to compare results with the main branch. pushd "$CANISTER_PATH" - canbench --less-verbose --show-summary > "$CANBENCH_OUTPUT" + canbench --less-verbose --hide-results --show-summary > "$CANBENCH_OUTPUT" popd # Append markers to individual benchmark results