-
Notifications
You must be signed in to change notification settings - Fork 5.4k
New issue
Have a question about this project? # for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “#”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? # to your account
Implement Typed Module Caching #6280
Merged
Merged
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
06b2e51
to
1ea636b
Compare
Benchmark for 03149bfClick to view benchmark
|
Benchmark for 10fc3e6Click to view benchmark
|
Benchmark for 6c45d0aClick to view benchmark
|
Benchmark for 3878468Click to view benchmark
|
Benchmark for efbe942Click to view benchmark
|
Benchmark for 2c7ca9cClick to view benchmark
|
f45e23d
to
d4bff74
Compare
Benchmark for ff415ccClick to view benchmark
|
Benchmark for bf7b59aClick to view benchmark
|
tritao
previously approved these changes
Aug 2, 2024
IGI-111
previously approved these changes
Aug 5, 2024
Benchmark for 6cc2233Click to view benchmark
|
sdankel
previously approved these changes
Aug 5, 2024
6676c7f
sdankel
approved these changes
Aug 15, 2024
Voxelot
approved these changes
Aug 15, 2024
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
approving since @tritao already approved, it just got invalidated due to syncing the master branch
Benchmark for b1e5e80Click to view benchmark
|
# for free
to join this conversation on GitHub.
Already have an account?
# to comment
Labels
compiler: frontend
Everything to do with type checking, control flow analysis, and everything between parsing and IRgen
language server
LSP server
performance
Everything related to performance, speed wise or memory wise.
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.
Description
This PR implements a typed module caching system for the compiler when interacted with from the language server. The main goal is to improve performance by caching typed modules and reusing them when possible, reducing unnecessary recompilation.
Key Changes
CowCache
for efficient, thread-safe caching with copy-on-write semanticsQueryEngine
ServerState
andSession
to utilize the new caching systemPerformance Improvements
These changes show promising performance improvements in processing didChange events, particularly for larger projects. Here are some benchmarks using the FUSD libraries Sway project (19 Sway files):
These improvements should lead to a more responsive development experience, especially when making frequent small changes.
closes #6228
improves: FuelLabs/sway-vscode-plugin#172
Checklist
Breaking*
orNew Feature
labels where relevant.