From 898609e3b708d1d85d2cef7d8bf985fa2006a797 Mon Sep 17 00:00:00 2001 From: Daniel Bevenius Date: Fri, 1 Jun 2018 14:53:51 +0200 Subject: [PATCH] test: add source for test.wasm The original commit 74e7a4a041fe83f106bc50ebe99c961afb28a0cd ("test: add basic WebAssembly test") references the source for test.wasm and while there are tools to go from wasm to wat but having the source viewable is helpful I think. PR-URL: https://github.com/nodejs/node/pull/21082 Reviewed-By: James M Snell Reviewed-By: Tiancheng "Timothy" Gu Reviewed-By: Lance Ball Reviewed-By: Luigi Pinca Reviewed-By: Gus Caplan Reviewed-By: Trivikram Kamat Reviewed-By: John-David Dalton --- test/fixtures/test.wasm | Bin 44 -> 50 bytes test/fixtures/test.wat | 10 ++++++++++ 2 files changed, 10 insertions(+) create mode 100644 test/fixtures/test.wat diff --git a/test/fixtures/test.wasm b/test/fixtures/test.wasm index 8b19588df228b76c6747d04aee091cbe268592d0..da1b0330069de60ad944216d8fd1ba403dd3f761 100644 GIT binary patch delta 33 mcmdNfnjj`4z{H%GlET2i1|&nu^BEYpI2qX)6c`j3v$z3lBL$fN delta 27 icmXrgnII;{#mJVJk`hv$&%nUN$;i&2z@WgG#SH*Qu>@cM diff --git a/test/fixtures/test.wat b/test/fixtures/test.wat new file mode 100644 index 00000000000..fa90b17cce0 --- /dev/null +++ b/test/fixtures/test.wat @@ -0,0 +1,10 @@ +;; Compiled using the WebAssembly Tootkit (https://github.com/WebAssembly/wabt) +;; $ wat2wasm test.wat -o test.wasm +(module + (func $add (export "add") (param $first i32) (param $second i32) (result i32) + get_local $first + get_local $second + (i32.add) + ) + (export "addTwo" (func $add)) +)