-
Notifications
You must be signed in to change notification settings - Fork 4
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
garbage collection #20
Comments
@yegor256 I think I should probably begin working on this. I'll first implement the prototype that does only what you've outlined and then we'll need to discuss the larger context: how will GC (and |
@yegor256 Okay, now that I've started to implements the GC, we need some way to track arriving edges (aka parents). Since we don't currently have it, I'll have to implement it. I'll just add a set of However, at some point we should definitely look at how to store graphs in memory in a more optimal way. |
@yegor256 A quick update: I've implemented the basic gc functionality, all that remains are tests. However, I've broken two tests: |
- Make `Sodg::collect` `pub(crate)` instead of `pub`. - Remove `peek_data` as it isn't needed
@UARTman this seems to be fixed, thanks! |
Right after a call of
Sodg.data()
function, the vertex must be sent to garbage collection, which may or may not delete the vertex. If there are no edges arriving to the vertex -- it may be deleted. If a vertex is deleted, all vertices that are connected to it through edges that depart from it -- must be placed into garbage collection pipeline.We shouldn't do this in a parallel thread. Everything should be done synchronously.
The text was updated successfully, but these errors were encountered: