-
-
Notifications
You must be signed in to change notification settings - Fork 5.6k
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
Refactor iterate git tree to reduce memory usage #31076
base: main
Are you sure you want to change the base?
Conversation
eaae69e
to
7bdf686
Compare
It doesn't seem right, especially the different "ctx" are mixed together. And in the end, you still read everything into memory To make it overall right, it needs to consume the outputs on the fly, and make the git command has ability to limit the read data size. |
This PR introduced an iteration method and only reduces memory when calculating language stats. For tree list, they are kept as before and we can improve it in the future. |
Make git tree recursive iteration stoppable and reduce the memory usage when calculating language stats.