summaryrefslogtreecommitdiff
path: root/crates/types
diff options
context:
space:
mode:
authorHenry Gressmann <mail@henrygressmann.de>2024-11-18 14:18:50 +0100
committerHenry Gressmann <mail@henrygressmann.de>2024-11-18 14:18:50 +0100
commit2d5899a38ef352f2aa056cc77d51c4668bf2c0a4 (patch)
treed9b33faa02257ec01434891a848c2ceffd47ceec /crates/types
parent802a10ad70b285660806e8e074e382a03c413f09 (diff)
chore: basic simd instructions
Signed-off-by: Henry Gressmann <mail@henrygressmann.de>
Diffstat (limited to 'crates/types')
-rw-r--r--crates/types/src/instructions.rs8
1 files changed, 4 insertions, 4 deletions
diff --git a/crates/types/src/instructions.rs b/crates/types/src/instructions.rs
index 1edfef7..fb3c1cc 100644
--- a/crates/types/src/instructions.rs
+++ b/crates/types/src/instructions.rs
@@ -52,7 +52,7 @@ pub enum ConstInstruction {
/// This makes it easier to implement the label stack iteratively.
///
/// See <https://webassembly.github.io/spec/core/binary/instructions.html>
-#[derive(Debug, Clone, PartialEq)]
+#[derive(Debug, Clone, Copy, PartialEq)]
#[cfg_attr(feature = "archive", derive(rkyv::Archive, rkyv::Serialize, rkyv::Deserialize))]
// should be kept as small as possible (16 bytes max)
#[rustfmt::skip]
@@ -193,10 +193,10 @@ impl From<SimdInstruction> for Instruction {
}
}
-#[derive(Debug, Clone, PartialEq)]
+#[derive(Debug, Clone, Copy, PartialEq)]
#[cfg_attr(feature = "archive", derive(rkyv::Archive, rkyv::Serialize, rkyv::Deserialize))]
#[rustfmt::skip]
-pub enum SimdInstruction {
+pub enum SimdInstruction {
V128Load(MemoryArg),
V128Load8x8S(MemoryArg), V128Load8x8U(MemoryArg),
V128Load16x4S(MemoryArg), V128Load16x4U(MemoryArg),
@@ -204,7 +204,7 @@ pub enum SimdInstruction {
V128Load8Splat(MemoryArg), V128Load16Splat(MemoryArg), V128Load32Splat(MemoryArg), V128Load64Splat(MemoryArg),
V128Load8Lane(MemoryArg, u8), V128Load16Lane(MemoryArg, u8), V128Load32Lane(MemoryArg, u8), V128Load64Lane(MemoryArg, u8),
-
+
V128Load32Zero(MemoryArg), V128Load64Zero(MemoryArg),
V128Store(MemoryArg), V128Store8Lane(MemoryArg, u8), V128Store16Lane(MemoryArg, u8), V128Store32Lane(MemoryArg, u8), V128Store64Lane(MemoryArg, u8),