1
Fork 0
mirror of https://github.com/RGBCube/serenity synced 2025-07-26 20:57:44 +00:00

LibJS/JIT: Add fast path for JumpConditional where accumulator is Int32

This commit is contained in:
Andreas Kling 2023-11-26 15:33:51 +01:00
parent cb46a7fd65
commit b2a1f39400
2 changed files with 35 additions and 56 deletions

View file

@ -168,7 +168,6 @@ private:
void load_accumulator(Assembler::Reg);
void store_accumulator(Assembler::Reg);
void compile_to_boolean(Assembler::Reg dst, Assembler::Reg src);
void compile_continuation(Optional<Bytecode::Label>, bool is_await);
template<typename Codegen>
@ -193,6 +192,12 @@ private:
branch_if_type(reg, INT32_TAG, codegen);
}
template<typename Codegen>
void branch_if_boolean(Assembler::Reg reg, Codegen codegen)
{
branch_if_type(reg, BOOLEAN_TAG, codegen);
}
template<typename Codegen>
void branch_if_object(Assembler::Reg reg, Codegen codegen)
{