bpo-46608: exclude marshalled-frozen data if deep-freezing to save 300 KB space by kumaraditya303 · Pull Request #31074 · python/cpython

This reduces the size of the data segment by 300 KB of the executable because if the modules are deep-frozen then the marshalled frozen data just wastes space. This was inspired by comment by @gvanrossum in #29118 (comment). Note: There is a new option --deepfreeze-only in freeze_modules.py to change this behavior, it is on be default to save disk space.

# du -s ./python before
27892   ./python
# du -s ./python after
27524   ./python

https://bugs.python.org/issue46608

Automerge-Triggered-By: GH:ericsnowcurrently