5#ifndef V8_WASM_BASELINE_LOONG64_LIFTOFF_ASSEMBLER_LOONG64_INL_H_
6#define V8_WASM_BASELINE_LOONG64_LIFTOFF_ASSEMBLER_LOONG64_INL_H_
59 bool i64_offset =
false,
unsigned shift_amount = 0) {
65 if (shift_amount != 0) {
72 if (is_int31(offset_imm)) {
73 int32_t offset_imm32 =
static_cast<int32_t
>(offset_imm);
114 assm->
St_h(src.gp(), dst);
117 assm->
St_w(src.gp(), dst);
122 assm->
St_d(src.gp(), dst);
125 assm->
Fst_s(src.fp(), dst);
128 assm->
Fst_d(src.fp(), dst);
171 Store(assm, dst, src.reg(), src.kind());
177 if (src.is_const()) {
178 if (src.i32_const() == 0) {
181 assm->
li(temp,
static_cast<int64_t
>(src.i32_const()));
193 assm->
St_w(temp, dst);
196 assm->
St_d(temp, dst);
222 kLiftoffFrameSetupFunctionReg) ==
230 LoadConstant(LiftoffRegister(kLiftoffFrameSetupFunctionReg),
236 int stack_param_delta) {
247 int slot_count = num_callee_stack_params + 2;
248 for (
int i = slot_count - 1;
i >= 0; --
i) {
254 addi_d(
sp, fp, -stack_param_delta * 8);
261 int offset, SafepointTableBuilder* safepoint_table_builder,
262 bool feedback_vector_slot,
size_t stack_param_slots) {
268 if (feedback_vector_slot) {
274 constexpr int kAvailableSpace = 256;
275 MacroAssembler patching_assembler(
282 patching_assembler.Add_d(
sp,
sp, Operand(-frame_size));
302 CHECK(is_int26(imm32));
303 patching_assembler.b(imm32 >> 2);
310 if (frame_size <
v8_flags.stack_size * 1024) {
313 Add_d(stack_limit, stack_limit, Operand(frame_size));
317 if (
v8_flags.experimental_wasm_growable_stacks) {
320 regs_to_save.set(WasmHandleStackOverflowDescriptor::FrameBaseRegister());
325 Add_d(WasmHandleStackOverflowDescriptor::FrameBaseRegister(), fp,
331 Call(
static_cast<Address>(Builtin::kWasmStackOverflow),
334 safepoint_table_builder->DefineSafepoint(
this);
342 Add_d(
sp,
sp, Operand(-frame_size));
349 CHECK(is_int26(imm32));
377 const FreezeCacheState& frozen) {
387 WasmTrustedInstanceData::kTieringBudgetArrayOffset);
390 int budget_arr_offset =
kInt32Size * declared_func_index;
393 MemOperand budget_addr(budget_array, budget_arr_offset);
394 Ld_w(budget, budget_addr);
395 Sub_w(budget, budget, budget_used);
396 St_w(budget, budget_addr);
398 Branch(ool_label,
less, budget, Operand(zero_reg));
402 if (!
v8_flags.experimental_wasm_growable_stacks) {
407 Label done, call_runtime;
410 &call_runtime,
eq, old_fp.gp(),
412 mov(old_fp.gp(), fp);
453 switch (value.type().kind()) {
514 uint32_t* protected_load_pc,
518 false, shift_amount);
526 uint8_t protected_instruction_offset_bias =
528 if (protected_load_pc) {
529 *protected_load_pc =
pc_offset() - protected_instruction_offset_bias;
534 int32_t offset_imm) {
539 int32_t offset_imm) {
544#ifdef V8_ENABLE_SANDBOX
545void LiftoffAssembler::LoadCodeEntrypointViaCodePointer(Register dst,
547 int32_t offset_imm) {
549 MacroAssembler::LoadCodeEntrypointViaCodePointer(dst, src_op,
556 int32_t offset_imm, Register src,
557 LiftoffRegList pinned,
558 uint32_t* protected_store_pc,
559 SkipWriteBarrier skip_write_barrier) {
562 offset_reg.is_valid() ? Operand(offset_reg) : Operand(offset_imm);
566 if (offset_reg.is_valid() && offset_imm) {
567 Register effective_offset = temps.Acquire();
568 Add_d(effective_offset, offset_reg, Operand(offset_imm));
569 offset_op = Operand(effective_offset);
572 if (offset_op.is_reg()) {
573 StoreTaggedField(src, MemOperand(dst_addr, offset_op.rm()));
575 StoreTaggedField(src, MemOperand(dst_addr, offset_imm));
581 if (protected_store_pc) {
585 if (skip_write_barrier ||
v8_flags.disable_write_barriers)
return;
593 StubCallMode::kCallWasmRuntimeStub);
598 Register offset_reg, uintptr_t offset_imm,
599 LoadType type, uint32_t* protected_load_pc,
600 bool is_load_mem,
bool i64_offset,
603 unsigned shift_amount = needs_shift ? type.size_log_2() : 0;
605 i64_offset, shift_amount);
607 switch (type.value()) {
608 case LoadType::kI32Load8U:
609 case LoadType::kI64Load8U:
610 Ld_bu(dst.gp(), src_op);
612 case LoadType::kI32Load8S:
613 case LoadType::kI64Load8S:
614 Ld_b(dst.gp(), src_op);
616 case LoadType::kI32Load16U:
617 case LoadType::kI64Load16U:
620 case LoadType::kI32Load16S:
621 case LoadType::kI64Load16S:
624 case LoadType::kI64Load32U:
627 case LoadType::kI32Load:
628 case LoadType::kI64Load32S:
631 case LoadType::kI64Load:
634 case LoadType::kF32Load:
637 case LoadType::kF32LoadF16:
640 case LoadType::kF64Load:
643 case LoadType::kS128Load:
656 uintptr_t offset_imm, LiftoffRegister src,
657 StoreType type, LiftoffRegList pinned,
658 uint32_t* protected_store_pc,
bool is_store_mem,
664 switch (type.value()) {
665 case StoreType::kI32Store8:
666 case StoreType::kI64Store8:
667 St_b(src.gp(), dst_op);
669 case StoreType::kI32Store16:
670 case StoreType::kI64Store16:
673 case StoreType::kI32Store:
674 case StoreType::kI64Store32:
677 case StoreType::kI64Store:
680 case StoreType::kF32Store:
683 case StoreType::kF32StoreF16:
686 case StoreType::kF64Store:
689 case StoreType::kS128Store:
702 Register offset_reg, uintptr_t offset_imm,
703 LoadType type, LiftoffRegList pinned,
708 switch (type.value()) {
709 case LoadType::kI32Load8U:
710 case LoadType::kI64Load8U: {
711 Ld_bu(dst.gp(), src_op);
715 case LoadType::kI32Load16U:
716 case LoadType::kI64Load16U: {
717 Ld_hu(dst.gp(), src_op);
721 case LoadType::kI32Load: {
722 Ld_w(dst.gp(), src_op);
726 case LoadType::kI64Load32U: {
727 Ld_wu(dst.gp(), src_op);
731 case LoadType::kI64Load: {
732 Ld_d(dst.gp(), src_op);
742 uintptr_t offset_imm, LiftoffRegister src,
743 StoreType type, LiftoffRegList pinned,
748 switch (type.value()) {
749 case StoreType::kI64Store8:
750 case StoreType::kI32Store8: {
752 St_b(src.gp(), dst_op);
755 case StoreType::kI64Store16:
756 case StoreType::kI32Store16: {
758 St_h(src.gp(), dst_op);
761 case StoreType::kI64Store32:
762 case StoreType::kI32Store: {
764 St_w(src.gp(), dst_op);
767 case StoreType::kI64Store: {
769 St_d(src.gp(), dst_op);
777#define ASSEMBLE_ATOMIC_BINOP_EXT(load_linked, store_conditional, size, \
778 bin_instr, aligned) \
781 andi(temp3, temp0, aligned); \
782 Sub_d(temp0, temp0, Operand(temp3)); \
783 slli_w(temp3, temp3, 3); \
786 load_linked(temp1, MemOperand(temp0, 0)); \
787 ExtractBits(result.gp(), temp1, temp3, size, false); \
788 bin_instr(temp2, result.gp(), Operand(value.gp())); \
789 InsertBits(temp1, temp2, temp3, size); \
790 store_conditional(temp1, MemOperand(temp0, 0)); \
791 BranchShort(&binop, eq, temp1, Operand(zero_reg)); \
795#define ATOMIC_BINOP_CASE(name, inst32, inst64, opcode) \
796 void LiftoffAssembler::Atomic##name( \
797 Register dst_addr, Register offset_reg, uintptr_t offset_imm, \
798 LiftoffRegister value, LiftoffRegister result, StoreType type, \
800 LiftoffRegList pinned{dst_addr, value, result}; \
801 if (offset_reg != no_reg) pinned.set(offset_reg); \
802 Register temp0 = pinned.set(GetUnusedRegister(kGpReg, pinned)).gp(); \
803 Register temp1 = pinned.set(GetUnusedRegister(kGpReg, pinned)).gp(); \
804 Register temp2 = pinned.set(GetUnusedRegister(kGpReg, pinned)).gp(); \
805 Register temp3 = pinned.set(GetUnusedRegister(kGpReg, pinned)).gp(); \
806 MemOperand dst_op = \
807 liftoff::GetMemOp(this, dst_addr, offset_reg, offset_imm, i64_offset); \
808 Add_d(temp0, dst_op.base(), dst_op.offset()); \
809 switch (type.value()) { \
810 case StoreType::kI64Store8: \
811 ASSEMBLE_ATOMIC_BINOP_EXT(Ll_d, Sc_d, 8, inst64, 7); \
813 case StoreType::kI32Store8: \
814 ASSEMBLE_ATOMIC_BINOP_EXT(Ll_w, Sc_w, 8, inst32, 3); \
816 case StoreType::kI64Store16: \
817 ASSEMBLE_ATOMIC_BINOP_EXT(Ll_d, Sc_d, 16, inst64, 7); \
819 case StoreType::kI32Store16: \
820 ASSEMBLE_ATOMIC_BINOP_EXT(Ll_w, Sc_w, 16, inst32, 3); \
822 case StoreType::kI64Store32: \
823 ASSEMBLE_ATOMIC_BINOP_EXT(Ll_d, Sc_d, 32, inst64, 7); \
825 case StoreType::kI32Store: \
826 am##opcode##_db_w(result.gp(), value.gp(), temp0); \
828 case StoreType::kI64Store: \
829 am##opcode##_db_d(result.gp(), value.gp(), temp0); \
841#define ASSEMBLE_ATOMIC_BINOP(load_linked, store_conditional, bin_instr) \
846 load_linked(result.gp(), MemOperand(temp0, 0)); \
847 bin_instr(temp1, result.gp(), Operand(value.gp())); \
848 store_conditional(temp1, MemOperand(temp0, 0)); \
849 BranchShort(&binop, eq, temp1, Operand(zero_reg)); \
854 uintptr_t offset_imm, LiftoffRegister value,
855 LiftoffRegister
result, StoreType type,
858 if (offset_reg !=
no_reg) pinned.set(offset_reg);
865 Add_d(temp0, dst_op.base(), dst_op.offset());
866 switch (type.value()) {
867 case StoreType::kI64Store8:
870 case StoreType::kI32Store8:
873 case StoreType::kI64Store16:
876 case StoreType::kI32Store16:
879 case StoreType::kI64Store32:
882 case StoreType::kI32Store:
885 case StoreType::kI64Store:
892#undef ASSEMBLE_ATOMIC_BINOP
893#undef ASSEMBLE_ATOMIC_BINOP_EXT
894#undef ATOMIC_BINOP_CASE
896#define ASSEMBLE_ATOMIC_EXCHANGE_INTEGER_EXT(load_linked, store_conditional, \
900 andi(temp1, temp0, aligned); \
901 Sub_d(temp0, temp0, Operand(temp1)); \
902 slli_w(temp1, temp1, 3); \
905 load_linked(temp2, MemOperand(temp0, 0)); \
906 ExtractBits(result.gp(), temp2, temp1, size, false); \
907 InsertBits(temp2, value.gp(), temp1, size); \
908 store_conditional(temp2, MemOperand(temp0, 0)); \
909 BranchShort(&exchange, eq, temp2, Operand(zero_reg)); \
914 uintptr_t offset_imm,
915 LiftoffRegister value,
916 LiftoffRegister
result, StoreType type,
919 if (offset_reg !=
no_reg) pinned.set(offset_reg);
925 Add_d(temp0, dst_op.base(), dst_op.offset());
926 switch (type.value()) {
927 case StoreType::kI64Store8:
930 case StoreType::kI32Store8:
933 case StoreType::kI64Store16:
936 case StoreType::kI32Store16:
939 case StoreType::kI64Store32:
942 case StoreType::kI32Store:
945 case StoreType::kI64Store:
952#undef ASSEMBLE_ATOMIC_EXCHANGE_INTEGER_EXT
954#define ASSEMBLE_ATOMIC_COMPARE_EXCHANGE_INTEGER(load_linked, \
957 Label compareExchange; \
960 bind(&compareExchange); \
961 load_linked(result.gp(), MemOperand(temp0, 0)); \
962 BranchShort(&exit, ne, expected.gp(), Operand(result.gp())); \
963 mov(temp2, new_value.gp()); \
964 store_conditional(temp2, MemOperand(temp0, 0)); \
965 BranchShort(&compareExchange, eq, temp2, Operand(zero_reg)); \
970#define ASSEMBLE_ATOMIC_COMPARE_EXCHANGE_INTEGER_EXT( \
971 load_linked, store_conditional, size, aligned) \
973 Label compareExchange; \
975 andi(temp1, temp0, aligned); \
976 Sub_d(temp0, temp0, Operand(temp1)); \
977 slli_w(temp1, temp1, 3); \
979 bind(&compareExchange); \
980 load_linked(temp2, MemOperand(temp0, 0)); \
981 ExtractBits(result.gp(), temp2, temp1, size, false); \
982 ExtractBits(temp2, expected.gp(), zero_reg, size, false); \
983 BranchShort(&exit, ne, temp2, Operand(result.gp())); \
984 InsertBits(temp2, new_value.gp(), temp1, size); \
985 store_conditional(temp2, MemOperand(temp0, 0)); \
986 BranchShort(&compareExchange, eq, temp2, Operand(zero_reg)); \
992 Register dst_addr, Register offset_reg, uintptr_t offset_imm,
993 LiftoffRegister expected, LiftoffRegister new_value, LiftoffRegister
result,
994 StoreType type,
bool i64_offset) {
995 LiftoffRegList pinned{dst_addr, expected, new_value,
result};
996 if (offset_reg !=
no_reg) pinned.set(offset_reg);
1002 Add_d(temp0, dst_op.base(), dst_op.offset());
1003 switch (type.value()) {
1004 case StoreType::kI64Store8:
1007 case StoreType::kI32Store8:
1010 case StoreType::kI64Store16:
1013 case StoreType::kI32Store16:
1016 case StoreType::kI64Store32:
1019 case StoreType::kI32Store:
1022 case StoreType::kI64Store:
1029#undef ASSEMBLE_ATOMIC_COMPARE_EXCHANGE_INTEGER
1030#undef ASSEMBLE_ATOMIC_COMPARE_EXCHANGE_INTEGER_EXT
1035 uint32_t caller_slot_idx,
1042 uint32_t caller_slot_idx,
1044 Register frame_pointer) {
1058 Register scratch = temps.Acquire();
1124 switch (value.type().kind()) {
1127 Register scratch = temps.Acquire();
1136 Register scratch = temps.Acquire();
1196 Add_d(a0, fp, Operand(-
start - size));
1197 Add_d(a1, fp, Operand(-
start));
1211 Sub_d(dst, fp, Operand(
offset));
1223 LiftoffRegister src) {
1230 Register scratch = temps.Acquire();
1238 Add_d(scratch, scratch, Operand(1));
1245 MacroAssembler::Mul_w(dst, lhs, rhs);
1249 Label* trap_div_by_zero,
1250 Label* trap_div_unrepresentable) {
1262 MacroAssembler::Div_w(dst, lhs, rhs);
1266 Label* trap_div_by_zero) {
1268 MacroAssembler::Div_wu(dst, lhs, rhs);
1272 Label* trap_div_by_zero) {
1274 MacroAssembler::Mod_w(dst, lhs, rhs);
1278 Label* trap_div_by_zero) {
1280 MacroAssembler::Mod_wu(dst, lhs, rhs);
1283#define I32_BINOP(name, instruction) \
1284 void LiftoffAssembler::emit_i32_##name(Register dst, Register lhs, \
1286 instruction(dst, lhs, rhs); \
1299#define I32_BINOP_I(name, instruction) \
1300 void LiftoffAssembler::emit_i32_##name##i(Register dst, Register lhs, \
1302 instruction(dst, lhs, Operand(imm)); \
1328#define I32_SHIFTOP(name, instruction) \
1329 void LiftoffAssembler::emit_i32_##name(Register dst, Register src, \
1330 Register amount) { \
1331 instruction(dst, src, amount); \
1333#define I32_SHIFTOP_I(name, instruction, instruction1) \
1334 I32_SHIFTOP(name, instruction) \
1335 void LiftoffAssembler::emit_i32_##name##i(Register dst, Register src, \
1337 instruction1(dst, src, amount & 0x1f); \
1349 MacroAssembler::Add_d(dst.gp(), lhs.gp(), Operand(imm));
1353 LiftoffRegister rhs) {
1354 MacroAssembler::Mul_d(dst.gp(), lhs.gp(), rhs.gp());
1364 Register scratch = temps.Acquire();
1366 MacroAssembler::Mul_d(dst.gp(), lhs.gp(), scratch);
1370 LiftoffRegister rhs,
1371 Label* trap_div_by_zero,
1372 Label* trap_div_unrepresentable) {
1384 MacroAssembler::Div_d(dst.gp(), lhs.gp(), rhs.gp());
1389 LiftoffRegister rhs,
1390 Label* trap_div_by_zero) {
1392 MacroAssembler::Div_du(dst.gp(), lhs.gp(), rhs.gp());
1397 LiftoffRegister rhs,
1398 Label* trap_div_by_zero) {
1400 MacroAssembler::Mod_d(dst.gp(), lhs.gp(), rhs.gp());
1405 LiftoffRegister rhs,
1406 Label* trap_div_by_zero) {
1408 MacroAssembler::Mod_du(dst.gp(), lhs.gp(), rhs.gp());
1412#define I64_BINOP(name, instruction) \
1413 void LiftoffAssembler::emit_i64_##name( \
1414 LiftoffRegister dst, LiftoffRegister lhs, LiftoffRegister rhs) { \
1415 instruction(dst.gp(), lhs.gp(), rhs.gp()); \
1428#define I64_BINOP_I(name, instruction) \
1429 void LiftoffAssembler::emit_i64_##name##i( \
1430 LiftoffRegister dst, LiftoffRegister lhs, int32_t imm) { \
1431 instruction(dst.gp(), lhs.gp(), Operand(imm)); \
1442#define I64_SHIFTOP(name, instruction) \
1443 void LiftoffAssembler::emit_i64_##name( \
1444 LiftoffRegister dst, LiftoffRegister src, Register amount) { \
1445 instruction(dst.gp(), src.gp(), amount); \
1447#define I64_SHIFTOP_I(name, instruction, instructioni) \
1448 I64_SHIFTOP(name, instruction) \
1449 void LiftoffAssembler::emit_i64_##name##i(LiftoffRegister dst, \
1450 LiftoffRegister src, int amount) { \
1451 instructioni(dst.gp(), src.gp(), amount & 63); \
1533#define FP_BINOP(name, instruction) \
1534 void LiftoffAssembler::emit_##name(DoubleRegister dst, DoubleRegister lhs, \
1535 DoubleRegister rhs) { \
1536 instruction(dst, lhs, rhs); \
1538#define FP_UNOP(name, instruction) \
1539 void LiftoffAssembler::emit_##name(DoubleRegister dst, DoubleRegister src) { \
1540 instruction(dst, src); \
1542#define FP_UNOP_RETURN_TRUE(name, instruction) \
1543 bool LiftoffAssembler::emit_##name(DoubleRegister dst, DoubleRegister src) { \
1544 instruction(dst, src); \
1571#undef FP_UNOP_RETURN_TRUE
1574 LiftoffRegister dst,
1575 LiftoffRegister src, Label*
trap) {
1577 case kExprI32ConvertI64:
1580 case kExprI32SConvertF32: {
1600 case kExprI32UConvertF32: {
1618 case kExprI32SConvertF64: {
1632 case kExprI32UConvertF64: {
1645 case kExprI32ReinterpretF32:
1648 case kExprI64SConvertI32:
1649 slli_w(dst.gp(), src.gp(), 0);
1651 case kExprI64UConvertI32:
1654 case kExprI64SConvertF32: {
1674 case kExprI64UConvertF32: {
1683 case kExprI64SConvertF64: {
1703 case kExprI64UConvertF64: {
1712 case kExprI64ReinterpretF64:
1715 case kExprF32SConvertI32: {
1721 case kExprF32UConvertI32:
1724 case kExprF32ConvertF64:
1727 case kExprF32ReinterpretI32:
1730 case kExprF64SConvertI32: {
1736 case kExprF64UConvertI32:
1739 case kExprF64ConvertF32:
1742 case kExprF64ReinterpretI64:
1745 case kExprI32SConvertSatF32:
1749 case kExprI32UConvertSatF32: {
1750 Label isnan_or_lessthan_or_equal_zero;
1751 mov(dst.gp(), zero_reg);
1756 bind(&isnan_or_lessthan_or_equal_zero);
1759 case kExprI32SConvertSatF64:
1763 case kExprI32UConvertSatF64: {
1764 Label isnan_or_lessthan_or_equal_zero;
1765 mov(dst.gp(), zero_reg);
1770 bind(&isnan_or_lessthan_or_equal_zero);
1773 case kExprI64SConvertSatF32:
1777 case kExprI64UConvertSatF32: {
1778 Label isnan_or_lessthan_or_equal_zero;
1779 mov(dst.gp(), zero_reg);
1784 bind(&isnan_or_lessthan_or_equal_zero);
1787 case kExprI64SConvertSatF64:
1791 case kExprI64UConvertSatF64: {
1792 Label isnan_or_lessthan_or_equal_zero;
1793 mov(dst.gp(), zero_reg);
1798 bind(&isnan_or_lessthan_or_equal_zero);
1815 LiftoffRegister src) {
1820 LiftoffRegister src) {
1825 LiftoffRegister src) {
1826 slli_w(dst.gp(), src.gp(), 0);
1840 const FreezeCacheState& frozen) {
1844 Register scratch0 = temps.Acquire();
1845 slli_w(scratch0, lhs, 0);
1862 Register lhs, int32_t imm,
1863 const FreezeCacheState& frozen) {
1868 Register lhs, int32_t imm,
1869 const FreezeCacheState& frozen) {
1879 Register lhs, Register rhs) {
1881 Register scratch0 = temps.Acquire();
1884 slli_w(scratch0, lhs, 0);
1885 slli_w(scratch1, rhs, 0);
1887 CompareWord(cond, dst, scratch0, Operand(scratch1));
1891 sltui(dst, src.gp(), 1);
1895 LiftoffRegister lhs,
1896 LiftoffRegister rhs) {
1897 CompareWord(cond, dst, lhs.gp(), Operand(rhs.gp()));
1935 Label not_nan, cont;
1964 Label not_nan, cont;
1991 LiftoffRegister true_value,
1992 LiftoffRegister false_value,
1999 const FreezeCacheState& frozen) {
2001 Register scratch = temps.Acquire();
2008 Register offset_reg, uintptr_t offset_imm,
2011 uint32_t* protected_load_pc,
2013 bailout(
kSimd,
"load extend and load splat unimplemented");
2017 Register addr, Register offset_reg,
2018 uintptr_t offset_imm, LoadType type,
2019 uint8_t laneidx, uint32_t* protected_load_pc,
2025 uintptr_t offset_imm, LiftoffRegister src,
2026 StoreType type, uint8_t lane,
2027 uint32_t* protected_store_pc,
2033 LiftoffRegister lhs,
2034 LiftoffRegister rhs,
2035 const uint8_t shuffle[16],
2041 LiftoffRegister lhs,
2042 LiftoffRegister rhs) {
2047 LiftoffRegister lhs,
2048 LiftoffRegister rhs) {
2053 LiftoffRegister src) {
2058 LiftoffRegister src) {
2063 LiftoffRegister dst, LiftoffRegister src) {
2068 LiftoffRegister dst, LiftoffRegister src) {
2073 LiftoffRegister src1,
2074 LiftoffRegister src2,
2075 LiftoffRegister
mask,
2081 LiftoffRegister src) {
2086 LiftoffRegister src) {
2091 LiftoffRegister src) {
2096 LiftoffRegister src) {
2101 LiftoffRegister src) {
2106 LiftoffRegister src) {
2110#define SIMD_BINOP(name1, name2) \
2111 void LiftoffAssembler::emit_##name1##_extmul_low_##name2( \
2112 LiftoffRegister dst, LiftoffRegister src1, LiftoffRegister src2) { \
2113 bailout(kSimd, "emit_" #name1 "_extmul_low_" #name2); \
2115 void LiftoffAssembler::emit_##name1##_extmul_high_##name2( \
2116 LiftoffRegister dst, LiftoffRegister src1, LiftoffRegister src2) { \
2117 bailout(kSimd, "emit_" #name1 "_extmul_high_" #name2); \
2131#define SIMD_BINOP(name1, name2) \
2132 void LiftoffAssembler::emit_##name1##_extadd_pairwise_##name2( \
2133 LiftoffRegister dst, LiftoffRegister src) { \
2134 bailout(kSimd, "emit_" #name1 "_extadd_pairwise_" #name2); \
2144 LiftoffRegister src1,
2145 LiftoffRegister src2) {
2150 LiftoffRegister src1,
2151 LiftoffRegister src2) {
2156 LiftoffRegister lhs,
2157 LiftoffRegister rhs) {
2162 LiftoffRegister lhs,
2163 LiftoffRegister rhs,
2164 LiftoffRegister acc) {
2169 LiftoffRegister rhs) {
2174 LiftoffRegister rhs) {
2179 LiftoffRegister rhs) {
2184 LiftoffRegister rhs) {
2189 LiftoffRegister rhs) {
2194 LiftoffRegister rhs) {
2199 LiftoffRegister rhs) {
2204 LiftoffRegister rhs) {
2209 LiftoffRegister rhs) {
2214 LiftoffRegister rhs) {
2219 LiftoffRegister rhs) {
2224 LiftoffRegister rhs) {
2229 LiftoffRegister rhs) {
2234 LiftoffRegister rhs) {
2239 LiftoffRegister rhs) {
2244 LiftoffRegister rhs) {
2249 LiftoffRegister rhs) {
2254 LiftoffRegister rhs) {
2259 LiftoffRegister rhs) {
2264 LiftoffRegister rhs) {
2269 LiftoffRegister rhs) {
2274 LiftoffRegister rhs) {
2279 LiftoffRegister rhs) {
2284 LiftoffRegister rhs) {
2289 LiftoffRegister src) {
2294 LiftoffRegister rhs) {
2299 LiftoffRegister rhs) {
2304 LiftoffRegister rhs) {
2309 LiftoffRegister rhs) {
2314 const uint8_t imms[16]) {
2323 LiftoffRegister rhs) {
2328 LiftoffRegister rhs) {
2333 LiftoffRegister rhs) {
2338 LiftoffRegister lhs,
2339 LiftoffRegister rhs) {
2344 LiftoffRegister src1,
2345 LiftoffRegister src2,
2346 LiftoffRegister
mask) {
2351 LiftoffRegister src) {
2356 LiftoffRegister src) {
2361 LiftoffRegister src) {
2366 LiftoffRegister src) {
2371 LiftoffRegister rhs) {
2381 LiftoffRegister lhs,
2382 LiftoffRegister rhs) {
2387 LiftoffRegister lhs, int32_t rhs) {
2392 LiftoffRegister lhs,
2393 LiftoffRegister rhs) {
2398 LiftoffRegister lhs, int32_t rhs) {
2403 LiftoffRegister rhs) {
2408 LiftoffRegister lhs,
2409 LiftoffRegister rhs) {
2414 LiftoffRegister lhs,
2415 LiftoffRegister rhs) {
2420 LiftoffRegister rhs) {
2425 LiftoffRegister lhs,
2426 LiftoffRegister rhs) {
2431 LiftoffRegister lhs,
2432 LiftoffRegister rhs) {
2437 LiftoffRegister lhs,
2438 LiftoffRegister rhs) {
2443 LiftoffRegister lhs,
2444 LiftoffRegister rhs) {
2449 LiftoffRegister lhs,
2450 LiftoffRegister rhs) {
2455 LiftoffRegister lhs,
2456 LiftoffRegister rhs) {
2461 LiftoffRegister src) {
2466 LiftoffRegister src) {
2471 LiftoffRegister src) {
2476 LiftoffRegister src) {
2481 LiftoffRegister rhs) {
2491 LiftoffRegister lhs,
2492 LiftoffRegister rhs) {
2497 LiftoffRegister lhs, int32_t rhs) {
2502 LiftoffRegister lhs,
2503 LiftoffRegister rhs) {
2508 LiftoffRegister lhs, int32_t rhs) {
2513 LiftoffRegister rhs) {
2518 LiftoffRegister lhs,
2519 LiftoffRegister rhs) {
2524 LiftoffRegister lhs,
2525 LiftoffRegister rhs) {
2530 LiftoffRegister rhs) {
2535 LiftoffRegister lhs,
2536 LiftoffRegister rhs) {
2541 LiftoffRegister lhs,
2542 LiftoffRegister rhs) {
2547 LiftoffRegister rhs) {
2552 LiftoffRegister lhs,
2553 LiftoffRegister rhs) {
2558 LiftoffRegister lhs,
2559 LiftoffRegister rhs) {
2564 LiftoffRegister lhs,
2565 LiftoffRegister rhs) {
2570 LiftoffRegister lhs,
2571 LiftoffRegister rhs) {
2576 LiftoffRegister src) {
2581 LiftoffRegister src) {
2586 LiftoffRegister src) {
2591 LiftoffRegister rhs) {
2601 LiftoffRegister lhs,
2602 LiftoffRegister rhs) {
2607 LiftoffRegister lhs, int32_t rhs) {
2612 LiftoffRegister lhs,
2613 LiftoffRegister rhs) {
2618 LiftoffRegister lhs, int32_t rhs) {
2623 LiftoffRegister rhs) {
2628 LiftoffRegister rhs) {
2633 LiftoffRegister rhs) {
2638 LiftoffRegister lhs,
2639 LiftoffRegister rhs) {
2644 LiftoffRegister lhs,
2645 LiftoffRegister rhs) {
2650 LiftoffRegister lhs,
2651 LiftoffRegister rhs) {
2656 LiftoffRegister lhs,
2657 LiftoffRegister rhs) {
2662 LiftoffRegister lhs,
2663 LiftoffRegister rhs) {
2668 LiftoffRegister src) {
2673 LiftoffRegister src) {
2678 LiftoffRegister src) {
2683 LiftoffRegister rhs) {
2693 LiftoffRegister lhs,
2694 LiftoffRegister rhs) {
2699 LiftoffRegister lhs, int32_t rhs) {
2704 LiftoffRegister lhs,
2705 LiftoffRegister rhs) {
2710 LiftoffRegister lhs, int32_t rhs) {
2715 LiftoffRegister rhs) {
2720 LiftoffRegister rhs) {
2725 LiftoffRegister rhs) {
2730 LiftoffRegister rhs) {
2735 LiftoffRegister rhs) {
2740 LiftoffRegister src) {
2745 LiftoffRegister src) {
2750 LiftoffRegister src) {
2755 LiftoffRegister src) {
2761 LiftoffRegister src) {
2767 LiftoffRegister src) {
2773 LiftoffRegister src) {
2779 LiftoffRegister rhs) {
2784 LiftoffRegister rhs) {
2789 LiftoffRegister rhs) {
2794 LiftoffRegister rhs) {
2799 LiftoffRegister rhs) {
2804 LiftoffRegister rhs) {
2809 LiftoffRegister lhs,
2810 LiftoffRegister rhs) {
2815 LiftoffRegister lhs,
2816 LiftoffRegister rhs) {
2821 LiftoffRegister rhs) {
2826 LiftoffRegister rhs) {
2831 LiftoffRegister src) {
2836 LiftoffRegister src) {
2841 LiftoffRegister src) {
2846 LiftoffRegister src) {
2852 LiftoffRegister src) {
2858 LiftoffRegister src) {
2864 LiftoffRegister src) {
2870 LiftoffRegister rhs) {
2875 LiftoffRegister rhs) {
2880 LiftoffRegister rhs) {
2885 LiftoffRegister rhs) {
2890 LiftoffRegister rhs) {
2895 LiftoffRegister rhs) {
2900 LiftoffRegister rhs) {
2905 LiftoffRegister rhs) {
2910 LiftoffRegister lhs,
2911 LiftoffRegister rhs) {
2916 LiftoffRegister lhs,
2917 LiftoffRegister rhs) {
2922 LiftoffRegister src) {
2927 LiftoffRegister src) {
2932 LiftoffRegister src) {
2937 LiftoffRegister src) {
2942 LiftoffRegister src) {
2947 LiftoffRegister src) {
2952 LiftoffRegister src) {
2957 LiftoffRegister src) {
2962 LiftoffRegister src) {
2967 LiftoffRegister src) {
2972 LiftoffRegister lhs,
2973 LiftoffRegister rhs) {
2978 LiftoffRegister lhs,
2979 LiftoffRegister rhs) {
2984 LiftoffRegister lhs,
2985 LiftoffRegister rhs) {
2990 LiftoffRegister lhs,
2991 LiftoffRegister rhs) {
2996 LiftoffRegister src) {
3001 LiftoffRegister src) {
3006 LiftoffRegister src) {
3011 LiftoffRegister src) {
3016 LiftoffRegister src) {
3021 LiftoffRegister src) {
3026 LiftoffRegister src) {
3031 LiftoffRegister src) {
3036 LiftoffRegister src) {
3041 LiftoffRegister src) {
3046 LiftoffRegister src) {
3051 LiftoffRegister src) {
3056 LiftoffRegister lhs,
3057 LiftoffRegister rhs) {
3062 LiftoffRegister lhs,
3063 LiftoffRegister rhs) {
3068 LiftoffRegister src) {
3073 LiftoffRegister src) {
3078 LiftoffRegister src) {
3083 LiftoffRegister lhs,
3084 uint8_t imm_lane_idx) {
3089 LiftoffRegister lhs,
3090 uint8_t imm_lane_idx) {
3095 LiftoffRegister lhs,
3096 uint8_t imm_lane_idx) {
3101 LiftoffRegister lhs,
3102 uint8_t imm_lane_idx) {
3107 LiftoffRegister lhs,
3108 uint8_t imm_lane_idx) {
3113 LiftoffRegister lhs,
3114 uint8_t imm_lane_idx) {
3119 LiftoffRegister lhs,
3120 uint8_t imm_lane_idx) {
3125 LiftoffRegister lhs,
3126 uint8_t imm_lane_idx) {
3131 LiftoffRegister src1,
3132 LiftoffRegister src2,
3133 uint8_t imm_lane_idx) {
3138 LiftoffRegister src1,
3139 LiftoffRegister src2,
3140 uint8_t imm_lane_idx) {
3145 LiftoffRegister src1,
3146 LiftoffRegister src2,
3147 uint8_t imm_lane_idx) {
3152 LiftoffRegister src1,
3153 LiftoffRegister src2,
3154 uint8_t imm_lane_idx) {
3159 LiftoffRegister src1,
3160 LiftoffRegister src2,
3161 uint8_t imm_lane_idx) {
3166 LiftoffRegister src1,
3167 LiftoffRegister src2,
3168 uint8_t imm_lane_idx) {
3173 LiftoffRegister src1,
3174 LiftoffRegister src2,
3175 LiftoffRegister src3) {
3180 LiftoffRegister src1,
3181 LiftoffRegister src2,
3182 LiftoffRegister src3) {
3187 LiftoffRegister src1,
3188 LiftoffRegister src2,
3189 LiftoffRegister src3) {
3194 LiftoffRegister src1,
3195 LiftoffRegister src2,
3196 LiftoffRegister src3) {
3201 LiftoffRegister src) {
3206 LiftoffRegister lhs,
3207 uint8_t imm_lane_idx) {
3212 LiftoffRegister src1,
3213 LiftoffRegister src2,
3214 uint8_t imm_lane_idx) {
3219 LiftoffRegister src) {
3224 LiftoffRegister src) {
3229 LiftoffRegister src) {
3234 LiftoffRegister src) {
3239 LiftoffRegister src) {
3244 LiftoffRegister src) {
3249 LiftoffRegister src) {
3254 LiftoffRegister rhs) {
3259 LiftoffRegister rhs) {
3264 LiftoffRegister rhs) {
3269 LiftoffRegister rhs) {
3274 LiftoffRegister rhs) {
3279 LiftoffRegister rhs) {
3284 LiftoffRegister rhs) {
3289 LiftoffRegister rhs) {
3294 LiftoffRegister rhs) {
3299 LiftoffRegister rhs) {
3304 LiftoffRegister rhs) {
3309 LiftoffRegister rhs) {
3314 LiftoffRegister src) {
3319 LiftoffRegister src) {
3324 LiftoffRegister src) {
3329 LiftoffRegister src) {
3334 LiftoffRegister src) {
3339 LiftoffRegister src) {
3344 LiftoffRegister src) {
3349 LiftoffRegister src1,
3350 LiftoffRegister src2,
3351 LiftoffRegister src3) {
3356 LiftoffRegister src1,
3357 LiftoffRegister src2,
3358 LiftoffRegister src3) {
3367 Branch(ool_code,
ule,
sp, Operand(limit_address));
3380 while (!gp_regs.is_empty()) {
3381 LiftoffRegister
reg = gp_regs.GetFirstRegSet();
3391 unsigned slot_size = 8;
3394 while (!fp_regs.is_empty()) {
3395 LiftoffRegister
reg = fp_regs.GetFirstRegSet();
3406 unsigned fp_offset = 0;
3407 while (!fp_regs.is_empty()) {
3408 LiftoffRegister
reg = fp_regs.GetFirstRegSet();
3415 unsigned gp_offset = 0;
3416 while (!gp_regs.is_empty()) {
3417 LiftoffRegister
reg = gp_regs.GetLastRegSet();
3426 SafepointTableBuilder::Safepoint& safepoint, LiftoffRegList all_spills,
3427 LiftoffRegList ref_spills,
int spill_offset) {
3431 while (!gp_spills.is_empty()) {
3432 LiftoffRegister
reg = gp_spills.GetFirstRegSet();
3433 if (ref_spills.has(
reg)) {
3434 safepoint.DefineTaggedStackSlot(spill_offset);
3436 gp_spills.clear(
reg);
3447 Drop(
static_cast<int>(num_stack_slots));
3452 const std::initializer_list<VarState>
args,
const LiftoffRegister* rets,
3454 ExternalReference ext_ref) {
3466 constexpr Register kFirstArgReg = a0;
3467 mov(kFirstArgReg,
sp);
3470 constexpr int kNumCCallArgs = 1;
3475 const LiftoffRegister* next_result_reg = rets;
3476 if (return_kind != kVoid) {
3477 constexpr Register kReturnReg = a0;
3483 if (return_kind ==
kI32) {
3484 slli_w(next_result_reg->gp(), kReturnReg, 0);
3485 }
else if (kReturnReg != next_result_reg->gp()) {
3486 Move(*next_result_reg, LiftoffRegister(kReturnReg), return_kind);
3489 if (kReturnReg != next_result_reg->gp()) {
3490 Move(*next_result_reg, LiftoffRegister(kReturnReg), return_kind);
3497 if (out_argument_kind != kVoid) {
3505 ExternalReference ext_ref) {
3507 const int num_args =
static_cast<int>(args_list.size());
3517 ParallelMove parallel_move{
this};
3518 for (
int reg_arg = 0; reg_arg < num_args; ++reg_arg) {
3519 parallel_move.LoadIntoRegister(LiftoffRegister{
kCArgRegs[reg_arg]},
3522 parallel_move.Execute();
3537 compiler::CallDescriptor* call_descriptor,
3541 DCHECK(target.is_valid());
3542 CallWasmCodePointer(target, call_descriptor->signature_hash());
3546 compiler::CallDescriptor* call_descriptor, Register target) {
3547 DCHECK(target.is_valid());
3548 CallWasmCodePointer(target, call_descriptor->signature_hash(),
3572 Register scratch = temps.Acquire();
3587 LiftoffRegister src,
3589 LiftoffRegister tmp_s128,
3601 int last_stack_slot = param_slots;
3602 for (
auto& slot :
slots_) {
3603 const int stack_slot = slot.dst_slot_;
3606 last_stack_slot = stack_slot;
3608 switch (src.loc()) {
3610 if (src.kind() !=
kS128) {
V8_INLINE void RecordComment(const char *comment, const SourceLocation &loc=SourceLocation::Current())
void fcvt_d_s(FPURegister fd, FPURegister fj)
void fcvt_s_d(FPURegister fd, FPURegister fj)
void rotri_d(Register rd, Register rj, int32_t ui6)
void rotri_w(Register rd, Register rj, int32_t ui5)
void masknez(Register rd, Register rj, Register rk)
void ftintrz_w_d(FPURegister fd, FPURegister fj)
void slli_w(Register rd, Register rj, int32_t ui5)
void bstrpick_w(Register rd, Register rj, int32_t msbw, int32_t lsbw)
void ext_w_b(Register rd, Register rj)
void movfr2gr_s(Register rd, FPURegister fj)
void b(int branch_offset, Condition cond=al, RelocInfo::Mode rmode=RelocInfo::NO_INFO)
void movfr2gr_d(Register rd, FPURegister fj)
void alsl_d(Register rd, Register rj, Register rk, int32_t sa2)
friend class BlockTrampolinePoolScope
void movgr2fr_d(FPURegister fd, Register rj)
void fcopysign_s(FPURegister fd, FPURegister fj, FPURegister fk)
Simd128Register Simd128Register ra
void movgr2fr_w(FPURegister fd, Register rj)
void ftintrz_l_s(FPURegister fd, FPURegister fj)
void bstrpick_d(Register rd, Register rj, int32_t msbd, int32_t lsbd)
void xori(Register rd, Register rj, int32_t ui12)
friend class UseScratchRegisterScope
void ffint_s_w(FPURegister fd, FPURegister fj)
void ftintrz_w_s(FPURegister fd, FPURegister fj)
void fcopysign_d(FPURegister fd, FPURegister fj, FPURegister fk)
void amswap_db_d(Register rd, Register rk, Register rj)
void amswap_db_w(Register rd, Register rk, Register rj)
void ffint_s_l(FPURegister fd, FPURegister fj)
void add_d(Register rd, Register rj, Register rk)
void addi_d(Register rd, Register rj, int32_t si12)
void sltui(Register rd, Register rj, int32_t si12)
void ffint_d_l(FPURegister fd, FPURegister fj)
void ffint_d_w(FPURegister fd, FPURegister fj)
void ftintrz_l_d(FPURegister fd, FPURegister fj)
void addi_w(Register rd, Register rj, int32_t si12)
void ext_w_h(Register rd, Register rj)
void stop(Condition cond=al, int32_t code=kDefaultStopCode)
static constexpr int kFixedFrameSizeAboveFp
static V8_EXPORT_PRIVATE ExternalReference isolate_address()
void Ld_b(Register rd, const MemOperand &rj)
void LoadStackLimit(Register destination, StackLimitKind kind)
void Call(Register target, Condition cond=al)
void St_w(Register rd, const MemOperand &rj)
void Drop(int count, Condition cond=al)
void Fst_d(FPURegister fj, const MemOperand &dst)
void mov(Register rd, Register rj)
void SmiUntag(Register reg, SBit s=LeaveCC)
void Neg_s(FPURegister fd, FPURegister fj)
void Float64Min(FPURegister dst, FPURegister src1, FPURegister src2, Label *out_of_line)
void CompareIsNanF64(FPURegister cmp1, FPURegister cmp2, CFRegister cd=FCC0)
void Sc_d(Register rd, const MemOperand &rj)
void CompareF32(FPURegister cmp1, FPURegister cmp2, FPUCondition cc, CFRegister cd=FCC0)
void BranchFalseF(Label *target, CFRegister cc=FCC0)
void LoadZeroIfNotFPUCondition(Register dest, CFRegister=FCC0)
void Move(Register dst, Tagged< Smi > smi)
void Clz_d(Register rd, Register rj)
void Float64Max(FPURegister dst, FPURegister src1, FPURegister src2, Label *out_of_line)
void LoadTrustedPointerField(Register destination, MemOperand field_operand, IndirectPointerTag tag)
void Movz(Register rd, Register rj, Register rk)
void JumpIfSmi(Register value, Label *smi_label)
void Ld_d(Register rd, const MemOperand &rj)
void Ftintrz_ul_s(FPURegister fd, FPURegister fj, FPURegister scratch, Register result=no_reg)
void BranchShort(Label *label, Condition cond, Register r1, const Operand &r2, bool need_link=false)
void AssertUnreachable(AbortReason reason) NOOP_UNLESS_DEBUG_CODE
void Ll_d(Register rd, const MemOperand &rj)
void Ld_bu(Register rd, const MemOperand &rj)
void BranchFalseShortF(Label *target, CFRegister cc=FCC0)
void Ftintrz_ul_d(FPURegister fd, FPURegister fj, FPURegister scratch, Register result=no_reg)
void Movn(Register rd, Register rj, Register rk)
void Fld_d(FPURegister fd, const MemOperand &src)
void Ll_w(Register rd, const MemOperand &rj)
void CompareTaggedAndBranch(const Register &lhs, const Operand &rhs, Condition cond, Label *label)
void SmiTag(Register reg, SBit s=LeaveCC)
void Ld_h(Register rd, const MemOperand &rj)
void Ctz_w(Register rd, Register rj)
void Ffint_s_uw(FPURegister fd, FPURegister fj)
void Clz_w(Register rd, Register rj)
void CompareWord(Condition cond, Register dst, Register lhs, const Operand &rhs)
void Fst_s(FPURegister fj, const MemOperand &dst)
void Trunc_d(FPURegister fd, FPURegister fj)
void li(Register rd, Operand j, LiFlags mode=OPTIMIZE_SIZE)
void And(Register dst, Register src1, const Operand &src2, Condition cond=al)
void Float64MaxOutOfLine(FPURegister dst, FPURegister src1, FPURegister src2)
void St_d(Register rd, const MemOperand &rj)
void Ffint_d_uw(FPURegister fd, FPURegister fj)
void Trunc_s(FPURegister fd, FPURegister fj)
void Sc_w(Register rd, const MemOperand &rj)
void FmoveLow(Register dst_low, FPURegister src)
void Jump(Register target, Condition cond=al)
void EnterFrame(StackFrame::Type type, bool load_constant_pool_pointer_reg=false)
void Float64MinOutOfLine(FPURegister dst, FPURegister src1, FPURegister src2)
void Float32MinOutOfLine(FPURegister dst, FPURegister src1, FPURegister src2)
void LoadTaggedField(const Register &destination, const MemOperand &field_operand)
void Float32Min(FPURegister dst, FPURegister src1, FPURegister src2, Label *out_of_line)
void LoadProtectedPointerField(Register destination, MemOperand field_operand)
void CheckPageFlag(Register object, int mask, Condition cc, Label *condition_met)
int CallCFunction(ExternalReference function, int num_arguments, SetIsolateDataSlots set_isolate_data_slots=SetIsolateDataSlots::kYes, Label *return_label=nullptr)
void Neg_d(FPURegister fd, FPURegister fk)
void Float32MaxOutOfLine(FPURegister dst, FPURegister src1, FPURegister src2)
void Float32Max(FPURegister dst, FPURegister src1, FPURegister src2, Label *out_of_line)
void AllocateStackSpace(Register bytes)
void Ctz_d(Register rd, Register rj)
void Popcnt_d(Register rd, Register rj)
void CallRecordWriteStubSaveRegisters(Register object, Operand offset, SaveFPRegsMode fp_mode, StubCallMode mode=StubCallMode::kCallBuiltinPointer)
void Branch(Label *label, bool need_link=false)
void Ld_hu(Register rd, const MemOperand &rj)
void PrepareCallCFunction(int num_reg_arguments, int num_double_registers=0, Register scratch=no_reg)
void Ftintrz_uw_s(FPURegister fd, FPURegister fs, FPURegister scratch)
void LoadZeroIfFPUCondition(Register dest, CFRegister=FCC0)
void CompareIsNanF32(FPURegister cmp1, FPURegister cmp2, CFRegister cd=FCC0)
void BranchTrueShortF(Label *target, CFRegister cc=FCC0)
void Popcnt_w(Register rd, Register rj)
void Fld_s(FPURegister fd, const MemOperand &src)
void St_b(Register rd, const MemOperand &rj)
void St_h(Register rd, const MemOperand &rj)
void CompareF64(FPURegister cmp1, FPURegister cmp2, FPUCondition cc, CFRegister cd=FCC0)
void Ftintrz_uw_d(FPURegister fd, FPURegister fj, FPURegister scratch)
void Ld_wu(Register rd, const MemOperand &rj)
void Ld_w(Register rd, const MemOperand &rj)
static constexpr MainThreadFlags kPointersToHereAreInterestingMask
static constexpr MainThreadFlags kPointersFromHereAreInterestingMask
constexpr bool has(RegisterT reg) const
static constexpr Tagged< Smi > FromInt(int value)
static constexpr int32_t TypeToMarker(Type type)
static constexpr int kFrameTypeOffset
static constexpr Register GapRegister()
static constexpr int kInstanceDataOffset
static constexpr int kFeedbackVectorOffset
void emit_i8x16_swizzle(LiftoffRegister dst, LiftoffRegister lhs, LiftoffRegister rhs)
void emit_i64x2_uconvert_i32x4_low(LiftoffRegister dst, LiftoffRegister src)
bool emit_f16x8_nearest_int(LiftoffRegister dst, LiftoffRegister src)
void emit_store_nonzero_if_nan(Register dst, DoubleRegister src, ValueKind kind)
bool emit_f32x4_floor(LiftoffRegister dst, LiftoffRegister src)
void emit_f32x4_pmax(LiftoffRegister dst, LiftoffRegister lhs, LiftoffRegister rhs)
void emit_i64x2_sconvert_i32x4_low(LiftoffRegister dst, LiftoffRegister src)
void emit_i64x2_shl(LiftoffRegister dst, LiftoffRegister lhs, LiftoffRegister rhs)
void emit_f64x2_sub(LiftoffRegister dst, LiftoffRegister lhs, LiftoffRegister rhs)
void emit_f64x2_lt(LiftoffRegister dst, LiftoffRegister lhs, LiftoffRegister rhs)
void emit_i32x4_gt_s(LiftoffRegister dst, LiftoffRegister lhs, LiftoffRegister rhs)
void emit_i16x8_add_sat_u(LiftoffRegister dst, LiftoffRegister lhs, LiftoffRegister rhs)
void emit_i8x16_sub(LiftoffRegister dst, LiftoffRegister lhs, LiftoffRegister rhs)
void emit_f32x4_le(LiftoffRegister dst, LiftoffRegister lhs, LiftoffRegister rhs)
void emit_f64x2_div(LiftoffRegister dst, LiftoffRegister lhs, LiftoffRegister rhs)
void emit_i64_shli(LiftoffRegister dst, LiftoffRegister src, int32_t amount)
void emit_i8x16_add_sat_s(LiftoffRegister dst, LiftoffRegister lhs, LiftoffRegister rhs)
void emit_i32x4_relaxed_trunc_f64x2_u_zero(LiftoffRegister dst, LiftoffRegister src)
void emit_i32x4_min_s(LiftoffRegister dst, LiftoffRegister lhs, LiftoffRegister rhs)
void emit_i16x8_relaxed_q15mulr_s(LiftoffRegister dst, LiftoffRegister src1, LiftoffRegister src2)
void emit_i8x16_extract_lane_s(LiftoffRegister dst, LiftoffRegister lhs, uint8_t imm_lane_idx)
void emit_f32_min(DoubleRegister dst, DoubleRegister lhs, DoubleRegister rhs)
void emit_i32x4_ge_u(LiftoffRegister dst, LiftoffRegister lhs, LiftoffRegister rhs)
bool emit_f16x8_qfms(LiftoffRegister dst, LiftoffRegister src1, LiftoffRegister src2, LiftoffRegister src3)
void emit_f32x4_div(LiftoffRegister dst, LiftoffRegister lhs, LiftoffRegister rhs)
void emit_f64x2_pmax(LiftoffRegister dst, LiftoffRegister lhs, LiftoffRegister rhs)
bool emit_f16x8_trunc(LiftoffRegister dst, LiftoffRegister src)
bool emit_f16x8_extract_lane(LiftoffRegister dst, LiftoffRegister lhs, uint8_t imm_lane_idx)
void emit_i32_rems(Register dst, Register lhs, Register rhs, Label *trap_rem_by_zero)
void emit_i32_clz(Register dst, Register src)
void emit_i8x16_min_u(LiftoffRegister dst, LiftoffRegister lhs, LiftoffRegister rhs)
void emit_f64x2_max(LiftoffRegister dst, LiftoffRegister lhs, LiftoffRegister rhs)
void emit_i16x8_sub(LiftoffRegister dst, LiftoffRegister lhs, LiftoffRegister rhs)
void emit_store_nonzero(Register dst)
void emit_i8x16_shli(LiftoffRegister dst, LiftoffRegister lhs, int32_t rhs)
void emit_i32_eqz(Register dst, Register src)
void emit_i32x4_uconvert_f32x4(LiftoffRegister dst, LiftoffRegister src)
void emit_i16x8_uconvert_i8x16_low(LiftoffRegister dst, LiftoffRegister src)
void emit_f32x4_neg(LiftoffRegister dst, LiftoffRegister src)
void RecordUsedSpillOffset(int offset)
void emit_i16x8_splat(LiftoffRegister dst, LiftoffRegister src)
void emit_f32_max(DoubleRegister dst, DoubleRegister lhs, DoubleRegister rhs)
void emit_i8x16_uconvert_i16x8(LiftoffRegister dst, LiftoffRegister lhs, LiftoffRegister rhs)
void emit_i16x8_shri_s(LiftoffRegister dst, LiftoffRegister lhs, int32_t rhs)
void FillI64Half(Register, int offset, RegPairHalf)
bool emit_f16x8_splat(LiftoffRegister dst, LiftoffRegister src)
void emit_f32x4_demote_f64x2_zero(LiftoffRegister dst, LiftoffRegister src)
void emit_f64x2_splat(LiftoffRegister dst, LiftoffRegister src)
bool emit_i64_remu(LiftoffRegister dst, LiftoffRegister lhs, LiftoffRegister rhs, Label *trap_rem_by_zero)
void CallCWithStackBuffer(const std::initializer_list< VarState > args, const LiftoffRegister *rets, ValueKind return_kind, ValueKind out_argument_kind, int stack_bytes, ExternalReference ext_ref)
void emit_s128_and(LiftoffRegister dst, LiftoffRegister lhs, LiftoffRegister rhs)
void emit_f64x2_neg(LiftoffRegister dst, LiftoffRegister src)
void emit_i64x2_abs(LiftoffRegister dst, LiftoffRegister src)
void emit_i8x16_sub_sat_s(LiftoffRegister dst, LiftoffRegister lhs, LiftoffRegister rhs)
void emit_f32x4_max(LiftoffRegister dst, LiftoffRegister lhs, LiftoffRegister rhs)
void emit_i32x4_ge_s(LiftoffRegister dst, LiftoffRegister lhs, LiftoffRegister rhs)
void emit_f64x2_replace_lane(LiftoffRegister dst, LiftoffRegister src1, LiftoffRegister src2, uint8_t imm_lane_idx)
void emit_i32x4_dot_i16x8_s(LiftoffRegister dst, LiftoffRegister lhs, LiftoffRegister rhs)
void emit_i64_muli(LiftoffRegister dst, LiftoffRegister lhs, int32_t imm)
void emit_f64x2_le(LiftoffRegister dst, LiftoffRegister lhs, LiftoffRegister rhs)
void emit_i16x8_shr_u(LiftoffRegister dst, LiftoffRegister lhs, LiftoffRegister rhs)
void emit_i64x2_shr_u(LiftoffRegister dst, LiftoffRegister lhs, LiftoffRegister rhs)
void emit_i16x8_uconvert_i8x16_high(LiftoffRegister dst, LiftoffRegister src)
void emit_i16x8_eq(LiftoffRegister dst, LiftoffRegister lhs, LiftoffRegister rhs)
void emit_f32x4_pmin(LiftoffRegister dst, LiftoffRegister lhs, LiftoffRegister rhs)
void emit_i16x8_alltrue(LiftoffRegister dst, LiftoffRegister src)
void emit_i16x8_dot_i8x16_i7x16_s(LiftoffRegister dst, LiftoffRegister src1, LiftoffRegister src2)
void TailCallNativeWasmCode(Address addr)
void emit_i16x8_sconvert_i8x16_high(LiftoffRegister dst, LiftoffRegister src)
void SpillInstanceData(Register instance)
void RecordOolSpillSpaceSize(int size)
void emit_f64x2_qfma(LiftoffRegister dst, LiftoffRegister src1, LiftoffRegister src2, LiftoffRegister src3)
void AtomicSub(Register dst_addr, Register offset_reg, uintptr_t offset_imm, LiftoffRegister value, LiftoffRegister result, StoreType type, bool i64_offset)
void LoadTransform(LiftoffRegister dst, Register src_addr, Register offset_reg, uintptr_t offset_imm, LoadType type, LoadTransformationKind transform, uint32_t *protected_load_pc, bool i64_offset)
void emit_i32x4_uconvert_i16x8_low(LiftoffRegister dst, LiftoffRegister src)
void emit_s128_store_nonzero_if_nan(Register dst, LiftoffRegister src, Register tmp_gp, LiftoffRegister tmp_s128, ValueKind lane_kind)
void emit_i32x4_splat(LiftoffRegister dst, LiftoffRegister src)
void emit_i16x8_shri_u(LiftoffRegister dst, LiftoffRegister lhs, int32_t rhs)
bool emit_i16x8_sconvert_f16x8(LiftoffRegister dst, LiftoffRegister src)
void emit_i16x8_sconvert_i32x4(LiftoffRegister dst, LiftoffRegister lhs, LiftoffRegister rhs)
void emit_i8x16_add_sat_u(LiftoffRegister dst, LiftoffRegister lhs, LiftoffRegister rhs)
void emit_i32x4_shl(LiftoffRegister dst, LiftoffRegister lhs, LiftoffRegister rhs)
void emit_i16x8_add_sat_s(LiftoffRegister dst, LiftoffRegister lhs, LiftoffRegister rhs)
void AtomicCompareExchange(Register dst_addr, Register offset_reg, uintptr_t offset_imm, LiftoffRegister expected, LiftoffRegister new_value, LiftoffRegister value, StoreType type, bool i64_offset)
void emit_i8x16_shl(LiftoffRegister dst, LiftoffRegister lhs, LiftoffRegister rhs)
void emit_s128_not(LiftoffRegister dst, LiftoffRegister src)
void emit_i64_signextend_i16(LiftoffRegister dst, LiftoffRegister src)
void emit_i32x4_gt_u(LiftoffRegister dst, LiftoffRegister lhs, LiftoffRegister rhs)
void emit_i32x4_dot_i8x16_i7x16_add_s(LiftoffRegister dst, LiftoffRegister src1, LiftoffRegister src2, LiftoffRegister acc)
bool emit_f16x8_neg(LiftoffRegister dst, LiftoffRegister src)
void emit_f64x2_convert_low_i32x4_u(LiftoffRegister dst, LiftoffRegister src)
void emit_f32_copysign(DoubleRegister dst, DoubleRegister lhs, DoubleRegister rhs)
void emit_f32x4_add(LiftoffRegister dst, LiftoffRegister lhs, LiftoffRegister rhs)
bool emit_f16x8_pmax(LiftoffRegister dst, LiftoffRegister lhs, LiftoffRegister rhs)
void emit_i32x4_eq(LiftoffRegister dst, LiftoffRegister lhs, LiftoffRegister rhs)
void emit_i16x8_shli(LiftoffRegister dst, LiftoffRegister lhs, int32_t rhs)
void emit_f64_min(DoubleRegister dst, DoubleRegister lhs, DoubleRegister rhs)
void emit_i64x2_shr_s(LiftoffRegister dst, LiftoffRegister lhs, LiftoffRegister rhs)
void emit_i8x16_sconvert_i16x8(LiftoffRegister dst, LiftoffRegister lhs, LiftoffRegister rhs)
void emit_f64_set_cond(Condition condition, Register dst, DoubleRegister lhs, DoubleRegister rhs)
void emit_f32x4_sub(LiftoffRegister dst, LiftoffRegister lhs, LiftoffRegister rhs)
void emit_i16x8_add(LiftoffRegister dst, LiftoffRegister lhs, LiftoffRegister rhs)
void emit_f64x2_abs(LiftoffRegister dst, LiftoffRegister src)
void Fill(LiftoffRegister, int offset, ValueKind)
void emit_i64_signextend_i32(LiftoffRegister dst, LiftoffRegister src)
void emit_i64x2_extract_lane(LiftoffRegister dst, LiftoffRegister lhs, uint8_t imm_lane_idx)
void emit_f32x4_replace_lane(LiftoffRegister dst, LiftoffRegister src1, LiftoffRegister src2, uint8_t imm_lane_idx)
void LoadFullPointer(Register dst, Register src_addr, int32_t offset_imm)
void DeallocateStackSlot(uint32_t size)
void emit_i8x16_max_s(LiftoffRegister dst, LiftoffRegister lhs, LiftoffRegister rhs)
void emit_i16x8_max_s(LiftoffRegister dst, LiftoffRegister lhs, LiftoffRegister rhs)
bool emit_f16x8_sub(LiftoffRegister dst, LiftoffRegister lhs, LiftoffRegister rhs)
void emit_i32x4_abs(LiftoffRegister dst, LiftoffRegister src)
bool emit_f16x8_abs(LiftoffRegister dst, LiftoffRegister src)
void emit_i8x16_ge_s(LiftoffRegister dst, LiftoffRegister lhs, LiftoffRegister rhs)
void StackCheck(Label *ool_code)
void emit_f64x2_convert_low_i32x4_s(LiftoffRegister dst, LiftoffRegister src)
bool emit_f16x8_replace_lane(LiftoffRegister dst, LiftoffRegister src1, LiftoffRegister src2, uint8_t imm_lane_idx)
bool emit_f32x4_promote_low_f16x8(LiftoffRegister dst, LiftoffRegister src)
void Store(Register dst_addr, Register offset_reg, uintptr_t offset_imm, LiftoffRegister src, StoreType type, LiftoffRegList pinned, uint32_t *protected_store_pc=nullptr, bool is_store_mem=false, bool i64_offset=false)
bool emit_f16x8_mul(LiftoffRegister dst, LiftoffRegister lhs, LiftoffRegister rhs)
void Load(LiftoffRegister dst, Register src_addr, Register offset_reg, uintptr_t offset_imm, LoadType type, uint32_t *protected_load_pc=nullptr, bool is_load_mem=false, bool i64_offset=false, bool needs_shift=false)
void emit_i64x2_shri_u(LiftoffRegister dst, LiftoffRegister lhs, int32_t rhs)
bool emit_f16x8_max(LiftoffRegister dst, LiftoffRegister lhs, LiftoffRegister rhs)
void emit_i32x4_shr_s(LiftoffRegister dst, LiftoffRegister lhs, LiftoffRegister rhs)
void emit_f32x4_uconvert_i32x4(LiftoffRegister dst, LiftoffRegister src)
void emit_f32x4_relaxed_min(LiftoffRegister dst, LiftoffRegister lhs, LiftoffRegister rhs)
void emit_i64x2_shri_s(LiftoffRegister dst, LiftoffRegister lhs, int32_t rhs)
void emit_i32_signextend_i16(Register dst, Register src)
void emit_i8x16_gt_s(LiftoffRegister dst, LiftoffRegister lhs, LiftoffRegister rhs)
void emit_i32_divs(Register dst, Register lhs, Register rhs, Label *trap_div_by_zero, Label *trap_div_unrepresentable)
void emit_f32_neg(DoubleRegister dst, DoubleRegister src)
void emit_f64x2_promote_low_f32x4(LiftoffRegister dst, LiftoffRegister src)
void emit_i64_addi(LiftoffRegister dst, LiftoffRegister lhs, int64_t imm)
void LoadLane(LiftoffRegister dst, LiftoffRegister src, Register addr, Register offset_reg, uintptr_t offset_imm, LoadType type, uint8_t lane, uint32_t *protected_load_pc, bool i64_offset)
void emit_i16x8_sub_sat_u(LiftoffRegister dst, LiftoffRegister lhs, LiftoffRegister rhs)
void emit_i32x4_bitmask(LiftoffRegister dst, LiftoffRegister src)
void emit_i32x4_alltrue(LiftoffRegister dst, LiftoffRegister src)
void emit_i16x8_extract_lane_s(LiftoffRegister dst, LiftoffRegister lhs, uint8_t imm_lane_idx)
void emit_f64_copysign(DoubleRegister dst, DoubleRegister lhs, DoubleRegister rhs)
bool emit_f64x2_trunc(LiftoffRegister dst, LiftoffRegister src)
void CallBuiltin(Builtin builtin)
void emit_i8x16_rounding_average_u(LiftoffRegister dst, LiftoffRegister lhs, LiftoffRegister rhs)
void emit_i8x16_ne(LiftoffRegister dst, LiftoffRegister lhs, LiftoffRegister rhs)
void emit_i8x16_relaxed_swizzle(LiftoffRegister dst, LiftoffRegister lhs, LiftoffRegister rhs)
void emit_i16x8_abs(LiftoffRegister dst, LiftoffRegister src)
bool emit_f16x8_add(LiftoffRegister dst, LiftoffRegister lhs, LiftoffRegister rhs)
void CallFrameSetupStub(int declared_function_index)
void emit_i64x2_uconvert_i32x4_high(LiftoffRegister dst, LiftoffRegister src)
void emit_i32_remu(Register dst, Register lhs, Register rhs, Label *trap_rem_by_zero)
bool emit_f64x2_ceil(LiftoffRegister dst, LiftoffRegister src)
bool emit_f16x8_eq(LiftoffRegister dst, LiftoffRegister lhs, LiftoffRegister rhs)
void LoadSpillAddress(Register dst, int offset, ValueKind kind)
void emit_f32x4_qfms(LiftoffRegister dst, LiftoffRegister src1, LiftoffRegister src2, LiftoffRegister src3)
void emit_f64_neg(DoubleRegister dst, DoubleRegister src)
void emit_i64x2_replace_lane(LiftoffRegister dst, LiftoffRegister src1, LiftoffRegister src2, uint8_t imm_lane_idx)
void emit_i32_ctz(Register dst, Register src)
void StoreCallerFrameSlot(LiftoffRegister, uint32_t caller_slot_idx, ValueKind, Register frame_pointer)
void emit_i32x4_shli(LiftoffRegister dst, LiftoffRegister lhs, int32_t rhs)
void AtomicExchange(Register dst_addr, Register offset_reg, uintptr_t offset_imm, LiftoffRegister value, LiftoffRegister result, StoreType type, bool i64_offset)
void emit_i32x4_min_u(LiftoffRegister dst, LiftoffRegister lhs, LiftoffRegister rhs)
void emit_i64x2_mul(LiftoffRegister dst, LiftoffRegister lhs, LiftoffRegister rhs)
void Spill(VarState *slot)
void emit_s128_select(LiftoffRegister dst, LiftoffRegister src1, LiftoffRegister src2, LiftoffRegister mask)
bool emit_i64_rems(LiftoffRegister dst, LiftoffRegister lhs, LiftoffRegister rhs, Label *trap_rem_by_zero)
void emit_i8x16_replace_lane(LiftoffRegister dst, LiftoffRegister src1, LiftoffRegister src2, uint8_t imm_lane_idx)
bool emit_f16x8_ne(LiftoffRegister dst, LiftoffRegister lhs, LiftoffRegister rhs)
void emit_i64x2_sconvert_i32x4_high(LiftoffRegister dst, LiftoffRegister src)
void AssertUnreachable(AbortReason reason)
void CallC(const std::initializer_list< VarState > args, ExternalReference ext_ref)
void emit_i32x4_trunc_sat_f64x2_s_zero(LiftoffRegister dst, LiftoffRegister src)
bool emit_f16x8_floor(LiftoffRegister dst, LiftoffRegister src)
void emit_i64_signextend_i8(LiftoffRegister dst, LiftoffRegister src)
void emit_i64x2_bitmask(LiftoffRegister dst, LiftoffRegister src)
bool emit_i64_divu(LiftoffRegister dst, LiftoffRegister lhs, LiftoffRegister rhs, Label *trap_div_by_zero)
bool emit_f16x8_demote_f32x4_zero(LiftoffRegister dst, LiftoffRegister src)
void emit_f32x4_qfma(LiftoffRegister dst, LiftoffRegister src1, LiftoffRegister src2, LiftoffRegister src3)
void emit_f32x4_ne(LiftoffRegister dst, LiftoffRegister lhs, LiftoffRegister rhs)
void emit_i8x16_gt_u(LiftoffRegister dst, LiftoffRegister lhs, LiftoffRegister rhs)
void emit_f64x2_min(LiftoffRegister dst, LiftoffRegister lhs, LiftoffRegister rhs)
void emit_i32x4_shri_s(LiftoffRegister dst, LiftoffRegister lhs, int32_t rhs)
bool emit_f64x2_nearest_int(LiftoffRegister dst, LiftoffRegister src)
void DropStackSlotsAndRet(uint32_t num_stack_slots)
void emit_f32x4_abs(LiftoffRegister dst, LiftoffRegister src)
void emit_s128_and_not(LiftoffRegister dst, LiftoffRegister lhs, LiftoffRegister rhs)
void emit_s128_relaxed_laneselect(LiftoffRegister dst, LiftoffRegister src1, LiftoffRegister src2, LiftoffRegister mask, int lane_width)
void emit_i32x4_shri_u(LiftoffRegister dst, LiftoffRegister lhs, int32_t rhs)
void emit_f64x2_extract_lane(LiftoffRegister dst, LiftoffRegister lhs, uint8_t imm_lane_idx)
void emit_i16x8_replace_lane(LiftoffRegister dst, LiftoffRegister src1, LiftoffRegister src2, uint8_t imm_lane_idx)
void emit_i32x4_sconvert_f32x4(LiftoffRegister dst, LiftoffRegister src)
void emit_i8x16_shri_u(LiftoffRegister dst, LiftoffRegister lhs, int32_t rhs)
void LoadConstant(LiftoffRegister, WasmValue)
void emit_i32x4_uconvert_i16x8_high(LiftoffRegister dst, LiftoffRegister src)
int GetTotalFrameSize() const
void emit_i16x8_sub_sat_s(LiftoffRegister dst, LiftoffRegister lhs, LiftoffRegister rhs)
void emit_i16x8_max_u(LiftoffRegister dst, LiftoffRegister lhs, LiftoffRegister rhs)
void CallNativeWasmCode(Address addr)
bool emit_f32x4_trunc(LiftoffRegister dst, LiftoffRegister src)
void emit_i32x4_max_u(LiftoffRegister dst, LiftoffRegister lhs, LiftoffRegister rhs)
void emit_i32x4_ne(LiftoffRegister dst, LiftoffRegister lhs, LiftoffRegister rhs)
void PrepareTailCall(int num_callee_stack_params, int stack_param_delta)
void emit_f32x4_relaxed_max(LiftoffRegister dst, LiftoffRegister lhs, LiftoffRegister rhs)
bool emit_f16x8_ceil(LiftoffRegister dst, LiftoffRegister src)
void emit_i32_divu(Register dst, Register lhs, Register rhs, Label *trap_div_by_zero)
void emit_cond_jump(Condition, Label *, ValueKind value, Register lhs, Register rhs, const FreezeCacheState &frozen)
void LoadFromInstance(Register dst, Register instance, int offset, int size)
void emit_i8x16_min_s(LiftoffRegister dst, LiftoffRegister lhs, LiftoffRegister rhs)
void emit_i16x8_ne(LiftoffRegister dst, LiftoffRegister lhs, LiftoffRegister rhs)
void emit_smi_check(Register obj, Label *target, SmiCheckMode mode, const FreezeCacheState &frozen)
void emit_f64_max(DoubleRegister dst, DoubleRegister lhs, DoubleRegister rhs)
static bool NeedsAlignment(ValueKind kind)
void emit_f32x4_extract_lane(LiftoffRegister dst, LiftoffRegister lhs, uint8_t imm_lane_idx)
static int SlotSizeForType(ValueKind kind)
void LoadProtectedPointer(Register dst, Register src_addr, int32_t offset)
void emit_i16x8_shr_s(LiftoffRegister dst, LiftoffRegister lhs, LiftoffRegister rhs)
void emit_f64x2_qfms(LiftoffRegister dst, LiftoffRegister src1, LiftoffRegister src2, LiftoffRegister src3)
bool emit_f32x4_ceil(LiftoffRegister dst, LiftoffRegister src)
bool emit_i64_popcnt(LiftoffRegister dst, LiftoffRegister src)
void emit_u32_to_uintptr(Register dst, Register src)
bool supports_f16_mem_access()
void emit_i32x4_trunc_sat_f64x2_u_zero(LiftoffRegister dst, LiftoffRegister src)
void emit_i32_mul(Register dst, Register lhs, Register rhs)
void emit_i8x16_extract_lane_u(LiftoffRegister dst, LiftoffRegister lhs, uint8_t imm_lane_idx)
void emit_f32_set_cond(Condition condition, Register dst, DoubleRegister lhs, DoubleRegister rhs)
bool emit_f16x8_uconvert_i16x8(LiftoffRegister dst, LiftoffRegister src)
void emit_i16x8_min_s(LiftoffRegister dst, LiftoffRegister lhs, LiftoffRegister rhs)
void LoadInstanceDataFromFrame(Register dst)
void emit_i32x4_mul(LiftoffRegister dst, LiftoffRegister lhs, LiftoffRegister rhs)
bool emit_f16x8_demote_f64x2_zero(LiftoffRegister dst, LiftoffRegister src)
bool emit_f16x8_div(LiftoffRegister dst, LiftoffRegister lhs, LiftoffRegister rhs)
void emit_i16x8_gt_u(LiftoffRegister dst, LiftoffRegister lhs, LiftoffRegister rhs)
bool emit_f32x4_nearest_int(LiftoffRegister dst, LiftoffRegister src)
void emit_i32x4_sconvert_i16x8_high(LiftoffRegister dst, LiftoffRegister src)
void emit_i8x16_shri_s(LiftoffRegister dst, LiftoffRegister lhs, int32_t rhs)
void emit_i64_set_cond(Condition condition, Register dst, LiftoffRegister lhs, LiftoffRegister rhs)
bool emit_f64x2_floor(LiftoffRegister dst, LiftoffRegister src)
void emit_i8x16_sub_sat_u(LiftoffRegister dst, LiftoffRegister lhs, LiftoffRegister rhs)
void emit_i16x8_neg(LiftoffRegister dst, LiftoffRegister src)
void emit_i8x16_add(LiftoffRegister dst, LiftoffRegister lhs, LiftoffRegister rhs)
void emit_i32x4_sconvert_i16x8_low(LiftoffRegister dst, LiftoffRegister src)
void emit_f64x2_ne(LiftoffRegister dst, LiftoffRegister lhs, LiftoffRegister rhs)
bool emit_f16x8_le(LiftoffRegister dst, LiftoffRegister lhs, LiftoffRegister rhs)
bool emit_i32_popcnt(Register dst, Register src)
void emit_i16x8_rounding_average_u(LiftoffRegister dst, LiftoffRegister lhs, LiftoffRegister rhs)
void emit_i32x4_replace_lane(LiftoffRegister dst, LiftoffRegister src1, LiftoffRegister src2, uint8_t imm_lane_idx)
void MoveStackValue(uint32_t dst_offset, uint32_t src_offset, ValueKind)
void emit_i64x2_gt_s(LiftoffRegister dst, LiftoffRegister lhs, LiftoffRegister rhs)
void emit_i16x8_min_u(LiftoffRegister dst, LiftoffRegister lhs, LiftoffRegister rhs)
void emit_i64x2_ge_s(LiftoffRegister dst, LiftoffRegister lhs, LiftoffRegister rhs)
void Move(LiftoffRegister dst, LiftoffRegister src, ValueKind)
void emit_i8x16_ge_u(LiftoffRegister dst, LiftoffRegister lhs, LiftoffRegister rhs)
void emit_i64x2_sub(LiftoffRegister dst, LiftoffRegister lhs, LiftoffRegister rhs)
void emit_i16x8_uconvert_i32x4(LiftoffRegister dst, LiftoffRegister lhs, LiftoffRegister rhs)
bool emit_f16x8_lt(LiftoffRegister dst, LiftoffRegister lhs, LiftoffRegister rhs)
void emit_i8x16_popcnt(LiftoffRegister dst, LiftoffRegister src)
void AtomicStore(Register dst_addr, Register offset_reg, uintptr_t offset_imm, LiftoffRegister src, StoreType type, LiftoffRegList pinned, bool i64_offset)
static constexpr int kStackSlotSize
bool emit_f16x8_pmin(LiftoffRegister dst, LiftoffRegister lhs, LiftoffRegister rhs)
void PatchPrepareStackFrame(int offset, SafepointTableBuilder *, bool feedback_vector_slot, size_t stack_param_slots)
void emit_f32x4_sconvert_i32x4(LiftoffRegister dst, LiftoffRegister src)
void emit_ptrsize_cond_jumpi(Condition, Label *, Register lhs, int32_t imm, const FreezeCacheState &frozen)
void LoadCallerFrameSlot(LiftoffRegister, uint32_t caller_slot_idx, ValueKind)
void emit_i64x2_ne(LiftoffRegister dst, LiftoffRegister lhs, LiftoffRegister rhs)
void emit_i64x2_alltrue(LiftoffRegister dst, LiftoffRegister src)
void emit_i16x8_ge_s(LiftoffRegister dst, LiftoffRegister lhs, LiftoffRegister rhs)
void emit_f64x2_add(LiftoffRegister dst, LiftoffRegister lhs, LiftoffRegister rhs)
CacheState * cache_state()
void emit_i64_ctz(LiftoffRegister dst, LiftoffRegister src)
void emit_i32_set_cond(Condition, Register dst, Register lhs, Register rhs)
void emit_f32x4_min(LiftoffRegister dst, LiftoffRegister lhs, LiftoffRegister rhs)
bool emit_i64_divs(LiftoffRegister dst, LiftoffRegister lhs, LiftoffRegister rhs, Label *trap_div_by_zero, Label *trap_div_unrepresentable)
void emit_i16x8_sconvert_i8x16_low(LiftoffRegister dst, LiftoffRegister src)
void TailCallIndirect(compiler::CallDescriptor *call_descriptor, Register target)
void emit_i16x8_q15mulr_sat_s(LiftoffRegister dst, LiftoffRegister src1, LiftoffRegister src2)
void emit_i64x2_neg(LiftoffRegister dst, LiftoffRegister src)
void emit_i64x2_shli(LiftoffRegister dst, LiftoffRegister lhs, int32_t rhs)
void emit_i16x8_bitmask(LiftoffRegister dst, LiftoffRegister src)
void emit_i32x4_sub(LiftoffRegister dst, LiftoffRegister lhs, LiftoffRegister rhs)
void emit_i32x4_max_s(LiftoffRegister dst, LiftoffRegister lhs, LiftoffRegister rhs)
bool emit_f16x8_min(LiftoffRegister dst, LiftoffRegister lhs, LiftoffRegister rhs)
void emit_i32x4_relaxed_trunc_f32x4_s(LiftoffRegister dst, LiftoffRegister src)
void emit_i64x2_splat(LiftoffRegister dst, LiftoffRegister src)
void emit_f32x4_sqrt(LiftoffRegister dst, LiftoffRegister src)
void emit_i16x8_mul(LiftoffRegister dst, LiftoffRegister lhs, LiftoffRegister rhs)
void emit_i8x16_shr_u(LiftoffRegister dst, LiftoffRegister lhs, LiftoffRegister rhs)
void emit_i32x4_add(LiftoffRegister dst, LiftoffRegister lhs, LiftoffRegister rhs)
void emit_f64x2_mul(LiftoffRegister dst, LiftoffRegister lhs, LiftoffRegister rhs)
void AllocateStackSlot(Register addr, uint32_t size)
void emit_i32x4_extract_lane(LiftoffRegister dst, LiftoffRegister lhs, uint8_t imm_lane_idx)
void emit_s128_or(LiftoffRegister dst, LiftoffRegister lhs, LiftoffRegister rhs)
void LoadTaggedPointer(Register dst, Register src_addr, Register offset_reg, int32_t offset_imm, uint32_t *protected_load_pc=nullptr, bool offset_reg_needs_shift=false)
void PushRegisters(LiftoffRegList)
void emit_f64x2_eq(LiftoffRegister dst, LiftoffRegister lhs, LiftoffRegister rhs)
void emit_i8x16_alltrue(LiftoffRegister dst, LiftoffRegister src)
void emit_i32x4_shr_u(LiftoffRegister dst, LiftoffRegister lhs, LiftoffRegister rhs)
void emit_i8x16_abs(LiftoffRegister dst, LiftoffRegister src)
void emit_f32x4_splat(LiftoffRegister dst, LiftoffRegister src)
void emit_i8x16_shr_s(LiftoffRegister dst, LiftoffRegister lhs, LiftoffRegister rhs)
void emit_i32_cond_jumpi(Condition, Label *, Register lhs, int imm, const FreezeCacheState &frozen)
void emit_i64_eqz(Register dst, LiftoffRegister src)
void StoreTaggedPointer(Register dst_addr, Register offset_reg, int32_t offset_imm, Register src, LiftoffRegList pinned, uint32_t *protected_store_pc=nullptr, SkipWriteBarrier=kNoSkipWriteBarrier)
void emit_i64_clz(LiftoffRegister dst, LiftoffRegister src)
void bailout(LiftoffBailoutReason reason, const char *detail)
void emit_f32x4_mul(LiftoffRegister dst, LiftoffRegister lhs, LiftoffRegister rhs)
void IncrementSmi(LiftoffRegister dst, int offset)
void PopRegisters(LiftoffRegList)
LiftoffRegister GetUnusedRegister(RegClass rc, std::initializer_list< LiftoffRegister > try_first, LiftoffRegList pinned)
void emit_i16x8_gt_s(LiftoffRegister dst, LiftoffRegister lhs, LiftoffRegister rhs)
void emit_i16x8_shl(LiftoffRegister dst, LiftoffRegister lhs, LiftoffRegister rhs)
void emit_i8x16_splat(LiftoffRegister dst, LiftoffRegister src)
bool emit_f16x8_sconvert_i16x8(LiftoffRegister dst, LiftoffRegister src)
void emit_f64x2_sqrt(LiftoffRegister dst, LiftoffRegister src)
void emit_i8x16_shuffle(LiftoffRegister dst, LiftoffRegister lhs, LiftoffRegister rhs, const uint8_t shuffle[16], bool is_swizzle)
void emit_i64x2_add(LiftoffRegister dst, LiftoffRegister lhs, LiftoffRegister rhs)
void emit_i64_mul(LiftoffRegister dst, LiftoffRegister lhs, LiftoffRegister rhs)
void emit_i8x16_max_u(LiftoffRegister dst, LiftoffRegister lhs, LiftoffRegister rhs)
bool emit_select(LiftoffRegister dst, Register condition, LiftoffRegister true_value, LiftoffRegister false_value, ValueKind kind)
bool emit_i16x8_uconvert_f16x8(LiftoffRegister dst, LiftoffRegister src)
bool emit_type_conversion(WasmOpcode opcode, LiftoffRegister dst, LiftoffRegister src, Label *trap=nullptr)
void emit_i8x16_neg(LiftoffRegister dst, LiftoffRegister src)
void AtomicLoad(LiftoffRegister dst, Register src_addr, Register offset_reg, uintptr_t offset_imm, LoadType type, LiftoffRegList pinned, bool i64_offset)
void emit_i64x2_eq(LiftoffRegister dst, LiftoffRegister lhs, LiftoffRegister rhs)
void LoadReturnStackSlot(LiftoffRegister, int offset, ValueKind)
void emit_i32x4_neg(LiftoffRegister dst, LiftoffRegister src)
void emit_s128_xor(LiftoffRegister dst, LiftoffRegister lhs, LiftoffRegister rhs)
void emit_i16x8_ge_u(LiftoffRegister dst, LiftoffRegister lhs, LiftoffRegister rhs)
void emit_i32x4_relaxed_trunc_f32x4_u(LiftoffRegister dst, LiftoffRegister src)
void LoadTaggedPointerFromInstance(Register dst, Register instance, int offset)
void emit_v128_anytrue(LiftoffRegister dst, LiftoffRegister src)
void FillStackSlotsWithZero(int start, int size)
void emit_f32x4_lt(LiftoffRegister dst, LiftoffRegister lhs, LiftoffRegister rhs)
void emit_s128_const(LiftoffRegister dst, const uint8_t imms[16])
void StoreLane(Register dst, Register offset, uintptr_t offset_imm, LiftoffRegister src, StoreType type, uint8_t lane, uint32_t *protected_store_pc, bool i64_offset)
Register LoadOldFramePointer()
void CheckTierUp(int declared_func_index, int budget_used, Label *ool_label, const FreezeCacheState &frozen)
void emit_i16x8_extract_lane_u(LiftoffRegister dst, LiftoffRegister lhs, uint8_t imm_lane_idx)
void emit_f64x2_relaxed_min(LiftoffRegister dst, LiftoffRegister lhs, LiftoffRegister rhs)
void CallIndirect(const ValueKindSig *sig, compiler::CallDescriptor *call_descriptor, Register target)
void RecordSpillsInSafepoint(SafepointTableBuilder::Safepoint &safepoint, LiftoffRegList all_spills, LiftoffRegList ref_spills, int spill_offset)
void emit_f64x2_relaxed_max(LiftoffRegister dst, LiftoffRegister lhs, LiftoffRegister rhs)
bool emit_f16x8_qfma(LiftoffRegister dst, LiftoffRegister src1, LiftoffRegister src2, LiftoffRegister src3)
void emit_i8x16_eq(LiftoffRegister dst, LiftoffRegister lhs, LiftoffRegister rhs)
void clear_i32_upper_half(Register dst)
void emit_f64x2_pmin(LiftoffRegister dst, LiftoffRegister lhs, LiftoffRegister rhs)
bool emit_f16x8_sqrt(LiftoffRegister dst, LiftoffRegister src)
void LoadTrustedPointer(Register dst, Register src_addr, int offset, IndirectPointerTag tag)
void emit_i32x4_relaxed_trunc_f64x2_s_zero(LiftoffRegister dst, LiftoffRegister src)
static constexpr int StaticStackFrameSize()
void emit_f32x4_eq(LiftoffRegister dst, LiftoffRegister lhs, LiftoffRegister rhs)
void emit_i32_signextend_i8(Register dst, Register src)
void emit_i8x16_bitmask(LiftoffRegister dst, LiftoffRegister src)
constexpr unsigned GetNumRegsSet() const
constexpr DoubleRegister fp() const
constexpr Register gp() const
base::SmallVector< Slot, 8 > slots_
static int SlotSizeInBytes(const Slot &slot)
void Construct(int param_slots)
LiftoffAssembler *const asm_
static constexpr int ToTagged(int offset)
#define ATOMIC_BINOP_CASE(op, inst)
#define ASSEMBLE_ATOMIC_COMPARE_EXCHANGE_INTEGER(load_instr, store_instr, cmp_reg)
#define ASSEMBLE_ATOMIC_BINOP(load_instr, store_instr, bin_instr)
#define ASSEMBLE_ATOMIC_EXCHANGE_INTEGER_EXT( load_linked, store_conditional, sign_extend, size, representation)
#define ASSEMBLE_ATOMIC_BINOP_EXT(load_linked, store_conditional, sign_extend, size, bin_instr, representation)
#define ASSEMBLE_ATOMIC_COMPARE_EXCHANGE_INTEGER_EXT( load_linked, store_conditional, sign_extend, size, representation)
#define COMPRESS_POINTERS_BOOL
base::Vector< const DirectHandle< Object > > args
ZoneVector< RpoNumber > & result
#define FP_BINOP(name, instruction)
#define FP_UNOP_RETURN_TRUE(name, instruction)
#define SIMD_BINOP(name1, name2)
#define I64_BINOP(name, instruction)
#define I64_BINOP_I(name, instruction)
#define I32_SHIFTOP_I(name, instruction, instruction1)
#define FP_UNOP(name, instruction)
#define I64_SHIFTOP_I(name, instruction, instructioni)
#define I32_BINOP(name, instruction)
#define I32_BINOP_I(name, instruction)
MovableLabel continuation
LiftoffRegList regs_to_save
std::optional< OolTrapLabel > trap
constexpr bool IsPowerOfTwo(T value)
constexpr int WhichPowerOfTwo(T value)
void Store(LiftoffAssembler *assm, LiftoffRegister src, MemOperand dst, ValueKind kind)
void StoreToMemory(LiftoffAssembler *assm, MemOperand dst, const LiftoffAssembler::VarState &src)
constexpr DoubleRegister kScratchDoubleReg
MemOperand GetStackSlot(int offset)
void Load(LiftoffAssembler *assm, LiftoffRegister dst, MemOperand src, ValueKind kind)
void push(LiftoffAssembler *assm, LiftoffRegister reg, ValueKind kind, int padding=0)
constexpr DoubleRegister kScratchDoubleReg2
MemOperand GetInstanceDataOperand()
MemOperand GetMemOp(LiftoffAssembler *assm, UseScratchRegisterScope *temps, Register addr, Register offset, int32_t offset_imm, unsigned shift_amount=0)
FPUCondition ConditionToConditionCmpFPU(Condition condition, bool *predicate)
constexpr DoubleRegister kFpReturnRegisters[]
constexpr Register kGpParamRegisters[]
constexpr DoubleRegister kFpParamRegisters[]
constexpr DoubleRegList kLiftoffAssemblerFpCacheRegs
constexpr Register kGpReturnRegisters[]
int declared_function_index(const WasmModule *module, int func_index)
constexpr int value_kind_size(ValueKind kind)
static constexpr LiftoffRegList kGpCacheRegList
static constexpr LiftoffRegList kFpCacheRegList
constexpr bool is_reference(ValueKind kind)
LiftoffAssembler::ValueKindSig ValueKindSig
constexpr Register no_reg
constexpr int kSimd128Size
@ kUnsignedGreaterThanEqual
DwVfpRegister DoubleRegister
constexpr DoubleRegister kScratchDoubleReg
kWasmInternalFunctionIndirectPointerTag instance_data
constexpr DoubleRegister kScratchDoubleReg2
constexpr Register kScratchReg2
constexpr Register kScratchReg
kWasmInternalFunctionIndirectPointerTag kProtectedInstanceDataOffset sig
constexpr int kSystemPointerSize
constexpr Register kReturnRegister0
constexpr bool SmiValuesAre31Bits()
V8_EXPORT_PRIVATE FlagValues v8_flags
const intptr_t kSmiTagMask
constexpr uint8_t kInstrSize
constexpr Register kCArgRegs[]
std::unique_ptr< AssemblerBuffer > ExternalAssemblerBuffer(void *start, int size)
#define DCHECK_LE(v1, v2)
#define DCHECK_NE(v1, v2)
#define DCHECK_GE(v1, v2)
#define DCHECK(condition)
#define DCHECK_LT(v1, v2)
#define DCHECK_EQ(v1, v2)
Register cached_instance_data
LiftoffRegList used_registers
#define V8_LIKELY(condition)