refactor: add thread safety lock assertion to WriteBlockIndexDB() #24002

pull jonatack wants to merge 1 commits into bitcoin:master from jonatack:add-thread-safety-lock-assertion-to-WriteBlockIndexDB changing 1 files +1 −0
  1. jonatack commented at 12:16 pm on January 7, 2022: member

    New helper function BlockManager::WriteBlockIndexDB() added in #23974 has a thread safety lock annotation in its declaration but is missing the corresponding run-time lock assertion in its definition.

    Per doc/developer-notes.md: “Combine annotations in function declarations with run-time asserts in function definitions.”

  2. refactor: add thread safety lock assertion to WriteBlockIndexDB()
    The new helper function, BlockManager::WriteBlockIndexDB(),
    has a thread safety lock annotation in its declaration but is
    missing the corresponding run-time lock assertion in its definition.
    
    Per doc/developer-notes.md: "Combine annotations in function
    declarations with run-time asserts in function definitions."
    1823766fc6
  3. fanquake commented at 12:23 pm on January 7, 2022: member
    Combine into #22932 once it’s rebased?
  4. jonatack commented at 12:29 pm on January 7, 2022: member

    Combine into #22932 once it’s rebased?

    This code doesn’t touch that pull. (It’s also been open for several months without ACKs, so I’m planning to split it up into smaller pulls to ease review.)

  5. fanquake commented at 12:36 pm on January 7, 2022: member

    This code doesn’t touch that pull.

    That would be difficult given the code modified here has only been added to the repo since that PR was last rebased. I suggested combining because #22932 is full of changes very similar to this one.

  6. jonatack commented at 12:50 pm on January 7, 2022: member
    #22932 does not touch this function and there is no guarantee that it will be merged. I plan to reduce its scope or perhaps close it.
  7. DrahtBot added the label Block storage on Jan 7, 2022
  8. DrahtBot added the label Refactoring on Jan 7, 2022
  9. DrahtBot commented at 1:59 am on January 8, 2022: member

    The following sections might be updated with supplementary metadata relevant to reviewers and maintainers.

    Conflicts

    Reviewers, this pull request conflicts with the following ones:

    • #22564 ([WIP] refactor: Move mutable globals cleared in ::UnloadBlockIndex to BlockManager by dongcarl)

    If you consider this pull request important, please also help to review the conflicting pull requests. Ideally, start with the one that should be merged first.

  10. MarcoFalke commented at 8:08 am on January 8, 2022: member
    cr ACK 1823766fc69a3d57767af11f182826533465f621
  11. MarcoFalke merged this on Jan 8, 2022
  12. MarcoFalke closed this on Jan 8, 2022

  13. jonatack deleted the branch on Jan 8, 2022
  14. sidhujag referenced this in commit 191608dff8 on Jan 9, 2022
  15. DrahtBot locked this on Jan 8, 2023

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: 2024-11-23 09:12 UTC

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