aboutsummaryrefslogtreecommitdiff
path: root/tools/translate_xmacro.h
diff options
context:
space:
mode:
Diffstat (limited to 'tools/translate_xmacro.h')
-rw-r--r--tools/translate_xmacro.h31
1 files changed, 16 insertions, 15 deletions
diff --git a/tools/translate_xmacro.h b/tools/translate_xmacro.h
index 2fc4558..5e5bd79 100644
--- a/tools/translate_xmacro.h
+++ b/tools/translate_xmacro.h
@@ -1,19 +1,20 @@
/* X-macro-like definition of translation routines for each webasm opcode */
-TS(WASM_I32_ADD, add)
-TS(WASM_I32_SUB, sub)
-TS(WASM_I32_DIV_U, div)
-TS(WASM_I32_MUL, mul)
+/* wasm_opcode_______**translation_routine**argument_types**result_type*/
+TS (WASM_I32_ADD, add, i32_i32, i32)
+TS (WASM_I32_SUB, sub, i32_i32, i32)
+TS (WASM_I32_DIV_U, div, i32_i32, i32)
+TS (WASM_I32_MUL, mul, i32_i32, i32)
-TLS(WASM_I32_LOAD, load_p)
-TLS(WASM_I32_LOAD8_S, loadbsx_p)
-TLS(WASM_I32_LOAD8_U, loadbzx_p)
-TLS(WASM_I32_LOAD16_S, loadwsx_p)
-TLS(WASM_I32_LOAD16_U, loadwzx_p)
-TLS(WASM_I32_STORE, store_p)
-TLS(WASM_I32_STORE8, storeb_p)
-TLS(WASM_I32_STORE16, storew_p)
+TLS(WASM_I32_LOAD, load_p, i32, i32)
+TLS(WASM_I32_LOAD8_S, loadbsx_p, i32, i32)
+TLS(WASM_I32_LOAD8_U, loadbzx_p, i32, i32)
+TLS(WASM_I32_LOAD16_S, loadwsx_p, i32, i32)
+TLS(WASM_I32_LOAD16_U, loadwzx_p, i32, i32)
+TLS(WASM_I32_STORE, store_p, i32_i32, empty)
+TLS(WASM_I32_STORE8, storeb_p, i32_i32, empty)
+TLS(WASM_I32_STORE16, storew_p, i32_i32, empty)
-TC(WASM_CALL, call)
-TC(WASM_LOCAL_GET, local_get)
-TC(WASM_I32_CONST, const)
+TC (WASM_CALL, call, custom, custom)
+TC (WASM_LOCAL_GET, local_get, empty, custom)
+TC (WASM_I32_CONST, const, empty, i32)