JS: Add compileForOverlayEval: true - #20421
Merged
Merged
Conversation
asgerf
force-pushed
the
js/compile-for-overlay-eval
branch
from
September 12, 2025 07:52
4f55fcb to
33001a7
Compare
asgerf
marked this pull request as ready for review
September 12, 2025 11:27
Contributor
There was a problem hiding this comment.
Pull Request Overview
Enables the compileForOverlayEval: true configuration in the JavaScript CodeQL library and optimizes token navigation by introducing a helper predicate to improve join ordering performance.
- Adds
compileForOverlayEval: trueto the qlpack.yml configuration - Introduces
adjacentTokenshelper predicate to optimize join order in token navigation - Refactors
getNextToken()method to use the new helper predicate
Reviewed Changes
Copilot reviewed 2 out of 2 changed files in this pull request and generated no comments.
| File | Description |
|---|---|
| javascript/ql/lib/qlpack.yml | Enables compileForOverlayEval configuration option |
| javascript/ql/lib/semmle/javascript/Tokens.qll | Adds adjacentTokens helper predicate and refactors getNextToken for better performance |
Napalys
previously approved these changes
Sep 15, 2025
asgerf
marked this pull request as draft
September 18, 2025 19:26
asgerf
force-pushed
the
js/compile-for-overlay-eval
branch
from
October 22, 2025 09:49
33001a7 to
f4b798b
Compare
asgerf
marked this pull request as ready for review
October 27, 2025 10:12
asgerf
marked this pull request as draft
October 27, 2025 12:31
asgerf
force-pushed
the
js/compile-for-overlay-eval
branch
from
October 27, 2025 12:32
80475a6 to
fdb6dd3
Compare
asgerf
marked this pull request as ready for review
October 30, 2025 09:11
tausbn
previously approved these changes
Oct 30, 2025
tausbn
left a comment
Contributor
There was a problem hiding this comment.
One minor comment, otherwise this looks good to me. 👍
|
|
||
| import javascript | ||
|
|
||
| private predicate adjacentTokens(Token token1, Token token2) { |
Contributor
There was a problem hiding this comment.
No pragma[nomagic] on this to prevent future reinlining?
Contributor
Author
There was a problem hiding this comment.
Added pragma[nomagic]. The DIL seems to be unchanged so we shouldn't have to rerun the evaluations.
tausbn
approved these changes
Oct 30, 2025
asgerf
force-pushed
the
js/compile-for-overlay-eval
branch
from
October 30, 2025 14:31
120dcd3 to
c583b48
Compare
This file contains hidden or 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
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.
Adds
compileForOverlayEval: trueand fixes a bad join order arising when this is enabled.Evaluations: