[regexp] Improve regex interpreter dispatch
This CL changes the dispatch technique in the regex interpreter to token-threaded dispatch, if computed gotos are supported by the compiler. Otherwise old switch-based dispatch is still used (e.g. for MSVC). With computed gotos, less jumps will be emitted (no extra jump to single branch point/begin of switch) and branch prediction will be better because of no single branch point. This CL improves performance on the RexBench Benchmark suite by ~10%. Bug: v8:9575 Change-Id: I585ad824ff1cc595a5dfa8831ad66d6810d0119b Reviewed-on: https://chromium-review.googlesource.com/c/v8/v8/+/1733073Reviewed-by: Peter Marshall <petermarshall@chromium.org> Reviewed-by: Yang Guo <yangguo@chromium.org> Reviewed-by: Jakob Gruber <jgruber@chromium.org> Reviewed-by: Clemens Hammacher <clemensh@chromium.org> Commit-Queue: Patrick Thier <pthier@google.com> Cr-Commit-Position: refs/heads/master@{#63126}
Showing
This diff is collapsed.
Please
register
or
sign in
to comment