5#ifndef V8_CODEGEN_MIPS64_MACRO_ASSEMBLER_MIPS64_H_
6#define V8_CODEGEN_MIPS64_MACRO_ASSEMBLER_MIPS64_H_
8#ifndef INCLUDED_FROM_MACRO_ASSEMBLER_H
9#error This header must be included via macro-assembler.h
70#if defined(V8_TARGET_LITTLE_ENDIAN)
71#define SmiWordOffset(offset) (offset + kPointerSize / 2)
73#define SmiWordOffset(offset) offset
95 using MacroAssemblerBase::MacroAssemblerBase;
109 if (bytes == 0)
return;
153#define COND_TYPED_ARGS Condition cond, Register r1, const Operand &r2
154#define COND_ARGS cond, r1, r2
157#define DECLARE_NORELOC_PROTOTYPE(Name, target_type) \
158 void Name(target_type target, BranchDelaySlot bd = PROTECT); \
159 inline void Name(BranchDelaySlot bd, target_type target) { \
162 void Name(target_type target, COND_TYPED_ARGS, \
163 BranchDelaySlot bd = PROTECT); \
164 inline void Name(BranchDelaySlot bd, target_type target, COND_TYPED_ARGS) { \
165 Name(target, COND_ARGS, bd); \
168#define DECLARE_BRANCH_PROTOTYPES(Name) \
169 DECLARE_NORELOC_PROTOTYPE(Name, Label*) \
170 DECLARE_NORELOC_PROTOTYPE(Name, int32_t)
176#undef DECLARE_BRANCH_PROTOTYPES
177#undef COND_TYPED_ARGS
182 CompareF(
S,
cc, cmp1, cmp2);
186 CompareIsNanF(
S, cmp1, cmp2);
190 CompareF(
D,
cc, cmp1, cmp2);
194 CompareIsNanF(
D, cmp1, cmp2);
242 return ExternalReferenceAsOperand(ExternalReference::Create(
id),
no_reg);
249 Condition cond = al, Register rs = zero_reg, \
250 const Operand &rt = Operand(zero_reg), \
251 BranchDelaySlot bd = PROTECT
259 void PatchAndJump(Address target);
283 Register code_data_container_object,
296#ifdef V8_ENABLE_WEBASSEMBLY
297 void ResolveWasmCodePointer(
Register target);
298 void CallWasmCodePointer(
Register target,
309 Label* jump_deoptimization_entry_label);
315 Ret(cond, rs, rt, bd);
327 void DropAndRet(
int drop);
379 Branch(3, cond, tst1,
Operand(tst2));
413 Register exclusion3 = no_reg)
const;
456#define DEFINE_INSTRUCTION(instr) \
457 void instr(Register rd, Register rs, const Operand& rt); \
458 void instr(Register rd, Register rs, Register rt) { \
459 instr(rd, rs, Operand(rt)); \
461 void instr(Register rs, Register rt, int32_t j) { instr(rs, rt, Operand(j)); }
463#define DEFINE_INSTRUCTION2(instr) \
464 void instr(Register rs, const Operand& rt); \
465 void instr(Register rs, Register rt) { instr(rs, Operand(rt)); } \
466 void instr(Register rs, int32_t j) { instr(rs, Operand(j)); }
514#undef DEFINE_INSTRUCTION
515#undef DEFINE_INSTRUCTION2
516#undef DEFINE_INSTRUCTION3
568 int num_double_arguments);
595 Label* return_location =
nullptr);
597 Register function,
int num_arguments,
599 Label* return_location =
nullptr);
602 int num_double_arguments,
604 Label* return_location =
nullptr);
606 Register function,
int num_reg_arguments,
int num_double_arguments,
608 Label* return_location =
nullptr);
627 Label* condition_met);
661 bool sign_extend =
false);
761 mfhc1(dst_high, src);
769 mfhc1(dst_high, src);
773 mthc1(src_high, dst);
784 mthc1(src_high, dst);
800 Move(dst, base::bit_cast<uint32_t>(imm));
803 Move(dst, base::bit_cast<uint64_t>(imm));
823#ifdef _MIPS_ARCH_MIPS64R6
824 static const int kSwitchTablePrologueSize = 6;
826 static const int kSwitchTablePrologueSize = 11;
831 template <
typename Func>
833 Func GetLabelFunction);
956#ifdef V8_ENABLE_LEAPTIERING
964 void LoadEntrypointAndParameterCountFromJSDispatchTable(
983 LoadRoot(scratch, index);
991 LoadRoot(scratch, index);
992 Branch(if_equal,
eq, with,
Operand(scratch));
999 LoadRoot(scratch, index);
1000 Branch(if_not_equal,
ne, with,
Operand(scratch));
1006 unsigned higher_limit,
Label* on_in_range);
1071 LoadNativeContextSlot(dst, Context::GLOBAL_PROXY_INDEX);
1085 Register expected_parameter_count_or_dispatch_handle,
1093#ifdef V8_ENABLE_LEAPTIERING
1160 CallRuntime(Runtime::FunctionForId(fid), num_arguments);
1168 bool builtin_exit_frame =
false);
1179 if (!
v8_flags.native_code_counters)
return;
1180 EmitIncrementCounter(counter, value, scratch1, scratch2);
1186 if (!
v8_flags.native_code_counters)
return;
1187 EmitDecrementCounter(counter, value, scratch1, scratch2);
1245#ifndef V8_ENABLE_LEAPTIERING
1248 Label* flags_need_processing);
1252 template <
typename Field>
1254 Ext(dst, src, Field::kShift, Field::kSize);
1257 template <
typename Field>
1259 DecodeField<Field>(
reg,
reg);
1264 inline int32_t GetOffset(int32_t
offset,
Label* L, OffsetSize bits);
1267 bool has_double_zero_reg_set_ =
false;
1289 Register function,
int num_reg_arguments,
int num_double_arguments,
1291 Label* return_location =
nullptr);
1323 template <
typename RoundFunc>
1327 template <
typename RoundFunc>
1337template <
typename Func>
1339 Func GetLabelFunction) {
1345 Register scratch = temps.Acquire();
1367 for (
size_t index = 0; index < case_count; ++
index) {
1368 dd(GetLabelFunction(index));
1372struct MoveCycleState {
1378 std::optional<UseScratchRegisterScope>
temps;
1405 Register function_address,
1406 ExternalReference thunk_ref, Register thunk_arg,
1407 int slots_to_drop_on_return,
1414#define ACCESS_MASM(masm) masm->
interpreter::OperandScale scale
Simd128Register Simd128Register ra
void addiupc(Register rs, int32_t imm19)
void BlockTrampolinePoolFor(int instructions)
void daddu(Register rd, Register rs, Register rt)
void dsll(Register rd, Register rt, uint16_t sa)
static constexpr int kFixedSlotCountAboveFp
void Clz(Register rd, Register rs)
void Trunc_ul_d(Register rd, FPURegister fs, FPURegister scratch, Register result=no_reg)
void JumpIfRoot(Register with, RootIndex index, Label *if_equal)
void Push(Register src1, Register src2, Register src3, Register src4, Register src5)
void GenerateSwitchTable(Register index, size_t case_count, Func GetLabelFunction)
void Ret(BranchDelaySlot bd, Condition cond=al, Register rs=zero_reg, const Operand &rt=Operand(zero_reg))
void Abort(AbortReason msg)
void CallCodeObject(Register code_data_container_object, CodeEntrypointTag tag)
void LoadStackLimit(Register destination, StackLimitKind kind)
void LoadReceiver(Register dest)
void Cvt_s_ul(FPURegister fd, Register rs)
void Pop(Register src1, Register src2, Register src3)
void InitializeRootRegister()
void GetObjectType(Register function, Register map, Register type_reg)
void Trunc_ul_s(Register rd, FPURegister fs, FPURegister scratch, Register result=no_reg)
void CallJSFunction(Register function_object, uint16_t argument_count)
void LiLower32BitHelper(Register rd, Operand j)
void Lbu(Register rd, const MemOperand &rs)
void BranchAndLinkShort(Label *L, BranchDelaySlot bdslot=PROTECT)
bool IsNear(Label *L, Condition cond, int rs_reg)
void BranchAndLinkLong(Label *L, BranchDelaySlot bdslot)
void LoadSplat(MSASize sz, MSARegister dst, MemOperand src)
int CallCFunction(ExternalReference function, int num_reg_arguments, int num_double_arguments, SetIsolateDataSlots set_isolate_data_slots=SetIsolateDataSlots::kYes, Label *return_location=nullptr)
void DecodeField(Register reg)
void JumpIfIsInRange(Register value, unsigned lower_limit, unsigned higher_limit, Label *on_in_range)
void ExtractBits(Register dest, Register source, Register pos, int size, bool sign_extend=false)
int CallCFunction(Register function, int num_reg_arguments, int num_double_arguments, SetIsolateDataSlots set_isolate_data_slots=SetIsolateDataSlots::kYes, Label *return_location=nullptr)
void Move(FPURegister dst, float imm)
void MultiPopFPU(DoubleRegList regs)
void RecordWriteField(Register object, int offset, Register value, Register scratch, RAStatus ra_status, SaveFPRegsMode save_fp, SmiCheck smi_check=SmiCheck::kInline)
void Move(FPURegister dst, FPURegister src)
void Ctz(Register rd, Register rs)
void Swap(Register reg1, Register reg2, Register scratch=no_reg)
void Cvt_s_uw(FPURegister fd, FPURegister fs)
void Cvt_d_ul(FPURegister fd, Register rs)
void CallRuntime(Runtime::FunctionId fid)
void Move(FPURegister dst, Register src)
int CalculateStackPassedWords(int num_reg_arguments, int num_double_arguments)
void MultiPushFPU(DoubleRegList regs)
bool BranchShortHelper(int16_t offset, Label *L, Condition cond, Register rs, const Operand &rt, BranchDelaySlot bdslot)
void LoadZeroIfFPUCondition(Register dest)
void Trunc_l_d(FPURegister fd, FPURegister fs)
void EnterFrame(StackFrame::Type type)
void Scd(Register rd, const MemOperand &rs)
void Dins(Register rt, Register rs, uint16_t pos, uint16_t size)
void CompareIsNanF(SecondaryField sizeField, FPURegister cmp1, FPURegister cmp2)
void Sh(Register rd, const MemOperand &rs)
void li(Register dst, Handle< HeapObject > value, LiFlags mode=OPTIMIZE_SIZE)
void Move(FPURegister dst, double imm)
void DecodeField(Register dst, Register src)
void AssertFunction(Register object) NOOP_UNLESS_DEBUG_CODE
void Branch(Label *L, Condition cond, Register rs, RootIndex index, BranchDelaySlot bdslot=PROTECT)
void Call(Register target, COND_ARGS)
void Ceil_l_d(FPURegister fd, FPURegister fs)
void Uswc1(FPURegister fd, const MemOperand &rs, Register scratch)
void Float64Min(FPURegister dst, FPURegister src1, FPURegister src2, Label *out_of_line)
void AssertGeneratorObject(Register object) NOOP_UNLESS_DEBUG_CODE
void StoreReceiver(Register rec)
void JumpIfNotRoot(Register with, RootIndex index, Label *if_not_equal)
void Lb(Register rd, const MemOperand &rs)
void TailCallBuiltin(Builtin builtin, Condition cond, Register type, Operand range)
static int InstrCountForLi64Bit(int64_t value)
void Movz(Register rd, Register rs, Register rt)
void LoadEntryFromBuiltin(Builtin builtin, Register destination)
void Neg_s(FPURegister fd, FPURegister fs)
void TestCodeIsMarkedForDeoptimizationAndJump(Register code_data_container, Register scratch, Condition cond, Label *target)
void Trunc_uw_s(FPURegister fd, FPURegister fs, FPURegister scratch)
void PushStandardFrame(Register function_reg)
void Floor_l_d(FPURegister fd, FPURegister fs)
void li(Register dst, ExternalReference value, LiFlags mode=OPTIMIZE_SIZE)
int CallCFunction(ExternalReference function, int num_arguments, SetIsolateDataSlots set_isolate_data_slots=SetIsolateDataSlots::kYes, Label *return_location=nullptr)
void Swc1(FPURegister fs, const MemOperand &dst)
void Move(Register dst, Register src)
static const int kSwitchTablePrologueSize
void Move(Register dst, FPURegister src)
void BranchAndLinkShort(int32_t offset, BranchDelaySlot bdslot=PROTECT)
void Jump(intptr_t target, RelocInfo::Mode rmode, COND_ARGS)
void JumpIfEqual(Register a, int32_t b, Label *dest)
void li_optimized(Register rd, Operand j, LiFlags mode=OPTIMIZE_SIZE)
void mov(Register rd, Register rt)
void StoreReturnAddressAndCall(Register target)
void Move(Register dst, Tagged< Smi > value)
void Msub_s(FPURegister fd, FPURegister fr, FPURegister fs, FPURegister ft, FPURegister scratch)
void LoadZeroIfConditionZero(Register dest, Register condition)
void FmoveLow(FPURegister dst, Register src_low)
void Float64Max(FPURegister dst, FPURegister src1, FPURegister src2, Label *out_of_line)
void Trunc_l_ud(FPURegister fd, FPURegister fs, FPURegister scratch)
void LeaveExitFrame(Register scratch)
void AssertFeedbackVector(Register object, Register scratch) NOOP_UNLESS_DEBUG_CODE
void CallBuiltinByIndex(Register builtin_index, Register target)
void LoadRootRelative(Register destination, int32_t offset) final
void Round_d_d(FPURegister fd, FPURegister fs)
static int ActivationFrameAlignment()
void Push(Handle< HeapObject > handle)
void PrepareCallCFunction(int num_reg_arguments, Register scratch)
void Cvt_s_ul(FPURegister fd, FPURegister fs)
void MultiPush(RegList regs)
void CallEphemeronKeyBarrier(Register object, Register slot_address, SaveFPRegsMode fp_mode)
void CompareIsNanF32(FPURegister cmp1, FPURegister cmp2)
void Ceil_d_d(FPURegister fd, FPURegister fs)
void Lwu(Register rd, const MemOperand &rs)
void Jump(Register target, COND_ARGS)
int CallCFunctionHelper(Register function, int num_reg_arguments, int num_double_arguments, SetIsolateDataSlots set_isolate_data_slots=SetIsolateDataSlots::kYes, Label *return_location=nullptr)
void LoadRootRegisterOffset(Register destination, intptr_t offset) final
void CompareF32(FPUCondition cc, FPURegister cmp1, FPURegister cmp2)
void FmoveHigh(Register dst_high, FPURegister src)
void AssertSmi(Register object) NOOP_UNLESS_DEBUG_CODE
bool IsDoubleZeroRegSet()
void CheckDebugHook(Register fun, Register new_target, Register expected_parameter_count_or_dispatch_handle, Register actual_parameter_count)
void SmiUntag(Register dst, Register src)
void Move(FPURegister dst, Register src_low, Register src_high)
void Msub_d(FPURegister fd, FPURegister fr, FPURegister fs, FPURegister ft, FPURegister scratch)
void Neg_d(FPURegister fd, FPURegister fs)
void LoadFeedbackVectorFlagsAndJumpIfNeedsProcessing(Register flags, Register feedback_vector, CodeKind current_code_kind, Label *flags_need_processing)
void Trunc_w_d(FPURegister fd, FPURegister fs)
void Ulwu(Register rd, const MemOperand &rs)
void BranchTrueShortF(Label *target, BranchDelaySlot bd=PROTECT)
void LoadFeedbackVector(Register dst, Register closure, Register scratch, Label *fbv_undef)
bool BranchAndLinkShortCheck(int32_t offset, Label *L, Condition cond, Register rs, const Operand &rt, BranchDelaySlot bdslot)
void EmitIncrementCounter(StatsCounter *counter, int value, Register scratch1, Register scratch2)
void Cvt_d_ul(FPURegister fd, FPURegister fs)
void MultiPushMSA(DoubleRegList regs)
int CallCFunction(Register function, int num_arguments, SetIsolateDataSlots set_isolate_data_slots=SetIsolateDataSlots::kYes, Label *return_location=nullptr)
void TailCallBuiltin(Builtin builtin)
void Bnvc(Register rt, Register rs, Label *L)
void LoadAddressPCRelative(Register dst, Label *target)
void LoadGlobalFunctionInitialMap(Register function, Register map, Register scratch)
void InvokeFunctionCode(Register function, Register new_target, Register expected_parameter_count, Register actual_parameter_count, InvokeType type)
void BailoutIfDeoptimized()
void Trunc_ul_s(FPURegister fd, FPURegister fs, FPURegister scratch, Register result=no_reg)
void Sd(Register rd, const MemOperand &rs)
void BranchShortHelper(int16_t offset, Label *L, BranchDelaySlot bdslot)
int RequiredStackSizeForCallerSaved(SaveFPRegsMode fp_mode, Register exclusion1=no_reg, Register exclusion2=no_reg, Register exclusion3=no_reg) const
void ReplaceClosureCodeWithOptimizedCode(Register optimized_code, Register closure, Register scratch1, Register scratch2)
void Lwc1(FPURegister fd, const MemOperand &src)
void RecordWrite(Register object, Register address, Register value, RAStatus ra_status, SaveFPRegsMode save_fp, SmiCheck smi_check=SmiCheck::kInline)
void Move_d(FPURegister dst, FPURegister src)
void Jump(const ExternalReference &reference)
MemOperand ExternalReferenceAsOperand(IsolateFieldId id)
void Trunc_s_s(FPURegister fd, FPURegister fs)
void InvokePrologue(Register expected_parameter_count, Register actual_parameter_count, InvokeType type)
void DaddOverflow(Register dst, Register left, const Operand &right, Register overflow)
void Uldc1(FPURegister fd, const MemOperand &rs, Register scratch)
void RoundDouble(FPURegister dst, FPURegister src, FPURoundingMode mode, RoundFunc round)
void RoundFloat(FPURegister dst, FPURegister src, FPURoundingMode mode, RoundFunc round)
void Push(Register src1, Register src2, Register src3)
void Call(Address target, RelocInfo::Mode rmode, COND_ARGS)
void BranchLong(Label *L, BranchDelaySlot bdslot)
void Move(Register dst, Handle< HeapObject > handle)
void EnterExitFrame(Register scratch, int stack_space, StackFrame::Type frame_type)
void Drop(int count, Condition cond=cc_always, Register reg=no_reg, const Operand &op=Operand(no_reg))
void SmiTag(Register dst, Register src)
void CompareWord(Condition cond, Register dst, Register lhs, const Operand &rhs)
void Check(Condition cc, AbortReason reason, Register rs, Operand rt)
void CompareF64(FPUCondition cc, FPURegister cmp1, FPURegister cmp2)
MemOperand ExternalReferenceAsOperand(ExternalReference reference, Register scratch)
void CallBuiltin(Builtin builtin)
void IncrementCounter(StatsCounter *counter, int value, Register scratch1, Register scratch2)
bool BranchShortHelperR6(int32_t offset, Label *L, Condition cond, Register rs, const Operand &rt)
void Move(FPURegister dst, uint64_t src)
void BranchFalseF(Label *target, BranchDelaySlot bd=PROTECT)
void Pop(uint32_t count=1)
void PushCommonFrame(Register marker_reg=no_reg)
void Lsa(Register rd, Register rs, Register rt, uint8_t sa, Register scratch=at)
void LeaveFrame(StackFrame::Type type)
void li(Register rd, Operand j, LiFlags mode=OPTIMIZE_SIZE)
void Movt(Register rd, Register rs, uint16_t cc=0)
int PushCallerSaved(SaveFPRegsMode fp_mode, Register exclusion1=no_reg, Register exclusion2=no_reg, Register exclusion3=no_reg)
void Sw(Register rd, const MemOperand &rs)
void MultiPopMSA(DoubleRegList regs)
void JumpToExternalReference(const ExternalReference &builtin, bool builtin_exit_frame=false)
void LoadZeroIfNotFPUCondition(Register dest)
void Float64MaxOutOfLine(FPURegister dst, FPURegister src1, FPURegister src2)
Operand ClearedValue() const
void StackOverflowCheck(Register num_args, Register scratch1, Register scratch2, Label *stack_overflow)
void BranchAndLinkShortHelper(int16_t offset, Label *L, BranchDelaySlot bdslot)
void MulOverflow(Register dst, Register left, const Operand &right, Register overflow)
void Lhu(Register rd, const MemOperand &rs)
void InsertBits(Register dest, Register source, Register pos, int size)
void BranchLong(int32_t offset, BranchDelaySlot bdslot=PROTECT)
void FmoveHigh(FPURegister dst, Register src_high)
void BranchTrueF(Label *target, BranchDelaySlot bd=PROTECT)
void JumpIfNotSmi(Register value, Label *not_smi_label, BranchDelaySlot bd=PROTECT)
void MultiPop(RegList regs)
void InvokeFunctionWithNewTarget(Register function, Register new_target, Register actual_parameter_count, InvokeType type)
void li(Register rd, int64_t j, LiFlags mode=OPTIMIZE_SIZE)
bool BranchAndLinkShortHelper(int16_t offset, Label *L, Condition cond, Register rs, const Operand &rt, BranchDelaySlot bdslot)
void FmoveLow(Register dst_low, FPURegister src)
void Push(Register src, Condition cond, Register tst1, Register tst2)
void BindExceptionHandler(Label *label)
void ExtMulHigh(MSADataType type, MSARegister dst, MSARegister src1, MSARegister src2)
void LoadRoot(Register destination, RootIndex index) final
void Trunc_d_d(FPURegister fd, FPURegister fs)
void BranchShortMSA(MSABranchDF df, Label *target, MSABranchCondition cond, MSARegister wt, BranchDelaySlot bd=PROTECT)
void LoadLane(MSASize sz, MSARegister dst, uint8_t laneidx, MemOperand src)
void PushRoot(RootIndex index)
void Popcnt(Register rd, Register rs)
void Pop(Register src1, Register src2)
void PrepareCEntryArgs(int num_args)
void Float64MinOutOfLine(FPURegister dst, FPURegister src1, FPURegister src2)
void InvokeFunction(Register function, Register expected_parameter_count, Register actual_parameter_count, InvokeType type)
void Floor_d_d(FPURegister fd, FPURegister fs)
void TruncateDoubleToI(Isolate *isolate, Zone *zone, Register result, DoubleRegister double_input, StubCallMode stub_mode)
void Float32MinOutOfLine(FPURegister dst, FPURegister src1, FPURegister src2)
void Trunc_uw_d(FPURegister fd, FPURegister fs, FPURegister scratch)
void Ceil_w_d(FPURegister fd, FPURegister fs)
void Float32Min(FPURegister dst, FPURegister src1, FPURegister src2, Label *out_of_line)
void Round_s_s(FPURegister fd, FPURegister fs)
void PushArray(Register array, Register size, Register scratch, Register scratch2, PushArrayOrder order=kNormal)
void DecrementCounter(StatsCounter *counter, int value, Register scratch1, Register scratch2)
void Ext(Register rt, Register rs, uint16_t pos, uint16_t size)
void MSARoundD(MSARegister dst, MSARegister src, FPURoundingMode mode)
void Call(Handle< Code > code, RelocInfo::Mode rmode=RelocInfo::CODE_TARGET, COND_ARGS)
void LoadZeroIfConditionNotZero(Register dest, Register condition)
void Dlsa(Register rd, Register rs, Register rt, uint8_t sa, Register scratch=at)
void EmitDecrementCounter(StatsCounter *counter, int value, Register scratch1, Register scratch2)
void LoadFromConstantsTable(Register destination, int constant_index) final
void SmiUntag(Register reg)
MemOperand EntryFromBuiltinAsOperand(Builtin builtin)
void Sdc1(FPURegister fs, const MemOperand &dst)
void AssertNotSmi(Register object) NOOP_UNLESS_DEBUG_CODE
void PrepareCEntryFunction(const ExternalReference &ref)
void ComputeCodeStartAddress(Register dst)
void MaybeSaveRegisters(RegList registers)
void Ins(Register rt, Register rs, uint16_t pos, uint16_t size)
void AllocateStackSpace(int bytes)
DISALLOW_IMPLICIT_CONSTRUCTORS(MacroAssembler)
void ExtAddPairwise(MSADataType type, MSARegister dst, MSARegister src)
void LoadWordPair(Register rd, const MemOperand &rs, Register scratch=at)
void Lld(Register rd, const MemOperand &rs)
void Jump(Handle< Code > code, RelocInfo::Mode rmode, COND_ARGS)
void SmiTst(Register value, Register scratch)
void SmiToInt32(Register smi)
void JumpJSFunction(Register function_object, JumpMode jump_mode=JumpMode::kJump)
void SbxCheck(Condition cc, AbortReason reason, Register rj, Operand rk)
void Lw(Register rd, const MemOperand &rs)
void Madd_s(FPURegister fd, FPURegister fr, FPURegister fs, FPURegister ft, FPURegister scratch)
void BranchShortHelperR6(int32_t offset, Label *L)
void AssertConstructor(Register object) NOOP_UNLESS_DEBUG_CODE
bool BranchShortCheck(int32_t offset, Label *L, Condition cond, Register rs, const Operand &rt, BranchDelaySlot bdslot)
void CallRuntime(const Runtime::Function *f, int num_arguments)
void LoadWeakValue(Register out, Register in, Label *target_if_cleared)
void ByteSwapUnsigned(Register dest, Register src, int operand_size)
void Lh(Register rd, const MemOperand &rs)
void Usdc1(FPURegister fd, const MemOperand &rs, Register scratch)
void EnterFrame(StackFrame::Type type, bool load_constant_pool_pointer_reg)
void Assert(Condition cc, AbortReason reason, Register rs, Operand rt) NOOP_UNLESS_DEBUG_CODE
void FPUCanonicalizeNaN(const DoubleRegister dst, const DoubleRegister src)
void GenerateTailCallToReturnedCode(Runtime::FunctionId function_id)
void Madd_d(FPURegister fd, FPURegister fr, FPURegister fs, FPURegister ft, FPURegister scratch)
void AssertJSAny(Register object, Register map_tmp, Register tmp, AbortReason abort_reason) NOOP_UNLESS_DEBUG_CODE
void Push(Tagged< Smi > smi)
void Cvt_d_uw(FPURegister fd, FPURegister fs)
void Float32MaxOutOfLine(FPURegister dst, FPURegister src1, FPURegister src2)
void Float32Max(FPURegister dst, FPURegister src1, FPURegister src2, Label *out_of_line)
void AssertFeedbackCell(Register object, Register scratch) NOOP_UNLESS_DEBUG_CODE
void CallForDeoptimization(Builtin target, int deopt_id, Label *exit, DeoptimizeKind kind, Label *ret, Label *jump_deoptimization_entry_label)
void Sc(Register rd, const MemOperand &rs)
void Bovc(Register rt, Register rs, Label *L)
void DropArgumentsAndPushNewReceiver(Register argc, Register receiver)
void CompareIsNanF64(FPURegister cmp1, FPURegister cmp2)
void MSARoundW(MSARegister dst, MSARegister src, FPURoundingMode mode)
void AllocateStackSpace(Register bytes)
void LoadEntryFromBuiltinIndex(Register builtin_index, Register target)
void JumpIfLessThan(Register a, int32_t b, Label *dest)
void Move(Register output, MemOperand operand)
void Dpopcnt(Register rd, Register rs)
void Ll(Register rd, const MemOperand &rs)
void Ulwc1(FPURegister fd, const MemOperand &rs, Register scratch)
void Round_l_d(FPURegister fd, FPURegister fs)
void DMulOverflow(Register dst, Register left, const Operand &right, Register overflow)
void Push(Register src1, Register src2, Register src3, Register src4)
void Jump(Address target, RelocInfo::Mode rmode, COND_ARGS)
void AssertBoundFunction(Register object) NOOP_UNLESS_DEBUG_CODE
void LoadAddress(Register dst, Label *target)
void StoreWordPair(Register rd, const MemOperand &rs, Register scratch=at)
void Trunc_ul_d(FPURegister fd, FPURegister fs, FPURegister scratch, Register result=no_reg)
void Sb(Register rd, const MemOperand &rs)
void SmiTag(Register reg)
void Ld(Register rd, const MemOperand &rs)
void Ceil_s_s(FPURegister fd, FPURegister fs)
void GetInstanceTypeRange(Register map, Register type_reg, InstanceType lower_limit, Register range)
void Movn(Register rd, Register rs, Register rt)
void OptimizeCodeOrTailCallOptimizedCodeSlot(Register flags, Register feedback_vector)
void Movf(Register rd, Register rs, uint16_t cc=0)
void LoadIsolateField(Register dst, IsolateFieldId id)
void LoadRoot(Register destination, RootIndex index, Condition cond, Register src1, const Operand &src2)
void Trunc_uw_d(Register rd, FPURegister fs, FPURegister scratch)
void JumpIfSmi(Register value, Label *smi_label, BranchDelaySlot bd=PROTECT)
void Move_s(FPURegister dst, FPURegister src)
void ByteSwapSigned(Register dest, Register src, int operand_size)
void MaybeRestoreRegisters(RegList registers)
void CallRecordWriteStub(Register object, Register slot_address, SaveFPRegsMode fp_mode, StubCallMode mode=StubCallMode::kCallBuiltinPointer)
void Floor_s_s(FPURegister fd, FPURegister fs)
void PrepareCallCFunction(int num_reg_arguments, int num_double_registers, Register scratch)
void Dclz(Register rd, Register rs)
void BranchAndLinkShortHelperR6(int32_t offset, Label *L)
void Dctz(Register rd, Register rs)
int PopCallerSaved(SaveFPRegsMode fp_mode, Register exclusion1=no_reg, Register exclusion2=no_reg, Register exclusion3=no_reg)
void AssertUndefinedOrAllocationSite(Register object, Register scratch) NOOP_UNLESS_DEBUG_CODE
void CompareF(SecondaryField sizeField, FPUCondition cc, FPURegister cmp1, FPURegister cmp2)
void Pref(int32_t hint, const MemOperand &rs)
void Round_w_d(FPURegister fd, FPURegister fs)
void BranchMSA(Label *target, MSABranchDF df, MSABranchCondition cond, MSARegister wt, BranchDelaySlot bd=PROTECT)
void DsubOverflow(Register dst, Register left, const Operand &right, Register overflow)
void StubPrologue(StackFrame::Type type)
void Trunc_uw_s(Register rd, FPURegister fs, FPURegister scratch)
void StoreLane(MSASize sz, MSARegister src, uint8_t laneidx, MemOperand dst)
void StoreRootRelative(int32_t offset, Register value) final
void Move(FPURegister dst, uint32_t src)
void Push(Register src1, Register src2)
void LoadMap(Register destination, Register object)
void SmiUntag(Register dst, const MemOperand &src)
void AssertStackIsAligned() NOOP_UNLESS_DEBUG_CODE
void TailCallRuntime(Runtime::FunctionId fid)
void ExtMulLow(MSADataType type, MSARegister dst, MSARegister src1, MSARegister src2)
void BranchFalseShortF(Label *target, BranchDelaySlot bd=PROTECT)
void CallRuntime(Runtime::FunctionId fid, int num_arguments)
void Dext(Register rt, Register rs, uint16_t pos, uint16_t size)
void LoadNativeContextSlot(Register dst, int index)
void CallRecordWriteStubSaveRegisters(Register object, Register slot_address, SaveFPRegsMode fp_mode, StubCallMode mode=StubCallMode::kCallBuiltinPointer)
void TryInlineTruncateDoubleToI(Register result, DoubleRegister input, Label *done)
bool BranchAndLinkShortHelperR6(int32_t offset, Label *L, Condition cond, Register rs, const Operand &rt)
void Floor_w_d(FPURegister fd, FPURegister fs)
void Move(Register dst_low, Register dst_high, FPURegister src)
void Ldc1(FPURegister fd, const MemOperand &src)
void CheckPageFlag(Register object, Register scratch, int mask, Condition cc, Label *condition_met)
void JumpCodeObject(Register code_data_container_object, CodeEntrypointTag tag, JumpMode jump_mode=JumpMode::kJump)
void DropArguments(Register count)
void AssertCallableFunction(Register object) NOOP_UNLESS_DEBUG_CODE
void LoadCodeInstructionStart(Register destination, Register code_data_container_object, CodeEntrypointTag tag)
void SmiScale(Register dst, Register src, int scale)
void Ush(Register rd, const MemOperand &rs, Register scratch)
#define NOOP_UNLESS_DEBUG_CODE
static const ArchVariants kArchVariant
DirectHandle< Object > new_target
ZoneVector< RpoNumber > & result
#define DEFINE_INSTRUCTION2(instr)
#define DEFINE_INSTRUCTION(instr)
#define DECLARE_BRANCH_PROTOTYPES(Name)
RegListBase< RegisterT > registers
InstructionOperand destination
constexpr Register no_reg
V8_INLINE IndirectHandle< T > handle(Tagged< T > object, Isolate *isolate)
constexpr Register kRootRegister
constexpr int kPointerSizeLog2
MemOperand ExitFrameCallerStackSlotOperand(int index)
RegListBase< Register > RegList
constexpr int kPointerSize
MemOperand FieldMemOperand(Register object, int offset)
constexpr int kSystemPointerSize
MemOperand CFunctionArgumentOperand(int index)
constexpr bool SmiValuesAre31Bits()
const int kCArgsSlotsSize
V8_EXPORT_PRIVATE FlagValues v8_flags
constexpr bool SmiValuesAre32Bits()
const intptr_t kSmiTagMask
void CallApiFunctionAndReturn(MacroAssembler *masm, bool with_profiling, Register function_address, ExternalReference thunk_ref, Register thunk_arg, int slots_to_drop_on_return, MemOperand *argc_operand, MemOperand return_value_operand)
constexpr uint8_t kInstrSize
Register GetRegisterThatIsNotOneOf(Register reg1, Register reg2=no_reg, Register reg3=no_reg, Register reg4=no_reg, Register reg5=no_reg, Register reg6=no_reg)
MemOperand ExitFrameStackSlotOperand(int offset)
#define DCHECK_GE(v1, v2)
#define DCHECK(condition)
#define DCHECK_GT(v1, v2)
#define V8_EXPORT_PRIVATE
std::optional< CPURegister > scratch_reg
std::optional< UseScratchRegisterScope > temps