Skip to content

Think about plugging potential Data.Tree unfoldTreeM_BF space leak #199

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

Open
treeowl opened this issue Apr 22, 2016 · 0 comments
Open

Think about plugging potential Data.Tree unfoldTreeM_BF space leak #199

treeowl opened this issue Apr 22, 2016 · 0 comments

Comments

@treeowl
Copy link
Contributor

treeowl commented Apr 22, 2016

unfoldForestM_BF (both the current implementation and the level-wise one in #198) has a potential space leak. In particular, we need to keep track of the number of children of each node when we dump the child seeds into the queue or concatenate them all. The implementations do this by holding on to the seed lists until it's time to rebuild, and then (one way or another) counting the seeds in each. If the seeds are large, this is potentially a problem. If we want, we can force the seed count earlier, avoiding the leak. However, I haven't yet found a way to do this that doesn't lead to performance problems.

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

2 participants