mirror of
https://github.com/RGBCube/serenity
synced 2025-07-26 19:57:45 +00:00
LibJS/JIT: Add fast path for Add Int32, Int32
This uses the 32-bit registers to perform the addition and bail if the overflow flag (OF) is set.
This commit is contained in:
parent
4b23a7dfb4
commit
4f3945024a
3 changed files with 74 additions and 1 deletions
|
@ -57,7 +57,6 @@ private:
|
|||
void compile_resolve_this_binding(Bytecode::Op::ResolveThisBinding const&);
|
||||
|
||||
# define JS_ENUMERATE_COMMON_BINARY_OPS_WITHOUT_FAST_PATH(O) \
|
||||
O(Add, add) \
|
||||
O(Sub, sub) \
|
||||
O(Mul, mul) \
|
||||
O(Div, div) \
|
||||
|
@ -91,6 +90,7 @@ private:
|
|||
JS_ENUMERATE_COMMON_UNARY_OPS(DO_COMPILE_COMMON_UNARY_OP)
|
||||
# undef DO_COMPILE_COMMON_UNARY_OP
|
||||
|
||||
void compile_add(Bytecode::Op::Add const&);
|
||||
void compile_less_than(Bytecode::Op::LessThan const&);
|
||||
|
||||
void compile_return(Bytecode::Op::Return const&);
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue