| OLD | NEW |
| 1 // Copyright 2015 the V8 project authors. All rights reserved. | 1 // Copyright 2015 the V8 project authors. All rights reserved. |
| 2 // Use of this source code is governed by a BSD-style license that can be | 2 // Use of this source code is governed by a BSD-style license that can be |
| 3 // found in the LICENSE file. | 3 // found in the LICENSE file. |
| 4 | 4 |
| 5 #ifndef V8_WASM_MACRO_GEN_H_ | 5 #ifndef V8_WASM_MACRO_GEN_H_ |
| 6 #define V8_WASM_MACRO_GEN_H_ | 6 #define V8_WASM_MACRO_GEN_H_ |
| 7 | 7 |
| 8 #include "src/wasm/wasm-opcodes.h" | 8 #include "src/wasm/wasm-opcodes.h" |
| 9 | 9 |
| 10 #define U32_LE(v) \ | 10 #define U32_LE(v) \ |
| (...skipping 337 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 348 ZERO_ALIGNMENT, ZERO_OFFSET | 348 ZERO_ALIGNMENT, ZERO_OFFSET |
| 349 #define WASM_LOAD_MEM_OFFSET(type, offset, index) \ | 349 #define WASM_LOAD_MEM_OFFSET(type, offset, index) \ |
| 350 index, static_cast<byte>( \ | 350 index, static_cast<byte>( \ |
| 351 v8::internal::wasm::WasmOpcodes::LoadStoreOpcodeOf(type, false)), \ | 351 v8::internal::wasm::WasmOpcodes::LoadStoreOpcodeOf(type, false)), \ |
| 352 ZERO_ALIGNMENT, static_cast<byte>(offset) | 352 ZERO_ALIGNMENT, static_cast<byte>(offset) |
| 353 #define WASM_STORE_MEM_OFFSET(type, offset, index, val) \ | 353 #define WASM_STORE_MEM_OFFSET(type, offset, index, val) \ |
| 354 index, val, \ | 354 index, val, \ |
| 355 static_cast<byte>( \ | 355 static_cast<byte>( \ |
| 356 v8::internal::wasm::WasmOpcodes::LoadStoreOpcodeOf(type, true)), \ | 356 v8::internal::wasm::WasmOpcodes::LoadStoreOpcodeOf(type, true)), \ |
| 357 ZERO_ALIGNMENT, static_cast<byte>(offset) | 357 ZERO_ALIGNMENT, static_cast<byte>(offset) |
| 358 #define WASM_LOAD_MEM_ALIGNMENT(type, index, alignment) \ |
| 359 index, static_cast<byte>( \ |
| 360 v8::internal::wasm::WasmOpcodes::LoadStoreOpcodeOf(type, false)), \ |
| 361 alignment, ZERO_OFFSET |
| 362 #define WASM_STORE_MEM_ALIGNMENT(type, index, alignment, val) \ |
| 363 index, val, \ |
| 364 static_cast<byte>( \ |
| 365 v8::internal::wasm::WasmOpcodes::LoadStoreOpcodeOf(type, true)), \ |
| 366 alignment, ZERO_OFFSET |
| 358 | 367 |
| 359 #define WASM_CALL_FUNCTION0(index) \ | 368 #define WASM_CALL_FUNCTION0(index) \ |
| 360 kExprCallFunction, 0, static_cast<byte>(index) | 369 kExprCallFunction, 0, static_cast<byte>(index) |
| 361 #define WASM_CALL_FUNCTION1(index, a) \ | 370 #define WASM_CALL_FUNCTION1(index, a) \ |
| 362 a, kExprCallFunction, 1, static_cast<byte>(index) | 371 a, kExprCallFunction, 1, static_cast<byte>(index) |
| 363 #define WASM_CALL_FUNCTION2(index, a, b) \ | 372 #define WASM_CALL_FUNCTION2(index, a, b) \ |
| 364 a, b, kExprCallFunction, 2, static_cast<byte>(index) | 373 a, b, kExprCallFunction, 2, static_cast<byte>(index) |
| 365 #define WASM_CALL_FUNCTION3(index, a, b, c) \ | 374 #define WASM_CALL_FUNCTION3(index, a, b, c) \ |
| 366 a, b, c, kExprCallFunction, 3, static_cast<byte>(index) | 375 a, b, c, kExprCallFunction, 3, static_cast<byte>(index) |
| 367 #define WASM_CALL_FUNCTION4(index, a, b, c, d) \ | 376 #define WASM_CALL_FUNCTION4(index, a, b, c, d) \ |
| (...skipping 206 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 574 #define SIG_ENTRY_x(r) kWasmFunctionTypeForm, 0, 1, r | 583 #define SIG_ENTRY_x(r) kWasmFunctionTypeForm, 0, 1, r |
| 575 #define SIG_ENTRY_x_x(r, a) kWasmFunctionTypeForm, 1, a, 1, r | 584 #define SIG_ENTRY_x_x(r, a) kWasmFunctionTypeForm, 1, a, 1, r |
| 576 #define SIG_ENTRY_x_xx(r, a, b) kWasmFunctionTypeForm, 2, a, b, 1, r | 585 #define SIG_ENTRY_x_xx(r, a, b) kWasmFunctionTypeForm, 2, a, b, 1, r |
| 577 #define SIG_ENTRY_x_xxx(r, a, b, c) kWasmFunctionTypeForm, 3, a, b, c, 1, r | 586 #define SIG_ENTRY_x_xxx(r, a, b, c) kWasmFunctionTypeForm, 3, a, b, c, 1, r |
| 578 #define SIZEOF_SIG_ENTRY_x 4 | 587 #define SIZEOF_SIG_ENTRY_x 4 |
| 579 #define SIZEOF_SIG_ENTRY_x_x 5 | 588 #define SIZEOF_SIG_ENTRY_x_x 5 |
| 580 #define SIZEOF_SIG_ENTRY_x_xx 6 | 589 #define SIZEOF_SIG_ENTRY_x_xx 6 |
| 581 #define SIZEOF_SIG_ENTRY_x_xxx 7 | 590 #define SIZEOF_SIG_ENTRY_x_xxx 7 |
| 582 | 591 |
| 583 #endif // V8_WASM_MACRO_GEN_H_ | 592 #endif // V8_WASM_MACRO_GEN_H_ |
| OLD | NEW |