Disentangle progress estimation from checkpoints and update it #9472

pull sipa wants to merge 5 commits into bitcoin:master from sipa:update_tx_estimation changing 9 files +58 −61
  1. sipa commented at 4:24 PM on January 4, 2017: member

    Fixes #9448.

    This moves the transaction estimation code out of the checkpoint code and data, as this information is not used for checkpoints (a consensus-relevant property). In the last commit, the estimated transaction count is updated for mainnet and testnet to blocks from a few days ago.

  2. sipa renamed this:
    Disentangle progress estimationc from heckpoints and update it
    Disentangle progress estimation from checkpoints and update it
    on Jan 4, 2017
  3. MarcoFalke added the label Refactoring on Jan 4, 2017
  4. MarcoFalke added this to the milestone 0.14.0 on Jan 4, 2017
  5. in src/chainparams.cpp:None in fec404013d outdated
     240 | @@ -240,9 +241,10 @@ class CTestNetParams : public CChainParams {
     241 |          };
     242 |  
     243 |          chainTxData = ChainTxData{
     244 | -            1337966069,
     245 | -            1488,
     246 | -            300
     247 | +            // Data as of block 00000000c2872f8f8a8935c8e3c5862be9038c97d4de2cf37ed496991166928a (height 1063660)
     248 | +            1483546230
    


    MarcoFalke commented at 4:33 PM on January 4, 2017:

    I think this might not compile due to missing ,?


    sipa commented at 4:52 PM on January 4, 2017:

    Fixed

  6. MarcoFalke commented at 4:34 PM on January 4, 2017: member

    utACK fec404013df40cfd767ae186723a94c23990c424 mod nit

  7. sipa force-pushed on Jan 4, 2017
  8. gmaxwell commented at 4:54 PM on January 4, 2017: contributor

    Concept ACK.

  9. sipa commented at 6:54 PM on January 4, 2017: member

    Just realized that this code is wrong: it assumes the SIGCHECK_VERIFICATION_FACTOR applies after the timestamp and not before (as opposed to after the last checkpoint).

  10. sipa commented at 6:56 PM on January 4, 2017: member

    Suggestion: get rid of the SIGCHECK_VERIFICATION_FACTOR entirely (as it now applies to over 80% of the chain's transactions).

  11. gmaxwell commented at 8:49 PM on January 4, 2017: contributor

    I agree with getting rid of it.

  12. [MOVEONLY] Move progress estimation out of checkpoints a4bac66cca
  13. Move tx estimation data out of CCheckPointData 3641141c8f
  14. Remove SIGCHECK_VERIFICATION_FACTOR 6dd81169fc
  15. sipa force-pushed on Jan 4, 2017
  16. sipa commented at 9:21 PM on January 4, 2017: member

    Updated to remove SIGCHECK_VERIFICATION_FACTOR

  17. laanwj commented at 12:35 PM on January 5, 2017: member

    Concept ACK

  18. cdecker commented at 1:42 PM on January 5, 2017: contributor

    ACK 2ac28a1749ccc1e733c24b762b77ab099df48a3b

  19. Shorten variable names and switch to tx/s e356d9a758
  20. Update estimated transaction count data df3637177a
  21. in src/validation.cpp:None in 2ac28a1749 outdated
    4146 | +    if (pindex == NULL)
    4147 | +        return 0.0;
    4148 | +
    4149 | +    int64_t nNow = time(NULL);
    4150 | +
    4151 | +    double fTxTotal;
    


    TheBlueMatt commented at 7:17 PM on January 7, 2017:

    Dont we use "d" for floats to disambiguate flags?


    sipa commented at 4:27 PM on January 11, 2017:

    Indeed. Fixed!


    MarcoFalke commented at 11:20 AM on January 12, 2017:

    Post merge µNit: Seems this was not fixed.


    laanwj commented at 11:51 AM on January 12, 2017:

    Bah, why are we using hungarian notation of variables in new code at all?


    sipa commented at 9:23 PM on January 12, 2017:

    Because there is a persistent "imitate the surrounding code" suggestion. If we actually want to migrate away from using that style, I'm all for it, but it means we should start enforcing a new style in reviews.

  22. sipa force-pushed on Jan 11, 2017
  23. jtimon commented at 10:42 PM on January 11, 2017: contributor

    Concept ACK. I'm going to only utACK individual commits for now: a4bac66cca62a5514579a15d198f3baa80683172 3641141c8f9bdc68fcc0792ce8842a8e33ea7320

  24. gmaxwell commented at 10:45 PM on January 11, 2017: contributor

    ACK.

  25. laanwj merged this on Jan 12, 2017
  26. laanwj closed this on Jan 12, 2017

  27. laanwj referenced this in commit fac0f30482 on Jan 12, 2017
  28. codablock referenced this in commit fc32d2cec6 on Jan 19, 2018
  29. codablock referenced this in commit 4dba63220a on Jan 20, 2018
  30. codablock referenced this in commit 658479355e on Jan 21, 2018
  31. andvgal referenced this in commit 384db35824 on Jan 6, 2019
  32. CryptoCentric referenced this in commit 15143329d3 on Feb 27, 2019
  33. CryptoCentric referenced this in commit e11d1ae195 on Feb 27, 2019
  34. DrahtBot locked this on Sep 8, 2021

github-metadata-mirror

This is a metadata mirror of the GitHub repository bitcoin/bitcoin. This site is not affiliated with GitHub. Content is generated from a GitHub metadata backup.
generated: 2026-04-13 18:15 UTC

This site is hosted by @0xB10C
More mirrored repositories can be found on mirror.b10c.me