wa-lang.org/wazero@v1.0.2/internal/integration_test/spectest/v2/testdata/simd_i16x8_arith.wast (about) 1 ;; Tests for i16x8 arithmetic operations on major boundary values and all special values. 2 3 4 (module 5 (func (export "i16x8.add") (param v128 v128) (result v128) (i16x8.add (local.get 0) (local.get 1))) 6 (func (export "i16x8.sub") (param v128 v128) (result v128) (i16x8.sub (local.get 0) (local.get 1))) 7 (func (export "i16x8.mul") (param v128 v128) (result v128) (i16x8.mul (local.get 0) (local.get 1))) 8 (func (export "i16x8.neg") (param v128) (result v128) (i16x8.neg (local.get 0))) 9 ) 10 11 12 ;; i16x8.add 13 (assert_return (invoke "i16x8.add" (v128.const i16x8 0 0 0 0 0 0 0 0) 14 (v128.const i16x8 0 0 0 0 0 0 0 0)) 15 (v128.const i16x8 0 0 0 0 0 0 0 0)) 16 (assert_return (invoke "i16x8.add" (v128.const i16x8 0 0 0 0 0 0 0 0) 17 (v128.const i16x8 1 1 1 1 1 1 1 1)) 18 (v128.const i16x8 1 1 1 1 1 1 1 1)) 19 (assert_return (invoke "i16x8.add" (v128.const i16x8 1 1 1 1 1 1 1 1) 20 (v128.const i16x8 1 1 1 1 1 1 1 1)) 21 (v128.const i16x8 2 2 2 2 2 2 2 2)) 22 (assert_return (invoke "i16x8.add" (v128.const i16x8 0 0 0 0 0 0 0 0) 23 (v128.const i16x8 -1 -1 -1 -1 -1 -1 -1 -1)) 24 (v128.const i16x8 -1 -1 -1 -1 -1 -1 -1 -1)) 25 (assert_return (invoke "i16x8.add" (v128.const i16x8 1 1 1 1 1 1 1 1) 26 (v128.const i16x8 -1 -1 -1 -1 -1 -1 -1 -1)) 27 (v128.const i16x8 0 0 0 0 0 0 0 0)) 28 (assert_return (invoke "i16x8.add" (v128.const i16x8 -1 -1 -1 -1 -1 -1 -1 -1) 29 (v128.const i16x8 -1 -1 -1 -1 -1 -1 -1 -1)) 30 (v128.const i16x8 -2 -2 -2 -2 -2 -2 -2 -2)) 31 (assert_return (invoke "i16x8.add" (v128.const i16x8 16383 16383 16383 16383 16383 16383 16383 16383) 32 (v128.const i16x8 16384 16384 16384 16384 16384 16384 16384 16384)) 33 (v128.const i16x8 32767 32767 32767 32767 32767 32767 32767 32767)) 34 (assert_return (invoke "i16x8.add" (v128.const i16x8 16384 16384 16384 16384 16384 16384 16384 16384) 35 (v128.const i16x8 16384 16384 16384 16384 16384 16384 16384 16384)) 36 (v128.const i16x8 -32768 -32768 -32768 -32768 -32768 -32768 -32768 -32768)) 37 (assert_return (invoke "i16x8.add" (v128.const i16x8 -16383 -16383 -16383 -16383 -16383 -16383 -16383 -16383) 38 (v128.const i16x8 -16384 -16384 -16384 -16384 -16384 -16384 -16384 -16384)) 39 (v128.const i16x8 -32767 -32767 -32767 -32767 -32767 -32767 -32767 -32767)) 40 (assert_return (invoke "i16x8.add" (v128.const i16x8 -16384 -16384 -16384 -16384 -16384 -16384 -16384 -16384) 41 (v128.const i16x8 -16384 -16384 -16384 -16384 -16384 -16384 -16384 -16384)) 42 (v128.const i16x8 -32768 -32768 -32768 -32768 -32768 -32768 -32768 -32768)) 43 (assert_return (invoke "i16x8.add" (v128.const i16x8 -16385 -16385 -16385 -16385 -16385 -16385 -16385 -16385) 44 (v128.const i16x8 -16384 -16384 -16384 -16384 -16384 -16384 -16384 -16384)) 45 (v128.const i16x8 32767 32767 32767 32767 32767 32767 32767 32767)) 46 (assert_return (invoke "i16x8.add" (v128.const i16x8 32765 32765 32765 32765 32765 32765 32765 32765) 47 (v128.const i16x8 1 1 1 1 1 1 1 1)) 48 (v128.const i16x8 32766 32766 32766 32766 32766 32766 32766 32766)) 49 (assert_return (invoke "i16x8.add" (v128.const i16x8 32766 32766 32766 32766 32766 32766 32766 32766) 50 (v128.const i16x8 1 1 1 1 1 1 1 1)) 51 (v128.const i16x8 32767 32767 32767 32767 32767 32767 32767 32767)) 52 (assert_return (invoke "i16x8.add" (v128.const i16x8 32768 32768 32768 32768 32768 32768 32768 32768) 53 (v128.const i16x8 1 1 1 1 1 1 1 1)) 54 (v128.const i16x8 -32767 -32767 -32767 -32767 -32767 -32767 -32767 -32767)) 55 (assert_return (invoke "i16x8.add" (v128.const i16x8 -32766 -32766 -32766 -32766 -32766 -32766 -32766 -32766) 56 (v128.const i16x8 -1 -1 -1 -1 -1 -1 -1 -1)) 57 (v128.const i16x8 -32767 -32767 -32767 -32767 -32767 -32767 -32767 -32767)) 58 (assert_return (invoke "i16x8.add" (v128.const i16x8 -32767 -32767 -32767 -32767 -32767 -32767 -32767 -32767) 59 (v128.const i16x8 -1 -1 -1 -1 -1 -1 -1 -1)) 60 (v128.const i16x8 -32768 -32768 -32768 -32768 -32768 -32768 -32768 -32768)) 61 (assert_return (invoke "i16x8.add" (v128.const i16x8 -32768 -32768 -32768 -32768 -32768 -32768 -32768 -32768) 62 (v128.const i16x8 -1 -1 -1 -1 -1 -1 -1 -1)) 63 (v128.const i16x8 32767 32767 32767 32767 32767 32767 32767 32767)) 64 (assert_return (invoke "i16x8.add" (v128.const i16x8 32767 32767 32767 32767 32767 32767 32767 32767) 65 (v128.const i16x8 32767 32767 32767 32767 32767 32767 32767 32767)) 66 (v128.const i16x8 -2 -2 -2 -2 -2 -2 -2 -2)) 67 (assert_return (invoke "i16x8.add" (v128.const i16x8 -32768 -32768 -32768 -32768 -32768 -32768 -32768 -32768) 68 (v128.const i16x8 -32768 -32768 -32768 -32768 -32768 -32768 -32768 -32768)) 69 (v128.const i16x8 0 0 0 0 0 0 0 0)) 70 (assert_return (invoke "i16x8.add" (v128.const i16x8 -32768 -32768 -32768 -32768 -32768 -32768 -32768 -32768) 71 (v128.const i16x8 -32767 -32767 -32767 -32767 -32767 -32767 -32767 -32767)) 72 (v128.const i16x8 1 1 1 1 1 1 1 1)) 73 (assert_return (invoke "i16x8.add" (v128.const i16x8 65535 65535 65535 65535 65535 65535 65535 65535) 74 (v128.const i16x8 0 0 0 0 0 0 0 0)) 75 (v128.const i16x8 -1 -1 -1 -1 -1 -1 -1 -1)) 76 (assert_return (invoke "i16x8.add" (v128.const i16x8 65535 65535 65535 65535 65535 65535 65535 65535) 77 (v128.const i16x8 1 1 1 1 1 1 1 1)) 78 (v128.const i16x8 0 0 0 0 0 0 0 0)) 79 (assert_return (invoke "i16x8.add" (v128.const i16x8 65535 65535 65535 65535 65535 65535 65535 65535) 80 (v128.const i16x8 -1 -1 -1 -1 -1 -1 -1 -1)) 81 (v128.const i16x8 -2 -2 -2 -2 -2 -2 -2 -2)) 82 (assert_return (invoke "i16x8.add" (v128.const i16x8 65535 65535 65535 65535 65535 65535 65535 65535) 83 (v128.const i16x8 32767 32767 32767 32767 32767 32767 32767 32767)) 84 (v128.const i16x8 32766 32766 32766 32766 32766 32766 32766 32766)) 85 (assert_return (invoke "i16x8.add" (v128.const i16x8 65535 65535 65535 65535 65535 65535 65535 65535) 86 (v128.const i16x8 -32768 -32768 -32768 -32768 -32768 -32768 -32768 -32768)) 87 (v128.const i16x8 32767 32767 32767 32767 32767 32767 32767 32767)) 88 (assert_return (invoke "i16x8.add" (v128.const i16x8 65535 65535 65535 65535 65535 65535 65535 65535) 89 (v128.const i16x8 65535 65535 65535 65535 65535 65535 65535 65535)) 90 (v128.const i16x8 -2 -2 -2 -2 -2 -2 -2 -2)) 91 (assert_return (invoke "i16x8.add" (v128.const i16x8 0x3fff 0x3fff 0x3fff 0x3fff 0x3fff 0x3fff 0x3fff 0x3fff) 92 (v128.const i16x8 0x4000 0x4000 0x4000 0x4000 0x4000 0x4000 0x4000 0x4000)) 93 (v128.const i16x8 32767 32767 32767 32767 32767 32767 32767 32767)) 94 (assert_return (invoke "i16x8.add" (v128.const i16x8 0x4000 0x4000 0x4000 0x4000 0x4000 0x4000 0x4000 0x4000) 95 (v128.const i16x8 0x4000 0x4000 0x4000 0x4000 0x4000 0x4000 0x4000 0x4000)) 96 (v128.const i16x8 -32768 -32768 -32768 -32768 -32768 -32768 -32768 -32768)) 97 (assert_return (invoke "i16x8.add" (v128.const i16x8 -0x3fff -0x3fff -0x3fff -0x3fff -0x3fff -0x3fff -0x3fff -0x3fff) 98 (v128.const i16x8 -0x4000 -0x4000 -0x4000 -0x4000 -0x4000 -0x4000 -0x4000 -0x4000)) 99 (v128.const i16x8 -32767 -32767 -32767 -32767 -32767 -32767 -32767 -32767)) 100 (assert_return (invoke "i16x8.add" (v128.const i16x8 -0x4000 -0x4000 -0x4000 -0x4000 -0x4000 -0x4000 -0x4000 -0x4000) 101 (v128.const i16x8 -0x4000 -0x4000 -0x4000 -0x4000 -0x4000 -0x4000 -0x4000 -0x4000)) 102 (v128.const i16x8 -32768 -32768 -32768 -32768 -32768 -32768 -32768 -32768)) 103 (assert_return (invoke "i16x8.add" (v128.const i16x8 -0x4000 -0x4000 -0x4000 -0x4000 -0x4000 -0x4000 -0x4000 -0x4000) 104 (v128.const i16x8 -0x4001 -0x4001 -0x4001 -0x4001 -0x4001 -0x4001 -0x4001 -0x4001)) 105 (v128.const i16x8 32767 32767 32767 32767 32767 32767 32767 32767)) 106 (assert_return (invoke "i16x8.add" (v128.const i16x8 0x7fff 0x7fff 0x7fff 0x7fff 0x7fff 0x7fff 0x7fff 0x7fff) 107 (v128.const i16x8 0x7fff 0x7fff 0x7fff 0x7fff 0x7fff 0x7fff 0x7fff 0x7fff)) 108 (v128.const i16x8 -2 -2 -2 -2 -2 -2 -2 -2)) 109 (assert_return (invoke "i16x8.add" (v128.const i16x8 0x7fff 0x7fff 0x7fff 0x7fff 0x7fff 0x7fff 0x7fff 0x7fff) 110 (v128.const i16x8 0x01 0x01 0x01 0x01 0x01 0x01 0x01 0x01)) 111 (v128.const i16x8 -32768 -32768 -32768 -32768 -32768 -32768 -32768 -32768)) 112 (assert_return (invoke "i16x8.add" (v128.const i16x8 0x8000 0x8000 0x8000 0x8000 0x8000 0x8000 0x8000 0x8000) 113 (v128.const i16x8 -0x01 -0x01 -0x01 -0x01 -0x01 -0x01 -0x01 -0x01)) 114 (v128.const i16x8 32767 32767 32767 32767 32767 32767 32767 32767)) 115 (assert_return (invoke "i16x8.add" (v128.const i16x8 0x7fff 0x7fff 0x7fff 0x7fff 0x7fff 0x7fff 0x7fff 0x7fff) 116 (v128.const i16x8 0x8000 0x8000 0x8000 0x8000 0x8000 0x8000 0x8000 0x8000)) 117 (v128.const i16x8 -1 -1 -1 -1 -1 -1 -1 -1)) 118 (assert_return (invoke "i16x8.add" (v128.const i16x8 0x8000 0x8000 0x8000 0x8000 0x8000 0x8000 0x8000 0x8000) 119 (v128.const i16x8 0x8000 0x8000 0x8000 0x8000 0x8000 0x8000 0x8000 0x8000)) 120 (v128.const i16x8 0 0 0 0 0 0 0 0)) 121 (assert_return (invoke "i16x8.add" (v128.const i16x8 0xffff 0xffff 0xffff 0xffff 0xffff 0xffff 0xffff 0xffff) 122 (v128.const i16x8 0x01 0x01 0x01 0x01 0x01 0x01 0x01 0x01)) 123 (v128.const i16x8 0 0 0 0 0 0 0 0)) 124 (assert_return (invoke "i16x8.add" (v128.const i16x8 0xffff 0xffff 0xffff 0xffff 0xffff 0xffff 0xffff 0xffff) 125 (v128.const i16x8 0xffff 0xffff 0xffff 0xffff 0xffff 0xffff 0xffff 0xffff)) 126 (v128.const i16x8 -2 -2 -2 -2 -2 -2 -2 -2)) 127 (assert_return (invoke "i16x8.add" (v128.const i16x8 0x7fff 0x7fff 0x7fff 0x7fff 0x7fff 0x7fff 0x7fff 0x7fff) 128 (v128.const i8x16 0 0x80 0 0x80 0 0x80 0 0x80 0 0x80 0 0x80 0 0x80 0 0x80)) 129 (v128.const i16x8 -1 -1 -1 -1 -1 -1 -1 -1)) 130 (assert_return (invoke "i16x8.add" (v128.const i16x8 1 1 1 1 1 1 1 1) 131 (v128.const i8x16 255 255 255 255 255 255 255 255 255 255 255 255 255 255 255 255)) 132 (v128.const i16x8 0 0 0 0 0 0 0 0)) 133 (assert_return (invoke "i16x8.add" (v128.const i16x8 0x7fff 0x7fff 0x7fff 0x7fff 0x7fff 0x7fff 0x7fff 0x7fff) 134 (v128.const i32x4 0x80008000 0x80008000 0x80008000 0x80008000)) 135 (v128.const i16x8 -1 -1 -1 -1 -1 -1 -1 -1)) 136 (assert_return (invoke "i16x8.add" (v128.const i16x8 1 1 1 1 1 1 1 1) 137 (v128.const i32x4 0xffffffff 0xffffffff 0xffffffff 0xffffffff)) 138 (v128.const i16x8 0 0 0 0 0 0 0 0)) 139 (assert_return (invoke "i16x8.add" (v128.const i16x8 0x8000 0x8000 0x8000 0x8000 0x8000 0x8000 0x8000 0x8000) 140 (v128.const f32x4 +0.0 +0.0 +0.0 +0.0)) 141 (v128.const i16x8 0x8000 0x8000 0x8000 0x8000 0x8000 0x8000 0x8000 0x8000)) 142 (assert_return (invoke "i16x8.add" (v128.const i16x8 0x8000 0x8000 0x8000 0x8000 0x8000 0x8000 0x8000 0x8000) 143 (v128.const f32x4 -0.0 -0.0 -0.0 -0.0)) 144 (v128.const i16x8 0x8000 0 0x8000 0 0x8000 0 0x8000 0)) 145 (assert_return (invoke "i16x8.add" (v128.const i16x8 0x8000 0x8000 0x8000 0x8000 0x8000 0x8000 0x8000 0x8000) 146 (v128.const f32x4 1.0 1.0 1.0 1.0)) 147 (v128.const i16x8 0x8000 0xbf80 0x8000 0xbf80 0x8000 0xbf80 0x8000 0xbf80)) 148 (assert_return (invoke "i16x8.add" (v128.const i16x8 0x8000 0x8000 0x8000 0x8000 0x8000 0x8000 0x8000 0x8000) 149 (v128.const f32x4 -1.0 -1.0 -1.0 -1.0)) 150 (v128.const i16x8 0x8000 0x3f80 0x8000 0x3f80 0x8000 0x3f80 0x8000 0x3f80)) 151 (assert_return (invoke "i16x8.add" (v128.const i16x8 1 1 1 1 1 1 1 1) 152 (v128.const f32x4 +inf +inf +inf +inf)) 153 (v128.const i16x8 0x01 0x7f81 0x01 0x7f81 0x01 0x7f81 0x01 0x7f81)) 154 (assert_return (invoke "i16x8.add" (v128.const i16x8 1 1 1 1 1 1 1 1) 155 (v128.const f32x4 -inf -inf -inf -inf)) 156 (v128.const i16x8 0x01 0xff81 0x01 0xff81 0x01 0xff81 0x01 0xff81)) 157 (assert_return (invoke "i16x8.add" (v128.const i16x8 1 1 1 1 1 1 1 1) 158 (v128.const f32x4 nan nan nan nan)) 159 (v128.const i16x8 0x01 0x7fc1 0x01 0x7fc1 0x01 0x7fc1 0x01 0x7fc1)) 160 (assert_return (invoke "i16x8.add" (v128.const i16x8 0 1 2 3 4 5 6 7) 161 (v128.const i16x8 0 0xffff 0xfffe 0xfffd 0xfffc 0xfffb 0xfffa 0xfff9)) 162 (v128.const i16x8 0 0 0 0 0 0 0 0)) 163 (assert_return (invoke "i16x8.add" (v128.const i16x8 0 1 2 3 4 5 6 7) 164 (v128.const i16x8 0 2 4 6 8 10 12 14)) 165 (v128.const i16x8 0 3 6 9 12 15 18 21)) 166 (assert_return (invoke "i16x8.add" (v128.const i16x8 012_345 012_345 012_345 012_345 012_345 012_345 012_345 012_345) 167 (v128.const i16x8 056_789 056_789 056_789 056_789 056_789 056_789 056_789 056_789)) 168 (v128.const i16x8 03_598 03_598 03_598 03_598 03_598 03_598 03_598 03_598)) 169 (assert_return (invoke "i16x8.add" (v128.const i16x8 0x0_1234 0x0_1234 0x0_1234 0x0_1234 0x0_1234 0x0_1234 0x0_1234 0x0_1234) 170 (v128.const i16x8 0x0_5678 0x0_5678 0x0_5678 0x0_5678 0x0_5678 0x0_5678 0x0_5678 0x0_5678)) 171 (v128.const i16x8 0x0_68ac 0x0_68ac 0x0_68ac 0x0_68ac 0x0_68ac 0x0_68ac 0x0_68ac 0x0_68ac)) 172 173 ;; i16x8.sub 174 (assert_return (invoke "i16x8.sub" (v128.const i16x8 0 0 0 0 0 0 0 0) 175 (v128.const i16x8 0 0 0 0 0 0 0 0)) 176 (v128.const i16x8 0 0 0 0 0 0 0 0)) 177 (assert_return (invoke "i16x8.sub" (v128.const i16x8 0 0 0 0 0 0 0 0) 178 (v128.const i16x8 1 1 1 1 1 1 1 1)) 179 (v128.const i16x8 -1 -1 -1 -1 -1 -1 -1 -1)) 180 (assert_return (invoke "i16x8.sub" (v128.const i16x8 1 1 1 1 1 1 1 1) 181 (v128.const i16x8 1 1 1 1 1 1 1 1)) 182 (v128.const i16x8 0 0 0 0 0 0 0 0)) 183 (assert_return (invoke "i16x8.sub" (v128.const i16x8 0 0 0 0 0 0 0 0) 184 (v128.const i16x8 -1 -1 -1 -1 -1 -1 -1 -1)) 185 (v128.const i16x8 1 1 1 1 1 1 1 1)) 186 (assert_return (invoke "i16x8.sub" (v128.const i16x8 1 1 1 1 1 1 1 1) 187 (v128.const i16x8 -1 -1 -1 -1 -1 -1 -1 -1)) 188 (v128.const i16x8 2 2 2 2 2 2 2 2)) 189 (assert_return (invoke "i16x8.sub" (v128.const i16x8 -1 -1 -1 -1 -1 -1 -1 -1) 190 (v128.const i16x8 -1 -1 -1 -1 -1 -1 -1 -1)) 191 (v128.const i16x8 0 0 0 0 0 0 0 0)) 192 (assert_return (invoke "i16x8.sub" (v128.const i16x8 16383 16383 16383 16383 16383 16383 16383 16383) 193 (v128.const i16x8 16384 16384 16384 16384 16384 16384 16384 16384)) 194 (v128.const i16x8 -1 -1 -1 -1 -1 -1 -1 -1)) 195 (assert_return (invoke "i16x8.sub" (v128.const i16x8 16384 16384 16384 16384 16384 16384 16384 16384) 196 (v128.const i16x8 16384 16384 16384 16384 16384 16384 16384 16384)) 197 (v128.const i16x8 0 0 0 0 0 0 0 0)) 198 (assert_return (invoke "i16x8.sub" (v128.const i16x8 -16383 -16383 -16383 -16383 -16383 -16383 -16383 -16383) 199 (v128.const i16x8 -16384 -16384 -16384 -16384 -16384 -16384 -16384 -16384)) 200 (v128.const i16x8 1 1 1 1 1 1 1 1)) 201 (assert_return (invoke "i16x8.sub" (v128.const i16x8 -16384 -16384 -16384 -16384 -16384 -16384 -16384 -16384) 202 (v128.const i16x8 -16384 -16384 -16384 -16384 -16384 -16384 -16384 -16384)) 203 (v128.const i16x8 0 0 0 0 0 0 0 0)) 204 (assert_return (invoke "i16x8.sub" (v128.const i16x8 -16385 -16385 -16385 -16385 -16385 -16385 -16385 -16385) 205 (v128.const i16x8 -16384 -16384 -16384 -16384 -16384 -16384 -16384 -16384)) 206 (v128.const i16x8 -1 -1 -1 -1 -1 -1 -1 -1)) 207 (assert_return (invoke "i16x8.sub" (v128.const i16x8 32765 32765 32765 32765 32765 32765 32765 32765) 208 (v128.const i16x8 1 1 1 1 1 1 1 1)) 209 (v128.const i16x8 32764 32764 32764 32764 32764 32764 32764 32764)) 210 (assert_return (invoke "i16x8.sub" (v128.const i16x8 32766 32766 32766 32766 32766 32766 32766 32766) 211 (v128.const i16x8 1 1 1 1 1 1 1 1)) 212 (v128.const i16x8 32765 32765 32765 32765 32765 32765 32765 32765)) 213 (assert_return (invoke "i16x8.sub" (v128.const i16x8 32768 32768 32768 32768 32768 32768 32768 32768) 214 (v128.const i16x8 1 1 1 1 1 1 1 1)) 215 (v128.const i16x8 32767 32767 32767 32767 32767 32767 32767 32767)) 216 (assert_return (invoke "i16x8.sub" (v128.const i16x8 -32766 -32766 -32766 -32766 -32766 -32766 -32766 -32766) 217 (v128.const i16x8 -1 -1 -1 -1 -1 -1 -1 -1)) 218 (v128.const i16x8 -32765 -32765 -32765 -32765 -32765 -32765 -32765 -32765)) 219 (assert_return (invoke "i16x8.sub" (v128.const i16x8 -32767 -32767 -32767 -32767 -32767 -32767 -32767 -32767) 220 (v128.const i16x8 -1 -1 -1 -1 -1 -1 -1 -1)) 221 (v128.const i16x8 -32766 -32766 -32766 -32766 -32766 -32766 -32766 -32766)) 222 (assert_return (invoke "i16x8.sub" (v128.const i16x8 -32768 -32768 -32768 -32768 -32768 -32768 -32768 -32768) 223 (v128.const i16x8 -1 -1 -1 -1 -1 -1 -1 -1)) 224 (v128.const i16x8 -32767 -32767 -32767 -32767 -32767 -32767 -32767 -32767)) 225 (assert_return (invoke "i16x8.sub" (v128.const i16x8 32767 32767 32767 32767 32767 32767 32767 32767) 226 (v128.const i16x8 32767 32767 32767 32767 32767 32767 32767 32767)) 227 (v128.const i16x8 0 0 0 0 0 0 0 0)) 228 (assert_return (invoke "i16x8.sub" (v128.const i16x8 -32768 -32768 -32768 -32768 -32768 -32768 -32768 -32768) 229 (v128.const i16x8 -32768 -32768 -32768 -32768 -32768 -32768 -32768 -32768)) 230 (v128.const i16x8 0 0 0 0 0 0 0 0)) 231 (assert_return (invoke "i16x8.sub" (v128.const i16x8 -32768 -32768 -32768 -32768 -32768 -32768 -32768 -32768) 232 (v128.const i16x8 -32767 -32767 -32767 -32767 -32767 -32767 -32767 -32767)) 233 (v128.const i16x8 -1 -1 -1 -1 -1 -1 -1 -1)) 234 (assert_return (invoke "i16x8.sub" (v128.const i16x8 65535 65535 65535 65535 65535 65535 65535 65535) 235 (v128.const i16x8 0 0 0 0 0 0 0 0)) 236 (v128.const i16x8 -1 -1 -1 -1 -1 -1 -1 -1)) 237 (assert_return (invoke "i16x8.sub" (v128.const i16x8 65535 65535 65535 65535 65535 65535 65535 65535) 238 (v128.const i16x8 1 1 1 1 1 1 1 1)) 239 (v128.const i16x8 -2 -2 -2 -2 -2 -2 -2 -2)) 240 (assert_return (invoke "i16x8.sub" (v128.const i16x8 65535 65535 65535 65535 65535 65535 65535 65535) 241 (v128.const i16x8 -1 -1 -1 -1 -1 -1 -1 -1)) 242 (v128.const i16x8 0 0 0 0 0 0 0 0)) 243 (assert_return (invoke "i16x8.sub" (v128.const i16x8 65535 65535 65535 65535 65535 65535 65535 65535) 244 (v128.const i16x8 32767 32767 32767 32767 32767 32767 32767 32767)) 245 (v128.const i16x8 -32768 -32768 -32768 -32768 -32768 -32768 -32768 -32768)) 246 (assert_return (invoke "i16x8.sub" (v128.const i16x8 65535 65535 65535 65535 65535 65535 65535 65535) 247 (v128.const i16x8 -32768 -32768 -32768 -32768 -32768 -32768 -32768 -32768)) 248 (v128.const i16x8 32767 32767 32767 32767 32767 32767 32767 32767)) 249 (assert_return (invoke "i16x8.sub" (v128.const i16x8 65535 65535 65535 65535 65535 65535 65535 65535) 250 (v128.const i16x8 65535 65535 65535 65535 65535 65535 65535 65535)) 251 (v128.const i16x8 0 0 0 0 0 0 0 0)) 252 (assert_return (invoke "i16x8.sub" (v128.const i16x8 0x3fff 0x3fff 0x3fff 0x3fff 0x3fff 0x3fff 0x3fff 0x3fff) 253 (v128.const i16x8 0x4000 0x4000 0x4000 0x4000 0x4000 0x4000 0x4000 0x4000)) 254 (v128.const i16x8 -1 -1 -1 -1 -1 -1 -1 -1)) 255 (assert_return (invoke "i16x8.sub" (v128.const i16x8 0x4000 0x4000 0x4000 0x4000 0x4000 0x4000 0x4000 0x4000) 256 (v128.const i16x8 0x4000 0x4000 0x4000 0x4000 0x4000 0x4000 0x4000 0x4000)) 257 (v128.const i16x8 0 0 0 0 0 0 0 0)) 258 (assert_return (invoke "i16x8.sub" (v128.const i16x8 -0x3fff -0x3fff -0x3fff -0x3fff -0x3fff -0x3fff -0x3fff -0x3fff) 259 (v128.const i16x8 -0x4000 -0x4000 -0x4000 -0x4000 -0x4000 -0x4000 -0x4000 -0x4000)) 260 (v128.const i16x8 1 1 1 1 1 1 1 1)) 261 (assert_return (invoke "i16x8.sub" (v128.const i16x8 -0x4000 -0x4000 -0x4000 -0x4000 -0x4000 -0x4000 -0x4000 -0x4000) 262 (v128.const i16x8 -0x4000 -0x4000 -0x4000 -0x4000 -0x4000 -0x4000 -0x4000 -0x4000)) 263 (v128.const i16x8 0 0 0 0 0 0 0 0)) 264 (assert_return (invoke "i16x8.sub" (v128.const i16x8 -0x4000 -0x4000 -0x4000 -0x4000 -0x4000 -0x4000 -0x4000 -0x4000) 265 (v128.const i16x8 -0x4001 -0x4001 -0x4001 -0x4001 -0x4001 -0x4001 -0x4001 -0x4001)) 266 (v128.const i16x8 1 1 1 1 1 1 1 1)) 267 (assert_return (invoke "i16x8.sub" (v128.const i16x8 0x7fff 0x7fff 0x7fff 0x7fff 0x7fff 0x7fff 0x7fff 0x7fff) 268 (v128.const i16x8 0x7fff 0x7fff 0x7fff 0x7fff 0x7fff 0x7fff 0x7fff 0x7fff)) 269 (v128.const i16x8 0 0 0 0 0 0 0 0)) 270 (assert_return (invoke "i16x8.sub" (v128.const i16x8 0x7fff 0x7fff 0x7fff 0x7fff 0x7fff 0x7fff 0x7fff 0x7fff) 271 (v128.const i16x8 0x01 0x01 0x01 0x01 0x01 0x01 0x01 0x01)) 272 (v128.const i16x8 32766 32766 32766 32766 32766 32766 32766 32766)) 273 (assert_return (invoke "i16x8.sub" (v128.const i16x8 0x8000 0x8000 0x8000 0x8000 0x8000 0x8000 0x8000 0x8000) 274 (v128.const i16x8 -0x01 -0x01 -0x01 -0x01 -0x01 -0x01 -0x01 -0x01)) 275 (v128.const i16x8 -32767 -32767 -32767 -32767 -32767 -32767 -32767 -32767)) 276 (assert_return (invoke "i16x8.sub" (v128.const i16x8 0x7fff 0x7fff 0x7fff 0x7fff 0x7fff 0x7fff 0x7fff 0x7fff) 277 (v128.const i16x8 0x8000 0x8000 0x8000 0x8000 0x8000 0x8000 0x8000 0x8000)) 278 (v128.const i16x8 -1 -1 -1 -1 -1 -1 -1 -1)) 279 (assert_return (invoke "i16x8.sub" (v128.const i16x8 0x8000 0x8000 0x8000 0x8000 0x8000 0x8000 0x8000 0x8000) 280 (v128.const i16x8 0x8000 0x8000 0x8000 0x8000 0x8000 0x8000 0x8000 0x8000)) 281 (v128.const i16x8 0 0 0 0 0 0 0 0)) 282 (assert_return (invoke "i16x8.sub" (v128.const i16x8 0xffff 0xffff 0xffff 0xffff 0xffff 0xffff 0xffff 0xffff) 283 (v128.const i16x8 0x01 0x01 0x01 0x01 0x01 0x01 0x01 0x01)) 284 (v128.const i16x8 -2 -2 -2 -2 -2 -2 -2 -2)) 285 (assert_return (invoke "i16x8.sub" (v128.const i16x8 0xffff 0xffff 0xffff 0xffff 0xffff 0xffff 0xffff 0xffff) 286 (v128.const i16x8 0xffff 0xffff 0xffff 0xffff 0xffff 0xffff 0xffff 0xffff)) 287 (v128.const i16x8 0 0 0 0 0 0 0 0)) 288 (assert_return (invoke "i16x8.sub" (v128.const i16x8 0x7fff 0x7fff 0x7fff 0x7fff 0x7fff 0x7fff 0x7fff 0x7fff) 289 (v128.const i8x16 0 0x80 0 0x80 0 0x80 0 0x80 0 0x80 0 0x80 0 0x80 0 0x80)) 290 (v128.const i16x8 -1 -1 -1 -1 -1 -1 -1 -1)) 291 (assert_return (invoke "i16x8.sub" (v128.const i16x8 1 1 1 1 1 1 1 1) 292 (v128.const i8x16 255 255 255 255 255 255 255 255 255 255 255 255 255 255 255 255)) 293 (v128.const i16x8 0x02 0x02 0x02 0x02 0x02 0x02 0x02 0x02)) 294 (assert_return (invoke "i16x8.sub" (v128.const i16x8 0x7fff 0x7fff 0x7fff 0x7fff 0x7fff 0x7fff 0x7fff 0x7fff) 295 (v128.const i32x4 0x80008000 0x80008000 0x80008000 0x80008000)) 296 (v128.const i16x8 -1 -1 -1 -1 -1 -1 -1 -1)) 297 (assert_return (invoke "i16x8.sub" (v128.const i16x8 1 1 1 1 1 1 1 1) 298 (v128.const i32x4 0xffffffff 0xffffffff 0xffffffff 0xffffffff)) 299 (v128.const i16x8 0x02 0x02 0x02 0x02 0x02 0x02 0x02 0x02)) 300 (assert_return (invoke "i16x8.sub" (v128.const i16x8 0x8000 0x8000 0x8000 0x8000 0x8000 0x8000 0x8000 0x8000) 301 (v128.const f32x4 +0.0 +0.0 +0.0 +0.0)) 302 (v128.const i16x8 0x8000 0x8000 0x8000 0x8000 0x8000 0x8000 0x8000 0x8000)) 303 (assert_return (invoke "i16x8.sub" (v128.const i16x8 0x8000 0x8000 0x8000 0x8000 0x8000 0x8000 0x8000 0x8000) 304 (v128.const f32x4 -0.0 -0.0 -0.0 -0.0)) 305 (v128.const i16x8 0x8000 0 0x8000 0 0x8000 0 0x8000 0)) 306 (assert_return (invoke "i16x8.sub" (v128.const i16x8 0x8000 0x8000 0x8000 0x8000 0x8000 0x8000 0x8000 0x8000) 307 (v128.const f32x4 1.0 1.0 1.0 1.0)) 308 (v128.const i16x8 0x8000 0x4080 0x8000 0x4080 0x8000 0x4080 0x8000 0x4080)) 309 (assert_return (invoke "i16x8.sub" (v128.const i16x8 0x8000 0x8000 0x8000 0x8000 0x8000 0x8000 0x8000 0x8000) 310 (v128.const f32x4 -1.0 -1.0 -1.0 -1.0)) 311 (v128.const i16x8 0x8000 0xc080 0x8000 0xc080 0x8000 0xc080 0x8000 0xc080)) 312 (assert_return (invoke "i16x8.sub" (v128.const i16x8 1 1 1 1 1 1 1 1) 313 (v128.const f32x4 +inf +inf +inf +inf)) 314 (v128.const i16x8 0x01 0x8081 0x01 0x8081 0x01 0x8081 0x01 0x8081)) 315 (assert_return (invoke "i16x8.sub" (v128.const i16x8 1 1 1 1 1 1 1 1) 316 (v128.const f32x4 -inf -inf -inf -inf)) 317 (v128.const i16x8 0x01 0x81 0x01 0x81 0x01 0x81 0x01 0x81)) 318 (assert_return (invoke "i16x8.sub" (v128.const i16x8 1 1 1 1 1 1 1 1) 319 (v128.const f32x4 nan nan nan nan)) 320 (v128.const i16x8 0x01 0x8041 0x01 0x8041 0x01 0x8041 0x01 0x8041)) 321 (assert_return (invoke "i16x8.sub" (v128.const i16x8 0 1 2 3 4 5 6 7) 322 (v128.const i16x8 0 0xffff 0xfffe 0xfffd 0xfffc 0xfffb 0xfffa 0xfff9)) 323 (v128.const i16x8 0 0x02 0x04 0x06 0x08 0x0a 0x0c 0x0e)) 324 (assert_return (invoke "i16x8.sub" (v128.const i16x8 0 1 2 3 4 5 6 7) 325 (v128.const i16x8 0 2 4 6 8 10 12 14)) 326 (v128.const i16x8 0 -1 -2 -3 -4 -5 -6 -7)) 327 (assert_return (invoke "i16x8.sub" (v128.const i16x8 056_789 056_789 056_789 056_789 056_789 056_789 056_789 056_789) 328 (v128.const i16x8 012_345 012_345 012_345 012_345 012_345 012_345 012_345 012_345)) 329 (v128.const i16x8 044_444 044_444 044_444 044_444 044_444 044_444 044_444 044_444)) 330 (assert_return (invoke "i16x8.sub" (v128.const i16x8 0x0_5678 0x0_5678 0x0_5678 0x0_5678 0x0_5678 0x0_5678 0x0_5678 0x0_5678) 331 (v128.const i16x8 0x0_1234 0x0_1234 0x0_1234 0x0_1234 0x0_1234 0x0_1234 0x0_1234 0x0_1234)) 332 (v128.const i16x8 0x0_4444 0x0_4444 0x0_4444 0x0_4444 0x0_4444 0x0_4444 0x0_4444 0x0_4444)) 333 334 ;; i16x8.mul 335 (assert_return (invoke "i16x8.mul" (v128.const i16x8 0 0 0 0 0 0 0 0) 336 (v128.const i16x8 0 0 0 0 0 0 0 0)) 337 (v128.const i16x8 0 0 0 0 0 0 0 0)) 338 (assert_return (invoke "i16x8.mul" (v128.const i16x8 0 0 0 0 0 0 0 0) 339 (v128.const i16x8 1 1 1 1 1 1 1 1)) 340 (v128.const i16x8 0 0 0 0 0 0 0 0)) 341 (assert_return (invoke "i16x8.mul" (v128.const i16x8 1 1 1 1 1 1 1 1) 342 (v128.const i16x8 1 1 1 1 1 1 1 1)) 343 (v128.const i16x8 1 1 1 1 1 1 1 1)) 344 (assert_return (invoke "i16x8.mul" (v128.const i16x8 0 0 0 0 0 0 0 0) 345 (v128.const i16x8 -1 -1 -1 -1 -1 -1 -1 -1)) 346 (v128.const i16x8 0 0 0 0 0 0 0 0)) 347 (assert_return (invoke "i16x8.mul" (v128.const i16x8 1 1 1 1 1 1 1 1) 348 (v128.const i16x8 -1 -1 -1 -1 -1 -1 -1 -1)) 349 (v128.const i16x8 -1 -1 -1 -1 -1 -1 -1 -1)) 350 (assert_return (invoke "i16x8.mul" (v128.const i16x8 -1 -1 -1 -1 -1 -1 -1 -1) 351 (v128.const i16x8 -1 -1 -1 -1 -1 -1 -1 -1)) 352 (v128.const i16x8 1 1 1 1 1 1 1 1)) 353 (assert_return (invoke "i16x8.mul" (v128.const i16x8 16383 16383 16383 16383 16383 16383 16383 16383) 354 (v128.const i16x8 16384 16384 16384 16384 16384 16384 16384 16384)) 355 (v128.const i16x8 -16384 -16384 -16384 -16384 -16384 -16384 -16384 -16384)) 356 (assert_return (invoke "i16x8.mul" (v128.const i16x8 16384 16384 16384 16384 16384 16384 16384 16384) 357 (v128.const i16x8 16384 16384 16384 16384 16384 16384 16384 16384)) 358 (v128.const i16x8 0 0 0 0 0 0 0 0)) 359 (assert_return (invoke "i16x8.mul" (v128.const i16x8 -16383 -16383 -16383 -16383 -16383 -16383 -16383 -16383) 360 (v128.const i16x8 -16384 -16384 -16384 -16384 -16384 -16384 -16384 -16384)) 361 (v128.const i16x8 -16384 -16384 -16384 -16384 -16384 -16384 -16384 -16384)) 362 (assert_return (invoke "i16x8.mul" (v128.const i16x8 -16384 -16384 -16384 -16384 -16384 -16384 -16384 -16384) 363 (v128.const i16x8 -16384 -16384 -16384 -16384 -16384 -16384 -16384 -16384)) 364 (v128.const i16x8 0 0 0 0 0 0 0 0)) 365 (assert_return (invoke "i16x8.mul" (v128.const i16x8 -16385 -16385 -16385 -16385 -16385 -16385 -16385 -16385) 366 (v128.const i16x8 -16384 -16384 -16384 -16384 -16384 -16384 -16384 -16384)) 367 (v128.const i16x8 16384 16384 16384 16384 16384 16384 16384 16384)) 368 (assert_return (invoke "i16x8.mul" (v128.const i16x8 32765 32765 32765 32765 32765 32765 32765 32765) 369 (v128.const i16x8 1 1 1 1 1 1 1 1)) 370 (v128.const i16x8 32765 32765 32765 32765 32765 32765 32765 32765)) 371 (assert_return (invoke "i16x8.mul" (v128.const i16x8 32766 32766 32766 32766 32766 32766 32766 32766) 372 (v128.const i16x8 1 1 1 1 1 1 1 1)) 373 (v128.const i16x8 32766 32766 32766 32766 32766 32766 32766 32766)) 374 (assert_return (invoke "i16x8.mul" (v128.const i16x8 32768 32768 32768 32768 32768 32768 32768 32768) 375 (v128.const i16x8 1 1 1 1 1 1 1 1)) 376 (v128.const i16x8 -32768 -32768 -32768 -32768 -32768 -32768 -32768 -32768)) 377 (assert_return (invoke "i16x8.mul" (v128.const i16x8 -32766 -32766 -32766 -32766 -32766 -32766 -32766 -32766) 378 (v128.const i16x8 -1 -1 -1 -1 -1 -1 -1 -1)) 379 (v128.const i16x8 32766 32766 32766 32766 32766 32766 32766 32766)) 380 (assert_return (invoke "i16x8.mul" (v128.const i16x8 -32767 -32767 -32767 -32767 -32767 -32767 -32767 -32767) 381 (v128.const i16x8 -1 -1 -1 -1 -1 -1 -1 -1)) 382 (v128.const i16x8 32767 32767 32767 32767 32767 32767 32767 32767)) 383 (assert_return (invoke "i16x8.mul" (v128.const i16x8 -32768 -32768 -32768 -32768 -32768 -32768 -32768 -32768) 384 (v128.const i16x8 -1 -1 -1 -1 -1 -1 -1 -1)) 385 (v128.const i16x8 -32768 -32768 -32768 -32768 -32768 -32768 -32768 -32768)) 386 (assert_return (invoke "i16x8.mul" (v128.const i16x8 32767 32767 32767 32767 32767 32767 32767 32767) 387 (v128.const i16x8 32767 32767 32767 32767 32767 32767 32767 32767)) 388 (v128.const i16x8 1 1 1 1 1 1 1 1)) 389 (assert_return (invoke "i16x8.mul" (v128.const i16x8 -32768 -32768 -32768 -32768 -32768 -32768 -32768 -32768) 390 (v128.const i16x8 -32768 -32768 -32768 -32768 -32768 -32768 -32768 -32768)) 391 (v128.const i16x8 0 0 0 0 0 0 0 0)) 392 (assert_return (invoke "i16x8.mul" (v128.const i16x8 -32768 -32768 -32768 -32768 -32768 -32768 -32768 -32768) 393 (v128.const i16x8 -32767 -32767 -32767 -32767 -32767 -32767 -32767 -32767)) 394 (v128.const i16x8 -32768 -32768 -32768 -32768 -32768 -32768 -32768 -32768)) 395 (assert_return (invoke "i16x8.mul" (v128.const i16x8 65535 65535 65535 65535 65535 65535 65535 65535) 396 (v128.const i16x8 0 0 0 0 0 0 0 0)) 397 (v128.const i16x8 0 0 0 0 0 0 0 0)) 398 (assert_return (invoke "i16x8.mul" (v128.const i16x8 65535 65535 65535 65535 65535 65535 65535 65535) 399 (v128.const i16x8 1 1 1 1 1 1 1 1)) 400 (v128.const i16x8 -1 -1 -1 -1 -1 -1 -1 -1)) 401 (assert_return (invoke "i16x8.mul" (v128.const i16x8 65535 65535 65535 65535 65535 65535 65535 65535) 402 (v128.const i16x8 -1 -1 -1 -1 -1 -1 -1 -1)) 403 (v128.const i16x8 1 1 1 1 1 1 1 1)) 404 (assert_return (invoke "i16x8.mul" (v128.const i16x8 65535 65535 65535 65535 65535 65535 65535 65535) 405 (v128.const i16x8 32767 32767 32767 32767 32767 32767 32767 32767)) 406 (v128.const i16x8 -32767 -32767 -32767 -32767 -32767 -32767 -32767 -32767)) 407 (assert_return (invoke "i16x8.mul" (v128.const i16x8 65535 65535 65535 65535 65535 65535 65535 65535) 408 (v128.const i16x8 -32768 -32768 -32768 -32768 -32768 -32768 -32768 -32768)) 409 (v128.const i16x8 -32768 -32768 -32768 -32768 -32768 -32768 -32768 -32768)) 410 (assert_return (invoke "i16x8.mul" (v128.const i16x8 65535 65535 65535 65535 65535 65535 65535 65535) 411 (v128.const i16x8 65535 65535 65535 65535 65535 65535 65535 65535)) 412 (v128.const i16x8 1 1 1 1 1 1 1 1)) 413 (assert_return (invoke "i16x8.mul" (v128.const i16x8 0x3fff 0x3fff 0x3fff 0x3fff 0x3fff 0x3fff 0x3fff 0x3fff) 414 (v128.const i16x8 0x4000 0x4000 0x4000 0x4000 0x4000 0x4000 0x4000 0x4000)) 415 (v128.const i16x8 -16384 -16384 -16384 -16384 -16384 -16384 -16384 -16384)) 416 (assert_return (invoke "i16x8.mul" (v128.const i16x8 0x4000 0x4000 0x4000 0x4000 0x4000 0x4000 0x4000 0x4000) 417 (v128.const i16x8 0x4000 0x4000 0x4000 0x4000 0x4000 0x4000 0x4000 0x4000)) 418 (v128.const i16x8 0 0 0 0 0 0 0 0)) 419 (assert_return (invoke "i16x8.mul" (v128.const i16x8 -0x3fff -0x3fff -0x3fff -0x3fff -0x3fff -0x3fff -0x3fff -0x3fff) 420 (v128.const i16x8 -0x4000 -0x4000 -0x4000 -0x4000 -0x4000 -0x4000 -0x4000 -0x4000)) 421 (v128.const i16x8 -16384 -16384 -16384 -16384 -16384 -16384 -16384 -16384)) 422 (assert_return (invoke "i16x8.mul" (v128.const i16x8 -0x4000 -0x4000 -0x4000 -0x4000 -0x4000 -0x4000 -0x4000 -0x4000) 423 (v128.const i16x8 -0x4000 -0x4000 -0x4000 -0x4000 -0x4000 -0x4000 -0x4000 -0x4000)) 424 (v128.const i16x8 0 0 0 0 0 0 0 0)) 425 (assert_return (invoke "i16x8.mul" (v128.const i16x8 -0x4000 -0x4000 -0x4000 -0x4000 -0x4000 -0x4000 -0x4000 -0x4000) 426 (v128.const i16x8 -0x4001 -0x4001 -0x4001 -0x4001 -0x4001 -0x4001 -0x4001 -0x4001)) 427 (v128.const i16x8 16384 16384 16384 16384 16384 16384 16384 16384)) 428 (assert_return (invoke "i16x8.mul" (v128.const i16x8 0x7fff 0x7fff 0x7fff 0x7fff 0x7fff 0x7fff 0x7fff 0x7fff) 429 (v128.const i16x8 0x7fff 0x7fff 0x7fff 0x7fff 0x7fff 0x7fff 0x7fff 0x7fff)) 430 (v128.const i16x8 1 1 1 1 1 1 1 1)) 431 (assert_return (invoke "i16x8.mul" (v128.const i16x8 0x7fff 0x7fff 0x7fff 0x7fff 0x7fff 0x7fff 0x7fff 0x7fff) 432 (v128.const i16x8 0x01 0x01 0x01 0x01 0x01 0x01 0x01 0x01)) 433 (v128.const i16x8 32767 32767 32767 32767 32767 32767 32767 32767)) 434 (assert_return (invoke "i16x8.mul" (v128.const i16x8 0x8000 0x8000 0x8000 0x8000 0x8000 0x8000 0x8000 0x8000) 435 (v128.const i16x8 -0x01 -0x01 -0x01 -0x01 -0x01 -0x01 -0x01 -0x01)) 436 (v128.const i16x8 -32768 -32768 -32768 -32768 -32768 -32768 -32768 -32768)) 437 (assert_return (invoke "i16x8.mul" (v128.const i16x8 0x7fff 0x7fff 0x7fff 0x7fff 0x7fff 0x7fff 0x7fff 0x7fff) 438 (v128.const i16x8 0x8000 0x8000 0x8000 0x8000 0x8000 0x8000 0x8000 0x8000)) 439 (v128.const i16x8 -32768 -32768 -32768 -32768 -32768 -32768 -32768 -32768)) 440 (assert_return (invoke "i16x8.mul" (v128.const i16x8 0x8000 0x8000 0x8000 0x8000 0x8000 0x8000 0x8000 0x8000) 441 (v128.const i16x8 0x8000 0x8000 0x8000 0x8000 0x8000 0x8000 0x8000 0x8000)) 442 (v128.const i16x8 0 0 0 0 0 0 0 0)) 443 (assert_return (invoke "i16x8.mul" (v128.const i16x8 0xffff 0xffff 0xffff 0xffff 0xffff 0xffff 0xffff 0xffff) 444 (v128.const i16x8 0x01 0x01 0x01 0x01 0x01 0x01 0x01 0x01)) 445 (v128.const i16x8 -1 -1 -1 -1 -1 -1 -1 -1)) 446 (assert_return (invoke "i16x8.mul" (v128.const i16x8 0xffff 0xffff 0xffff 0xffff 0xffff 0xffff 0xffff 0xffff) 447 (v128.const i16x8 0xffff 0xffff 0xffff 0xffff 0xffff 0xffff 0xffff 0xffff)) 448 (v128.const i16x8 1 1 1 1 1 1 1 1)) 449 (assert_return (invoke "i16x8.mul" (v128.const i16x8 0x1000 0x1000 0x1000 0x1000 0x1000 0x1000 0x1000 0x1000) 450 (v128.const i8x16 0x10 0x10 0x10 0x10 0x10 0x10 0x10 0x10 0x10 0x10 0x10 0x10 0x10 0x10 0x10 0x10)) 451 (v128.const i16x8 0 0 0 0 0 0 0 0)) 452 (assert_return (invoke "i16x8.mul" (v128.const i16x8 65535 65535 65535 65535 65535 65535 65535 65535) 453 (v128.const i8x16 255 255 255 255 255 255 255 255 255 255 255 255 255 255 255 255)) 454 (v128.const i16x8 0x01 0x01 0x01 0x01 0x01 0x01 0x01 0x01)) 455 (assert_return (invoke "i16x8.mul" (v128.const i16x8 0x8000 0x8000 0x8000 0x8000 0x8000 0x8000 0x8000 0x8000) 456 (v128.const i32x4 0x00020002 0x00020002 0x00020002 0x00020002)) 457 (v128.const i16x8 0 0 0 0 0 0 0 0)) 458 (assert_return (invoke "i16x8.mul" (v128.const i16x8 65535 65535 65535 65535 65535 65535 65535 65535) 459 (v128.const i32x4 0xffffffff 0xffffffff 0xffffffff 0xffffffff)) 460 (v128.const i16x8 0x01 0x01 0x01 0x01 0x01 0x01 0x01 0x01)) 461 (assert_return (invoke "i16x8.mul" (v128.const i16x8 0x8000 0x8000 0x8000 0x8000 0x8000 0x8000 0x8000 0x8000) 462 (v128.const f32x4 +0.0 +0.0 +0.0 +0.0)) 463 (v128.const i16x8 0 0 0 0 0 0 0 0)) 464 (assert_return (invoke "i16x8.mul" (v128.const i16x8 0x8000 0x8000 0x8000 0x8000 0x8000 0x8000 0x8000 0x8000) 465 (v128.const f32x4 -0.0 -0.0 -0.0 -0.0)) 466 (v128.const i16x8 0 0 0 0 0 0 0 0)) 467 (assert_return (invoke "i16x8.mul" (v128.const i16x8 0x8000 0x8000 0x8000 0x8000 0x8000 0x8000 0x8000 0x8000) 468 (v128.const f32x4 1.0 1.0 1.0 1.0)) 469 (v128.const i16x8 0 0 0 0 0 0 0 0)) 470 (assert_return (invoke "i16x8.mul" (v128.const i16x8 0x8000 0x8000 0x8000 0x8000 0x8000 0x8000 0x8000 0x8000) 471 (v128.const f32x4 -1.0 -1.0 -1.0 -1.0)) 472 (v128.const i16x8 0 0 0 0 0 0 0 0)) 473 (assert_return (invoke "i16x8.mul" (v128.const i16x8 1 1 1 1 1 1 1 1) 474 (v128.const f32x4 +inf +inf +inf +inf)) 475 (v128.const i16x8 0 0x7f80 0 0x7f80 0 0x7f80 0 0x7f80)) 476 (assert_return (invoke "i16x8.mul" (v128.const i16x8 1 1 1 1 1 1 1 1) 477 (v128.const f32x4 -inf -inf -inf -inf)) 478 (v128.const i16x8 0 0xff80 0 0xff80 0 0xff80 0 0xff80)) 479 (assert_return (invoke "i16x8.mul" (v128.const i16x8 1 1 1 1 1 1 1 1) 480 (v128.const f32x4 nan nan nan nan)) 481 (v128.const i16x8 0 0x7fc0 0 0x7fc0 0 0x7fc0 0 0x7fc0)) 482 (assert_return (invoke "i16x8.mul" (v128.const i16x8 0 1 2 3 4 5 6 7) 483 (v128.const i16x8 0 0xffff 0xfffe 0xfffd 0xfffc 0xfffb 0xfffa 0xfff9)) 484 (v128.const i16x8 0 0xffff 0xfffc 0xfff7 0xfff0 0xffe7 0xffdc 0xffcf)) 485 (assert_return (invoke "i16x8.mul" (v128.const i16x8 0 1 2 3 4 5 6 7) 486 (v128.const i16x8 0 2 4 6 8 10 12 14)) 487 (v128.const i16x8 0 0x02 0x08 0x12 0x20 0x32 0x48 0x62)) 488 (assert_return (invoke "i16x8.mul" (v128.const i16x8 012_345 012_345 012_345 012_345 012_345 012_345 012_345 012_345) 489 (v128.const i16x8 056_789 056_789 056_789 056_789 056_789 056_789 056_789 056_789)) 490 (v128.const i16x8 021_613 021_613 021_613 021_613 021_613 021_613 021_613 021_613)) 491 (assert_return (invoke "i16x8.mul" (v128.const i16x8 0x0_1234 0x0_1234 0x0_1234 0x0_1234 0x0_1234 0x0_1234 0x0_1234 0x0_1234) 492 (v128.const i16x8 0x0_cdef 0x0_cdef 0x0_cdef 0x0_cdef 0x0_cdef 0x0_cdef 0x0_cdef 0x0_cdef)) 493 (v128.const i16x8 0x0_a28c 0x0_a28c 0x0_a28c 0x0_a28c 0x0_a28c 0x0_a28c 0x0_a28c 0x0_a28c)) 494 495 ;; i16x8.neg 496 (assert_return (invoke "i16x8.neg" (v128.const i16x8 0 0 0 0 0 0 0 0)) 497 (v128.const i16x8 0 0 0 0 0 0 0 0)) 498 (assert_return (invoke "i16x8.neg" (v128.const i16x8 1 1 1 1 1 1 1 1)) 499 (v128.const i16x8 -1 -1 -1 -1 -1 -1 -1 -1)) 500 (assert_return (invoke "i16x8.neg" (v128.const i16x8 -1 -1 -1 -1 -1 -1 -1 -1)) 501 (v128.const i16x8 1 1 1 1 1 1 1 1)) 502 (assert_return (invoke "i16x8.neg" (v128.const i16x8 32766 32766 32766 32766 32766 32766 32766 32766)) 503 (v128.const i16x8 -32766 -32766 -32766 -32766 -32766 -32766 -32766 -32766)) 504 (assert_return (invoke "i16x8.neg" (v128.const i16x8 -32767 -32767 -32767 -32767 -32767 -32767 -32767 -32767)) 505 (v128.const i16x8 32767 32767 32767 32767 32767 32767 32767 32767)) 506 (assert_return (invoke "i16x8.neg" (v128.const i16x8 -32768 -32768 -32768 -32768 -32768 -32768 -32768 -32768)) 507 (v128.const i16x8 -32768 -32768 -32768 -32768 -32768 -32768 -32768 -32768)) 508 (assert_return (invoke "i16x8.neg" (v128.const i16x8 32767 32767 32767 32767 32767 32767 32767 32767)) 509 (v128.const i16x8 -32767 -32767 -32767 -32767 -32767 -32767 -32767 -32767)) 510 (assert_return (invoke "i16x8.neg" (v128.const i16x8 65535 65535 65535 65535 65535 65535 65535 65535)) 511 (v128.const i16x8 1 1 1 1 1 1 1 1)) 512 (assert_return (invoke "i16x8.neg" (v128.const i16x8 0x01 0x01 0x01 0x01 0x01 0x01 0x01 0x01)) 513 (v128.const i16x8 -1 -1 -1 -1 -1 -1 -1 -1)) 514 (assert_return (invoke "i16x8.neg" (v128.const i16x8 -0x01 -0x01 -0x01 -0x01 -0x01 -0x01 -0x01 -0x01)) 515 (v128.const i16x8 1 1 1 1 1 1 1 1)) 516 (assert_return (invoke "i16x8.neg" (v128.const i16x8 -0x8000 -0x8000 -0x8000 -0x8000 -0x8000 -0x8000 -0x8000 -0x8000)) 517 (v128.const i16x8 -32768 -32768 -32768 -32768 -32768 -32768 -32768 -32768)) 518 (assert_return (invoke "i16x8.neg" (v128.const i16x8 -0x7fff -0x7fff -0x7fff -0x7fff -0x7fff -0x7fff -0x7fff -0x7fff)) 519 (v128.const i16x8 32767 32767 32767 32767 32767 32767 32767 32767)) 520 (assert_return (invoke "i16x8.neg" (v128.const i16x8 0x7fff 0x7fff 0x7fff 0x7fff 0x7fff 0x7fff 0x7fff 0x7fff)) 521 (v128.const i16x8 -32767 -32767 -32767 -32767 -32767 -32767 -32767 -32767)) 522 (assert_return (invoke "i16x8.neg" (v128.const i16x8 0x8000 0x8000 0x8000 0x8000 0x8000 0x8000 0x8000 0x8000)) 523 (v128.const i16x8 -32768 -32768 -32768 -32768 -32768 -32768 -32768 -32768)) 524 (assert_return (invoke "i16x8.neg" (v128.const i16x8 0xffff 0xffff 0xffff 0xffff 0xffff 0xffff 0xffff 0xffff)) 525 (v128.const i16x8 1 1 1 1 1 1 1 1)) 526 527 ;; type check 528 (assert_invalid (module (func (result v128) (i16x8.neg (i32.const 0)))) "type mismatch") 529 (assert_invalid (module (func (result v128) (i16x8.add (i32.const 0) (f32.const 0.0)))) "type mismatch") 530 (assert_invalid (module (func (result v128) (i16x8.sub (i32.const 0) (f32.const 0.0)))) "type mismatch") 531 (assert_invalid (module (func (result v128) (i16x8.mul (i32.const 0) (f32.const 0.0)))) "type mismatch") 532 533 ;; Test operation with empty argument 534 535 (assert_invalid 536 (module 537 (func $i16x8.neg-arg-empty (result v128) 538 (i16x8.neg) 539 ) 540 ) 541 "type mismatch" 542 ) 543 (assert_invalid 544 (module 545 (func $i16x8.add-1st-arg-empty (result v128) 546 (i16x8.add (v128.const i16x8 0 0 0 0 0 0 0 0)) 547 ) 548 ) 549 "type mismatch" 550 ) 551 (assert_invalid 552 (module 553 (func $i16x8.add-arg-empty (result v128) 554 (i16x8.add) 555 ) 556 ) 557 "type mismatch" 558 ) 559 (assert_invalid 560 (module 561 (func $i16x8.sub-1st-arg-empty (result v128) 562 (i16x8.sub (v128.const i16x8 0 0 0 0 0 0 0 0)) 563 ) 564 ) 565 "type mismatch" 566 ) 567 (assert_invalid 568 (module 569 (func $i16x8.sub-arg-empty (result v128) 570 (i16x8.sub) 571 ) 572 ) 573 "type mismatch" 574 ) 575 (assert_invalid 576 (module 577 (func $i16x8.mul-1st-arg-empty (result v128) 578 (i16x8.mul (v128.const i16x8 0 0 0 0 0 0 0 0)) 579 ) 580 ) 581 "type mismatch" 582 ) 583 (assert_invalid 584 (module 585 (func $i16x8.mul-arg-empty (result v128) 586 (i16x8.mul) 587 ) 588 ) 589 "type mismatch" 590 ) 591 592 ;; combination 593 (module 594 (func (export "add-sub") (param v128 v128 v128) (result v128) 595 (i16x8.add (i16x8.sub (local.get 0) (local.get 1))(local.get 2))) 596 (func (export "mul-add") (param v128 v128 v128) (result v128) 597 (i16x8.mul (i16x8.add (local.get 0) (local.get 1))(local.get 2))) 598 (func (export "mul-sub") (param v128 v128 v128) (result v128) 599 (i16x8.mul (i16x8.sub (local.get 0) (local.get 1))(local.get 2))) 600 (func (export "sub-add") (param v128 v128 v128) (result v128) 601 (i16x8.sub (i16x8.add (local.get 0) (local.get 1))(local.get 2))) 602 (func (export "add-neg") (param v128 v128) (result v128) 603 (i16x8.add (i16x8.neg (local.get 0)) (local.get 1))) 604 (func (export "mul-neg") (param v128 v128) (result v128) 605 (i16x8.mul (i16x8.neg (local.get 0)) (local.get 1))) 606 (func (export "sub-neg") (param v128 v128) (result v128) 607 (i16x8.sub (i16x8.neg (local.get 0)) (local.get 1))) 608 ) 609 610 (assert_return (invoke "add-sub" (v128.const i16x8 0 1 2 3 4 5 6 7) 611 (v128.const i16x8 0 2 4 6 8 10 12 14) 612 (v128.const i16x8 0 2 4 6 8 10 12 14)) 613 (v128.const i16x8 0 1 2 3 4 5 6 7)) 614 (assert_return (invoke "mul-add" (v128.const i16x8 0 1 2 3 4 5 6 7) 615 (v128.const i16x8 0 1 2 3 4 5 6 7) 616 (v128.const i16x8 2 2 2 2 2 2 2 2)) 617 (v128.const i16x8 0 4 8 12 16 20 24 28)) 618 (assert_return (invoke "mul-sub" (v128.const i16x8 0 2 4 6 8 10 12 14) 619 (v128.const i16x8 0 1 2 3 4 5 6 7) 620 (v128.const i16x8 0 1 2 3 4 5 6 7)) 621 (v128.const i16x8 0 1 4 9 16 25 36 49)) 622 (assert_return (invoke "sub-add" (v128.const i16x8 0 1 2 3 4 5 6 7) 623 (v128.const i16x8 0 2 4 6 8 10 12 14) 624 (v128.const i16x8 0 2 4 6 8 10 12 14)) 625 (v128.const i16x8 0 1 2 3 4 5 6 7)) 626 (assert_return (invoke "add-neg" (v128.const i16x8 0 1 2 3 4 5 6 7) 627 (v128.const i16x8 0 1 2 3 4 5 6 7)) 628 (v128.const i16x8 0 0 0 0 0 0 0 0)) 629 (assert_return (invoke "mul-neg" (v128.const i16x8 0 1 2 3 4 5 6 7) 630 (v128.const i16x8 2 2 2 2 2 2 2 2)) 631 (v128.const i16x8 0 -2 -4 -6 -8 -10 -12 -14)) 632 (assert_return (invoke "sub-neg" (v128.const i16x8 0 1 2 3 4 5 6 7) 633 (v128.const i16x8 0 1 2 3 4 5 6 7)) 634 (v128.const i16x8 0 -2 -4 -6 -8 -10 -12 -14))