guix-play/guix/store
Ludovic Courtès 5a7cb59648
deduplication: Detect holes and create sparse files.
This reduces disk usage of sparse files that are substituted such as
Guile object files (ELF files).  As of Guile 3.0.9, .go files are sparse
due to ELF sections being aligned on 64 KiB boundaries.

This reduces disk usage reported by “du -sh” by 9% for the ‘guix’
package, by 23% for ‘guile’, and by 35% for ‘guile-git’.

* guix/store/deduplication.scm (hole-size, find-holes): New procedures.
(tee)[seekable?]: New variable.
[read!]: Add case when SEEKABLE? is true.
* tests/store-deduplication.scm (cartesian-product): New procedure.
("copy-file/deduplicate, sparse files (holes: ~a/~a/~a)"): New test set.

Change-Id: Iad2ab7830dcb1220e2026f4a127a6c718afa8964
2024-05-25 16:44:42 +02:00
..
database.scm store: database: Use correct function name in assertion. 2024-04-07 19:07:26 +01:00
deduplication.scm deduplication: Detect holes and create sparse files. 2024-05-25 16:44:42 +02:00
roots.scm store: Tolerate non-existent GC root directories. 2023-06-18 23:36:25 +02:00
schema.sql
ssh.scm