New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
LibJS: Emit bytecode for function declaration instantiation #24272
Merged
awesomekling
merged 5 commits into
SerenityOS:master
from
kalenikaliaksandr:fdi-bytecode
May 11, 2024
Merged
LibJS: Emit bytecode for function declaration instantiation #24272
awesomekling
merged 5 commits into
SerenityOS:master
from
kalenikaliaksandr:fdi-bytecode
May 11, 2024
Conversation
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
github-actions
bot
added
👀 pr-needs-review
PR needs review from a maintainer or community member
and removed
👀 pr-needs-review
PR needs review from a maintainer or community member
labels
May 9, 2024
kalenikaliaksandr
force-pushed
the
fdi-bytecode
branch
3 times, most recently
from
May 10, 2024 17:27
a769892
to
7fe07b3
Compare
github-actions
bot
added
the
👀 pr-needs-review
PR needs review from a maintainer or community member
label
May 10, 2024
kalenikaliaksandr
force-pushed
the
fdi-bytecode
branch
2 times, most recently
from
May 10, 2024 18:14
1810cc2
to
9d285a8
Compare
github-actions
bot
removed
the
👀 pr-needs-review
PR needs review from a maintainer or community member
label
May 10, 2024
github-actions
bot
added
the
👀 pr-needs-review
PR needs review from a maintainer or community member
label
May 10, 2024
Benchmark results are mostly not affected by this change, but it moves us closer to some more useful Call optimizations by fixing following things:
|
kalenikaliaksandr
force-pushed
the
fdi-bytecode
branch
from
May 10, 2024 22:46
9d285a8
to
54e6264
Compare
Preparation for upcoming function where binding pattern will have to be used outside of ASTCodegen.cpp
Preparation for upcoming changes where NewFunction will have to be used with FunctionDeclaration node.
kalenikaliaksandr
force-pushed
the
fdi-bytecode
branch
from
May 11, 2024 02:06
54e6264
to
7aa8514
Compare
By doing that all instructions required for instantiation are emitted once in compilation and then reused for subsequent calls, instead of running generic instantiation process for each call.
If the minimal amount of required bindings is known in advance, it could be used to ensure capacity to avoid resizing the internal vector that holds bindings.
This function was used for function params initialization but no longer used after it got replaced by emitting bytecode.
github-actions
bot
removed
the
👀 pr-needs-review
PR needs review from a maintainer or community member
label
May 11, 2024
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
By doing that all instructions required for instantiation are emitted once in compilation and then reused for subsequent calls, instead of running generic instantiation process for each call.