summaryrefslogtreecommitdiff
path: root/src/binary-reader.cc
diff options
context:
space:
mode:
authorBen Smith <binji@chromium.org>2020-01-13 16:21:52 -0800
committerGitHub <noreply@github.com>2020-01-13 16:21:52 -0800
commitcd7e137c12691e91e566ac68ce0ad7a7b44b60b9 (patch)
tree21c92b76806a1e75349e2e30b5b478bb0d793847 /src/binary-reader.cc
parent79772de74d458e0f2451b94b9502b23dff316a15 (diff)
downloadwabt-cd7e137c12691e91e566ac68ce0ad7a7b44b60b9.tar.gz
wabt-cd7e137c12691e91e566ac68ce0ad7a7b44b60b9.tar.bz2
wabt-cd7e137c12691e91e566ac68ce0ad7a7b44b60b9.zip
[simd] Add support for narrow/widen instructions (#1301)
* i{8x16,16x8}.narrow_i{16x8,32x4}_{s,u} * i{16x8,32x4}.widen_{low,high}_i{8x16,16x8}_{s,u} (though not all combinations are valid) These are not currently supported in the interpreter. TODO: Implement other new SIMD instructions too: load and extend, bitwise and-not, lanewise rounding average
Diffstat (limited to 'src/binary-reader.cc')
-rw-r--r--src/binary-reader.cc12
1 files changed, 12 insertions, 0 deletions
diff --git a/src/binary-reader.cc b/src/binary-reader.cc
index bf6222da..ca8fcf0f 100644
--- a/src/binary-reader.cc
+++ b/src/binary-reader.cc
@@ -1014,6 +1014,10 @@ Result BinaryReader::ReadFunctionBody(Offset end_offset) {
case Opcode::F32X4Mul:
case Opcode::F64X2Mul:
case Opcode::V8X16Swizzle:
+ case Opcode::I8X16NarrowI16X8S:
+ case Opcode::I8X16NarrowI16X8U:
+ case Opcode::I16X8NarrowI32X4S:
+ case Opcode::I16X8NarrowI32X4U:
CALLBACK(OnBinaryExpr, opcode);
CALLBACK0(OnOpcodeBare);
break;
@@ -1141,6 +1145,14 @@ Result BinaryReader::ReadFunctionBody(Offset end_offset) {
case Opcode::F64X2Abs:
case Opcode::F32X4Sqrt:
case Opcode::F64X2Sqrt:
+ case Opcode::I16X8WidenLowI8X16S:
+ case Opcode::I16X8WidenHighI8X16S:
+ case Opcode::I16X8WidenLowI8X16U:
+ case Opcode::I16X8WidenHighI8X16U:
+ case Opcode::I32X4WidenLowI16X8S:
+ case Opcode::I32X4WidenHighI16X8S:
+ case Opcode::I32X4WidenLowI16X8U:
+ case Opcode::I32X4WidenHighI16X8U:
CALLBACK(OnUnaryExpr, opcode);
CALLBACK0(OnOpcodeBare);
break;