BIP 158 Flexibility and Filter Size



Summary:

A discussion on whether an application can watch for output scripts without watching for input scripts is ongoing. Wallet applications need to see both coin creation and spending, otherwise they may try to spend already spent coins. If no such applications exist, there isn't a reason to separate them. Using input scripts instead of input outpoints allows for additional savings from combining them due to the same scripts being spent as were created in the block, resulting from reuse and chaining. Txid has been argued to be useless based on Matt's argument, and it's suggested that only watching for an outpoint is necessary. A combined filter would potentially have up to 0.5 GB filter data per month, which could be a high barrier for adoption. The data supports separation of filters since a combined filter does not seem to come with significant savings. Basic size is roughly equal to txid plus input points plus output scripts sizes. A graph shows the comparison between the input script filter and the input outpoint filter, with the former being smaller due to address reuse. In more recent blocks, there are decreasing savings seen when combining the input prev script and output script filters versus keeping them separate. Tamas Blummer provides a link to a branch that is patched to produce the filter stats along with the main project and the BIP158 implementation.


Updated on: 2023-05-20T08:28:46.930851+00:00