Daniel Liu
677f923125
refactor(all): track state changes in state db #27349 ( #1947 )
2026-02-24 10:27:31 +05:30
Daniel Liu
398d9b693d
refactor(core): make signature of ContractCode hash-independent #27209 ( #1169 )
2026-02-13 09:11:43 +05:30
Daniel Liu
07d3c421f3
fix(trie): no persisted clean trie cache file #27525 ( #1170 )
2026-02-13 08:48:23 +05:30
Daniel Liu
3d194d4303
all: port boring changes from pbss #27176 ( #1158 )
...
* all: port boring changes from pbss
* core, trie: address comments from martin
* trie: minor fixes
* core/rawdb: update comment
* core, eth, tests, trie: address comments
* tests, trie: add extra check when update trie database
* trie/triedb/hashdb: degrade the error to warning
Co-authored-by: rjl493456442 <garyrong0905@gmail.com>
2026-01-26 11:21:46 +05:30
Daniel Liu
1b7d4afdd3
trie: add node type common package #27160 ( #1150 )
...
* trie: add node type common package
In trie/types package, a few node wrappers are defined, which will be used
in both trie package, trie/snap package, etc. Therefore, a standalone common
package is created to put these stuffs.
* trie: rename trie/types to trie/trienode
Co-authored-by: rjl493456442 <garyrong0905@gmail.com>
2026-01-21 10:47:53 +05:30
Daniel Liu
4a7eea65b9
trie: rework trie database #26813 ( #1149 )
...
Co-authored-by: rjl493456442 <garyrong0905@gmail.com>
2026-01-19 11:23:51 +05:30
Daniel Liu
583338686f
all: expose block number information to statedb #27753 ( #1936 )
2026-01-16 15:55:04 +05:30
Daniel Liu
63783a6b4c
core/state, trie: port changes from PBSS #26763 ( #1137 )
...
Co-authored-by: rjl493456442 <garyrong0905@gmail.com>
2025-12-22 12:03:56 +05:30
Daniel Liu
3b3aa9b013
core, trie: prepare for path-based trie storage #26603 ( #1126 )
...
This PR moves some trie-related db accessor methods to a different file, and also removes the schema type. Instead of the schema type, a string is used to distinguish between hashbased/pathbased db accessors.
This also moves some code from trie package to rawdb package.
This PR is intended to be a no-functionality-change prep PR for #25963 .
---------
Co-authored-by: Martin Holst Swende <martin@swende.se>
Co-authored-by: Gary Rong <garyrong0905@gmail.com>
2025-11-18 11:20:00 +05:30
Daniel Liu
07328dcec4
core, eth, trie: abstract node scheme #25532 ( #1123 )
...
This PR introduces a node scheme abstraction. The interface is only implemented by `hashScheme` at the moment, but will be extended by `pathScheme` very soon.
Apart from that, a few changes are also included which is worth mentioning:
- port the changes in the stacktrie, tracking the path prefix of nodes during commit
- use ethdb.Database for constructing trie.Database. This is not necessary right now, but it is required for path-based used to open reverse diff freezer
Co-authored-by: rjl493456442 <garyrong0905@gmail.com>
2025-11-17 11:25:08 +05:30
Daniel Liu
0c96e76992
trie, XDCx, XDCxlending: not expose db in trie ( #1763 )
2025-11-15 16:49:47 +05:30
Daniel Liu
28a4f25166
cmd, core, eth, trie: track deleted nodes #22225 #25757 ( #1120 )
...
Co-authored-by: rjl493456442 <garyrong0905@gmail.com>
Co-authored-by: Martin Holst Swende <martin@swende.se>
2025-11-12 13:32:22 +05:30
Daniel Liu
d11e128322
trie: handle more batch commit errors in Database #25674 ( #1118 )
...
Co-authored-by: Amir Hossein <77993374+Kamandlou@users.noreply.github.com>
2025-11-12 10:17:58 +05:30
Daniel Liu
22edaacf0d
trie: update comments + err check for preimages #25672 ( #1117 )
...
This PR includes minor updates to comments in trie/committer that reference insertion to the db, and adds an err != nil check for the return value of preimages.commit.
Co-authored-by: Darioush Jalali <darioush.jalali@avalabs.org>
2025-10-24 16:57:19 +08:00
Daniel Liu
271687e463
core, trie: remove DiskDB function from trie database #25690 ( #1116 )
2025-10-08 12:21:56 +08:00
Daniel Liu
862f18ec58
core/state, trie: fix trie flush order for proper pruning #25581 ( #1112 )
...
Co-authored-by: Péter Szilágyi <peterke@gmail.com>
2025-09-24 07:44:22 +08:00
Daniel Liu
0b13b19b55
trie: fix some typos #25551 #25648 ( #1111 )
2025-09-21 18:51:15 +08:00
Daniel Liu
637e732aff
trie: improve node rlp-decoding #25357 ( #1109 )
2025-09-17 08:42:42 +08:00
Daniel Liu
4e234f231a
core, trie: flush preimages to db on database close #25533 ( #1107 )
2025-09-09 17:32:22 +08:00
Daniel Liu
6c5c8c13de
core, trie: rework trie committer #25320 ( #1103 )
...
* all: rework trie and trie committer
* all: get rid of internal cache in trie
* all: fixes
* trie: polish
* core, trie: address comments
* trie: fix imports
* core/state: address comments
* core/state/snapshot: polish
* trie: remove unused code
* trie: update tests
* trie: don't set db as nil
* trie: address comments
* trie: unskip test
Co-authored-by: rjl493456442 <garyrong0905@gmail.com>
2025-08-31 15:58:48 +08:00
Daniel Liu
3fed9ebeb8
core, eth, trie: rework preimage store #25287 ( #1099 )
...
* core, trie, eth, cmd: rework preimage store
* trie: address comment
Co-authored-by: rjl493456442 <garyrong0905@gmail.com>
2025-08-29 05:22:44 +08:00
Daniel Liu
793293f041
trie: move locking into trieDB insert method #25030 ( #1091 )
...
Move locking into trieDB insert function
Co-authored-by: aaronbuchwald <aaron.buchwald56@gmail.com>
2025-08-22 16:38:30 +08:00
Daniel Liu
cf5766177a
trie: remove the duplicate write for preimage #23001 ( #1068 )
2025-07-28 16:50:39 +08:00
Daniel Liu
dabaf392a7
trie: fix size accounting in cleaner #25007 ( #1093 )
...
Decrease children size instead of dirties size when marking dirties as cleaned up in trie cleaner
Co-authored-by: aaronbuchwald <aaron.buchwald56@gmail.com>
2025-06-17 13:29:57 +08:00
Daniel Liu
93c2745b7b
all: disable recording preimage of trie keys #21402 ( #1054 )
2025-06-17 13:10:47 +08:00
Daniel Liu
1490033ec9
trie: fix typos #23768 ( #1074 )
2025-06-04 17:13:58 +08:00
Daniel Liu
c4a98d2ddb
trie: remove redundant conversions ( #1056 )
2025-06-03 11:50:02 +08:00
Daniel Liu
5b071d1b0d
trie: rename NodeFlag to nodeFlag ( #1049 )
2025-05-26 15:18:47 +08:00
Daniel Liu
b9a6c8c32d
cmd, core, eth, trie: add trie read caching layer ( #18087 ) ( #946 )
2025-04-16 17:27:43 +08:00
Daniel Liu
bf893cb73b
trie: reduce allocs in insertPreimage ( #21261 ) ( #943 )
...
Co-authored-by: Marius van der Wijden <m.vanderwijden@live.de>
2025-04-16 17:08:31 +08:00
Daniel Liu
c8b39cabae
trie: faster trie node encoding ( #24126 )
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
7198179c2a
cmd, trie: remove cmd/gc and hide some types in trie
2025-04-01 16:34:35 +08:00
Daniel Liu
a9b9f53701
core, eth, trie: add a prefix to contract code (21080)
2025-03-24 22:31:03 +08:00
olumuyiwadad
b5abbfed79
new EVM Upgrade
...
- Solidity Upgraded up to v0.8.0
- Fixed and Added eth_chainId
- Fix error in TransactionRecipet
- Reward halving issue fixed
2021-09-21 16:53:46 +05:30
olumuyiwadad
571c41f891
FIx Bad block error.
2021-09-17 17:59:06 +05:30
Jianrong
0fdab2027c
add linting as the first CI task
2021-08-07 14:27:08 +10:00
dev-vadim
dbe8c9d984
upgrade XDC.Network with v1.8.27.
2020-12-23 16:32:06 +05:30
Péter Szilágyi
80a2a35bc3
trie: there's no point in retrieving the metaroot
2019-04-08 12:00:42 +03:00
Martin Holst Swende
2843001ac2
trie: fix overflow in write cache parent tracking ( #18165 )
...
trie/database: fix overflow in parent tracking
2018-11-22 15:14:31 +02:00
Péter Szilágyi
434dd5bc00
cmd, core, eth, light, trie: add trie read caching layer
2018-11-15 12:22:13 +02:00
Péter Szilágyi
11bbc66082
eth, trie: fix tracer GC which accidentally pruned the metaroot
2018-08-09 12:33:30 +03:00
Mymskmkt
8051a0768a
trie: fix comment typo ( #17350 )
2018-08-08 16:08:40 +03:00
Péter Szilágyi
8a9c31a307
trie: handle removing the freshest node too
2018-07-30 16:31:17 +03:00
Péter Szilágyi
319098cc1c
trie: fix a temporary memory leak in the memcache
2018-07-02 15:47:33 +03:00
Péter Szilágyi
d926bf2c7e
trie: cache collapsed tries node, not rlp blobs ( #16876 )
...
The current trie memory database/cache that we do pruning on stores
trie nodes as binary rlp encoded blobs, and also stores the node
relationships/references for GC purposes. However, most of the trie
nodes (everything apart from a value node) is in essence just a
collection of references.
This PR switches out the RLP encoded trie blobs with the
collapsed-but-not-serialized trie nodes. This permits most of the
references to be recovered from within the node data structure,
avoiding the need to track them a second time (expensive memory wise).
2018-06-21 11:28:05 +02:00
Péter Szilágyi
a3267ed929
trie: don't report the root flushlist as an alloc
2018-06-11 14:32:13 +03:00
Péter Szilágyi
143c4341d8
core, eth, trie: streaming GC for the trie cache ( #16810 )
...
* core, eth, trie: streaming GC for the trie cache
* trie: track memcache statistics
2018-06-04 10:47:43 +03:00
Felix Lange
a5c0bbb4f4
all: update license information ( #16089 )
2018-02-14 13:49:11 +01:00
Péter Szilágyi
55599ee95d
core, trie: intermediate mempool between trie and database ( #15857 )
...
This commit reduces database I/O by not writing every state trie to disk.
2018-02-05 17:40:32 +01:00