• Clemens Hammacher's avatar
    [wasm] [interpreter] Implement indirect function calls · b8f88601
    Clemens Hammacher authored
    This CL adds support for indirect function calls to the interpreter. It
    can indirectly call other wasm function in the same instance, which are
    then executed in the interpreter, or call imported functions.
    
    Implementing this required some refactoring:
    - The wasm interpreter now unwraps import wrappers on demand, instead
      of unwrapping all of them on instantiation and storing a vector of
      handles. This also avoids the DeferredHandleScope completely, instead
      we just store two global handles in the code map.
    - The interpreter gets the code table, function tables and signature
      tables directly from the attached wasm instance object. This ensures
      that the interpreter sees all updates to tables that might have been
      performed by external code.
    - There is now common functionality for calling a code object. This is
      used for direct calls to imported functions and for all indirect
      calls. As these code objects can also be wasm functions which should
      be executed in the interpreter itself, I introduce a struct to hold
      the outcome of calling the code object, or a pointer to
      InterpreterCode to be called in the interpreter.
    
    R=ahaas@chromium.org
    BUG=v8:5822
    
    Change-Id: I20fb2ea007e79e5fcff9afb4b1ca31739ebcb83f
    Reviewed-on: https://chromium-review.googlesource.com/458417
    Commit-Queue: Clemens Hammacher <clemensh@chromium.org>
    Reviewed-by: 's avatarAndreas Haas <ahaas@chromium.org>
    Cr-Commit-Position: refs/heads/master@{#44059}
    b8f88601
Name
Last commit
Last update
..
benchmarks Loading commit data...
cctest Loading commit data...
common Loading commit data...
debugger Loading commit data...
fuzzer Loading commit data...
inspector Loading commit data...
intl Loading commit data...
js-perf-test Loading commit data...
memory Loading commit data...
message Loading commit data...
mjsunit Loading commit data...
mozilla Loading commit data...
preparser Loading commit data...
promises-aplus Loading commit data...
simdjs Loading commit data...
test262 Loading commit data...
unittests Loading commit data...
webkit Loading commit data...
BUILD.gn Loading commit data...
bot_default.gyp Loading commit data...
bot_default.isolate Loading commit data...
default.gyp Loading commit data...
default.isolate Loading commit data...
optimize_for_size.gyp Loading commit data...
optimize_for_size.isolate Loading commit data...
perf.gyp Loading commit data...
perf.isolate Loading commit data...