-
-
Notifications
You must be signed in to change notification settings - Fork 268
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
DocumentStore refactor #702
DocumentStore refactor #702
Conversation
This seems to have broken completion of Completion will show public decls from |
good catch! this is fixed now |
There is a significant performance hit associated with these changes. TLDR: ReleaseSafe 73x longer to reach first Process:
Results:
I know this is only the initial hit when fist opening a project, but 33 seconds and a gig of ram is alot. |
I didn't expect the performance penalty to be this bad. I will just continue to work on returning to "load on demand" when i have the time and then this could be merged. |
The memory consumption and runtime should now be close to master. |
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.
Looks good. 👍
Previously DocumentStore used a reference counting like approach for cleaning up unused document. This approach is unfitting because of cyclic dependencies.
As an example if
A.zig
importsB.zig
andB.zig
importsA.zig
they will never be closed.This new approach should collect all unneeded documents for cleanup.
CImports also received some care and are now managed globally instead of per document.