Commit graph

5 commits

Author SHA1 Message Date
Jerry
e63e390ec7 Recognize bad transactions and break loop in blockstm executor 2022-09-29 23:05:09 -07:00
Jerry
471afc8da2 Refactor blockstm executor 2022-09-29 23:05:09 -07:00
Jerry
c36ad88aec Block-stm optimization
Added tests for executor and some improvements:

1. Add a dependency map during execution. This will prevent aborted tasks from being sent for execution immedaitely after failure.
2. Change the key of MVHashMap from string to a byte array. This will reduce time to convert byte slices to strings.
3. Use sync.Map to reduce the time spent in global mutex.
4. Skip applying intermediate states.
5. Estimate dependency when an execution fails without dependency information.
6. Divide execution task queue into two separate queues. One for relatively certain transactions, and the other for speculative future transactions.
7. Setting dependencies of Txs coming from the same sender before starting parallel execution.
8. Process results in their semantic order (transaction index) instead of the order when they arrive. Replace result channel with a priority queue.
2022-09-28 16:12:20 -07:00
Pratik Patil
f7bd7ca66b Txn prioritizer implemented using mutex map (#487)
* basic txn prioritizer implemented using mutex map

* Re-execute parallel tasks when there is a read in coinbase or burn address

* Re-execute parallel tasks when there is a read in coinbase or burn address

* using *sync.RWMutex{} in mutexMap

Co-authored-by: Jerry <jerrycgh@gmail.com>
2022-09-28 16:12:20 -07:00
Jerry
bbcc6dd0ad Parallel state processor 2022-09-28 16:12:20 -07:00