New submission from Raymond Hettinger:
Save space and reduce I/O time (reading and writing) by compressing the
marshaled code in files.
In my code tree for Python 3, there was a nice space savings 19M to 7M. Here's
some of the output from my test:
8792 -> 4629 ./Tools/scripts/__pycache__/reindent.cpython-35.pyc
1660 -> 1063 ./Tools/scripts/__pycache__/rgrep.cpython-35.pyc
1995 -> 1129 ./Tools/scripts/__pycache__/run_tests.cpython-35.pyc
1439 -> 973 ./Tools/scripts/__pycache__/serve.cpython-35.pyc
727 -> 498 ./Tools/scripts/__pycache__/suff.cpython-35.pyc
3240 -> 1808 ./Tools/scripts/__pycache__/svneol.cpython-35.pyc
74866 -> 23611 ./Tools/scripts/__pycache__/texi2html.cpython-35.pyc
5562 -> 2870 ./Tools/scripts/__pycache__/treesync.cpython-35.pyc
1492 -> 970 ./Tools/scripts/__pycache__/untabify.cpython-35.pyc
1414 -> 891 ./Tools/scripts/__pycache__/which.cpython-35.pyc
19627963 -> 6976410 Total
I haven't measured it yet, but I believe this will improve Python's start-up
time (because fewer bytes get transferred from disk).
----------
files: compress_pyc.py
messages: 230576
nosy: rhettinger
priority: normal
severity: normal
stage: needs patch
status: open
title: Compress the marshalled data in PYC files
type: enhancement
versions: Python 3.5
Added file: http://bugs.python.org/file37125/compress_pyc.py
_______________________________________
Python tracker <[email protected]>
<http://bugs.python.org/issue22789>
_______________________________________
_______________________________________________
Python-bugs-list mailing list
Unsubscribe:
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com