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

Commit 36a8199

Browse files
penzntlively
authored andcommitted
Introduce Load and Extend (#98)
And remove i8x16.mul, as documented in #28 and #98.
1 parent 310141c commit 36a8199

File tree

3 files changed

+23
-3
lines changed

3 files changed

+23
-3
lines changed

proposals/simd/BinarySIMD.md

Lines changed: 6 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -109,7 +109,6 @@ The `v8x16.shuffle` instruction has 16 bytes after `simdop`.
109109
| `i8x16.sub` | `0x5a`| - |
110110
| `i8x16.sub_saturate_s` | `0x5b`| - |
111111
| `i8x16.sub_saturate_u` | `0x5c`| - |
112-
| `i8x16.mul` | `0x5d`| - |
113112
| `i16x8.neg` | `0x62`| - |
114113
| `i16x8.any_true` | `0x63`| - |
115114
| `i16x8.all_true` | `0x64`| - |
@@ -184,3 +183,9 @@ The `v8x16.shuffle` instruction has 16 bytes after `simdop`.
184183
| `i32x4.widen_high_i16x8_s` | `0xcf`| - |
185184
| `i32x4.widen_low_i16x8_u` | `0xd0`| - |
186185
| `i32x4.widen_high_i16x8_u` | `0xd1`| - |
186+
| `i16x8.load8x8_u` | `0xd2`| m:memarg |
187+
| `i16x8.load8x8_s` | `0xd3`| m:memarg |
188+
| `i32x4.load16x4_u` | `0xd4`| m:memarg |
189+
| `i32x4.load16x4_s` | `0xd5`| m:memarg |
190+
| `i64x2.load32x2_u` | `0xd6`| m:memarg |
191+
| `i64x2.load32x2_s` | `0xd7`| m:memarg |

proposals/simd/ImplementationStatus.md

Lines changed: 6 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -86,7 +86,6 @@
8686
| `i8x16.sub` | `-msimd128` | :heavy_check_mark: | :heavy_check_mark: | :heavy_check_mark: |
8787
| `i8x16.sub_saturate_s` | `-msimd128` | :heavy_check_mark: | :heavy_check_mark: | :heavy_check_mark: |
8888
| `i8x16.sub_saturate_u` | `-msimd128` | :heavy_check_mark: | :heavy_check_mark: | :heavy_check_mark: |
89-
| `i8x16.mul` | `-msimd128` | :heavy_check_mark: | :heavy_check_mark: | :heavy_check_mark: |
9089
| `i16x8.neg` | `-msimd128` | :heavy_check_mark: | :heavy_check_mark: | :heavy_check_mark: |
9190
| `i16x8.any_true` | `-msimd128` | :heavy_check_mark: | :heavy_check_mark: | :heavy_check_mark: |
9291
| `i16x8.all_true` | `-msimd128` | :heavy_check_mark: | :heavy_check_mark: | :heavy_check_mark: |
@@ -145,6 +144,12 @@
145144
| `f64x2.convert_u/i64x2` | `-munimplemented-simd128` | | :heavy_check_mark: | :heavy_check_mark: |
146145
| `v8x16.swizzle` | | | :heavy_check_mark: | |
147146
| `v8x16.shuffle` | | | :heavy_check_mark: | :heavy_check_mark: |
147+
| `i16x8.load8x8_u` | | | | |
148+
| `i16x8.load8x8_s` | | | | |
149+
| `i32x4.load16x4_u` | | | | |
150+
| `i32x4.load16x4_s` | | | | |
151+
| `i64x2.load32x2_u` | | | | |
152+
| `i64x2.load32x2_s` | | | | |
148153
| `i8x16.narrow_i16x8_s` | | :heavy_check_mark: | :heavy_check_mark: | |
149154
| `i8x16.narrow_i16x8_u` | | :heavy_check_mark: | :heavy_check_mark: | |
150155
| `i16x8.narrow_i32x4_s` | | :heavy_check_mark: | :heavy_check_mark: | |

proposals/simd/SIMD.md

Lines changed: 11 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -367,7 +367,6 @@ def S.sub(a, b):
367367
```
368368

369369
### Integer multiplication
370-
* `i8x16.mul(a: v128, b: v128) -> v128`
371370
* `i16x8.mul(a: v128, b: v128) -> v128`
372371
* `i32x4.mul(a: v128, b: v128) -> v128`
373372

@@ -675,6 +674,17 @@ Load a `v128` vector from the given heap address.
675674

676675
Load a single element and splat to all lanes of a `v128` vector.
677676

677+
### Load and Extend
678+
679+
* `i16x8.load8x8_u(memarg) -> v128`: load eight 8-bit integers and zero extend each one to a 16-bit lane
680+
* `i16x8.load8x8_s(memarg) -> v128`: load eight 8-bit integers and sign extend each one to a 16-bit lane
681+
* `i32x4.load16x4_u(memarg) -> v128`: load four 16-bit integers and zero extend each one to a 32-bit lane
682+
* `i32x4.load16x4_s(memarg) -> v128`: load four 16-bit integers and sign extend each one to a 32-bit lane
683+
* `i64x2.load32x2_u(memarg) -> v128`: load two 32-bit integers and zero extend each one to a 64-bit lane
684+
* `i64x2.load32x2_s(memarg) -> v128`: load two 32-bit integers and sign extend each one to a 64-bit lane
685+
686+
Fetch consequtive integers up to 32-bit wide and produce a vector with lanes up to 64 bits.
687+
678688
### Store
679689

680690
* `v128.store(memarg, data: v128)`

0 commit comments

Comments
 (0)