diff options
author | JF Bastien <github@jfbastien.com> | 2016-02-05 11:23:11 +0100 |
---|---|---|
committer | JF Bastien <github@jfbastien.com> | 2016-02-05 11:23:11 +0100 |
commit | 8f67b6e27a38c93fbca7f3c44a88889b3896952f (patch) | |
tree | 7f8fc703d206af8044ab794e2ae340387134c7f9 /test | |
parent | c1f9026c2788e4ef6f6af0c6d9aa04d22fc00320 (diff) | |
parent | 31409184708b04bae830869c7b6ce61726020444 (diff) | |
download | binaryen-8f67b6e27a38c93fbca7f3c44a88889b3896952f.tar.gz binaryen-8f67b6e27a38c93fbca7f3c44a88889b3896952f.tar.bz2 binaryen-8f67b6e27a38c93fbca7f3c44a88889b3896952f.zip |
Merge pull request #182 from WebAssembly/start
Support start
Diffstat (limited to 'test')
-rw-r--r-- | test/dot_s/start_main0.s | 8 | ||||
-rw-r--r-- | test/dot_s/start_main0.wast | 12 | ||||
-rw-r--r-- | test/dot_s/start_main2.s | 11 | ||||
-rw-r--r-- | test/dot_s/start_main2.wast | 20 |
4 files changed, 51 insertions, 0 deletions
diff --git a/test/dot_s/start_main0.s b/test/dot_s/start_main0.s new file mode 100644 index 000000000..85323ee62 --- /dev/null +++ b/test/dot_s/start_main0.s @@ -0,0 +1,8 @@ + .text + .file "main0" + .globl main + .type main,@function +main: # @main +# BB#0: +.Lfunc_end0: + .size main, .Lfunc_end0-main diff --git a/test/dot_s/start_main0.wast b/test/dot_s/start_main0.wast new file mode 100644 index 000000000..d40390aee --- /dev/null +++ b/test/dot_s/start_main0.wast @@ -0,0 +1,12 @@ +(module + (memory 0 4294967295) + (start $_start) + (export "main" $main) + (export "_start" $_start) + (func $main + ) + (func $_start + (call $main) + ) +) +;; METADATA: { "asmConsts": {},"staticBump": 4 } diff --git a/test/dot_s/start_main2.s b/test/dot_s/start_main2.s new file mode 100644 index 000000000..7f77ec463 --- /dev/null +++ b/test/dot_s/start_main2.s @@ -0,0 +1,11 @@ + .text + .file "main2" + .globl main + .type main,@function +main: # @main + .param i32, i32 + .result i32 +# BB#0: + return $0 +.Lfunc_end0: + .size main, .Lfunc_end0-main diff --git a/test/dot_s/start_main2.wast b/test/dot_s/start_main2.wast new file mode 100644 index 000000000..42e8b4897 --- /dev/null +++ b/test/dot_s/start_main2.wast @@ -0,0 +1,20 @@ +(module + (memory 0 4294967295) + (start $_start) + (export "main" $main) + (export "_start" $_start) + (func $main (param $$0 i32) (param $$1 i32) (result i32) + (return + (get_local $$0) + ) + ) + (func $_start + (local $0 i32) + (local $1 i32) + (call $main + (get_local $0) + (get_local $1) + ) + ) +) +;; METADATA: { "asmConsts": {},"staticBump": 4 } |