Skip to content
This repository was archived by the owner on Dec 22, 2021. It is now read-only.

Commit 2e55aab

Browse files
committed
i64x4.widen_(low/high)_i32x8_(s/u) instructions
1 parent 8551a32 commit 2e55aab

File tree

4 files changed

+42
-30
lines changed

4 files changed

+42
-30
lines changed

proposals/simd/BinarySIMD.md

+4
Original file line numberDiff line numberDiff line change
@@ -183,6 +183,10 @@ For example, `ImmLaneIdx16` is a byte with values in the range 0-15 (inclusive).
183183
| `i32x4.max_u` | `0xb9`| - |
184184
| `i32x4.dot_i16x8_s` | `0xba`| - |
185185
| `i64x2.neg` | `0xc1`| - |
186+
| `i64x2.widen_low_i32x4_s` | `0xc7`| - |
187+
| `i64x2.widen_high_i32x4_s` | `0xc8`| - |
188+
| `i64x2.widen_low_i32x4_u` | `0xc9`| - |
189+
| `i64x2.widen_high_i32x4_u` | `0xca`| - |
186190
| `i64x2.shl` | `0xcb`| - |
187191
| `i64x2.shr_s` | `0xcc`| - |
188192
| `i64x2.shr_u` | `0xcd`| - |

proposals/simd/ImplementationStatus.md

+4
Original file line numberDiff line numberDiff line change
@@ -157,6 +157,10 @@
157157
| `i64x2.add` | `-msimd128` | :heavy_check_mark: | | :heavy_check_mark: | :heavy_check_mark: |
158158
| `i64x2.sub` | `-msimd128` | :heavy_check_mark: | | :heavy_check_mark: | :heavy_check_mark: |
159159
| `i64x2.mul` | `-msimd128` | :heavy_check_mark: | | | :heavy_check_mark: |
160+
| `i64x2.widen_low_i32x4_s` | | | | | |
161+
| `i64x2.widen_high_i32x4_s` | | | | | |
162+
| `i64x2.widen_low_i32x4_u` | | | | | |
163+
| `i64x2.widen_high_i32x4_u` | | | | | |
160164
| `f32x4.abs` | `-msimd128` | :heavy_check_mark: | | :heavy_check_mark: | :heavy_check_mark: |
161165
| `f32x4.neg` | `-msimd128` | :heavy_check_mark: | | :heavy_check_mark: | :heavy_check_mark: |
162166
| `f32x4.sqrt` | `-msimd128` | :heavy_check_mark: | | :heavy_check_mark: | :heavy_check_mark: |

proposals/simd/NewOpcodes.md

+30-30
Original file line numberDiff line numberDiff line change
@@ -78,36 +78,36 @@
7878
| v128.xor | 0x51 |
7979
| v128.bitselect | 0x52 |
8080

