275402260c
We have to create WasmExportedFunction objects for any WebAssembly function which may escape a WebAssembly instance. Up until now we created these WasmExportedFunction objects eagerly during instantiation time: for any exported function, and any element in an exported table we create such an object. With the anyref proposal, the table.get instruction can allow any function in a table to escape its instance. Therefore we would have to create a WasmExportedFunction object for any function which is put into a table. With this CL we create WasmExportedFunctions for table entries lazily. We initialize tables with placeholders consisting of the instance and the function index. If we encounter a placeholder in table.get, we create the WasmExportedFunction for the expected function to return it. R=mstarzinger@chromium.org CC=titzer@chromium.org Bug: v8:7581 Change-Id: I4f32bd7433285d0b04a22c0fb70b736bac55b3f1 Reviewed-on: https://chromium-review.googlesource.com/c/v8/v8/+/1505575 Reviewed-by: Michael Starzinger <mstarzinger@chromium.org> Reviewed-by: Ben Titzer <titzer@chromium.org> Commit-Queue: Andreas Haas <ahaas@chromium.org> Cr-Commit-Position: refs/heads/master@{#60115} |
||
---|---|---|
.. | ||
benchmarks | ||
cctest | ||
common | ||
debugger | ||
fuzzer | ||
inspector | ||
intl | ||
js-perf-test | ||
memory | ||
message | ||
mjsunit | ||
mkgrokdump | ||
mozilla | ||
preparser | ||
test262 | ||
torque | ||
unittests | ||
wasm-js | ||
wasm-spec-tests | ||
webkit | ||
BUILD.gn | ||
OWNERS |