Keeping the lock longer than needed is confusing to reviewers and thread analysis. For example, keeping the lock while appending tx-invs, which requires the mempool lock, will tell thread analysis tools an incorrect lock order of (1) m_block_inv_mutex, (2) pool.cs.
p2p: Limit m_block_inv_mutex #21775
pull MarcoFalke wants to merge 1 commits into bitcoin:master from MarcoFalke:2104-netLockBlockInv changing 1 files +2 −2-
MarcoFalke commented at 6:44 PM on April 25, 2021: member
-
p2p: Limit m_block_inv_mutex fac96d0265
- MarcoFalke added the label P2P on Apr 25, 2021
- MarcoFalke added the label Refactoring on Apr 25, 2021
-
DrahtBot commented at 1:31 AM on April 26, 2021: member
<!--e57a25ab6845829454e8d69fc972939a-->
The following sections might be updated with supplementary metadata relevant to reviewers and maintainers.
<!--174a7506f384e20aa4161008e828411d-->
Conflicts
Reviewers, this pull request conflicts with the following ones:
- #21515 (Erlay: bandwidth-efficient transaction relay protocol by naumenkogs)
- #21160 (net/net processing: Move tx inventory into net_processing by jnewbery)
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.
-
Crypt-iQ commented at 7:04 PM on May 1, 2021: contributor
crACK fac96d026511f22f0202ce3631a38be0e990555f
Makes sense, the lock wasn't being used for the whole scope. Nice improvement!
-
jnewbery commented at 7:57 AM on May 3, 2021: member
Concept ACK.
Do you mind de-indenting the lines 4455-4581 in a second commit?
-
jnewbery commented at 8:09 AM on May 3, 2021: member
utACK fac96d026511f22f0202ce3631a38be0e990555f
- theStack approved
-
theStack commented at 8:56 AM on May 3, 2021: member
Code-Review ACK fac96d026511f22f0202ce3631a38be0e990555f
- MarcoFalke merged this on May 3, 2021
- MarcoFalke closed this on May 3, 2021
- MarcoFalke deleted the branch on May 3, 2021
- sidhujag referenced this in commit ce662fb42c on May 3, 2021
- gwillen referenced this in commit b67a98b030 on Jun 1, 2022
- DrahtBot locked this on Aug 16, 2022
Contributors
Labels