Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Create a non-generic StoreInner #610

Merged
merged 2 commits into from
Jan 14, 2023
Merged

Create a non-generic StoreInner #610

merged 2 commits into from
Jan 14, 2023

Conversation

Robbepop
Copy link
Member

This might be useful to make the engine's executor non-generic. A non-generic engine executor is important to decrease bloat but also to make use of the experimental #[union_fn] data structure.

@paritytech-cicd-pr
Copy link

paritytech-cicd-pr commented Jan 14, 2023

BENCHMARKS

NATIVEWASMTIME
BENCHMARKMASTERPRDIFFMASTERPRDIFFWASMTIME OVERHEAD
execute/
bare_call_0
1.34ms 1.35ms 🟢 0.90% 1.16ms 1.12ms 🟢 -3.47% 🟢 -17%
execute/
bare_call_0/typed
1.07ms 1.03ms 🟢 -4.06% 743.90µs 726.59µs 🟢 -2.34% 🟢 -29%
execute/
bare_call_1
1.42ms 1.43ms 🔴 1.41% 1.45ms 1.51ms 🔴 3.87% 🟢 6%
execute/
bare_call_16
2.46ms 2.36ms 🟢 -4.73% 4.29ms 4.44ms 🔴 3.64% 🟡 88%
execute/
bare_call_16/typed
1.64ms 1.56ms 🟢 -5.23% 2.31ms 2.65ms 🔴 15.03% 🟡 71%
execute/
bare_call_1/typed
1.07ms 1.10ms 🔴 2.90% 1.14ms 1.13ms ⚪ 0.00% 🟢 3%
execute/
bare_call_4
1.61ms 1.73ms 🔴 7.11% 2.00ms 2.18ms 🔴 9.16% 🟢 26%
execute/
bare_call_4/typed
1.16ms 1.11ms 🟢 -4.72% 1.22ms 1.21ms ⚪ -0.35% 🟢 10%
execute/
br_table
1.08ms 1.10ms ⚪ 2.06% 1.35ms 1.45ms 🔴 8.14% 🟢 32%
execute/
count_until
710.06µs 683.76µs 🟢 -3.77% 2.24ms 2.85ms 🔴 27.12% 🔴 317%
execute/
factorial_iterative
320.33µs 327.74µs 🔴 2.18% 941.82µs 1.22ms 🔴 29.55% 🔴 272%
execute/
factorial_recursive
634.91µs 641.20µs ⚪ 1.04% 1.67ms 1.51ms 🟢 -9.12% 🔴 136%
execute/
fib_iterative
1.46ms 1.43ms 🟢 -1.51% 4.87ms 6.51ms 🔴 33.57% 🔴 354%
execute/
fib_recursive
6.17ms 5.80ms 🟢 -6.37% 15.45ms 13.97ms 🟢 -9.62% 🔴 141%
execute/
global_bump
1.10ms 978.30µs 🟢 -11.18% 3.38ms 3.43ms ⚪ 1.24% 🔴 250%
execute/
global_const
719.51µs 718.79µs ⚪ -0.11% 2.58ms 3.22ms 🔴 25.13% 🔴 348%
execute/
host_calls
29.36µs 28.90µs 🟢 -1.58% 46.08µs 45.00µs 🟢 -2.36% 🟡 56%
execute/
memory_fill
1.35ms 1.34ms ⚪ -0.97% 4.27ms 5.18ms 🔴 21.60% 🔴 288%
execute/
memory_sum
1.32ms 1.31ms ⚪ -0.92% 4.30ms 5.29ms 🔴 23.72% 🔴 304%
execute/
memory_vec_add
2.83ms 2.74ms 🟢 -2.89% 9.06ms 10.37ms 🔴 14.49% 🔴 278%
execute/
recursive_is_even
1.13ms 1.14ms ⚪ 0.81% 2.86ms 2.36ms 🟢 -17.33% 🔴 107%
execute/
recursive_ok
149.59µs 151.64µs 🔴 1.46% 373.07µs 326.80µs 🟢 -12.37% 🔴 116%
execute/
recursive_scan
181.16µs 181.78µs ⚪ 0.44% 465.96µs 435.99µs 🟢 -6.33% 🔴 140%
execute/
recursive_trap
14.39µs 14.59µs ⚪ 1.63% 35.69µs 33.03µs 🟢 -7.60% 🔴 126%
execute/
regex_redux
573.78µs 561.83µs 🟢 -1.95% 1.77ms 1.79ms ⚪ 1.04% 🔴 218%
execute/
rev_complement
537.21µs 513.62µs 🟢 -3.63% 1.65ms 1.79ms 🔴 7.58% 🔴 248%
execute/
tiny_keccak
372.20µs 361.91µs 🟢 -2.62% 1.37ms 1.51ms 🔴 10.21% 🔴 317%
execute/
trunc_f2i
912.21µs 917.29µs ⚪ 0.75% 2.60ms 3.01ms 🔴 15.57% 🔴 228%
instantiate/
wasm_kernel
63.06µs 61.95µs ⚪ -3.01% 74.23µs 73.05µs ⚪ -1.22% 🟢 18%
translate/
erc1155
211.27µs 211.38µs ⚪ 0.32% 408.04µs 403.62µs ⚪ -1.08% 🟡 91%
translate/
erc20
102.87µs 103.26µs ⚪ 0.40% 198.21µs 200.37µs 🔴 1.38% 🟡 94%
translate/
erc721
148.98µs 147.88µs ⚪ -0.60% 290.22µs 289.25µs ⚪ -0.33% 🟡 96%
translate/
spidermonkey
0.00ns 0.00ns ⚪ 0.61% 0.00ns 0.00ns ⚪ -0.69% 🟢 0%
translate/
wasm_kernel
3.82ms 3.82ms ⚪ 0.56% 7.70ms 7.63ms ⚪ -0.81% 🟡 100%

Link to pipeline

@codecov-commenter
Copy link

codecov-commenter commented Jan 14, 2023

Codecov Report

Merging #610 (18724aa) into master (cc05d72) will increase coverage by 0.08%.
The diff coverage is 94.62%.

@@            Coverage Diff             @@
##           master     #610      +/-   ##
==========================================
+ Coverage   80.98%   81.07%   +0.08%     
==========================================
  Files          82       82              
  Lines        6758     6789      +31     
==========================================
+ Hits         5473     5504      +31     
  Misses       1285     1285              
Impacted Files Coverage Δ
crates/wasmi/src/store.rs 87.82% <94.62%> (+3.02%) ⬆️

📣 We’re building smart automated test selection to slash your CI/CD build times. Learn more

This is also required in order to make use of StoreInner instead of Store in the engine executor.
@Robbepop Robbepop merged commit 702cc68 into master Jan 14, 2023
@Robbepop Robbepop deleted the rf-store-inner branch January 14, 2023 17:39
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants