Skip declaration emit without a prior signature - #4726
Draft
Jake Bailey (jakebailey) wants to merge 2 commits into
Draft
Skip declaration emit without a prior signature#4726Jake Bailey (jakebailey) wants to merge 2 commits into
Jake Bailey (jakebailey) wants to merge 2 commits into
Conversation
Cover an incremental noEmit build where a change propagates through a re-export and its importer after source versions were stored as signatures.
When an unchanged importer has signature == version, there is no previous declaration signature available for comparison. Computing one may allow propagation to stop, but requires declaration emit. Skip that refinement and conservatively continue through the importer graph instead.
Contributor
There was a problem hiding this comment.
Pull request overview
Optimizes incremental builds by avoiding unnecessary declaration-signature emission when no prior declaration signature exists.
Changes:
- Conservatively propagates affected files without computing missing declaration signatures.
- Adds re-export propagation coverage.
- Updates incremental, no-emit, build, and watch baselines.
Reviewed changes
Copilot reviewed 13 out of 13 changed files in this pull request and generated no comments.
Show a summary per file
| File | Description |
|---|---|
internal/execute/incremental/affectedfileshandler.go |
Skips unnecessary declaration-signature computation. |
internal/execute/tsctests/tsc_test.go |
Adds re-export propagation scenario. |
testdata/baselines/reference/tsc/incremental/incremental-signature-propagation-through-reexports.js |
Records the new scenario. |
testdata/baselines/reference/tsc/incremental/const-enums.js |
Updates const-enum incremental output. |
testdata/baselines/reference/tsc/incremental/const-enums-aliased.js |
Updates aliased const-enum output. |
testdata/baselines/reference/tsc/incremental/const-enums-aliased-in-different-file.js |
Updates cross-file alias output. |
testdata/baselines/reference/tsc/incremental/change-to-modifier-of-class-expression-field.js |
Updates class-expression incremental output. |
testdata/baselines/reference/tsc/noEmit/changes-incremental.js |
Updates no-emit incremental state. |
testdata/baselines/reference/tsc/noEmit/changes-with-initial-noEmit-incremental.js |
Updates initial no-emit state. |
testdata/baselines/reference/tsbuild/noEmit/changes-incremental.js |
Updates build-mode no-emit output. |
testdata/baselines/reference/tsbuild/noEmit/changes-with-initial-noEmit-incremental.js |
Updates initial build-mode no-emit output. |
testdata/baselines/reference/tscWatch/commandLineWatch/watch-handles-file-rapidly-recreated.js |
Removes redundant watch signature computation. |
testdata/baselines/reference/tscWatch/commandLineWatch/watch-detects-change-in-symlinked-node_modules-file.js |
Updates symlink watch signature behavior. |
💡 Add a code-review agent skill for context-aware, tailored reviews. Learn more in the docs.
Member
Author
|
TypeScript Bot (@typescript-bot) perf test this |
|
Jake Bailey (@jakebailey) Here they are:
tscComparison Report - baseline..pr
System info unknown
Hosts
Scenarios
lspComparison Report - baseline..pr
System info unknown
Hosts
Scenarios
startupComparison Report - baseline..pr
System info unknown
Hosts
Scenarios
Developer Information: |
||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
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.
WIP