Skip to content
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

[Tracking] Reduce LSP Memory Footprint #6226

Open
1 of 8 tasks
JoshuaBatty opened this issue Jul 5, 2024 · 1 comment
Open
1 of 8 tasks

[Tracking] Reduce LSP Memory Footprint #6226

JoshuaBatty opened this issue Jul 5, 2024 · 1 comment
Assignees
Labels

Comments

@JoshuaBatty JoshuaBatty self-assigned this Jul 5, 2024
@JoshuaBatty JoshuaBatty added the language server LSP server label Jul 5, 2024
@JoshuaBatty JoshuaBatty changed the title Reduce LSP Memory Footprint: Tracking issue. [Tracking] Reduce LSP Memory Footprint Jul 5, 2024
@tritao
Copy link
Contributor

tritao commented Jul 26, 2024

Might be interesting to look into https://docs.rs/cstree/latest/cstree/, which implements some of the syntax tree design approaches initially presented by Roslyn (C# compiler) and Swift libsyntax.

Specifically:

cstree trees are trees over interned strings. This means cstree will deduplicate the text of tokens with the same source string, such as identifiers with the same name. In this position, rowan stores each token’s text together with its metadata as a custom DST (dynamically-sized type).

It would allow us to better intern and re-use parts of our syntax tree nodes.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

No branches or pull requests

2 participants