[wasm] Avoid unnecessary jump tables
If multiple code spaces are created, each of them currently gets its own jump table (on 64 bit platforms). Since we try to allocate new code spaces right after existing ones, this is often not necessary. We could instead reuse the existing jump table(s). This saves code space for the unneeded jump tables and avoid the cost of patching the redundant jump tables when we replace code objects. This CL implements this by checking whether an existing jump table (or pair of far jump table and (near) jump table) fully covers a new code space, and reuses the existing jump table in that case. R=ahaas@chromium.org Change-Id: Id8751b9c4036cf8f85f9baa2b0be8b2cfb5716ff Reviewed-on: https://chromium-review.googlesource.com/c/v8/v8/+/2043846Reviewed-by: Andreas Haas <ahaas@chromium.org> Commit-Queue: Clemens Backes <clemensb@chromium.org> Cr-Commit-Position: refs/heads/master@{#66364}
Showing
This diff is collapsed.
Please
register
or
sign in
to comment