mirror of
https://github.com/ruby/ruby.git
synced 2025-08-25 22:14:37 +02:00
Implement optimized send
This commit is contained in:
parent
2603d7a0b7
commit
2cc4f506ba
Notes:
git
2023-03-06 07:29:57 +00:00
9 changed files with 247 additions and 73 deletions
|
@ -63,15 +63,15 @@ module RubyVM::MJIT
|
|||
# @param jit [RubyVM::MJIT::JITState]
|
||||
# @param ctx [RubyVM::MJIT::Context]
|
||||
# @param asm [RubyVM::MJIT::Assembler]
|
||||
def compile_side_exit(jit, ctx, asm)
|
||||
def compile_side_exit(pc, ctx, asm)
|
||||
# Increment per-insn exit counter
|
||||
incr_insn_exit(jit.pc, asm)
|
||||
incr_insn_exit(pc, asm)
|
||||
|
||||
# Fix pc/sp offsets for the interpreter
|
||||
save_pc_and_sp(jit.pc, ctx.dup, asm) # dup to avoid sp_offset update
|
||||
save_pc_and_sp(pc, ctx.dup, asm) # dup to avoid sp_offset update
|
||||
|
||||
# Restore callee-saved registers
|
||||
asm.comment("exit to interpreter on #{pc_to_insn(jit.pc).name}")
|
||||
asm.comment("exit to interpreter on #{pc_to_insn(pc).name}")
|
||||
asm.pop(SP)
|
||||
asm.pop(EC)
|
||||
asm.pop(CFP)
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue