-
Notifications
You must be signed in to change notification settings - Fork 4.8k
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
[wasm] Fix bugs related to jiterpreter heuristic #99273
Conversation
Tagging subscribers to 'arch-wasm': @lewing Issue DetailsWhile investigating some benchmark regressions I noticed a couple bugs related to the jiterpreter. I did 3 runs of browser-bench for before/after and the difference is within noise for me, so I don't know whether this makes anything faster or slower. The existing instruction counter is broken in an unpredictable way though, and this correct implementation of it is at least possible to tune.
|
1629dcf
to
8a12c14
Compare
feee3c4
to
5775b59
Compare
Blocked by
Which is caused by a 2900-line generator function, the generated state machine seems to have a chance to end up with complex long branches in it depending on how the opcodes end up arranged, and fixing the jiterpreter heuristic permutes the opcodes just so. We could hide this problem by splitting the generator function in half, but for now we're going to figure out whether there's a better solution. |
Trace back branches when a method is verbose
This causes a warning. Introduced in dotnet#99273. ``` src/mono/mono/mini/interp/jiterpreter.c:1686:24: warning: a function declaration without a prototype is deprecated in all versions of C [-Wstrict-prototypes] mono_jiterp_is_enabled () { ^ void 1 warning generated. ```
This causes a warning. Introduced in #99273. ``` src/mono/mono/mini/interp/jiterpreter.c:1686:24: warning: a function declaration without a prototype is deprecated in all versions of C [-Wstrict-prototypes] mono_jiterp_is_enabled () { ^ void 1 warning generated. ```
While investigating some benchmark regressions I noticed a couple bugs related to the jiterpreter.
I did 3 runs of browser-bench for before/after and the difference is within noise for me, so I don't know whether this makes anything faster or slower. The existing instruction counter is broken in an unpredictable way though, and this correct implementation of it is at least possible to tune.