mirror of
https://github.com/RGBCube/serenity
synced 2025-07-28 07:47:34 +00:00
LibJS: Call builtins directly in the bytecode interpreter
Allows the bytecode interpreter to call the builtins c++ implementation directly without making a javascript call just as the JIT. Kraken test speedups: imaging-gaussian-blur.js (1.5x) and audio-oscillator.js (1.2x)
This commit is contained in:
parent
ce6cd4f45f
commit
e335354b30
4 changed files with 46 additions and 3 deletions
|
@ -57,6 +57,11 @@ public:
|
|||
m_builtins[to_underlying(builtin)] = value;
|
||||
}
|
||||
|
||||
Value get_builtin_value(Bytecode::Builtin builtin)
|
||||
{
|
||||
return m_builtins[to_underlying(builtin)];
|
||||
}
|
||||
|
||||
static FlatPtr global_environment_offset() { return OFFSET_OF(Realm, m_global_environment); }
|
||||
static FlatPtr builtins_offset() { return OFFSET_OF(Realm, m_builtins); }
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue