Firstly, this does not change any consensus parameters or deviate from current behavior.
Instead, hard-coded values are moved to chainparams so that all chains can specify values independently. Further, some values are handled by an interface class so that they may be dynamic based on block time. Each chain is free to implement MaxBlockSize/MaxTxSize/MaxBlockSigops as they wish. This helps to facilitate testing without interrupting mainnet/testnet.
For initial testing, I’ve added a secondary regtest chain with a dynamic blocksize: https://github.com/theuni/bitcoin/blob/blocksize-consensus/src/chainparams.cpp#L90
It’s very simple, but it allows for experimentation. There’s also a test that steps through a few size increases.
My only concern is with the storage of transactions in the wallet: https://github.com/theuni/bitcoin/commit/3872ccf3beff24204ff293db0e81ceb5c7740455#diff-e506682270036e4c8e0b8159a34b652d. We may want to be smarter about considering wallet transactions as valid by differentiating between those known to be in a block and those that aren’t. @jonasschnelli any opinion?
This should not be considered as change to allow for bigger blocks (several pieces are missing in that regard, including p2p changes and blockfile handling), but rather as a logical move of the parameters to a place that makes more sense for them.