Update yjit/src/codegen.rs
Co-authored-by: Takashi Kokubun <takashikkbn@gmail.com>
This commit is contained in:
parent
7943cb22f6
commit
c9ed59c2e2
@ -5399,10 +5399,8 @@ fn jit_rb_str_getbyte(
|
|||||||
let index = asm.stack_opnd(0);
|
let index = asm.stack_opnd(0);
|
||||||
let recv = asm.stack_opnd(1);
|
let recv = asm.stack_opnd(1);
|
||||||
|
|
||||||
let arg0_type = asm.ctx.get_opnd_type(index.into());
|
|
||||||
|
|
||||||
// rb_str_getbyte should be leaf if the index is a fixnum
|
// rb_str_getbyte should be leaf if the index is a fixnum
|
||||||
if arg0_type != Type::Fixnum {
|
if asm.ctx.get_opnd_type(index.into()) != Type::Fixnum {
|
||||||
// Raises when non-integers are passed in
|
// Raises when non-integers are passed in
|
||||||
jit_prepare_non_leaf_call(jit, asm);
|
jit_prepare_non_leaf_call(jit, asm);
|
||||||
}
|
}
|
||||||
|
Loading…
x
Reference in New Issue
Block a user