Subject: [bitcoin-dev] 7z block compression, 18%

From: NITSOPOULOS KONSTANTINOS <[email-masked]>
Date: Sat, 24 Apr 2021 13:02:31 +0200

Hi, I can compress new blocks by up to 18% using the 7z file type. I use wxHexEditor to dump a block's raw hex onto my disk, and then compress that with 7-Zip. I'd like to see 7z built into Bitcoin Core, for block compression (storage & propagation). The entire blockchain could be under 290GB if it's converted into a 7z archive-chain ("7z-chain"). I can compress some recent example blocks (hex -> less hex) if anyone wants. A future BIP could try increase the block Weight Units limit by up to 21% if 7z blocks are smaller & quick.

Programming compression seems too difficult for me, so I'm hoping somebody else does it!

Eventually I think transactions can be compressed by replacing addresses (& public keys) and coins, wherever possible, with just their own unique sequential index. TX amounts can also be compressed if they contain only a decimal digit or two, e.g. 00000000.10000000 XBT. A TX of 0.1 XBT between two existing addresses could be somehow compressed to half or maybe a quarter of its current size!

-Tinos