dtolnay/cargo-tally

Reduce memory usage

Offen

#76 geöffnet am 08.08.2023

 (2 Kommentare) (0 Reaktionen) (0 zugewiesene Personen)Rust (11 Forks)github user discovery
help wanted

Repository-Metriken

Stars
 (255 Sterne)
PR-Merge-Metriken
 (Keine gemergten PRs in 30 T)

Beschreibung

Memory usage of cargo tally can get quite severe. Running cargo tally winapi windows-sys peaked at 12.7 GB, which isn't terrible (but also far from great). However, when trying it with --transitive, the program exhausts my 32 GB of RAM and 8 GB of swap before Linux kills it as OOM, so it apparently uses in excess of 40 GB.

Is it somehow possible to reduce the amount of memory used? I don't mind if it takes longer to run; the speed is reasonable as-is. Perhaps if some data could be written to disk (and later read back as needed) if memory usage exceeds a threshold?

Contributor Guide