Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Implementation of BIP 101 : maximum block size increase #6341

Closed

Commits on Jul 14, 2015

  1. Refactor: protect mapNodeState with its own lock

    Encapsulate mapNodeState in a smart-pointer class with its own lock.
    
    Why? So Misbehaving() can be called from the sanity-check-a-message code without holding cs_main.
    
    And to get better exception safety (the smart-pointer approach gives RAII semantics).
    
    And because protecting fewer things with cs_main is a good idea.
    
    Tested by compiling with -DDEBUG_LOCKORDER, running all of the qa/rpc-tests, and running a node on the main network overnight.
    gavinandresen committed Jul 14, 2015
    Configuration menu
    Copy the full SHA
    03f877f View commit details
    Browse the repository at this point in the history
  2. Refactor, new CNode::FinalizeHeader method

    I need this to write some unit tests for the
    CNode::ReceiveMsgBytes() function.
    gavinandresen committed Jul 14, 2015
    Configuration menu
    Copy the full SHA
    0e096a0 View commit details
    Browse the repository at this point in the history
  3. Configuration menu
    Copy the full SHA
    021122c View commit details
    Browse the repository at this point in the history
  4. Configuration menu
    Copy the full SHA
    618d9f4 View commit details
    Browse the repository at this point in the history
  5. Implement hard fork to allow bigger blocks

    Unit test and code for a bigger-block hard fork.
    Parameters are:
      8MB cap
      ... doubling every two years (so 16MB in 2018)
      ... for twenty years
      ... earliest possible chain fork: 11 Jan 2016
      ... after miner supermajority (code in the next patch)
      ... and grace period once miner supermajority achieved (code in next patch)
    gavinandresen committed Jul 14, 2015
    Configuration menu
    Copy the full SHA
    7148527 View commit details
    Browse the repository at this point in the history
  6. Implement miner vote and grace period for block size fork

    These changes implement and test miner rollout of a bigger
    block size hard fork.
    
    qa/rpc-tests/bigblocks.py mines a 50% upgraded -regtest chain,
    generates 4MB of transactions, and then tests the upgrade and
    mining code to make sure larger blocks are only created when
    the fork conditions are met.
    
    The activation state of the fork is stored in the block tree database;
    it is written when the threshold is met (and unwritten if the
    threshold block is re-orged out of the best chain), and read at startup.
    gavinandresen committed Jul 14, 2015
    Configuration menu
    Copy the full SHA
    b7492b1 View commit details
    Browse the repository at this point in the history
  7. Configuration menu
    Copy the full SHA
    c63eb70 View commit details
    Browse the repository at this point in the history
  8. Configuration menu
    Copy the full SHA
    b58d925 View commit details
    Browse the repository at this point in the history