1. 13 Aug, 2021 1 commit
  2. 06 Aug, 2021 1 commit
  3. 05 Aug, 2021 1 commit
  4. 04 Aug, 2021 1 commit
  5. 19 Jul, 2021 1 commit
  6. 12 Jul, 2021 1 commit
  7. 09 Jul, 2021 1 commit
  8. 08 Jul, 2021 1 commit
    • Thibaud Michaud's avatar
      [wasm][fuzzer] Allow Liftoff as a reference tier · 3deb8218
      Thibaud Michaud authored
      Add an option to use Liftoff instead of the interpreter as the reference
      tier for fuzzing. The tier to use is chosen based on the input data
      before generating the module. This way, the module can use features
      depending on what is available in the reference tier, and we still get a
      chance to find correctness issues that would only be detected by the
      interpreter.
      
      R=clemensb@chromium.org
      
      Bug: v8:11856
      Change-Id: I2e9878345355a37caec5fdb338dda42a84e8e63a
      Reviewed-on: https://chromium-review.googlesource.com/c/v8/v8/+/3008645
      Commit-Queue: Thibaud Michaud <thibaudm@chromium.org>
      Reviewed-by: 's avatarClemens Backes <clemensb@chromium.org>
      Cr-Commit-Position: refs/heads/master@{#75633}
      3deb8218
  9. 05 Jul, 2021 1 commit
  10. 01 Jul, 2021 1 commit
  11. 30 Jun, 2021 3 commits
    • Manos Koukoutos's avatar
      Reland "[wasm] Refactor initializer expression handling" · 7981dc33
      Manos Koukoutos authored
      This is a reland of 071a1acf
      
      Changes compared to original:
      Expect SIMD test to fail if SIMD is not supported.
      
      Original change's description:
      > [wasm] Refactor initializer expression handling
      >
      > Design doc: https://bit.ly/3xPxWUe
      >
      > This CL introduces two main changes:
      > - Initializer expressions are now decoded by WasmFullDecoder. With
      >   wasm-gc, initializer expressions are no longer just constants, and
      >   require complex decoding (including stack tracking). This resulted in
      >   extensive code duplication.
      > - Initializer expressions are not stored explicitly by module-decoder as
      >   an AST (WasmInitExpr), but rather as a WireBytesRef, and are decoded
      >   again during module instantiation. This should reduce memory
      >   consumption for globals and other module elements with initializer
      >   expressions (which has been observed in the 40MB range in some
      >   real-world benchmarks.
      >
      > Summary of changes:
      > - Add a static parameter {kFunctionBody, kInitExpression} to the
      >   WasmDecoder. Use it to specialize validation to function bodies/init.
      >   expressions.
      > - Introduce a new Interface for the WasmFullDecoder for init.
      >   expressions.
      > - Differentiate between constant and non-constant opcodes in
      >   WasmFullDecoder.
      > - Change representation of init. expressions in WasmModule to
      >   WireBytesRef.
      > - Reimplement EvaluateInitExpression in module-instantiate to re-decode
      >   initializer expressions.
      > - Remove some now-invalid module decoder tests.
      >
      > Pending changes:
      > - Also refactor initializer expressions for element segment entries.
      > - Reintroduce deleted tests.
      >
      > Bug: v8:11895
      > Change-Id: I76512bfe1386c8338667d30fa6db93880a1e4b42
      > Reviewed-on: https://chromium-review.googlesource.com/c/v8/v8/+/2972910
      > Reviewed-by: Jakob Kummerow <jkummerow@chromium.org>
      > Commit-Queue: Manos Koukoutos <manoskouk@chromium.org>
      > Cr-Commit-Position: refs/heads/master@{#75476}
      
      Bug: v8:11895
      Change-Id: I2dface5ff28d5a2d439a65d3e5cb83135c061bb9
      Reviewed-on: https://chromium-review.googlesource.com/c/v8/v8/+/2997722
      Commit-Queue: Manos Koukoutos <manoskouk@chromium.org>
      Reviewed-by: 's avatarJakob Kummerow <jkummerow@chromium.org>
      Cr-Commit-Position: refs/heads/master@{#75492}
      7981dc33
    • Clemens Backes's avatar
      Revert "[wasm] Refactor initializer expression handling" · 5756c40e
      Clemens Backes authored
      This reverts commit 071a1acf.
      
      Reason for revert: Breaks on nosse: https://ci.chromium.org/ui/p/v8/builders/ci/V8%20Linux/42795/overview
      
      Original change's description:
      > [wasm] Refactor initializer expression handling
      >
      > Design doc: https://bit.ly/3xPxWUe
      >
      > This CL introduces two main changes:
      > - Initializer expressions are now decoded by WasmFullDecoder. With
      >   wasm-gc, initializer expressions are no longer just constants, and
      >   require complex decoding (including stack tracking). This resulted in
      >   extensive code duplication.
      > - Initializer expressions are not stored explicitly by module-decoder as
      >   an AST (WasmInitExpr), but rather as a WireBytesRef, and are decoded
      >   again during module instantiation. This should reduce memory
      >   consumption for globals and other module elements with initializer
      >   expressions (which has been observed in the 40MB range in some
      >   real-world benchmarks.
      >
      > Summary of changes:
      > - Add a static parameter {kFunctionBody, kInitExpression} to the
      >   WasmDecoder. Use it to specialize validation to function bodies/init.
      >   expressions.
      > - Introduce a new Interface for the WasmFullDecoder for init.
      >   expressions.
      > - Differentiate between constant and non-constant opcodes in
      >   WasmFullDecoder.
      > - Change representation of init. expressions in WasmModule to
      >   WireBytesRef.
      > - Reimplement EvaluateInitExpression in module-instantiate to re-decode
      >   initializer expressions.
      > - Remove some now-invalid module decoder tests.
      >
      > Pending changes:
      > - Also refactor initializer expressions for element segment entries.
      > - Reintroduce deleted tests.
      >
      > Bug: v8:11895
      > Change-Id: I76512bfe1386c8338667d30fa6db93880a1e4b42
      > Reviewed-on: https://chromium-review.googlesource.com/c/v8/v8/+/2972910
      > Reviewed-by: Jakob Kummerow <jkummerow@chromium.org>
      > Commit-Queue: Manos Koukoutos <manoskouk@chromium.org>
      > Cr-Commit-Position: refs/heads/master@{#75476}
      
      Bug: v8:11895
      Change-Id: I9fcfdedad73ef21beb9632f50305b8e678a2dff6
      No-Presubmit: true
      No-Tree-Checks: true
      No-Try: true
      Reviewed-on: https://chromium-review.googlesource.com/c/v8/v8/+/2997582
      Auto-Submit: Clemens Backes <clemensb@chromium.org>
      Commit-Queue: Rubber Stamper <rubber-stamper@appspot.gserviceaccount.com>
      Bot-Commit: Rubber Stamper <rubber-stamper@appspot.gserviceaccount.com>
      Cr-Commit-Position: refs/heads/master@{#75484}
      5756c40e
    • Manos Koukoutos's avatar
      [wasm] Refactor initializer expression handling · 071a1acf
      Manos Koukoutos authored
      Design doc: https://bit.ly/3xPxWUe
      
      This CL introduces two main changes:
      - Initializer expressions are now decoded by WasmFullDecoder. With
        wasm-gc, initializer expressions are no longer just constants, and
        require complex decoding (including stack tracking). This resulted in
        extensive code duplication.
      - Initializer expressions are not stored explicitly by module-decoder as
        an AST (WasmInitExpr), but rather as a WireBytesRef, and are decoded
        again during module instantiation. This should reduce memory
        consumption for globals and other module elements with initializer
        expressions (which has been observed in the 40MB range in some
        real-world benchmarks.
      
      Summary of changes:
      - Add a static parameter {kFunctionBody, kInitExpression} to the
        WasmDecoder. Use it to specialize validation to function bodies/init.
        expressions.
      - Introduce a new Interface for the WasmFullDecoder for init.
        expressions.
      - Differentiate between constant and non-constant opcodes in
        WasmFullDecoder.
      - Change representation of init. expressions in WasmModule to
        WireBytesRef.
      - Reimplement EvaluateInitExpression in module-instantiate to re-decode
        initializer expressions.
      - Remove some now-invalid module decoder tests.
      
      Pending changes:
      - Also refactor initializer expressions for element segment entries.
      - Reintroduce deleted tests.
      
      Bug: v8:11895
      Change-Id: I76512bfe1386c8338667d30fa6db93880a1e4b42
      Reviewed-on: https://chromium-review.googlesource.com/c/v8/v8/+/2972910Reviewed-by: 's avatarJakob Kummerow <jkummerow@chromium.org>
      Commit-Queue: Manos Koukoutos <manoskouk@chromium.org>
      Cr-Commit-Position: refs/heads/master@{#75476}
      071a1acf
  12. 21 Jun, 2021 1 commit
  13. 18 Jun, 2021 1 commit
  14. 14 Jun, 2021 1 commit
  15. 08 Jun, 2021 1 commit
  16. 02 Jun, 2021 1 commit
  17. 19 May, 2021 1 commit
  18. 07 Apr, 2021 1 commit
  19. 23 Mar, 2021 1 commit
    • Andreas Haas's avatar
      [api] Add callback to set up conditional features · 16d9298a
      Andreas Haas authored
      Origin trials allow webpages to use experimental features even though
      the features are not yet enabled by default. These features will then
      get enabled per execution context: it is possible that the feature is
      enabled in one execution context but disabled in another execution
      context. In V8 we check for origin trials by calling a callback provided
      by the embedder that takes the context as a parameter and returns
      whether a feature is enabled in this context or not.
      
      This approach fails when a feature changes the context itself, e.g. by
      extending the global object. In that case the context is not available
      yet to check for the origin trial.
      
      To solve the problem this CL adds a new API function that can be called
      by the embedder to notify V8 that context with the origin trial
      information is finished. After that V8 can read the origin trial
      information from the context and extend e.g. the global object with the
      origin trial features.
      
      Additionally to the API this CL also adds code to enable the
      WebAssembly.Exception constructor conditionally, depending on whether
      it has been enabled by an origin trial or not.
      
      The Blink-side change: https://crrev.com/c/2775573
      
      R=ulan@chromium.org, jkummerow@chromium.org
      
      Change-Id: Ic05c4a89eb3e0e31469e49da8767d630c43b2e00
      Reviewed-on: https://chromium-review.googlesource.com/c/v8/v8/+/2773287Reviewed-by: 's avatarAndreas Haas <ahaas@chromium.org>
      Reviewed-by: 's avatarUlan Degenbaev <ulan@chromium.org>
      Reviewed-by: 's avatarJakob Kummerow <jkummerow@chromium.org>
      Commit-Queue: Andreas Haas <ahaas@chromium.org>
      Cr-Commit-Position: refs/heads/master@{#73597}
      16d9298a
  20. 22 Feb, 2021 1 commit
  21. 15 Jan, 2021 1 commit
  22. 02 Dec, 2020 1 commit
    • Manos Koukoutos's avatar
      [wasm-gc] read_heap_type should check if index is in module bounds · 0396b732
      Manos Koukoutos authored
      read_heap_type did not have knowledge of the module for which the heap
      type was being decoded. As a result, callers of read_heap_type (or
      read_value_type, which in turn calls read_heap_type) had to check after
      the fact that a decoded indexed type (ref, ref null, or rtt) references
      a type index within the module's bounds. This was not done consistently,
      and was missing (at least) in DecodeLocals.
      To avoid such problems in the future, this CL refactors read_heap_type
      to accept a module and check the decoded index against it.
      
      Changes:
      - Add WasmModule argument to read_heap_type. Do so accordingly to all
        its transitive callers (read_value_type, immediate arguments,
        DecodeLocalDecls, DecodeValue/HeapType in unittests).
      - Add index check to read_heap_type and emit an error for an
        out-of-bounds index.
      - Remove all other now-redundant index validations. Replace them with
        decoder->ok() if needed (since read_heap_type will now emit an error).
      - Fix error message in Validate for BlockTypeImmediate.
      - In DecodeLocalDecls in unittests, pass an empty module to
        DecodeLocalDecls in the main code.
      - Add a unit test with an invalid index in local type declarations.
      
      Bug: v8:9495
      Change-Id: I4ed1204847db80f78b6ae85fa40d300cd2456295
      Reviewed-on: https://chromium-review.googlesource.com/c/v8/v8/+/2569757Reviewed-by: 's avatarJakob Kummerow <jkummerow@chromium.org>
      Commit-Queue: Manos Koukoutos <manoskouk@chromium.org>
      Cr-Commit-Position: refs/heads/master@{#71572}
      0396b732
  23. 19 Nov, 2020 1 commit
  24. 05 Oct, 2020 1 commit
  25. 21 Sep, 2020 2 commits
  26. 15 Sep, 2020 1 commit
  27. 10 Sep, 2020 1 commit
    • Ng Zhi An's avatar
      Reland "[wasm-simd] Stage SIMD" · 36138aff
      Ng Zhi An authored
      This reverts commit e8976cf9.
      
      Reason for revert: Mark f32x4_cmp as fail, lowering is not fully implemented yet.
      
      Original change's description:
      > Revert "[wasm-simd] Stage SIMD"
      > 
      > This reverts commit 1d2726dd.
      > 
      > Reason for revert: ODROID failure: https://ci.chromium.org/p/v8/builders/ci/V8%20Arm%20-%20debug/15814?
      > 
      > Original change's description:
      > > [wasm-simd] Stage SIMD
      > > 
      > > SIMD has been pretty stable for a while now, we are not expecting big
      > > changes (like opcode renumbers), there might be new instructions added,
      > > and they will all be backwards-compatible.
      > > 
      > > The reference interpreter in the SIMD proposal is now capable of
      > > generating JS files for all test cases, so we can now run them.
      > > 
      > > There is a bit of tweaking necessary, since SIMD tests are in
      > > tests/core/simd subfolder in the spec, so we need to change the glob
      > > into a find that will traverse into subdirectory.
      > > 
      > > Bug: v8:10835
      > > Change-Id: I1f7e3cf37f21b2aa2537d1e34242da2373bbf626
      > > Reviewed-on: https://chromium-review.googlesource.com/c/v8/v8/+/2378587
      > > Commit-Queue: Zhi An Ng <zhin@chromium.org>
      > > Reviewed-by: Andreas Haas <ahaas@chromium.org>
      > > Cr-Commit-Position: refs/heads/master@{#69793}
      > 
      > TBR=bbudge@chromium.org,ahaas@chromium.org,zhin@chromium.org
      > 
      > Change-Id: I3a90c616109ca048691d97ab45698bc15a678e18
      > No-Presubmit: true
      > No-Tree-Checks: true
      > No-Try: true
      > Bug: v8:10835
      > Reviewed-on: https://chromium-review.googlesource.com/c/v8/v8/+/2402379
      > Reviewed-by: Shu-yu Guo <syg@chromium.org>
      > Commit-Queue: Shu-yu Guo <syg@chromium.org>
      > Cr-Commit-Position: refs/heads/master@{#69794}
      
      TBR=bbudge@chromium.org,ahaas@chromium.org,zhin@chromium.org,syg@chromium.org
      
      # Not skipping CQ checks because this is a reland.
      
      Bug: v8:10835
      Change-Id: I3d87dd2adba6ada2ec3ebf5e13bff378a74b03e8
      Reviewed-on: https://chromium-review.googlesource.com/c/v8/v8/+/2402386Reviewed-by: 's avatarZhi An Ng <zhin@chromium.org>
      Reviewed-by: 's avatarAndreas Haas <ahaas@chromium.org>
      Commit-Queue: Zhi An Ng <zhin@chromium.org>
      Cr-Commit-Position: refs/heads/master@{#69817}
      36138aff
  28. 09 Sep, 2020 2 commits
    • Shu-yu Guo's avatar
      Revert "[wasm-simd] Stage SIMD" · e8976cf9
      Shu-yu Guo authored
      This reverts commit 1d2726dd.
      
      Reason for revert: ODROID failure: https://ci.chromium.org/p/v8/builders/ci/V8%20Arm%20-%20debug/15814?
      
      Original change's description:
      > [wasm-simd] Stage SIMD
      > 
      > SIMD has been pretty stable for a while now, we are not expecting big
      > changes (like opcode renumbers), there might be new instructions added,
      > and they will all be backwards-compatible.
      > 
      > The reference interpreter in the SIMD proposal is now capable of
      > generating JS files for all test cases, so we can now run them.
      > 
      > There is a bit of tweaking necessary, since SIMD tests are in
      > tests/core/simd subfolder in the spec, so we need to change the glob
      > into a find that will traverse into subdirectory.
      > 
      > Bug: v8:10835
      > Change-Id: I1f7e3cf37f21b2aa2537d1e34242da2373bbf626
      > Reviewed-on: https://chromium-review.googlesource.com/c/v8/v8/+/2378587
      > Commit-Queue: Zhi An Ng <zhin@chromium.org>
      > Reviewed-by: Andreas Haas <ahaas@chromium.org>
      > Cr-Commit-Position: refs/heads/master@{#69793}
      
      TBR=bbudge@chromium.org,ahaas@chromium.org,zhin@chromium.org
      
      Change-Id: I3a90c616109ca048691d97ab45698bc15a678e18
      No-Presubmit: true
      No-Tree-Checks: true
      No-Try: true
      Bug: v8:10835
      Reviewed-on: https://chromium-review.googlesource.com/c/v8/v8/+/2402379Reviewed-by: 's avatarShu-yu Guo <syg@chromium.org>
      Commit-Queue: Shu-yu Guo <syg@chromium.org>
      Cr-Commit-Position: refs/heads/master@{#69794}
      e8976cf9
    • Ng Zhi An's avatar
      [wasm-simd] Stage SIMD · 1d2726dd
      Ng Zhi An authored
      SIMD has been pretty stable for a while now, we are not expecting big
      changes (like opcode renumbers), there might be new instructions added,
      and they will all be backwards-compatible.
      
      The reference interpreter in the SIMD proposal is now capable of
      generating JS files for all test cases, so we can now run them.
      
      There is a bit of tweaking necessary, since SIMD tests are in
      tests/core/simd subfolder in the spec, so we need to change the glob
      into a find that will traverse into subdirectory.
      
      Bug: v8:10835
      Change-Id: I1f7e3cf37f21b2aa2537d1e34242da2373bbf626
      Reviewed-on: https://chromium-review.googlesource.com/c/v8/v8/+/2378587
      Commit-Queue: Zhi An Ng <zhin@chromium.org>
      Reviewed-by: 's avatarAndreas Haas <ahaas@chromium.org>
      Cr-Commit-Position: refs/heads/master@{#69793}
      1d2726dd
  29. 01 Sep, 2020 1 commit
  30. 26 Aug, 2020 2 commits
  31. 20 Aug, 2020 1 commit
    • Andreas Haas's avatar
      [wasm][fuzzer] Enable trap handlers · 1e6d2cb3
      Andreas Haas authored
      On x64, trap handlers are enabled as part of the default configuration.
      However, each embedder has to enable trap handlers explicitly, and in
      the wasm fuzzers, trap handlers were not enabled. This CL enables trap
      handlers now in all wasm fuzzers.
      
      Drive-by change: enable all staged wasm features in the wasm-async
      fuzzer.
      
      R=clemensb@chromium.org
      
      Change-Id: Ib7c2addb092551b5554a2b74830e5b67db077909
      Reviewed-on: https://chromium-review.googlesource.com/c/v8/v8/+/2362957
      Commit-Queue: Andreas Haas <ahaas@chromium.org>
      Reviewed-by: 's avatarClemens Backes <clemensb@chromium.org>
      Cr-Commit-Position: refs/heads/master@{#69500}
      1e6d2cb3
  32. 18 Aug, 2020 1 commit
    • Clemens Backes's avatar
      Reland "[wasm][fuzzer] Fix exception detection" · f7d169c6
      Clemens Backes authored
      This is a reland of 899cb348.
      The new fuzzer regression test is skipped in jitless.
      
      Original change's description:
      > [wasm][fuzzer] Fix exception detection
      >
      > Exceptions were detected by checking for a pending exception on the
      > isolate, but {CallWasmFunctionForTesting} was clearing any pending
      > exception before returning.
      > This CL fixes that by explicitly passing back a boolean which is set if
      > an exception occurred during execution.
      >
      > R=ahaas@chromium.org
      >
      > Bug: chromium:1115280
      > Change-Id: Ife71ceef0751d18e0870335b9520c2bf77e351cc
      > Reviewed-on: https://chromium-review.googlesource.com/c/v8/v8/+/2352787
      > Reviewed-by: Andreas Haas <ahaas@chromium.org>
      > Commit-Queue: Clemens Backes <clemensb@chromium.org>
      > Cr-Commit-Position: refs/heads/master@{#69404}
      
      Bug: chromium:1115280
      Change-Id: I9bb7300d423c53214e51e61233b0a6b09a21fd97
      Reviewed-on: https://chromium-review.googlesource.com/c/v8/v8/+/2361464Reviewed-by: 's avatarAndreas Haas <ahaas@chromium.org>
      Commit-Queue: Clemens Backes <clemensb@chromium.org>
      Cr-Commit-Position: refs/heads/master@{#69446}
      f7d169c6
  33. 17 Aug, 2020 1 commit
  34. 14 Aug, 2020 2 commits