diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index bb819cc..c72958e 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -2,7 +2,7 @@ name: CI on: [pull_request] env: - RUST_VERSION: 1.86.0 + RUST_VERSION: 1.93.1 CARGO_TERM_COLOR: always # Force Cargo to use colors TERM: xterm-256color diff --git a/Cargo.lock b/Cargo.lock index 6882265..5d9b28d 100644 --- a/Cargo.lock +++ b/Cargo.lock @@ -260,9 +260,9 @@ dependencies = [ [[package]] name = "candid" -version = "0.10.20" +version = "0.10.27" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "8037a01ec09d6c06883a38bad4f47b8d06158ad360b841e0ae5707c9884dfaf6" +checksum = "1ba5b4833b63bf7b785fecdd2cc918ed90d988fd974825d5c48e7b407c39ef38" dependencies = [ "anyhow", "binread", @@ -283,9 +283,9 @@ dependencies = [ [[package]] name = "candid_derive" -version = "0.10.20" +version = "0.10.27" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "fb45f4d5eff3805598ee633dd80f8afb306c023249d34b5b7dfdc2080ea1df2e" +checksum = "7b60664b6324832dfb4863f3b19eb4d58819cd38fba6d3941b101213cea0d9ec" dependencies = [ "lazy_static", "proc-macro2", @@ -431,9 +431,9 @@ dependencies = [ [[package]] name = "darling" -version = "0.20.11" +version = "0.23.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "fc7f46116c46ff9ab3eb1597a45688b6715c6e628b5c133e288e709a29bcb4ee" +checksum = "25ae13da2f202d56bd7f91c25fba009e7717a1e4a1cc98a76d844b65ae912e9d" dependencies = [ "darling_core", "darling_macro", @@ -441,11 +441,10 @@ dependencies = [ [[package]] name = "darling_core" -version = "0.20.11" +version = "0.23.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "0d00b9596d185e565c2207a0b01f8bd1a135483d02d9b7b0a54b11da8d53412e" +checksum = "9865a50f7c335f53564bb694ef660825eb8610e0a53d3e11bf1b0d3df31e03b0" dependencies = [ - "fnv", "ident_case", "proc-macro2", "quote", @@ -455,9 +454,9 @@ dependencies = [ [[package]] name = "darling_macro" -version = "0.20.11" +version = "0.23.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "fc34b93ccb385b40dc71c6fceac4b2ad23662c7eeb248cf10d529b7e055b6ead" +checksum = "ac3984ec7bd6cfa798e62b4a642426a5be0e68f9401cfc2a01e3fa9ea2fcdb8d" dependencies = [ "darling_core", "quote", @@ -909,21 +908,18 @@ dependencies = [ [[package]] name = "ic-cdk" -version = "0.19.0" +version = "0.20.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "818d6d5416a8f0212e1b132703b0da51e36c55f2b96677e96f2bbe7702e1bd85" +checksum = "a64dfa64757e7bfdd3bd6048c35e1edd74b69325deeed6bcaafedbc864c645fc" dependencies = [ "candid", "ic-cdk-executor", "ic-cdk-macros", "ic-error-types", - "ic-management-canister-types 0.5.0", "ic0", "pin-project-lite", "serde", - "serde_bytes", - "slotmap", - "thiserror 2.0.17", + "thiserror 2.0.18", ] [[package]] @@ -939,9 +935,9 @@ dependencies = [ [[package]] name = "ic-cdk-macros" -version = "0.19.0" +version = "0.20.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "66dad91a214945cb3605bc9ef6901b87e2ac41e3624284c2cabba49d43aa4f43" +checksum = "fd0794365edf9997b1114b4ea10358c6af1317e39fc6611b4fc67053a44ec8f1" dependencies = [ "candid", "darling", @@ -973,17 +969,6 @@ dependencies = [ "strum_macros", ] -[[package]] -name = "ic-management-canister-types" -version = "0.3.3" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "ea7e5b8a0f7c3b320d9450ac950547db4f24a31601b5d398f9680b64427455d2" -dependencies = [ - "candid", - "serde", - "serde_bytes", -] - [[package]] name = "ic-management-canister-types" version = "0.5.0" @@ -997,9 +982,9 @@ dependencies = [ [[package]] name = "ic-transport-types" -version = "0.40.1" +version = "0.45.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "a2e7706e55836e8104c98149ec0796d20d5213fef972ac01b544657d410f1883" +checksum = "4a775244756a5d97ff19b08071a946a4b4896904e35deb036bf215e80f2e703d" dependencies = [ "candid", "hex", @@ -1010,14 +995,14 @@ dependencies = [ "serde_cbor", "serde_repr", "sha2", - "thiserror 2.0.17", + "thiserror 2.0.18", ] [[package]] name = "ic0" -version = "1.0.1" +version = "1.1.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "1499d08fd5be8f790d477e1865d63bab6a8d748300e141270c4296e6d5fdd6bc" +checksum = "c77c8932bff1f09502d0d8c079d5a206a06afe523e35e816162cf4d30b5bf80d" [[package]] name = "ic_principal" @@ -1468,9 +1453,9 @@ checksum = "9b4f627cb1b25917193a259e49bdad08f671f8d9708acfd5fe0a8c1455d87220" [[package]] name = "pin-project-lite" -version = "0.2.16" +version = "0.2.17" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "3b3cff922bd51709b605d9ead9aa71031d81447142d828eb4a6eba76fe619f9b" +checksum = "a89322df9ebe1c1578d689c92318e070967d1042b512afbe49518723f4e6d5cd" [[package]] name = "pin-utils" @@ -1480,9 +1465,9 @@ checksum = "8b870d8c151b6f2fb93e84a13146138f05d02ed11c7e7c54f8826aaaf7c9f184" [[package]] name = "pocket-ic" -version = "10.0.0" +version = "13.0.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "4c9b78f339182efb981ceca2ac360aa280609f8d8c785e5a7eeda488f53497a8" +checksum = "e30621a12b204880522340df8327930d1b7fdefd784c9fc6093b311440fa0506" dependencies = [ "backoff", "base64 0.13.1", @@ -1490,12 +1475,12 @@ dependencies = [ "flate2", "hex", "ic-certification", - "ic-management-canister-types 0.3.3", + "ic-management-canister-types", "ic-transport-types", "reqwest", "schemars", + "semver", "serde", - "serde_bytes", "serde_cbor", "serde_json", "sha2", @@ -1503,7 +1488,7 @@ dependencies = [ "strum", "strum_macros", "tempfile", - "thiserror 2.0.17", + "thiserror 2.0.18", "tokio", "tracing", "tracing-appender", @@ -1558,9 +1543,9 @@ dependencies = [ [[package]] name = "proc-macro2" -version = "1.0.103" +version = "1.0.106" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "5ee95bc4ef87b8d5ba32e8b7714ccc834865276eab0aed5c9958d00ec45f49e8" +checksum = "8fd00f0bb2e90d81d1044c2b32617f68fcb9fa3bb7640c23e9c748e53fb30934" dependencies = [ "unicode-ident", ] @@ -1598,7 +1583,7 @@ dependencies = [ "rustc-hash", "rustls", "socket2", - "thiserror 2.0.17", + "thiserror 2.0.18", "tokio", "tracing", "web-time", @@ -1619,7 +1604,7 @@ dependencies = [ "rustls", "rustls-pki-types", "slab", - "thiserror 2.0.17", + "thiserror 2.0.18", "tinyvec", "tracing", "web-time", @@ -1958,6 +1943,10 @@ name = "semver" version = "1.0.27" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "d767eb0aabc880b29956c35734170f26ed551a859dbd361d140cdbeca61ab1e2" +dependencies = [ + "serde", + "serde_core", +] [[package]] name = "serde" @@ -2301,11 +2290,11 @@ dependencies = [ [[package]] name = "thiserror" -version = "2.0.17" +version = "2.0.18" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "f63587ca0f12b72a0600bcba1d40081f830876000bb46dd2337a3051618f4fc8" +checksum = "4288b5bcbc7920c07a1149a35cf9590a2aa808e0bc1eafaade0b80947865fbc4" dependencies = [ - "thiserror-impl 2.0.17", + "thiserror-impl 2.0.18", ] [[package]] @@ -2321,9 +2310,9 @@ dependencies = [ [[package]] name = "thiserror-impl" -version = "2.0.17" +version = "2.0.18" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "3ff15c8ecd7de3849db632e14d18d2571fa09dfc5ed93479bc4485c7a517c913" +checksum = "ebc4ee7f67670e9b64d05fa4253e753e016c6c95ff35b89b7941d6b856dec1d5" dependencies = [ "proc-macro2", "quote", diff --git a/Cargo.toml b/Cargo.toml index cec57d0..103448c 100644 --- a/Cargo.toml +++ b/Cargo.toml @@ -9,12 +9,12 @@ members = [ resolver = "2" [workspace.dependencies] -candid = "0.10.20" +candid = "0.10.27" clap = { version = "4.5.53", features = ["derive"] } colored = "3.0.0" flate2 = "1.1.5" hex = "0.4.3" -ic-cdk = "0.19.0" +ic-cdk = "0.20.1" proc-macro2 = "1.0.103" quote = "1.0.42" reqwest = { version = "0.12.24", features = [ diff --git a/canbench-bin/Cargo.toml b/canbench-bin/Cargo.toml index 42470d7..39a6535 100644 --- a/canbench-bin/Cargo.toml +++ b/canbench-bin/Cargo.toml @@ -26,7 +26,7 @@ inferno = { version = "0.11", default-features = false, features = [ ] } # `pocket-ic` should be pinned to an exact version so that the PocketIC server binary version # `POCKET_IC_SERVER_VERSION` defined in `canbench-bin/src/lib.rs` is compatible. -pocket-ic = "=10.0.0" +pocket-ic = "=13.0.0" reqwest.workspace = true rustc-demangle.workspace = true semver.workspace = true diff --git a/canbench-bin/src/lib.rs b/canbench-bin/src/lib.rs index 4314589..4b94e5b 100644 --- a/canbench-bin/src/lib.rs +++ b/canbench-bin/src/lib.rs @@ -30,10 +30,10 @@ use wasmparser::Parser as WasmParser; // Other queries exposed by the canister are ignored. const BENCH_PREFIX: &str = "__canbench__"; -const POCKET_IC_SERVER_VERSION: &str = "10.0.0"; +const POCKET_IC_SERVER_VERSION: &str = "13.0.0"; const POCKET_IC_LINUX_SHA: &str = - "bfc17d1acad243841121eee5347dd7453e0d8a8f8f6e090c261fae17523c3144"; -const POCKET_IC_MAC_SHA: &str = "fb4a30d3d076411ea9b40f5219d75014ffa05465807c1d32fe86cda481133c65"; + "b19a15ba0650a3987e78a8017dee0e99c5518194d1e0c4fd45b53cd32598544e"; +const POCKET_IC_MAC_SHA: &str = "2e38d2266865ae285d612bd533675073d11d0cb77b8365c203431af753ce930e"; /// The maximum number of rows to display in the summary table. const MAX_DISPLAYED_ROWS: usize = 50; diff --git a/canbench-bin/tests/expected/benchmark_instruction_tracing.txt b/canbench-bin/tests/expected/benchmark_instruction_tracing.txt index c062f08..c03b0e1 100644 --- a/canbench-bin/tests/expected/benchmark_instruction_tracing.txt +++ b/canbench-bin/tests/expected/benchmark_instruction_tracing.txt @@ -2,7 +2,7 @@ Benchmark: write_stable_memory (new) total: - instructions: 49.11 K (new) + instructions: 49.12 K (new) heap_increase: 0 pages (new) stable_memory_increase: 1 pages (new) Instruction traces written to write_stable_memory.svg @@ -33,7 +33,7 @@ Summary: Only significant changes: | status | name | calls | ins | ins Δ% | HI | HI Δ% | SMI | SMI Δ% | |--------|---------------------|-------|--------|---------|----|--------|-----|---------| -| new | write_stable_memory | | 49.11K | | 0 | | 1 | | +| new | write_stable_memory | | 49.12K | | 0 | | 1 | | ins = instructions, HI = heap_increase, SMI = stable_memory_increase, Δ% = percent change diff --git a/canbench-bin/tests/expected/benchmark_reports_noisy_change_above_default_noise_threshold.txt b/canbench-bin/tests/expected/benchmark_reports_noisy_change_above_default_noise_threshold.txt index ac80de2..f9afaa7 100644 --- a/canbench-bin/tests/expected/benchmark_reports_noisy_change_above_default_noise_threshold.txt +++ b/canbench-bin/tests/expected/benchmark_reports_noisy_change_above_default_noise_threshold.txt @@ -12,7 +12,7 @@ Summary: instructions: status: Improvements detected 🟢 counts: [total 1 | regressed 0 | improved 1 | new 0 | unchanged 0] - change: [max -154.23K | p75 -154.23K | median -154.23K | p25 -154.23K | min -154.23K] + change: [max -154.22K | p75 -154.22K | median -154.22K | p25 -154.22K | min -154.22K] change %: [max -4.36% | p75 -4.36% | median -4.36% | p25 -4.36% | min -4.36%] heap_increase: diff --git a/canbench-bin/tests/expected/benchmark_reports_noisy_change_within_custom_noise_threshold.txt b/canbench-bin/tests/expected/benchmark_reports_noisy_change_within_custom_noise_threshold.txt index 891a757..8793336 100644 --- a/canbench-bin/tests/expected/benchmark_reports_noisy_change_within_custom_noise_threshold.txt +++ b/canbench-bin/tests/expected/benchmark_reports_noisy_change_within_custom_noise_threshold.txt @@ -12,7 +12,7 @@ Summary: instructions: status: No significant changes 👍 counts: [total 1 | regressed 0 | improved 0 | new 0 | unchanged 1] - change: [max -154.23K | p75 -154.23K | median -154.23K | p25 -154.23K | min -154.23K] + change: [max -154.22K | p75 -154.22K | median -154.22K | p25 -154.22K | min -154.22K] change %: [max -4.36% | p75 -4.36% | median -4.36% | p25 -4.36% | min -4.36%] heap_increase: diff --git a/canbench-bin/tests/expected/benchmark_stable_writes.txt b/canbench-bin/tests/expected/benchmark_stable_writes.txt index b2206ef..657c17e 100644 --- a/canbench-bin/tests/expected/benchmark_stable_writes.txt +++ b/canbench-bin/tests/expected/benchmark_stable_writes.txt @@ -2,7 +2,7 @@ Benchmark: write_stable_memory (new) total: - instructions: 49.11 K (new) + instructions: 49.12 K (new) heap_increase: 0 pages (new) stable_memory_increase: 1 pages (new) @@ -32,7 +32,7 @@ Summary: Only significant changes: | status | name | calls | ins | ins Δ% | HI | HI Δ% | SMI | SMI Δ% | |--------|---------------------|-------|--------|---------|----|--------|-----|---------| -| new | write_stable_memory | | 49.11K | | 0 | | 1 | | +| new | write_stable_memory | | 49.12K | | 0 | | 1 | | ins = instructions, HI = heap_increase, SMI = stable_memory_increase, Δ% = percent change diff --git a/canbench-bin/tests/expected/benchmark_works_with_init_args.txt b/canbench-bin/tests/expected/benchmark_works_with_init_args.txt index 3afb447..6fa0086 100644 --- a/canbench-bin/tests/expected/benchmark_works_with_init_args.txt +++ b/canbench-bin/tests/expected/benchmark_works_with_init_args.txt @@ -2,7 +2,7 @@ Benchmark: state_check total: - instructions: 841 (no change) + instructions: 888 (regressed by 5.59%) heap_increase: 0 pages (no change) stable_memory_increase: 0 pages (no change) @@ -10,10 +10,10 @@ Benchmark: state_check Summary: instructions: - status: No significant changes 👍 - counts: [total 1 | regressed 0 | improved 0 | new 0 | unchanged 1] - change: [max 0 | p75 0 | median 0 | p25 0 | min 0] - change %: [max 0.00% | p75 0.00% | median 0.00% | p25 0.00% | min 0.00%] + status: Regressions detected 🔴 + counts: [total 1 | regressed 1 | improved 0 | new 0 | unchanged 0] + change: [max +47 | p75 +47 | median +47 | p25 +47 | min +47] + change %: [max +5.59% | p75 +5.59% | median +5.59% | p25 +5.59% | min +5.59%] heap_increase: status: No significant changes 👍 @@ -28,3 +28,12 @@ Summary: change %: [max 0.00% | p75 0.00% | median 0.00% | p25 0.00% | min 0.00%] --------------------------------------------------- + +Only significant changes: +| status | name | calls | ins | ins Δ% | HI | HI Δ% | SMI | SMI Δ% | +|--------|-------------|-------|-----|---------|----|--------|-----|---------| +| + | state_check | | 888 | +5.59% | 0 | 0.00% | 0 | 0.00% | + +ins = instructions, HI = heap_increase, SMI = stable_memory_increase, Δ% = percent change + +--------------------------------------------------- diff --git a/canbench-bin/tests/expected/reports_recursive_scopes_benchmark.txt b/canbench-bin/tests/expected/reports_recursive_scopes_benchmark.txt index bbb90da..1a49555 100644 --- a/canbench-bin/tests/expected/reports_recursive_scopes_benchmark.txt +++ b/canbench-bin/tests/expected/reports_recursive_scopes_benchmark.txt @@ -2,7 +2,7 @@ Benchmark: bench_recursive_scopes total: - instructions: 30.09 M (0.31%) (change within noise threshold) + instructions: 30.09 M (0.30%) (change within noise threshold) heap_increase: 0 pages (no change) stable_memory_increase: 0 pages (no change) @@ -24,8 +24,8 @@ Summary: instructions: status: No significant changes 👍 counts: [total 1 | regressed 0 | improved 0 | new 0 | unchanged 1] - change: [max +91.74K | p75 +91.74K | median +91.74K | p25 +91.74K | min +91.74K] - change %: [max +0.31% | p75 +0.31% | median +0.31% | p25 +0.31% | min +0.31%] + change: [max +91.48K | p75 +91.48K | median +91.48K | p25 +91.48K | min +91.48K] + change %: [max +0.30% | p75 +0.30% | median +0.30% | p25 +0.30% | min +0.30%] heap_increase: status: No significant changes 👍 diff --git a/canbench-bin/tests/expected/reports_repeated_scope_in_existing_benchmark.txt b/canbench-bin/tests/expected/reports_repeated_scope_in_existing_benchmark.txt index 7342252..28ba577 100644 --- a/canbench-bin/tests/expected/reports_repeated_scope_in_existing_benchmark.txt +++ b/canbench-bin/tests/expected/reports_repeated_scope_in_existing_benchmark.txt @@ -2,13 +2,13 @@ Benchmark: bench_repeated_scope_exists total: - instructions: 16.31 K (regressed from 0) + instructions: 15.40 K (regressed from 0) heap_increase: 0 pages (no change) stable_memory_increase: 0 pages (no change) scope_1 (scope): calls: 10 (no change) - instructions: 8669 (regressed by 983.62%) + instructions: 7999 (regressed by 899.87%) heap_increase: 0 pages (improved by 100.00%) stable_memory_increase: 0 pages (no change) @@ -18,7 +18,7 @@ Summary: instructions: status: Regressions detected 🔴 counts: [total 1 | regressed 1 | improved 0 | new 0 | unchanged 0] - change: [max +16.31K | p75 +16.31K | median +16.31K | p25 +16.31K | min +16.31K] + change: [max +15.40K | p75 +15.40K | median +15.40K | p25 +15.40K | min +15.40K] change %: [max +inf% | p75 +inf% | median +inf% | p25 +inf% | min +inf%] heap_increase: @@ -38,8 +38,8 @@ Summary: Only significant changes: | status | name | calls | ins | ins Δ% | HI | HI Δ% | SMI | SMI Δ% | |--------|--------------------------------------|-------|--------|----------|----|----------|-----|---------| -| + | bench_repeated_scope_exists | | 16.31K | +inf% | 0 | 0.00% | 0 | 0.00% | -| +/- | bench_repeated_scope_exists::scope_1 | 10 | 8.67K | +983.62% | 0 | -100.00% | 0 | 0.00% | +| + | bench_repeated_scope_exists | | 15.40K | +inf% | 0 | 0.00% | 0 | 0.00% | +| +/- | bench_repeated_scope_exists::scope_1 | 10 | 8.00K | +899.87% | 0 | -100.00% | 0 | 0.00% | ins = instructions, HI = heap_increase, SMI = stable_memory_increase, Δ% = percent change diff --git a/canbench-bin/tests/expected/reports_repeated_scope_in_new_benchmark.txt b/canbench-bin/tests/expected/reports_repeated_scope_in_new_benchmark.txt index 3eeda32..47b3fc7 100644 --- a/canbench-bin/tests/expected/reports_repeated_scope_in_new_benchmark.txt +++ b/canbench-bin/tests/expected/reports_repeated_scope_in_new_benchmark.txt @@ -2,13 +2,13 @@ Benchmark: bench_repeated_scope_new (new) total: - instructions: 16.31 K (new) + instructions: 15.40 K (new) heap_increase: 0 pages (new) stable_memory_increase: 0 pages (new) scope_1 (scope): calls: 10 (new) - instructions: 8669 (new) + instructions: 7999 (new) heap_increase: 0 pages (new) stable_memory_increase: 0 pages (new) @@ -38,8 +38,8 @@ Summary: Only significant changes: | status | name | calls | ins | ins Δ% | HI | HI Δ% | SMI | SMI Δ% | |--------|-----------------------------------|-------|--------|---------|----|--------|-----|---------| -| new | bench_repeated_scope_new | | 16.31K | | 0 | | 0 | | -| new | bench_repeated_scope_new::scope_1 | 10 | 8.67K | | 0 | | 0 | | +| new | bench_repeated_scope_new | | 15.40K | | 0 | | 0 | | +| new | bench_repeated_scope_new::scope_1 | 10 | 8.00K | | 0 | | 0 | | ins = instructions, HI = heap_increase, SMI = stable_memory_increase, Δ% = percent change diff --git a/canbench-bin/tests/expected/reports_scopes_in_existing_benchmark.txt b/canbench-bin/tests/expected/reports_scopes_in_existing_benchmark.txt index c20644f..cfa48fd 100644 --- a/canbench-bin/tests/expected/reports_scopes_in_existing_benchmark.txt +++ b/canbench-bin/tests/expected/reports_scopes_in_existing_benchmark.txt @@ -2,19 +2,19 @@ Benchmark: bench_scope_exists total: - instructions: 3987 (regressed from 0) + instructions: 3834 (regressed from 0) heap_increase: 0 pages (no change) stable_memory_increase: 0 pages (no change) scope_1 (scope): calls: 1 (no change) - instructions: 1046 (regressed by 30.75%) + instructions: 970 (regressed by 21.25%) heap_increase: 0 pages (improved by 100.00%) stable_memory_increase: 0 pages (no change) scope_2 (scope): calls: 1 (new) - instructions: 847 (new) + instructions: 781 (new) heap_increase: 0 pages (new) stable_memory_increase: 0 pages (new) @@ -24,7 +24,7 @@ Summary: instructions: status: Regressions detected 🔴 counts: [total 1 | regressed 1 | improved 0 | new 0 | unchanged 0] - change: [max +3.99K | p75 +3.99K | median +3.99K | p25 +3.99K | min +3.99K] + change: [max +3.83K | p75 +3.83K | median +3.83K | p25 +3.83K | min +3.83K] change %: [max +inf% | p75 +inf% | median +inf% | p25 +inf% | min +inf%] heap_increase: @@ -44,9 +44,9 @@ Summary: Only significant changes: | status | name | calls | ins | ins Δ% | HI | HI Δ% | SMI | SMI Δ% | |--------|-----------------------------|-------|-------|---------|----|----------|-----|---------| -| + | bench_scope_exists | | 3.99K | +inf% | 0 | 0.00% | 0 | 0.00% | -| +/- | bench_scope_exists::scope_1 | 1 | 1.05K | +30.75% | 0 | -100.00% | 0 | 0.00% | -| new | bench_scope_exists::scope_2 | 1 | 847 | | 0 | | 0 | | +| + | bench_scope_exists | | 3.83K | +inf% | 0 | 0.00% | 0 | 0.00% | +| +/- | bench_scope_exists::scope_1 | 1 | 970 | +21.25% | 0 | -100.00% | 0 | 0.00% | +| new | bench_scope_exists::scope_2 | 1 | 781 | | 0 | | 0 | | ins = instructions, HI = heap_increase, SMI = stable_memory_increase, Δ% = percent change diff --git a/canbench-bin/tests/expected/reports_scopes_in_new_benchmark.txt b/canbench-bin/tests/expected/reports_scopes_in_new_benchmark.txt index 238bc91..35e4bf7 100644 --- a/canbench-bin/tests/expected/reports_scopes_in_new_benchmark.txt +++ b/canbench-bin/tests/expected/reports_scopes_in_new_benchmark.txt @@ -2,19 +2,19 @@ Benchmark: bench_scope_new (new) total: - instructions: 3987 (new) + instructions: 3834 (new) heap_increase: 0 pages (new) stable_memory_increase: 0 pages (new) scope_1 (scope): calls: 1 (new) - instructions: 1046 (new) + instructions: 970 (new) heap_increase: 0 pages (new) stable_memory_increase: 0 pages (new) scope_2 (scope): calls: 1 (new) - instructions: 847 (new) + instructions: 781 (new) heap_increase: 0 pages (new) stable_memory_increase: 0 pages (new) @@ -44,9 +44,9 @@ Summary: Only significant changes: | status | name | calls | ins | ins Δ% | HI | HI Δ% | SMI | SMI Δ% | |--------|--------------------------|-------|-------|---------|----|--------|-----|---------| -| new | bench_scope_new | | 3.99K | | 0 | | 0 | | -| new | bench_scope_new::scope_1 | 1 | 1.05K | | 0 | | 0 | | -| new | bench_scope_new::scope_2 | 1 | 847 | | 0 | | 0 | | +| new | bench_scope_new | | 3.83K | | 0 | | 0 | | +| new | bench_scope_new::scope_1 | 1 | 970 | | 0 | | 0 | | +| new | bench_scope_new::scope_2 | 1 | 781 | | 0 | | 0 | | ins = instructions, HI = heap_increase, SMI = stable_memory_increase, Δ% = percent change diff --git a/canbench-bin/tests/tests.rs b/canbench-bin/tests/tests.rs index cc6e751..f9b49e0 100644 --- a/canbench-bin/tests/tests.rs +++ b/canbench-bin/tests/tests.rs @@ -19,10 +19,9 @@ macro_rules! current_test_name { #[test] fn overwrite_feature_must_be_disabled() { // Fails if the "overwrite" feature is accidentally enabled (e.g. via `--all-features` in CI). - assert!( - !cfg!(feature = "overwrite"), - "'overwrite' feature must be disabled" - ); + if cfg!(feature = "overwrite") { + panic!("'overwrite' feature must be disabled"); + } } /// Loads the expected output for a given test case. diff --git a/examples/btreemap_vs_hashmap/canbench_results.yml b/examples/btreemap_vs_hashmap/canbench_results.yml index 715767d..775e99a 100644 --- a/examples/btreemap_vs_hashmap/canbench_results.yml +++ b/examples/btreemap_vs_hashmap/canbench_results.yml @@ -2,32 +2,32 @@ benches: insert_users: total: calls: 1 - instructions: 2558172740 - heap_increase: 872 + instructions: 2729624702 + heap_increase: 871 stable_memory_increase: 0 scopes: {} pre_upgrade_bench: total: calls: 1 - instructions: 486886999 + instructions: 391740965 heap_increase: 519 stable_memory_increase: 184 scopes: serialize_state: calls: 1 - instructions: 423947334 + instructions: 328801361 heap_increase: 519 stable_memory_increase: 0 writing_to_stable_memory: calls: 5 - instructions: 62932560 + instructions: 62932531 heap_increase: 0 stable_memory_increase: 184 remove_users: total: calls: 1 - instructions: 2109060849 + instructions: 1564558256 heap_increase: 0 stable_memory_increase: 0 scopes: {} -version: 0.2.1 +version: 0.4.1 diff --git a/examples/fibonacci/canbench_results.yml b/examples/fibonacci/canbench_results.yml index 5761f8a..4f42fc7 100644 --- a/examples/fibonacci/canbench_results.yml +++ b/examples/fibonacci/canbench_results.yml @@ -34,4 +34,4 @@ benches: heap_increase: 0 stable_memory_increase: 0 scopes: {} -version: 0.2.1 +version: 0.4.1 diff --git a/rust-toolchain.toml b/rust-toolchain.toml index 36ed7c7..a07f6e2 100644 --- a/rust-toolchain.toml +++ b/rust-toolchain.toml @@ -1,3 +1,3 @@ [toolchain] -channel = "1.86.0" # NOTE: remember to update CI as well. +channel = "1.93.1" # NOTE: remember to update CI as well. targets = ["wasm32-unknown-unknown"]