mirror of
https://codeberg.org/anoncontributorxmr/monero.git
synced 2024-11-30 06:43:28 +01:00
b8787f4302
This curbs runaway growth while still allowing substantial spikes in block weight Original specification from ArticMine: here is the scaling proposal Define: LongTermBlockWeight Before fork: LongTermBlockWeight = BlockWeight At or after fork: LongTermBlockWeight = min(BlockWeight, 1.4*LongTermEffectiveMedianBlockWeight) Note: To avoid possible consensus issues over rounding the LongTermBlockWeight for a given block should be calculated to the nearest byte, and stored as a integer in the block itself. The stored LongTermBlockWeight is then used for future calculations of the LongTermEffectiveMedianBlockWeight and not recalculated each time. Define: LongTermEffectiveMedianBlockWeight LongTermEffectiveMedianBlockWeight = max(300000, MedianOverPrevious100000Blocks(LongTermBlockWeight)) Change Definition of EffectiveMedianBlockWeight From (current definition) EffectiveMedianBlockWeight = max(300000, MedianOverPrevious100Blocks(BlockWeight)) To (proposed definition) EffectiveMedianBlockWeight = min(max(300000, MedianOverPrevious100Blocks(BlockWeight)), 50*LongTermEffectiveMedianBlockWeight) Notes: 1) There are no other changes to the existing penalty formula, median calculation, fees etc. 2) There is the requirement to store the LongTermBlockWeight of a block unencrypted in the block itself. This is to avoid possible consensus issues over rounding and also to prevent the calculations from becoming unwieldy as we move away from the fork. 3) When the EffectiveMedianBlockWeight cap is reached it is still possible to mine blocks up to 2x the EffectiveMedianBlockWeight by paying the corresponding penalty. Note: the long term block weight is stored in the database, but not in the actual block itself, since it requires recalculating anyway for verification. |
||
---|---|---|
.. | ||
account.cpp | ||
address_from_url.cpp | ||
aligned.cpp | ||
apply_permutation.cpp | ||
ban.cpp | ||
base58.cpp | ||
block_queue.cpp | ||
block_reward.cpp | ||
blockchain_db.cpp | ||
bulletproofs.cpp | ||
canonical_amounts.cpp | ||
chacha.cpp | ||
checkpoints.cpp | ||
CMakeLists.txt | ||
command_line.cpp | ||
crypto.cpp | ||
decompose_amount_into_digits.cpp | ||
device.cpp | ||
dns_resolver.cpp | ||
epee_boosted_tcp_server.cpp | ||
epee_levin_protocol_handler_async.cpp | ||
epee_utils.cpp | ||
expect.cpp | ||
fee.cpp | ||
get_xtype_from_string.cpp | ||
hardfork.cpp | ||
hashchain.cpp | ||
http.cpp | ||
is_hdd.cpp | ||
json_serialization.cpp | ||
keccak.cpp | ||
logging.cpp | ||
long_term_block_weight.cpp | ||
main.cpp | ||
memwipe.cpp | ||
mlocker.cpp | ||
mnemonics.cpp | ||
mul_div.cpp | ||
multiexp.cpp | ||
multisig.cpp | ||
net.cpp | ||
notify.cpp | ||
output_distribution.cpp | ||
output_selection.cpp | ||
parse_amount.cpp | ||
pruning.cpp | ||
random.cpp | ||
ringct.cpp | ||
ringdb.cpp | ||
serialization.cpp | ||
sha256.cpp | ||
slow_memmem.cpp | ||
subaddress.cpp | ||
test_notifier.cpp | ||
test_peerlist.cpp | ||
test_protocol_pack.cpp | ||
test_tx_utils.cpp | ||
threadpool.cpp | ||
unbound.cpp | ||
unit_tests_utils.h | ||
uri.cpp | ||
varint.cpp | ||
vercmp.cpp | ||
wipeable_string.cpp |