wownero/tests/core_tests
moneromooo-monero b8787f4302
ArticMine's new block weight algorithm
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.
2019-03-04 09:33:58 +00:00
..
CMakeLists.txt Bulletproof aggregated verification and tests 2018-09-11 13:37:37 +00:00
block_reward.cpp v8: per byte fee, pad bulletproofs, fixed 11 ring size 2018-09-11 13:38:07 +00:00
block_reward.h Update 2018 copyright 2018-01-26 10:03:20 -05:00
block_validation.cpp v8: per byte fee, pad bulletproofs, fixed 11 ring size 2018-09-11 13:38:07 +00:00
block_validation.h Update 2018 copyright 2018-01-26 10:03:20 -05:00
bulletproofs.cpp add a bulletproof version, new bulletproof type, and rct config 2019-01-22 23:17:24 +00:00
bulletproofs.h add a bulletproof version, new bulletproof type, and rct config 2019-01-22 23:17:24 +00:00
chain_split_1.cpp Update 2018 copyright 2018-01-26 10:03:20 -05:00
chain_split_1.h Update 2018 copyright 2018-01-26 10:03:20 -05:00
chain_switch_1.cpp replace std::list with std::vector on some hot paths 2018-06-26 22:14:21 +01:00
chain_switch_1.h replace std::list with std::vector on some hot paths 2018-06-26 22:14:21 +01:00
chaingen.cpp v8: per byte fee, pad bulletproofs, fixed 11 ring size 2018-09-11 13:38:07 +00:00
chaingen.h core_tests: add a --list_tests command line switch 2019-01-07 14:42:19 +00:00
chaingen001.cpp replace std::list with std::vector on some hot paths 2018-06-26 22:14:21 +01:00
chaingen_main.cpp Merge pull request #5046 2019-01-18 19:00:16 +02:00
chaingen_tests_list.h Bulletproof aggregated verification and tests 2018-09-11 13:37:37 +00:00
double_spend.cpp replace std::list with std::vector on some hot paths 2018-06-26 22:14:21 +01:00
double_spend.h Update 2018 copyright 2018-01-26 10:03:20 -05:00
double_spend.inl replace std::list with std::vector on some hot paths 2018-06-26 22:14:21 +01:00
integer_overflow.cpp Update 2018 copyright 2018-01-26 10:03:20 -05:00
integer_overflow.h Update 2018 copyright 2018-01-26 10:03:20 -05:00
multisig.cpp ringct: encode 8 byte amount, saving 24 bytes per output 2019-01-22 23:17:31 +00:00
multisig.h core_tests: rename invalid multisig tests to read "invalid" 2018-12-22 01:31:43 +00:00
rct.cpp add a bulletproof version, new bulletproof type, and rct config 2019-01-22 23:17:24 +00:00
rct.h Update 2018 copyright 2018-01-26 10:03:20 -05:00
ring_signature_1.cpp replace std::list with std::vector on some hot paths 2018-06-26 22:14:21 +01:00
ring_signature_1.h Update 2018 copyright 2018-01-26 10:03:20 -05:00
transaction_tests.cpp remove some unused code 2018-11-23 15:37:36 +00:00
transaction_tests.h Update 2018 copyright 2018-01-26 10:03:20 -05:00
tx_validation.cpp keypair::generate: always require hw::device to avoid possible mistake 2018-03-14 21:00:16 +09:00
tx_validation.h Update 2018 copyright 2018-01-26 10:03:20 -05:00
v2_tests.cpp Update 2018 copyright 2018-01-26 10:03:20 -05:00
v2_tests.h ArticMine's new block weight algorithm 2019-03-04 09:33:58 +00:00