aboutsummaryrefslogtreecommitdiff
path: root/src/test/mempool_tests.cpp
Commit message (Collapse)AuthorAgeFilesLines
* Merge #13780: 0.17: Pre-branch maintenanceWladimir J. van der Laan2018-08-081-1/+1
|\ | | | | | | | | | | | | | | | | | | | | | | | | | | 3fc20632a3ad30809356a58d2cf0ea4a4ad4cec3 qt: Set BLOCK_CHAIN_SIZE = 220 (DrahtBot) 2b6a2f4a28792f2fe9dc1be843b1ff1ecae35e8a Regenerate manpages (DrahtBot) eb7daf4d600eeb631427c018a984a77a34aca66e Update copyright headers to 2018 (DrahtBot) Pull request description: Some trivial maintenance to avoid having to do it again after the 0.17 branch off. (The scripts to do this are in `./contrib/`) Tree-SHA512: 16b2af45e0351b1c691c5311d48025dc6828079e98c2aa2e600dc5910ee8aa01858ca6c356538150dc46fe14c8819ed8ec8e4ec9a0f682b9950dd41bc50518fa
| * Update copyright headers to 2018DrahtBot2018-07-271-1/+1
| |
* | refactor: Avoid locking tx pool cs thriceMarcoFalke2018-07-291-2/+5
|/
* scripted-diff: Remove trailing whitespacesJoão Barbosa2018-07-241-1/+1
| | | | | | | | -BEGIN VERIFY SCRIPT- sed --in-place'' --regexp-extended 's/[[:space:]]+$//g' $(git grep -I --files-with-matches --extended-regexp '[[:space:]]+$' -- src test ':!*.svg' ':!src/crypto/sha256_sse4*' ':!src/leveldb' ':!src/qt/locale' ':!src/secp256k1' ':!src/univalue') -END VERIFY SCRIPT-
* tests: Drop variadic macroMarcoFalke2018-06-131-9/+6
|
* test: Add MempoolAncestryTestsKarl-Johan Alm2018-06-111-0/+178
|
* Add Clang thread safety analysis annotationspracticalswift2018-05-051-1/+1
|
* Make it clear which functions that are intended to be translation unit localpracticalswift2018-05-031-1/+1
| | | | | Do not share functions that are meant to be translation unit local with other translation units. Use internal linkage for those consistently.
* test: Fix sign for expected valuesKarl-Johan Alm2018-04-111-10/+10
| | | | A number of BOOST_CHECK_EQUAL calls would result in warnings about signs.
* Fix typosDimitris Apostolou2018-03-211-1/+1
|
* Merge #12118: Sort mempool by min(feerate, ancestor_feerate)Wladimir J. van der Laan2018-01-151-0/+17
|\ | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | 0a22a52 Use mempool's ancestor sort in transaction selection (Suhas Daftuar) 7abfa53 Add test for new ancestor feerate sort behavior (Suhas Daftuar) 9a51319 Sort mempool by min(feerate, ancestor_feerate) (Suhas Daftuar) 6773f92 Refactor CompareTxMemPoolEntryByDescendantScore (Suhas Daftuar) Pull request description: This more closely approximates the desirability of a given transaction for mining, and should result in less re-sorting when transactions get removed from the mempool after being mined. I measured this as approximately a 5% speedup in removeForBlock. Tree-SHA512: ffa36b567c5dfe3e8908c545a459b6a5ec0de26e7dc81b1050dd235cac9046564b4409a3f8c5ba97bd8b30526e8fec8f78480a912e317979467f32305c3dd37b
| * Add test for new ancestor feerate sort behaviorSuhas Daftuar2018-01-121-0/+17
| |
* | Remove unused mempool indexSuhas Daftuar2018-01-091-29/+0
|/
* Increment MIT Licence copyright header year on files modified in 2017Akira Takizawa2018-01-031-1/+1
|
* scripted-diff: Replace #include "" with #include <> (ryanofsky)MeshCollider2017-11-161-4/+4
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | -BEGIN VERIFY SCRIPT- for f in \ src/*.cpp \ src/*.h \ src/bench/*.cpp \ src/bench/*.h \ src/compat/*.cpp \ src/compat/*.h \ src/consensus/*.cpp \ src/consensus/*.h \ src/crypto/*.cpp \ src/crypto/*.h \ src/crypto/ctaes/*.h \ src/policy/*.cpp \ src/policy/*.h \ src/primitives/*.cpp \ src/primitives/*.h \ src/qt/*.cpp \ src/qt/*.h \ src/qt/test/*.cpp \ src/qt/test/*.h \ src/rpc/*.cpp \ src/rpc/*.h \ src/script/*.cpp \ src/script/*.h \ src/support/*.cpp \ src/support/*.h \ src/support/allocators/*.h \ src/test/*.cpp \ src/test/*.h \ src/wallet/*.cpp \ src/wallet/*.h \ src/wallet/test/*.cpp \ src/wallet/test/*.h \ src/zmq/*.cpp \ src/zmq/*.h do base=${f%/*}/ relbase=${base#src/} sed -i "s:#include \"\(.*\)\"\(.*\):if test -e \$base'\\1'; then echo \"#include <\"\$relbase\"\\1>\\2\"; else echo \"#include <\\1>\\2\"; fi:e" $f done -END VERIFY SCRIPT-
* tests: Add missing locks to testspracticalswift2017-11-101-0/+2
| | | | | | Add missing locks to tests to satisfy lock requirements (such as EXCLUSIVE_LOCKS_REQUIRED(...) (Clang Thread Safety Analysis), AssertLockHeld(...) and implicit lock assumptions).
* Force explicit double -> int conversion for CFeeRate constructorMatt Corallo2017-09-111-3/+3
| | | | | | | This resolves an issue where estimatesmartfee would return 999 sat/byte instead of 1000, due to floating point loss of precision Thanks to sipa for suggesting is_integral.
* Merge #9548: Remove min reasonable feeWladimir J. van der Laan2017-03-071-4/+4
|\ | | | | | | | | | | | | | | ad82cb0 Remove unnecessary min fee argument in CTxMemPool constructor (Alex Morcos) 2a7b56c CBlockPolicyEstimator now uses hard coded minimum bucket feerate (Alex Morcos) ac9d3d2 Change fee estimation bucket limit variable names (Alex Morcos) Tree-SHA512: 6e3bc7df3497ed60c7620845d222063e33a0238020f5c3316e61e0eff758078588ea8dd51196ceb59aa561ba106f8cdae62cebe521adb3247108bb49f15252d6
| * Remove unnecessary min fee argument in CTxMemPool constructorAlex Morcos2017-01-171-4/+4
| |
* | [cleanup] Remove coin age priority completely.Alex Morcos2017-03-031-1/+0
| | | | | | | | Remove GetPriority and ComputePriority. Remove internal machinery for tracking priority in CTxMemPoolEntry.
* | [test] Remove priority from testsAlex Morcos2017-03-031-22/+20
|/ | | | Remove all coin age priority functionality from unit tests and RPC tests.
* Remove member variable hadNoDependencies from CTxMemPoolEntryAlex Morcos2017-01-041-2/+0
| | | | Fee estimation can just check its own mapMemPoolTxs to determine the same information. Note that now fee estimation for block processing must happen before those transactions are removed, but this shoudl be a speedup.
* Increment MIT Licence copyright header year on files modified in 2016isle29832016-12-311-1/+1
| | | | | | Edited via: $ contrib/devtools/copyright_header.py update .
* Merge #7562: Bump transaction version default to 2Wladimir J. van der Laan2016-12-151-2/+11
|\ | | | | | | | | | | | | c5c92c4 Update python tests for default tx version=2 (BtcDrak) dab207e Preserve tx version=1 for certain tests (BtcDrak) c5d746a tiny test fix for mempool_tests (Alex Morcos) 1f0ca1a Bump default transaction version to 2 (BtcDrak)
| * tiny test fix for mempool_testsAlex Morcos2016-12-081-2/+11
| |
* | remove internal tracking of mempool conflicts for reporting to walletAlex Morcos2016-12-051-19/+21
| |
* | remove external usage of mempool conflict trackingAlex Morcos2016-12-051-1/+1
|/
* Introduce convenience type CTransactionRefPieter Wuille2016-11-191-4/+4
|
* Make CBlock::vtx a vector of shared_ptr<CTransaction>Pieter Wuille2016-11-191-3/+3
|
* trivial: Remove variable unused after refactoringDaniel Kraft2016-11-021-1/+0
| | | | | | Remove a variable that is now unused after the recent refactoring (in 51f278329d43398428d60f5986f8d29a2041d28d) but has not been cleaned up so far.
* Return shared_ptr<CTransaction> from mempool removesPieter Wuille2016-10-211-1/+2
|
* Make removed and conflicted arguments optional to removePieter Wuille2016-10-211-15/+12
|
* BIP141: Other consensus critical limits, and BIP145Pieter Wuille2016-06-221-5/+6
| | | | Includes changes by Suhas Daftuar, Luke-jr, and mruddy.
* Add ancestor feerate index to mempoolSuhas Daftuar2016-03-141-0/+104
|
* Rename CTxMemPool::remove -> removeRecursiveSuhas Daftuar2016-03-141-10/+10
| | | | | remove is no longer called non-recursively, so simplify the logic and eliminate an unnecessary parameter
* Add tags to mempool's mapTx indicesSuhas Daftuar2016-02-161-11/+11
|
* Bump copyright headers to 2015MarcoFalke2015-12-131-1/+1
|
* Add a score index to the mempool.Alex Morcos2015-12-011-9/+43
| | | | The score index is meant to represent the order of priority for being included in a block for miners. Initially this is set to the transactions modified (by any feeDelta) fee rate. Index improvements and unit tests by sdaftuar.
* Implement helper class for CTxMemPoolEntry constructorAlex Morcos2015-11-161-32/+37
| | | | This is only for unit tests.
* Fix bug in mempool_tests unit testAlex Morcos2015-11-131-2/+2
|
* Undo GetMinFee-requires-extra-call-to-hit-0Matt Corallo2015-10-141-1/+0
|
* Add reasonable test case for mempool trimmingMatt Corallo2015-10-131-0/+154
|
* Reverse the sort on the mempool's feerate indexSuhas Daftuar2015-10-131-23/+23
|
* Track transaction packages in CTxMemPoolEntrySuhas Daftuar2015-09-191-10/+139
| | | | | | | | | | | | | Associate with each CTxMemPoolEntry all the size/fees of descendant mempool transactions. Sort mempool by max(feerate of entry, feerate of descendants). Update statistics on-the-fly as transactions enter or leave the mempool. Also add ancestor and descendant limiting, so that transactions can be rejected if the number or size of unconfirmed ancestors exceeds a target, or if adding a transaction would cause some other mempool entry to have too many (or too large) a set of unconfirmed in- mempool descendants.
* TxMemPool: Change mapTx to a boost::multi_index_containerAshley Holman2015-09-191-0/+52
| | | | | | Indexes on: - Tx Hash - Fee Rate (fee-per-kb)
* Includes: Cleanup around net main and walletJorge Timón2015-07-231-1/+0
| | | | | | -Move from .h to .cpp: in main, net and wallet -Remove unnecessary #include "main.h" -Cleanup some wallet files includes
* Keep mempool consistent during block-reorgsGavin Andresen2015-03-261-0/+104
This fixes a subtle bug involving block re-orgs and non-standard transactions. Start with a block containing a non-standard transaction, and one or more transactions spending it in the memory pool. Then re-org away from that block to another chain that does not contain the non-standard transaction. Result before this fix: the dependent transactions get stuck in the mempool without their parent, putting the mempool in an inconsistent state. Tested with a new unit test.