mirror of
https://github.com/ruby/ruby.git
synced 2025-08-27 15:06:10 +02:00
Fix invokebuiltin in Ruby MJIT
45fe7f7575/tool/ruby_vm/views/_mjit_compile_invokebuiltin.erb (L21)
has not been ported correctly.
This commit is contained in:
parent
3dd4e381fe
commit
96d29dff66
2 changed files with 11 additions and 4 deletions
|
@ -446,9 +446,10 @@ module RubyVM::MJIT
|
|||
def compile_invokebuiltin(f, insn, stack_size, sp_inc, body, operands)
|
||||
bf = C.RB_BUILTIN.new(operands[0])
|
||||
if bf.compiler > 0
|
||||
index = (insn.name == :invokebuiltin ? -1 : operands[1])
|
||||
C.fprintf(f, "{\n")
|
||||
C.fprintf(f, " VALUE val;\n")
|
||||
C.builtin_compiler(f, bf, operands[1], stack_size, body.builtin_inline_p)
|
||||
C.builtin_compiler(f, bf, index, stack_size, body.builtin_inline_p)
|
||||
C.fprintf(f, " stack[#{stack_size + sp_inc - 1}] = val;\n")
|
||||
C.fprintf(f, "}\n")
|
||||
return true
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue