• Clemens Backes's avatar
    [wasm] Pass correct code section start in streaming compilation · 7bace1d4
    Clemens Backes authored
    The streaming decoder computed the code section start from the passed
    "offset". That offset is computed from the module offset *after* the
    number of functions has been read. Hence 1 is subtracted, with the
    comment:
    // The offset passed to {ProcessCodeSectionHeader} is an error offset and
    // not the start offset of a buffer. Therefore we need the -1 here.
    
    That subtraction of 1 worked when the number of functions was encoded in
    a 1-byte LEB, otherwise it was off.
    
    This CL fixes the immediate issue of passing the right code offset. The
    usage of the previously existing offset also seems wrong, and I will try
    to clean that up in a follow-up CL.
    
    R=ahaas@chromium.org
    CC=szuend@chromium.org
    
    Bug: chromium:1150303
    Change-Id: I64bb2ececeb4749b7ba2096cd148ccb4079eca4f
    Reviewed-on: https://chromium-review.googlesource.com/c/v8/v8/+/2562383
    Commit-Queue: Clemens Backes <clemensb@chromium.org>
    Reviewed-by: 's avatarAndreas Haas <ahaas@chromium.org>
    Cr-Commit-Position: refs/heads/master@{#71503}
    7bace1d4
Name
Last commit
Last update
..
api Loading commit data...
asmjs Loading commit data...
assembler Loading commit data...
base Loading commit data...
codegen Loading commit data...
compiler Loading commit data...
compiler-dispatcher Loading commit data...
date Loading commit data...
diagnostics Loading commit data...
execution Loading commit data...
heap Loading commit data...
interpreter Loading commit data...
libplatform Loading commit data...
logging Loading commit data...
numbers Loading commit data...
objects Loading commit data...
parser Loading commit data...
profiler Loading commit data...
regress Loading commit data...
strings Loading commit data...
tasks Loading commit data...
torque Loading commit data...
utils Loading commit data...
wasm Loading commit data...
zone Loading commit data...
BUILD.gn Loading commit data...
DEPS Loading commit data...
run-all-unittests.cc Loading commit data...
test-helpers.cc Loading commit data...
test-helpers.h Loading commit data...
test-utils.cc Loading commit data...
test-utils.h Loading commit data...
testcfg.py Loading commit data...
unittests.status Loading commit data...