diff options
author | Takashi Kokubun <takashikkbn@gmail.com> | 2023-04-01 16:59:19 -0700 |
---|---|---|
committer | Takashi Kokubun <takashikkbn@gmail.com> | 2023-04-01 17:03:45 -0700 |
commit | cfea319772faeef1d3d0ff69916221c29b691ee0 (patch) | |
tree | f4c5a15628c63abd459f38ba864a7a122722d5d0 /lib/ruby_vm/rjit | |
parent | 0973b93e495bd39da5032747fbc5051bb226c1a9 (diff) | |
download | ruby-cfea319772faeef1d3d0ff69916221c29b691ee0.tar.gz |
RJIT: Migrate bmethod to jit_call_iseq
Diffstat (limited to 'lib/ruby_vm/rjit')
-rw-r--r-- | lib/ruby_vm/rjit/insn_compiler.rb | 26 |
1 files changed, 5 insertions, 21 deletions
diff --git a/lib/ruby_vm/rjit/insn_compiler.rb b/lib/ruby_vm/rjit/insn_compiler.rb index b8b286385a..c3e3a16282 100644 --- a/lib/ruby_vm/rjit/insn_compiler.rb +++ b/lib/ruby_vm/rjit/insn_compiler.rb @@ -4309,24 +4309,6 @@ module RubyVM::RJIT EndBlock end - # vm_call_iseq_setup (ISEQ only) - # @param jit [RubyVM::RJIT::JITState] - # @param ctx [RubyVM::RJIT::Context] - # @param asm [RubyVM::RJIT::Assembler] - def jit_call_iseq_setup(jit, ctx, asm, cme, calling, iseq, frame_type: nil, prev_ep: nil) - opt_pc = jit_callee_setup_arg(jit, ctx, asm, calling.flags, calling.argc, iseq) - if opt_pc == CantCompile - return CantCompile - end - - if calling.flags & C::VM_CALL_TAILCALL != 0 - # We don't support vm_call_iseq_setup_tailcall - asm.incr_counter(:send_tailcall) - return CantCompile - end - jit_call_iseq_setup_normal(jit, ctx, asm, cme, calling, iseq, opt_pc, frame_type:, prev_ep:) - end - # vm_call_iseq_setup_normal (vm_call_iseq_setup_2 -> vm_call_iseq_setup_normal) # @param jit [RubyVM::RJIT::JITState] # @param ctx [RubyVM::RJIT::Context] @@ -4683,9 +4665,11 @@ module RubyVM::RJIT return CantCompile end - frame_type = C::VM_FRAME_MAGIC_BLOCK | C::VM_FRAME_FLAG_BMETHOD | C::VM_FRAME_FLAG_LAMBDA - prev_ep = capture.ep - jit_call_iseq_setup(jit, ctx, asm, cme, calling, iseq, frame_type:, prev_ep:) + jit_call_iseq( + jit, ctx, asm, cme, calling, iseq, + frame_type: C::VM_FRAME_MAGIC_BLOCK | C::VM_FRAME_FLAG_BMETHOD | C::VM_FRAME_FLAG_LAMBDA, + prev_ep: capture.ep, + ) end # vm_call_alias |