Constant-riscv-a.h (2262B)
1 // Copyright 2022 the V8 project authors. All rights reserved. 2 // Use of this source code is governed by a BSD-style license that can be 3 // found in the LICENSE file. 4 #ifndef jit_riscv64_constant_Constant_riscv64_a_h_ 5 #define jit_riscv64_constant_Constant_riscv64_a_h_ 6 7 #include "jit/riscv64/constant/Base-constant-riscv.h" 8 namespace js { 9 namespace jit { 10 11 enum OpcodeRISCVA : uint32_t { 12 // RV32A Standard Extension 13 RO_LR_W = AMO | (0b010 << kFunct3Shift) | (0b00010 << kFunct5Shift), 14 RO_SC_W = AMO | (0b010 << kFunct3Shift) | (0b00011 << kFunct5Shift), 15 RO_AMOSWAP_W = AMO | (0b010 << kFunct3Shift) | (0b00001 << kFunct5Shift), 16 RO_AMOADD_W = AMO | (0b010 << kFunct3Shift) | (0b00000 << kFunct5Shift), 17 RO_AMOXOR_W = AMO | (0b010 << kFunct3Shift) | (0b00100 << kFunct5Shift), 18 RO_AMOAND_W = AMO | (0b010 << kFunct3Shift) | (0b01100 << kFunct5Shift), 19 RO_AMOOR_W = AMO | (0b010 << kFunct3Shift) | (0b01000 << kFunct5Shift), 20 RO_AMOMIN_W = AMO | (0b010 << kFunct3Shift) | (0b10000 << kFunct5Shift), 21 RO_AMOMAX_W = AMO | (0b010 << kFunct3Shift) | (0b10100 << kFunct5Shift), 22 RO_AMOMINU_W = AMO | (0b010 << kFunct3Shift) | (0b11000 << kFunct5Shift), 23 RO_AMOMAXU_W = AMO | (0b010 << kFunct3Shift) | (0b11100 << kFunct5Shift), 24 25 #ifdef JS_CODEGEN_RISCV64 26 // RV64A Standard Extension (in addition to RV32A) 27 RO_LR_D = AMO | (0b011 << kFunct3Shift) | (0b00010 << kFunct5Shift), 28 RO_SC_D = AMO | (0b011 << kFunct3Shift) | (0b00011 << kFunct5Shift), 29 RO_AMOSWAP_D = AMO | (0b011 << kFunct3Shift) | (0b00001 << kFunct5Shift), 30 RO_AMOADD_D = AMO | (0b011 << kFunct3Shift) | (0b00000 << kFunct5Shift), 31 RO_AMOXOR_D = AMO | (0b011 << kFunct3Shift) | (0b00100 << kFunct5Shift), 32 RO_AMOAND_D = AMO | (0b011 << kFunct3Shift) | (0b01100 << kFunct5Shift), 33 RO_AMOOR_D = AMO | (0b011 << kFunct3Shift) | (0b01000 << kFunct5Shift), 34 RO_AMOMIN_D = AMO | (0b011 << kFunct3Shift) | (0b10000 << kFunct5Shift), 35 RO_AMOMAX_D = AMO | (0b011 << kFunct3Shift) | (0b10100 << kFunct5Shift), 36 RO_AMOMINU_D = AMO | (0b011 << kFunct3Shift) | (0b11000 << kFunct5Shift), 37 RO_AMOMAXU_D = AMO | (0b011 << kFunct3Shift) | (0b11100 << kFunct5Shift), 38 #endif // JS_CODEGEN_RISCV64 39 }; 40 } // namespace jit 41 } // namespace js 42 43 #endif // jit_riscv64_constant_Constant_riscv64_a_h_