mirror of
https://github.com/RGBCube/serenity
synced 2025-07-25 16:17:45 +00:00
LibJS/JIT: Resolve the GetGlobal identifier at JIT time
This commit is contained in:
parent
c92954db36
commit
234ed2d466
4 changed files with 12 additions and 13 deletions
|
@ -952,7 +952,7 @@ void Compiler::compile_get_by_value(Bytecode::Op::GetByValue const& op)
|
|||
check_exception();
|
||||
}
|
||||
|
||||
static Value cxx_get_global(VM& vm, Bytecode::IdentifierTableIndex identifier, u32 cache_index)
|
||||
static Value cxx_get_global(VM& vm, DeprecatedFlyString const& identifier, u32 cache_index)
|
||||
{
|
||||
return TRY_OR_SET_EXCEPTION(Bytecode::get_global(vm.bytecode_interpreter(), identifier, cache_index));
|
||||
}
|
||||
|
@ -961,7 +961,7 @@ void Compiler::compile_get_global(Bytecode::Op::GetGlobal const& op)
|
|||
{
|
||||
m_assembler.mov(
|
||||
Assembler::Operand::Register(ARG1),
|
||||
Assembler::Operand::Imm(op.identifier().value()));
|
||||
Assembler::Operand::Imm(bit_cast<u64>(&m_bytecode_executable.get_identifier(op.identifier()))));
|
||||
m_assembler.mov(
|
||||
Assembler::Operand::Register(ARG2),
|
||||
Assembler::Operand::Imm(op.cache_index()));
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue