-
Notifications
You must be signed in to change notification settings - Fork 172
Simple LRU garbage collection for interned values #839
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
base: master
Are you sure you want to change the base?
Conversation
✅ Deploy Preview for salsa-rs canceled.
|
CodSpeed Performance ReportMerging #839 will not alter performanceComparing Summary
|
b500f7e
to
b54e365
Compare
Interesting. I suspect this is new but I'm investigating a similar issue related to interned in cycles |
That makes me wonder if your PR might help to come up with simpler repros for the fixpoint issues that we're seeing. I should give this a try tomorrow. On the perf side. You could try using the |
I quickly tried the branch in Red Knot but I also got new panics that we didn't see before. That makes me suspect that some revision tracking might be off in this PR? What I like to do to debug those issues is to compare the tracing output and see where things go different |
I think the issue is unrelated to durabilities but about interned query arguments. If a query takes an interned struct as an argument then an older memo may be incorrectly verified after the slot has been reused, but the IDs still match. I think we have to check that the memo and first_interned_at revisions match to avoid this, but I'm not exactly sure where that would be. |
I think I understand. What you're saying is that I think will need something similar to what we have in tracked structs where salsa informs other ingredients that the memo was collected so that they can free resources as well if necessary: The second part in tracked struct that protects against this is that we separately track |
fb0472d
to
073a988
Compare
Basic implementation of #597.
The garbage collection strategy used here is very simple.
I'm concerned about a few things, so leaving this as a draft for now.
Data was not interned in the latest revision for its durability
. I'm not sure exactly why this is happening, but I suspect it's related to durabilities.