1. 25 Jul, 2022 1 commit
  2. 01 Jul, 2022 1 commit
  3. 27 Jun, 2022 1 commit
  4. 16 Jun, 2022 1 commit
  5. 08 Jun, 2022 1 commit
  6. 31 Jan, 2022 1 commit
  7. 27 Jan, 2022 1 commit
    • Manos Koukoutos's avatar
      [wasm-gc] Implement iso-recursive types · fe531e1f
      Manos Koukoutos authored
      This CL replaces the equirecursive type system for wasm-gc with the
      isorecursive hybrid type system presented here:
      https://github.com/WebAssembly/gc/issues/257.
      
      In broad strokes, this includes the following changes:
      - In the module decoder, remove equirecursive types. Implement recursive
        type groups, subtype definitions, and function/struct/array
        definitions. Treat nominal modules as syntactic sugar of an
        isorecursive module, where all types belong in the same recursive
        group.
      - Remove rtt.sub and all related infrastructure.
      - Change subtyping to work with explicit supertypes only.
      - Add ValidSubtypeDefinition in subtyping, to check that subtype
        declarations are valid during decoding.
      - Remove the subtyping cache.
      - Add support for functions to have specific signature index in
        WasmModuleBuilder and in test-gc.cc.
      - Adapt tests.
      
      Current restrictions:
      - Recursive groups are not stored beyond decoding.
      - Type canonicalization is not implemented. No tests relying on types
        being considered identical post-canonicalization.
      - No cross-module subtyping is possible. Tests relying on cross-module
        subtyping have been commented out.
      
      Bug: v8:7748
      Change-Id: I69fd04ecc5611f6230c95d5c89d1c520163fffae
      Reviewed-on: https://chromium-review.googlesource.com/c/v8/v8/+/3416239Reviewed-by: 's avatarTobias Tebbi <tebbi@chromium.org>
      Reviewed-by: 's avatarJakob Kummerow <jkummerow@chromium.org>
      Commit-Queue: Manos Koukoutos <manoskouk@chromium.org>
      Cr-Commit-Position: refs/heads/main@{#78816}
      fe531e1f
  8. 05 Nov, 2021 1 commit
    • Manos Koukoutos's avatar
      [wasm][fuzzer] Complex init. expressions in JS testcase · 74d9a764
      Manos Koukoutos authored
      We enable struct.new and array.init initializer expressions in the JS
      testcase generated by --wasm-fuzzer-gen-test. We needed to make some
      changes in the WasmInitExpr class, and to implement a new interface for
      the WasmFullDecoder, which constructs a WasmInitExpr.
      Changes:
      - Make WasmInitExpr a ZoneObject. Use a pointer for its operands_ field.
        This is needed so WasmInitExpr is trivially copiable, and thus usable
        as a Value type in WasmFullDecoder.
      - Implement a WasmFullDecoder interface in wasm-fuzzer-common that
        constructs a WasmInitExpr. Use it to decode initializers in the
        module generated by the fuzzer.
      - Change AppendInitExpr to take a WasmInitExpr as argument.
      - Fix an issue with printing of struct definitions.
      - Change initializer expression used for structs to struct.new_with_rtt.
        This is consistent with the currently used structural types.
      
      Bug: v8:11954
      Change-Id: I65a87cc98701a54f32500be192b3b6eef2ff6c8c
      Reviewed-on: https://chromium-review.googlesource.com/c/v8/v8/+/3257712Reviewed-by: 's avatarAndreas Haas <ahaas@chromium.org>
      Reviewed-by: 's avatarThibaud Michaud <thibaudm@chromium.org>
      Commit-Queue: Manos Koukoutos <manoskouk@chromium.org>
      Cr-Commit-Position: refs/heads/main@{#77730}
      74d9a764
  9. 20 Sep, 2021 1 commit
  10. 15 Sep, 2021 1 commit
  11. 14 Jun, 2021 1 commit
  12. 08 Jun, 2021 1 commit
  13. 04 Jun, 2021 1 commit
    • Manos Koukoutos's avatar
      [wasm] Implement EvaluateInitExpression · dc3f7f81
      Manos Koukoutos authored
      So far, initializer-expression evaluation was tied to setting global
      values. We now need it to operate independently of globals, so that we
      can implement new constant expressions like struct.new, which need their
      arguments to be computed before they can be initialized.
      
      Changes:
      - Move type computation of WasmInitExpr into WasmInitExpr::type.
      - Fix WasmInitExpr::type kRttSub case for rtts without depth.
      - Introduce InstanceBuilder::EvaluateInitExpression().
      - Rename InstanceBuilder::GetRawGlobalPointer() ->
        GetRawUntaggedGlobalPointer().
      - Simplify InstanceBuilder::InitGlobals using EvaluateInitExpression().
      - Introduce ValueType::is_numeric.
      - Add Simd128(byte*) constructor.
      - Introduce WasmValue::CopyTo() for numeric types.
      
      Change-Id: Ic502b611f3998187abd9fc6ec377c2954c27abdc
      Reviewed-on: https://chromium-review.googlesource.com/c/v8/v8/+/2939982
      Commit-Queue: Manos Koukoutos <manoskouk@chromium.org>
      Reviewed-by: 's avatarClemens Backes <clemensb@chromium.org>
      Cr-Commit-Position: refs/heads/master@{#74949}
      dc3f7f81
  14. 19 May, 2021 1 commit
  15. 05 May, 2021 1 commit
    • Manos Koukoutos's avatar
      [wasm] Complete element segment features for reftypes/typed-funcref · 37579df7
      Manos Koukoutos authored
      Main changes:
      - Allow global.get in elements segments with expressions-as-elements.
      - Allow element segments with types other than funcref.
      
      Detailed changes:
      - Move WasmInitExpr to its own file. Add stream opearator << support.
      - Simplify type of PrintCollection.
      - Make WasmElemSegment use an array of WasmInitExpr's over the previous
        ad-hoc implementation. Move null_index to WasmModuleBuilder.
      - Refactor consume_element_segment_header. Make it return a
        WasmElemSegment.
      - Refactor consume_element_expr. Make it return a WasmInitExpr.
      - Refactor DecodeElementSection. Make it invoke
        consume_element_segment_header, then populate its element array.
      - Update module-instantiate.cc to handle global.get elements.
      - Fix bug in wasm-objects.cc where the wrong type index was passed into
        module()->has_signature()
      - Adapt and add tests.
      
      Change-Id: I5abfbe424dbb750ee2dca59f91c451ffcb79f95f
      Reviewed-on: https://chromium-review.googlesource.com/c/v8/v8/+/2857959
      Commit-Queue: Manos Koukoutos <manoskouk@chromium.org>
      Reviewed-by: 's avatarJakob Kummerow <jkummerow@chromium.org>
      Cr-Commit-Position: refs/heads/master@{#74374}
      37579df7