Skip to content

Internal reactor queue blocks further type-checking of currently type-checked file #10211

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

Closed
11 tasks done
TIHan opened this issue Oct 2, 2020 · 3 comments
Closed
11 tasks done

Comments

@TIHan
Copy link
Contributor

TIHan commented Oct 2, 2020

Whenever we save a file, incremental builder picks up on the file change and invalidates all files that depend on it, and potentially it will invalidate other incremental builds(projects). An IDE may request analysis on the files that depended on the one that was changed; this blocks the reactor queue from processing anything until all the requests for analyses have been finished. The result is that the tooling stops being functional in the file that you currently saved and are editing, even though the information exists.

As part of 10292 we will do all of these:

  • All of the FSharpCheckFileResults operations will no longer use the Reactor and hence no longer by async.
  • The four operations Get*UsesOfAllSymbolsIn* were only async to support cancellation. For clarity these will no no longer by async and instead accept an optional cancellation token
  • userOpName is removed from all the operations which are no longer async (it is there for async causality tracing)
  • StructuredDescriptionTextAsync and DescriptionTextAsync no longer used the Reactor thread. They are marked as obsolete, and instead synchronous StructuredDescriptionText and DescriptionText should be used
  • The caches scriptClosureCache and incrementalBuildersCache are now usable from any thread
  • The optional argument hasTextChangedSinceLastTypecheck is removed from FSharpChecker API as it no longer needed by Visual F# Tools since 2017 rewrite
  • The optional argument textSnapshotInfo is removed from FSharpChecker API as it only existed to pass back to hasTextChangedSinceLastTypecheck
@auduchinok
Copy link
Member

Seems to be related to #4537.

@TIHan TIHan added this to the 16.9 milestone Oct 21, 2020
@TIHan TIHan self-assigned this Oct 21, 2020
@dsyme
Copy link
Contributor

dsyme commented Oct 22, 2020

@auduchinok @saul I've added notes about the further work to remove the reliance on the reactor in #10292 , will also copy them over there. This leads to API changes in FCS, see the notes.

@auduchinok
Copy link
Member

@dsyme This is fantastic news, I'm looking forward to seeing how it works!

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

No branches or pull requests

4 participants