81-
| i8x16 Op | opcode | i16x8 Op | opcode | i32x4 Op | opcode | i64x2 Op | opcode |
82-
| -------------------- | ------ | ------------------------ | ------ | ------------------------ | ------ | ----------- | ------ |
83-
| i8x16.abs | 0x60 | i16x8.abs | 0x80 | i32x4.abs | 0xa0 | ---- | 0xc0 |
84-
| i8x16.neg | 0x61 | i16x8.neg | 0x81 | i32x4.neg | 0xa1 | i64x2.neg | 0xc1 |
85-
| i8x16.any_true | 0x62 | i16x8.any_true | 0x82 | i32x4.any_true | 0xa2 | ---- | 0xc2 |
86-
| i8x16.all_true | 0x63 | i16x8.all_true | 0x83 | i32x4.all_true | 0xa3 | ---- | 0xc3 |
87-
| i8x16.bitmask | 0x64 | i16x8.bitmask | 0x84 | i32x4.bitmask | 0xa4 | ---- | 0xc4 |
88-
| i8x16.narrow_i16x8_s | 0x65 | i16x8.narrow_i32x4_s | 0x85 | ---- narrow ---- | 0xa5 | ---- | 0xc5 |
89-
| i8x16.narrow_i16x8_u | 0x66 | i16x8.narrow_i32x4_u | 0x86 | ---- narrow ---- | 0xa6 | ---- | 0xc6 |
90-
| ---- widen ---- | 0x67 | i16x8.widen_low_i8x16_s | 0x87 | i32x4.widen_low_i16x8_s | 0xa7 | ---- | 0xc7 |
91-
| ---- widen ---- | 0x68 | i16x8.widen_high_i8x16_s | 0x88 | i32x4.widen_high_i16x8_s | 0xa8 | ---- | 0xc8 |
92-
| ---- widen ---- | 0x69 | i16x8.widen_low_i8x16_u | 0x89 | i32x4.widen_low_i16x8_u | 0xa9 | ---- | 0xc9 |
93-
| ---- widen ---- | 0x6a | i16x8.widen_high_i8x16_u | 0x8a | i32x4.widen_high_i16x8_u | 0xaa | ---- | 0xca |
94-
| i8x16.shl | 0x6b | i16x8.shl | 0x8b | i32x4.shl | 0xab | i64x2.shl | 0xcb |
95-
| i8x16.shr_s | 0x6c | i16x8.shr_s | 0x8c | i32x4.shr_s | 0xac | i64x2.shr_s | 0xcc |
96-
| i8x16.shr_u | 0x6d | i16x8.shr_u | 0x8d | i32x4.shr_u | 0xad | i64x2.shr_u | 0xcd |
97-
| i8x16.add | 0x6e | i16x8.add | 0x8e | i32x4.add | 0xae | i64x2.add | 0xce |
98-
| i8x16.add_sat_s | 0x6f | i16x8.add_sat_s | 0x8f | ---- add_sat ---- | 0xaf | ---- | 0xcf |
99-
| i8x16.add_sat_u | 0x70 | i16x8.add_sat_u | 0x90 | ---- add_sat ---- | 0xb0 | ---- | 0xd0 |
100-
| i8x16.sub | 0x71 | i16x8.sub | 0x91 | i32x4.sub | 0xb1 | i64x2.sub | 0xd1 |
101-
| i8x16.sub_sat_s | 0x72 | i16x8.sub_sat_s | 0x92 | ---- sub_sat ---- | 0xb2 | ---- | 0xd2 |
102-
| i8x16.sub_sat_u | 0x73 | i16x8.sub_sat_u | 0x93 | ---- sub_sat ---- | 0xb3 | ---- | 0xd3 |
103-
| ------------- | 0x74 | ------------- | 0x94 | ------------- | 0xb4 | ---- | 0xd4 |
104-
| ---- mul ---- | 0x75 | i16x8.mul | 0x95 | i32x4.mul | 0xb5 | i64x2.mul | 0xd5 |
105-
| i8x16.min_s | 0x76 | i16x8.min_s | 0x96 | i32x4.min_s | 0xb6 | ---- | 0xd6 |
106-
| i8x16.min_u | 0x77 | i16x8.min_u | 0x97 | i32x4.min_u | 0xb7 | ---- | 0xd7 |
107-
| i8x16.max_s | 0x78 | i16x8.max_s | 0x98 | i32x4.max_s | 0xb8 | ---- | 0xd8 |
108-
| i8x16.max_u | 0x79 | i16x8.max_u | 0x99 | i32x4.max_u | 0xb9 | ---- | 0xd9 |
109-
| ---------------- | 0x7a | ---------------- | 0x9a | i32x4.dot_i16x8_s | 0xba | ---- | 0xda |
110-
| i8x16.avgr_u | 0x7b | i16x8.avgr_u | 0x9b | ---- avgr_u ---- | 0xbb | ---- | 0xdb |
81+
| i8x16 Op | opcode | i16x8 Op | opcode | i32x4 Op | opcode | i64x2 Op | opcode |
82+
| -------------------- | ------ | ------------------------ | ------ | ------------------------ | ------ | ------------------------ | ------ |
83+
| i8x16.abs | 0x60 | i16x8.abs | 0x80 | i32x4.abs | 0xa0 | ---- | 0xc0 |
84+
| i8x16.neg | 0x61 | i16x8.neg | 0x81 | i32x4.neg | 0xa1 | i64x2.neg | 0xc1 |
85+
| i8x16.any_true | 0x62 | i16x8.any_true | 0x82 | i32x4.any_true | 0xa2 | ---- | 0xc2 |
86+
| i8x16.all_true | 0x63 | i16x8.all_true | 0x83 | i32x4.all_true | 0xa3 | ---- | 0xc3 |
87+
| i8x16.bitmask | 0x64 | i16x8.bitmask | 0x84 | i32x4.bitmask | 0xa4 | ---- | 0xc4 |
88+
| i8x16.narrow_i16x8_s | 0x65 | i16x8.narrow_i32x4_s | 0x85 | ---- narrow ---- | 0xa5 | ---- | 0xc5 |
89+
| i8x16.narrow_i16x8_u | 0x66 | i16x8.narrow_i32x4_u | 0x86 | ---- narrow ---- | 0xa6 | ---- | 0xc6 |
90+
| ---- widen ---- | 0x67 | i16x8.widen_low_i8x16_s | 0x87 | i32x4.widen_low_i16x8_s | 0xa7 | i64x2.widen_low_i32x4_s | 0xc7 |
91+
| ---- widen ---- | 0x68 | i16x8.widen_high_i8x16_s | 0x88 | i32x4.widen_high_i16x8_s | 0xa8 | i64x2.widen_high_i32x4_s | 0xc8 |
92+
| ---- widen ---- | 0x69 | i16x8.widen_low_i8x16_u | 0x89 | i32x4.widen_low_i16x8_u | 0xa9 | i64x2.widen_low_i32x4_u | 0xc9 |
93+
| ---- widen ---- | 0x6a | i16x8.widen_high_i8x16_u | 0x8a | i32x4.widen_high_i16x8_u | 0xaa | i64x2.widen_high_i32x4_u | 0xca |
94+
| i8x16.shl | 0x6b | i16x8.shl | 0x8b | i32x4.shl | 0xab | i64x2.shl | 0xcb |
95+
| i8x16.shr_s | 0x6c | i16x8.shr_s | 0x8c | i32x4.shr_s | 0xac | i64x2.shr_s | 0xcc |
96+
| i8x16.shr_u | 0x6d | i16x8.shr_u | 0x8d | i32x4.shr_u | 0xad | i64x2.shr_u | 0xcd |
97+
| i8x16.add | 0x6e | i16x8.add | 0x8e | i32x4.add | 0xae | i64x2.add | 0xce |
98+
| i8x16.add_sat_s | 0x6f | i16x8.add_sat_s | 0x8f | ---- add_sat ---- | 0xaf | ---- | 0xcf |
99+
| i8x16.add_sat_u | 0x70 | i16x8.add_sat_u | 0x90 | ---- add_sat ---- | 0xb0 | ---- | 0xd0 |
100+
| i8x16.sub | 0x71 | i16x8.sub | 0x91 | i32x4.sub | 0xb1 | i64x2.sub | 0xd1 |
101+
| i8x16.sub_sat_s | 0x72 | i16x8.sub_sat_s | 0x92 | ---- sub_sat ---- | 0xb2 | ---- | 0xd2 |
102+
| i8x16.sub_sat_u | 0x73 | i16x8.sub_sat_u | 0x93 | ---- sub_sat ---- | 0xb3 | ---- | 0xd3 |
103+
| ------------- | 0x74 | ------------- | 0x94 | ------------- | 0xb4 | ---- | 0xd4 |
104+
| ---- mul ---- | 0x75 | i16x8.mul | 0x95 | i32x4.mul | 0xb5 | i64x2.mul | 0xd5 |
105+
| i8x16.min_s | 0x76 | i16x8.min_s | 0x96 | i32x4.min_s | 0xb6 | ---- | 0xd6 |
106+
| i8x16.min_u | 0x77 | i16x8.min_u | 0x97 | i32x4.min_u | 0xb7 | ---- | 0xd7 |
107+
| i8x16.max_s | 0x78 | i16x8.max_s | 0x98 | i32x4.max_s | 0xb8 | ---- | 0xd8 |
108+
| i8x16.max_u | 0x79 | i16x8.max_u | 0x99 | i32x4.max_u | 0xb9 | ---- | 0xd9 |
109+
| ---------------- | 0x7a | ---------------- | 0x9a | i32x4.dot_i16x8_s | 0xba | ---- | 0xda |
110+
| i8x16.avgr_u | 0x7b | i16x8.avgr_u | 0x9b | ---- avgr_u ---- | 0xbb | ---- | 0xdb |
111111

112112
| f32x4 Op | opcode | f64x2 Op | opcode |
113113
| --------------- | ------ | --------------- | ------ |

proposals/simd/SIMD.md

+4
Original file line numberDiff line numberDiff line change
@@ -1019,6 +1019,10 @@ def S.narrow_T_u(a, b):
10191019
* `i32x4.widen_high_i16x8_s(a: v128) -> v128`
10201020
* `i32x4.widen_low_i16x8_u(a: v128) -> v128`
10211021
* `i32x4.widen_high_i16x8_u(a: v128) -> v128`
1022+
* `i64x2.widen_low_i32x4_s(a: v128) -> v128`
1023+
* `i64x2.widen_high_i32x4_s(a: v128) -> v128`
1024+
* `i64x2.widen_low_i32x4_u(a: v128) -> v128`
1025+
* `i64x2.widen_high_i32x4_u(a: v128) -> v128`
10221026

10231027
Converts low or high half of the smaller lane vector to a larger lane vector,
10241028
sign extended or zero (unsigned) extended.

0 commit comments

Comments
 (0)