summaryrefslogtreecommitdiff
path: root/test/example
diff options
context:
space:
mode:
authorDaniel Wirtz <dcode@dcode.io>2021-04-07 23:27:06 +0200
committerGitHub <noreply@github.com>2021-04-07 23:27:06 +0200
commita36c455f6a2e9fa48751c985fa49b33ce94277c4 (patch)
tree02967daa87d3ae20b0aa3026610c8a55a8012eec /test/example
parent2f2d5a80197b837aea928a0a604a13cc1c74219b (diff)
downloadbinaryen-a36c455f6a2e9fa48751c985fa49b33ce94277c4.tar.gz
binaryen-a36c455f6a2e9fa48751c985fa49b33ce94277c4.tar.bz2
binaryen-a36c455f6a2e9fa48751c985fa49b33ce94277c4.zip
Add i64x2.extend_low/high_* SIMD instructions to C/JS API (#3778)
Adds C/JS APIs for the SIMD instructions * ExtendLowSVecI32x4ToVecI64x2 * ExtendHighSVecI32x4ToVecI64x2 * ExtendLowUVecI32x4ToVecI64x2 * ExtendHighUVecI32x4ToVecI64x2
Diffstat (limited to 'test/example')
-rw-r--r--test/example/c-api-kitchen-sink.c4
-rw-r--r--test/example/c-api-kitchen-sink.txt20
2 files changed, 24 insertions, 0 deletions
diff --git a/test/example/c-api-kitchen-sink.c b/test/example/c-api-kitchen-sink.c
index abc5e1489..887f33b58 100644
--- a/test/example/c-api-kitchen-sink.c
+++ b/test/example/c-api-kitchen-sink.c
@@ -439,6 +439,10 @@ void test_core() {
makeUnary(module, BinaryenExtendHighSVecI16x8ToVecI32x4(), v128),
makeUnary(module, BinaryenExtendLowUVecI16x8ToVecI32x4(), v128),
makeUnary(module, BinaryenExtendHighUVecI16x8ToVecI32x4(), v128),
+ makeUnary(module, BinaryenExtendLowSVecI32x4ToVecI64x2(), v128),
+ makeUnary(module, BinaryenExtendHighSVecI32x4ToVecI64x2(), v128),
+ makeUnary(module, BinaryenExtendLowUVecI32x4ToVecI64x2(), v128),
+ makeUnary(module, BinaryenExtendHighUVecI32x4ToVecI64x2(), v128),
// Binary
makeBinary(module, BinaryenAddInt32(), i32),
makeBinary(module, BinaryenSubFloat64(), f64),
diff --git a/test/example/c-api-kitchen-sink.txt b/test/example/c-api-kitchen-sink.txt
index 8bf0c770a..244777478 100644
--- a/test/example/c-api-kitchen-sink.txt
+++ b/test/example/c-api-kitchen-sink.txt
@@ -492,6 +492,26 @@ BinaryenFeatureAll: 8191
)
)
(drop
+ (i64x2.extend_low_i32x4_s
+ (v128.const i32x4 0x04030201 0x08070605 0x0c0b0a09 0x100f0e0d)
+ )
+ )
+ (drop
+ (i64x2.extend_high_i32x4_s
+ (v128.const i32x4 0x04030201 0x08070605 0x0c0b0a09 0x100f0e0d)
+ )
+ )
+ (drop
+ (i64x2.extend_low_i32x4_u
+ (v128.const i32x4 0x04030201 0x08070605 0x0c0b0a09 0x100f0e0d)
+ )
+ )
+ (drop
+ (i64x2.extend_high_i32x4_u
+ (v128.const i32x4 0x04030201 0x08070605 0x0c0b0a09 0x100f0e0d)
+ )
+ )
+ (drop
(i32.add
(i32.const -10)
(i32.const -11)