From 0d3d295144598cb5999ed5d305f7ddc87c44e8c6 Mon Sep 17 00:00:00 2001 From: Andreas Rossberg Date: Fri, 10 Feb 2023 07:58:43 +0100 Subject: [PATCH 1/3] [test] Import v128 global --- .github/workflows/main.yml | 2 +- interpreter/Makefile | 2 +- test/core/linking.wast | 10 ++++++++++ 3 files changed, 12 insertions(+), 2 deletions(-) diff --git a/.github/workflows/main.yml b/.github/workflows/main.yml index 2e43f200a5..0ff1bd5fbe 100644 --- a/.github/workflows/main.yml +++ b/.github/workflows/main.yml @@ -23,7 +23,7 @@ jobs: uses: actions/setup-node@v1 with: node-version: 18.x - - run: cd interpreter && opam exec make all + - run: cd interpreter && opam exec make JS=node all ref-interpreter-js-library: runs-on: ubuntu-latest diff --git a/interpreter/Makefile b/interpreter/Makefile index 78cbea556a..97e6e17c2f 100644 --- a/interpreter/Makefile +++ b/interpreter/Makefile @@ -23,7 +23,7 @@ FLAGS = -lexflags -ml -cflags '-w +a-4-27-42-44-45-70 -warn-error +a-3' OCBA = ocamlbuild $(FLAGS) $(DIRS:%=-I %) OCB = $(OCBA) $(LIBS:%=-libs %) JSO = js_of_ocaml -q --opt 3 -JS = node # set to JS shell command to run JS tests, empty to skip +JS = # set to JS shell command to run JS tests, empty to skip # Main targets diff --git a/test/core/linking.wast b/test/core/linking.wast index 994e0f49d0..e6d4f6058c 100644 --- a/test/core/linking.wast +++ b/test/core/linking.wast @@ -129,6 +129,16 @@ ) +(module + (global (export "g-v128") v128 (v128.const i64x2 0 0)) +) +(register "Mv128") + +(module + (import "Mv128" "g-v128" (global v128)) +) + + ;; Tables (module $Mt From 41456dcb9159554a0c5ce0dd9f4fd5bdae5a637b Mon Sep 17 00:00:00 2001 From: Andreas Rossberg Date: Thu, 16 Feb 2023 11:38:38 +0100 Subject: [PATCH 2/3] Use mutable global --- test/core/linking.wast | 9 +++++++-- 1 file changed, 7 insertions(+), 2 deletions(-) diff --git a/test/core/linking.wast b/test/core/linking.wast index e6d4f6058c..e0dd763c7c 100644 --- a/test/core/linking.wast +++ b/test/core/linking.wast @@ -130,12 +130,17 @@ (module - (global (export "g-v128") v128 (v128.const i64x2 0 0)) + ;; TODO: Reactivate once the fix for https://bugs.chromium.org/p/v8/issues/detail?id=13732 + ;; has made it to the downstream node.js that we use on CI. + ;; (global (export "g-v128") v128 (v128.const i64x2 0 0)) + (global (export "mg-v128") (mut v128) (v128.const i64x2 0 0)) ) (register "Mv128") (module - (import "Mv128" "g-v128" (global v128)) + ;; TODO: See above + ;; (import "Mv128" "g-v128" (global v128)) + (import "Mv128" "mg-v128" (global (mut v128))) ) From 6a8274a1750e057f91bb77d11e5427bb3396e6bf Mon Sep 17 00:00:00 2001 From: Andreas Rossberg Date: Thu, 16 Feb 2023 11:42:08 +0100 Subject: [PATCH 3/3] Minimise comment-out --- test/core/linking.wast | 7 +++---- 1 file changed, 3 insertions(+), 4 deletions(-) diff --git a/test/core/linking.wast b/test/core/linking.wast index e0dd763c7c..578a8c1881 100644 --- a/test/core/linking.wast +++ b/test/core/linking.wast @@ -130,15 +130,14 @@ (module - ;; TODO: Reactivate once the fix for https://bugs.chromium.org/p/v8/issues/detail?id=13732 - ;; has made it to the downstream node.js that we use on CI. - ;; (global (export "g-v128") v128 (v128.const i64x2 0 0)) + (global (export "g-v128") v128 (v128.const i64x2 0 0)) (global (export "mg-v128") (mut v128) (v128.const i64x2 0 0)) ) (register "Mv128") (module - ;; TODO: See above + ;; TODO: Reactivate once the fix for https://bugs.chromium.org/p/v8/issues/detail?id=13732 + ;; has made it to the downstream node.js that we use on CI. ;; (import "Mv128" "g-v128" (global v128)) (import "Mv128" "mg-v128" (global (mut v128))) )