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

LSP Optimization: Remove ParseResult and write to session types directly #5516

Merged
merged 3 commits into from
Jan 25, 2024

Conversation

JoshuaBatty
Copy link
Member

@JoshuaBatty JoshuaBatty commented Jan 25, 2024

Description

We no longer write TokenMap or Metrics into an intermediate copy and then back to the original in write_parse_result. Instead, we write to them directly during traversal if the compilation was successful.

related to #5445

Metric Before After Change (%)
traverse & write 122.018ms 74.353ms -39.07%

Checklist

  • I have linked to any relevant issues.
  • I have commented my code, particularly in hard-to-understand areas.
  • I have updated the documentation where relevant (API docs, the reference, and the Sway book).
  • I have added tests that prove my fix is effective or that my feature works.
  • I have added (or requested a maintainer to add) the necessary Breaking* or New Feature labels where relevant.
  • I have done my best to ensure that my PR adheres to the Fuel Labs Code Review Standards.
  • I have requested a review from the relevant team or maintainers.

@JoshuaBatty JoshuaBatty marked this pull request as draft January 25, 2024 01:45
@JoshuaBatty JoshuaBatty self-assigned this Jan 25, 2024
@JoshuaBatty JoshuaBatty added the language server LSP server label Jan 25, 2024
@JoshuaBatty JoshuaBatty changed the title Remove ParseResult and write to session types directly LSP Optimization: Remove ParseResult and write to session types directly Jan 25, 2024
@JoshuaBatty JoshuaBatty marked this pull request as ready for review January 25, 2024 02:57
@JoshuaBatty JoshuaBatty requested review from a team January 25, 2024 02:57
@JoshuaBatty JoshuaBatty enabled auto-merge (squash) January 25, 2024 04:34
@JoshuaBatty JoshuaBatty merged commit d06f3b4 into master Jan 25, 2024
33 checks passed
@JoshuaBatty JoshuaBatty deleted the josh/optimize_writes branch January 25, 2024 12:55
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants