diff options
author | Wojciech Kosior <kwojtus@protonmail.com> | 2020-10-06 18:49:05 +0200 |
---|---|---|
committer | Wojciech Kosior <kwojtus@protonmail.com> | 2020-10-06 18:49:05 +0200 |
commit | 63a2cced4238af7d171e0b8807d887c435b4656b (patch) | |
tree | e08a23b3700ccd540c053d7c4cbe24bf7cf53d6c /tools/wasm.h | |
parent | f0cd9e4e8bc1e1b109fff627c75527ee7195c82e (diff) | |
download | AGH-engineering-thesis-63a2cced4238af7d171e0b8807d887c435b4656b.tar.gz AGH-engineering-thesis-63a2cced4238af7d171e0b8807d887c435b4656b.zip |
add translation of relational operations and loops
Diffstat (limited to 'tools/wasm.h')
-rw-r--r-- | tools/wasm.h | 12 |
1 files changed, 12 insertions, 0 deletions
diff --git a/tools/wasm.h b/tools/wasm.h index 476f892..8333ce5 100644 --- a/tools/wasm.h +++ b/tools/wasm.h @@ -22,6 +22,7 @@ #define EXPORT_GLOBALIDX 0x03 /* WebAssembly opcodes */ +#define WASM_LOOP 0x03 #define WASM_IF 0x04 #define WASM_ELSE 0x05 #define WASM_END 0x0B @@ -30,6 +31,7 @@ #define WASM_CALL 0x10 #define WASM_LOCAL_GET 0x20 +#define WASM_LOCAL_SET 0x21 #define WASM_I32_LOAD 0x28 #define WASM_I32_LOAD8_S 0x2C @@ -43,6 +45,16 @@ #define WASM_I32_CONST 0x41 +#define WASM_I32_EQ 0x46 +#define WASM_I32_LT_S 0x48 +#define WASM_I32_LT_U 0x49 +#define WASM_I32_GT_S 0x4A +#define WASM_I32_GT_U 0x4B +#define WASM_I32_LE_S 0x4C +#define WASM_I32_LE_U 0x4D +#define WASM_I32_GE_S 0x4E +#define WASM_I32_GE_U 0x4F + #define WASM_I32_ADD 0x6A #define WASM_I32_SUB 0x6B #define WASM_I32_MUL 0x6C |