diff options
author | Wei-Ning Huang <w@dexon.org> | 2018-11-21 16:14:51 +0800 |
---|---|---|
committer | Wei-Ning Huang <w@byzantine-lab.io> | 2019-06-12 17:27:18 +0800 |
commit | 95cdd25856f2a38861f6abd622cbc3232f909268 (patch) | |
tree | 1c76919498802cd58ab1601f1b9c9e4c1cf856f2 /core/blockchain.go | |
parent | 43846e6cfaa477d406277895275bf3c722e1bdec (diff) | |
download | go-tangerine-95cdd25856f2a38861f6abd622cbc3232f909268.tar go-tangerine-95cdd25856f2a38861f6abd622cbc3232f909268.tar.gz go-tangerine-95cdd25856f2a38861f6abd622cbc3232f909268.tar.bz2 go-tangerine-95cdd25856f2a38861f6abd622cbc3232f909268.tar.lz go-tangerine-95cdd25856f2a38861f6abd622cbc3232f909268.tar.xz go-tangerine-95cdd25856f2a38861f6abd622cbc3232f909268.tar.zst go-tangerine-95cdd25856f2a38861f6abd622cbc3232f909268.zip |
core: add global signature cache and improve concurrency (#42)
From the go trace result, the bottleneck hides in the lock of
StoreTxCache. To improve this, we update the cache in a batched fassion.
Diffstat (limited to 'core/blockchain.go')
-rw-r--r-- | core/blockchain.go | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/core/blockchain.go b/core/blockchain.go index 983448de8..e7b1c846f 100644 --- a/core/blockchain.go +++ b/core/blockchain.go @@ -268,7 +268,7 @@ func (bc *BlockChain) AddConfirmedBlock(block *coreTypes.Block) error { if err != nil { return err } - _, err = transactions.TouchSenders(types.MakeSigner(bc.Config(), new(big.Int))) + _, err = types.GlobalSigCache.Add(types.NewEIP155Signer(bc.Config().ChainID), transactions) if err != nil { return err } |