Commit graph

13026 commits

Author SHA1 Message Date
gary rong
1424987768 trie: polish commit function (#21692)
* trie: polish commit function

* trie: fix typo
2025-04-07 16:44:32 +08:00
gary rong
9da3ae1075 trie: polishes to trie committer (#21351)
* trie: update tests to check commit integrity

* trie: polish committer

* trie: fix typo

* trie: remove hasvalue notion

According to the benchmarks, type assertion between the pointer and
interface is extremely fast.

BenchmarkIntmethod-12           1000000000               1.91 ns/op
BenchmarkInterface-12           1000000000               2.13 ns/op
BenchmarkTypeSwitch-12          1000000000               1.81 ns/op
BenchmarkTypeAssertion-12       2000000000               1.78 ns/op

So the overhead for asserting whether the shortnode has "valuenode"
child is super tiny. No necessary to have another field.

* trie: linter nitpicks

Co-authored-by: Martin Holst Swende <martin@swende.se>
2025-04-07 16:44:32 +08:00
Daniel Liu
54f73e471f trie: Derivesha with stacktrie (#21407) 2025-04-07 16:44:32 +08:00
Daniel Liu
a4c7d7f458 all: clean duplicate constants in package common 2025-04-07 16:43:01 +08:00
Daniel Liu
468babfc3e console, internal/jsre: fix autocomplete issues (#26518) 2025-04-07 16:38:42 +08:00
Daniel Liu
5a49853cb4 Makefile: add devtools and help targets, remove gc target 2025-04-07 16:38:00 +08:00
Daniel Liu
a6cd3c54eb build: support auto-completion for bash 2025-04-07 16:37:05 +08:00
Wanwiset Peerapatanapokin
993d08cc3a
Merge pull request #931 from XinFinOrg/fix-docker-warning
cicd: fix warning when build docker
2025-04-02 11:19:42 +04:00
Daniel Liu
7198179c2a cmd, trie: remove cmd/gc and hide some types in trie 2025-04-01 16:34:35 +08:00
Daniel Liu
91cbe818ea common, params: define cancun block for testnet and print more chain config 2025-04-01 14:41:05 +08:00
wanwiset25
f9585a5f3e fix docker build warning 2025-03-31 06:03:42 +04:00
benjamin202410
b8a9a8bfb1
Merge pull request #924 from XinFinOrg/update-reward-percapita
Update reward percapita
2025-03-28 23:52:33 -07:00
Daniel Liu
ff7bcf8d15 core/state: separate hashes and committer, collapse on commit (#20481) 2025-03-28 22:34:59 +08:00
Daniel Liu
db4dc24094 core/state: accumulate writes and only update tries when must (#19953) 2025-03-28 22:34:59 +08:00
Daniel Liu
c73a0aa929 core/state: fix state iterator (#19127) 2025-03-28 22:34:59 +08:00
Daniel Liu
3fd025e814 core/state: optimize state object and storage iteration according to EIP-1283 (#17383) 2025-03-28 22:34:59 +08:00
Gerui Wang
6bac06b1e7 feat: fixed reward per node (per capita) 2025-03-25 22:33:49 +08:00
Gerui Wang
84ae914350 feat: add TIPEpochHalving, better style 2025-03-25 22:16:35 +08:00
Wang Gerui
7c4668fa91 style: clean comment 2025-03-25 22:10:03 +08:00
Daniel Liu
c2ad1b529b
Merge pull request #926 from gzliudan/fix-zero-tip-tx
core/txpool: fix zero tip tx always pending
2025-03-25 12:18:26 +08:00
Daniel Liu
f2f2044470 core/txpool: fix zero tip tx always pending 2025-03-25 11:56:46 +08:00
Daniel Liu
cd975aa165
Merge pull request #925 from gzliudan/code-prefix
consensus, core, eth, trie: add a prefix to contract code
2025-03-25 11:56:08 +08:00
Daniel Liu
a9b9f53701 core, eth, trie: add a prefix to contract code (21080) 2025-03-24 22:31:03 +08:00
Daniel Liu
9c144eee05
Merge pull request #922 from gzliudan/commit-genesis
core: improve commit genesis
2025-03-20 22:22:28 +08:00
Daniel Liu
6285a4fe05 core: improve commit genesis 2025-03-20 14:15:09 +08:00
Daniel Liu
b7eeb0d939
Merge pull request #921 from gzliudan/group-net-db-flags
cmd: group network and database flags together
2025-03-20 14:07:11 +08:00
Daniel Liu
5fff93dd01 cmd: group network and database flags together 2025-03-20 10:37:01 +08:00
Daniel Liu
f3d100edba
Merge pull request #915 from gzliudan/update_crypto
upgrade package crypto
2025-03-19 18:04:30 +08:00
Marius van der Wijden
5bf4da1f47 crypto/secp256k1: update libsecp256k1 (#31242)
Updates the libsecp256k1 dependency to commit:
c0d9480fbbf8eccbd4be23ed27f6f2af6f3b211e

PR:
```
BenchmarkSign-24    	   57756	     21214 ns/op	     164 B/op	       3 allocs/op
BenchmarkRecover-24    	   37156	     33044 ns/op	      80 B/op	       1 allocs/op
BenchmarkEcrecoverSignature-24    	   36889	     32935 ns/op	      80 B/op	       1 allocs/op
BenchmarkVerifySignature-24    	   41163	     29207 ns/op	       0 B/op	       0 allocs/op
BenchmarkDecompressPubkey-24    	  318624	      4062 ns/op	     304 B/op	       6 allocs/op
```

Master:
```
BenchmarkSign-24    	   34509	     35330 ns/op	     164 B/op	       3 allocs/op
BenchmarkRecover-24    	   25418	     47725 ns/op	      80 B/op	       1 allocs/op
BenchmarkEcrecoverSignature-24    	   25735	     47591 ns/op	      80 B/op	       1 allocs/op
BenchmarkVerifySignature-24    	   29108	     41097 ns/op	       0 B/op	       0 allocs/op
BenchmarkDecompressPubkey-24    	  294747	      4143 ns/op	     304 B/op	       6 allocs/op
```

Performance seems to be improved significantly:
```
Sign-24      34.86µ ± 3%   21.66µ ± 2%  -37.86% (p=0.000 n=10)
Recover-24   46.14µ ± 3%   33.24µ ± 2%  -27.95% (p=0.000 n=10)
```
2025-03-19 18:02:46 +08:00
Marius van der Wijden
31cc9b0d5f crypto: add comment to FromECDSAPub (#31241)
closes https://github.com/ethereum/go-ethereum/issues/26240
2025-03-19 18:02:46 +08:00
Daniel Liu
6ec0d13873 core/txpool, crypto, node: fix os.CreateTemp in test (#31172) 2025-03-19 18:02:46 +08:00
Ryan Tinianov
76a5008ec7 all: add build tags for wasip1 (#31090) 2025-03-19 18:02:46 +08:00
Felix Lange
98ad241607 crypto: add IsOnCurve check (#31100) 2025-03-19 18:02:46 +08:00
Daniel Liu
f7c46d0ad7 crypto: fix some typos in comments and names (#31023) 2025-03-19 18:02:46 +08:00
JukLee0ira
2d33123b0a p2p: measure subprotocol bandwidth usage (#20133) 2025-03-19 18:01:32 +08:00
Daniel Liu
79e7aef66b
Merge pull request #919 from gzliudan/final-block
rpc: support keyword `finalized` as block number
2025-03-19 17:48:37 +08:00
Daniel Liu
3e4a13d038 rpc: accept finalized as block number 2025-03-19 17:47:52 +08:00
Daniel Liu
b293363f0e
Merge pull request #918 from gzliudan/fix-issue-19286
core: initialize current block/fastblock atomics to nil
2025-03-19 17:46:34 +08:00
Daniel Liu
3856e16d8c core: initialize current block/fastblock atomics to nil (19352) 2025-03-19 17:46:12 +08:00
Daniel Liu
a1d6e839c0
Merge pull request #920 from gzliudan/rm-flag-docroot
cmd/utils, eth/ethconfig: remove flag docroot
2025-03-19 17:26:55 +08:00
Daniel Liu
ccf8ff2e64 cmd/utils, eth/ethconfig: remove flag docroot 2025-03-19 15:32:57 +08:00
Daniel Liu
95c7b224af
Merge pull request #916 from gzliudan/quick-test
build: add command `make quick-test` to save test time
2025-03-18 12:26:30 +08:00
Daniel Liu
6f020100d3 build: add command make quick-test to save test time 2025-03-17 17:30:02 +08:00
Daniel Liu
923645801d
Merge pull request #914 from gzliudan/fix_devnet_config
common, params: update parameters of devnet
2025-03-16 07:32:11 +08:00
Daniel Liu
d6fd1e868e common, params: update parameters of devnet 2025-03-16 01:06:12 +08:00
Daniel Liu
59550744d9
Merge pull request #913 from gzliudan/fix_devnet_config
params: fix outdated DevnetChainConfig
2025-03-15 23:53:33 +08:00
Daniel Liu
db820bdd91 params: fix outdated DevnetChainConfig 2025-03-15 23:48:20 +08:00
Daniel Liu
e258b875d6
Merge pull request #911 from gzliudan/improve_fee_history
eth/gasprice: improve function FeeHistory
2025-03-14 08:04:38 +08:00
Daniel Liu
5ef815a6c9 eth/gasprice: sanity check ratio values (#31270) 2025-03-14 08:04:02 +08:00
Daniel Liu
8f68af5da0 eth/gasprice: add query limit for FeeHistory to defend DDOS attack (#29644) 2025-03-14 08:04:02 +08:00