зеркало из https://github.com/github/ruby.git
YJIT: add jb (unsigned less-than) instruction to backend (#8168)
This commit is contained in:
Родитель
98b4256aa7
Коммит
4f99240b2e
|
@ -1085,6 +1085,9 @@ impl Assembler
|
|||
Insn::Jbe(target) => {
|
||||
emit_conditional_jump::<{Condition::LS}>(cb, compile_side_exit(*target, self, ocb));
|
||||
},
|
||||
Insn::Jb(target) => {
|
||||
emit_conditional_jump::<{Condition::CC}>(cb, compile_side_exit(*target, self, ocb));
|
||||
},
|
||||
Insn::Jo(target) => {
|
||||
emit_conditional_jump::<{Condition::VS}>(cb, compile_side_exit(*target, self, ocb));
|
||||
},
|
||||
|
|
|
@ -423,9 +423,12 @@ pub enum Insn {
|
|||
// Produces no output
|
||||
IncrCounter { mem: Opnd, value: Opnd },
|
||||
|
||||
/// Jump if below or equal
|
||||
/// Jump if below or equal (unsigned)
|
||||
Jbe(Target),
|
||||
|
||||
/// Jump if below (unsigned)
|
||||
Jb(Target),
|
||||
|
||||
/// Jump if equal
|
||||
Je(Target),
|
||||
|
||||
|
@ -579,6 +582,7 @@ impl Insn {
|
|||
Insn::FrameTeardown => "FrameTeardown",
|
||||
Insn::IncrCounter { .. } => "IncrCounter",
|
||||
Insn::Jbe(_) => "Jbe",
|
||||
Insn::Jb(_) => "Jb",
|
||||
Insn::Je(_) => "Je",
|
||||
Insn::Jl(_) => "Jl",
|
||||
Insn::Jg(_) => "Jg",
|
||||
|
@ -727,6 +731,7 @@ impl<'a> Iterator for InsnOpndIterator<'a> {
|
|||
Insn::FrameSetup |
|
||||
Insn::FrameTeardown |
|
||||
Insn::Jbe(_) |
|
||||
Insn::Jb(_) |
|
||||
Insn::Je(_) |
|
||||
Insn::Jl(_) |
|
||||
Insn::Jg(_) |
|
||||
|
@ -825,6 +830,7 @@ impl<'a> InsnOpndMutIterator<'a> {
|
|||
Insn::FrameSetup |
|
||||
Insn::FrameTeardown |
|
||||
Insn::Jbe(_) |
|
||||
Insn::Jb(_) |
|
||||
Insn::Je(_) |
|
||||
Insn::Jl(_) |
|
||||
Insn::Jg(_) |
|
||||
|
|
|
@ -709,6 +709,14 @@ impl Assembler
|
|||
}
|
||||
},
|
||||
|
||||
Insn::Jb(target) => {
|
||||
match compile_side_exit(*target, self, ocb) {
|
||||
Target::CodePtr(code_ptr) | Target::SideExitPtr(code_ptr) => jb_ptr(cb, code_ptr),
|
||||
Target::Label(label_idx) => jb_label(cb, label_idx),
|
||||
Target::SideExit { .. } => unreachable!("Target::SideExit should have been compiled by compile_side_exit"),
|
||||
}
|
||||
},
|
||||
|
||||
Insn::Jz(target) => {
|
||||
match compile_side_exit(*target, self, ocb) {
|
||||
Target::CodePtr(code_ptr) | Target::SideExitPtr(code_ptr) => jz_ptr(cb, code_ptr),
|
||||
|
|
Загрузка…
Ссылка в новой задаче