-
-
Notifications
You must be signed in to change notification settings - Fork 419
Open
Description
Summary
Add support for the core.packedGitLimit configuration option, which controls the maximum amount of memory that can be used to mmap pack files.
Description
The core.packedGitLimit option sets a limit on the total amount of memory used to mmap pack files. When this limit is reached, Git will unmap older pack files to make room for new ones. This helps control memory usage in repositories with many large pack files.
Benefits
- Better memory management for repositories with large pack files
- Prevents excessive memory usage in long-running processes
- Improves compatibility with Git's memory management behavior
- Essential for applications that work with very large repositories
Implementation Notes
This would involve tracking mmapped pack file memory usage and implementing an LRU-style eviction mechanism when the limit is reached.