forked from bitcoin/bitcoin
-
Notifications
You must be signed in to change notification settings - Fork 1.2k
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
DNM fix CI failure on develop #6198
Closed
Closed
Conversation
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
, bitcoin#24909, bitcoin#24178, bitcoin#24171, bitcoin#25404, bitcoin#25514, bitcoin#25720, partial bitcoin#23832, bitcoin#24169, bitcoin#25454 (headers backports)" This reverts commit 117dda9, reversing changes made to e803b32.
…nager.m_blockman
…Block this commit will not work with `--enable-c++20` as c++20 does away with aggregate initialization when constructors are declared. a partial backport of bitcoin#24169 will sort that out.
…der` Avoid TSan-reported data race ``` WARNING: ThreadSanitizer: data race (pid=360336) Write of size 8 at 0x7b5000002db8 by thread T15 (mutexes: write M0): #0 BlockManager::AddToBlockIndex(CBlockHeader const&, uint256 const&, CBlockIndex*&, BlockStatus) /src/dash/src/node/blockstorage.cpp:117:25 (dashd+0x44df7a) (BuildId: e27186c7ba08e897d376eb5779db9809baf7ad37) #1 ChainstateManager::AcceptBlockHeader(CBlockHeader const&, BlockValidationState&, CChainParams const&, CBlockIndex**) /src/dash/src/validation.cpp:3758:36 (dashd+0x83e45d) (BuildId: e27186c7ba08e897d376eb5779db9809baf7ad37) dashpay#2 CChainState::AcceptBlock(std::shared_ptr<CBlock const> const&, BlockValidationState&, CBlockIndex**, bool, FlatFilePos const*, bool*) /src/dash/src/validation.cpp:3812:37 (dashd+0x842848) (BuildId: e27186c7ba08e897d376eb5779db9809baf7ad37) [...] Previous read of size 8 at 0x7b5000002db8 by thread T12: #0 CDSNotificationInterface::UpdatedBlockTip(CBlockIndex const*, CBlockIndex const*, bool) /src/dash/src/dsnotificationinterface.cpp:82:42 (dashd+0x91e87e) (BuildId: e27186c7ba08e897d376eb5779db9809baf7ad37) #1 operator() /src/dash/src/validationinterface.cpp:199:79 (dashd+0x889f1e) (BuildId: e27186c7ba08e897d376eb5779db9809baf7ad37) dashpay#2 Iterate<(lambda at validationinterface.cpp:199:30)> /src/dash/src/validationinterface.cpp:88:17 (dashd+0x889f1e) [...] [...] SUMMARY: ThreadSanitizer: data race [...] ```
bitcoin#25454 introduces a 10 point penalty for remitting more than MAX_BLOCKS_TO_ANNOUNCE unconnected block headers. Whether they are connected or not is determined by taking the first entry and running its hashPrevBlock through LookupBlockIndex. This new behaviour causes a test failure in p2p_dos_header_tree.py in Dash. Bitcoin doesn't face a test failure with this new behaviour as the first non-fork block in its test data is the dump for block 1 (00000000b873e7 9784647a6c82962c70d228557d24a747ea4d1b8bbe878e1206) but Dash uses block 0 (00000bafbc94add76cb75e2ec92894837288a481e5c005f6563d91623bf8bc2c), the genesis block. By definition of a genesis block, it has a hashPrevBlock of 0, which cannot be looked up. This trips the penalty. This doesn't cause any problems in the field as nobody is expected to ever broadcast the genesis block but it does cause a test failure for us. We need to correct that by getting rid of the genesis block from the test data.
commits reverted: - 753ed61
…o the same peer excludes: - 99f4785
…to Peer Co-authored-by: UdjinM6 <[email protected]>
…n a block is found
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Issue being fixed or feature implemented
To trigger CI for tsan
What was done?
Describe your changes in detail
How Has This Been Tested?
Please describe in detail how you tested your changes.
Include details of your testing environment, and the tests you ran
to see how your change affects other areas of the code, etc.
Breaking Changes
Please describe any breaking changes your code introduces
Checklist:
Go over all the following points, and put an
x
in all the boxes that apply.