Commit Graph

32 Commits

Author SHA1 Message Date
Alex Sharov
b683ed435c
Compress params change (#651)
Main Target: reduce RAM usage of huffman tables. If possible - improve
decompression speed. Compression speed not so important.

Experiments on 74Gb uncompressed file (bsc
012500-013000-transactions.seg)
Ram - needed just to open compressed file (Huff tables, etc...)
dec_speed - loop with `word, _ = g.Next(word[:0])`
skip_speed - loop with `g.Skip()` 
```
| DictSize | Ram  | file_size | dec_speed | skip_speed |
| -------- | ---- | --------- | --------- | ---------- |
| 1M       | 70Mb | 35871Mb   | 4m06s     | 1m58s      |
| 512K     | 42Mb | 36496Mb   | 3m49s     | 1m51s      |
| 256K     | 21Mb | 37100Mb   | 3m44s     | 1m48s      |
| 128K     | 11Mb | 37782Mb   | 3m25s     | 1m44s      |
| 64K      | 7Mb  | 38597Mb   | 3m16s     | 1m34s      |
| 32K      | 5Mb  | 39626Mb   | 3m0s      | 1m29s      |
```
 
Also about small sampling: skip superstrings if superstringNumber % 4 !=
0 does reduce compression ratio by 1% - checked on big BSC file and
small (1gb) goerli file.

so, I feel it's not so bad idea to use:
maxDictPatterns=64k
samplingFactor=4

Tradeoffs: sacrify 5% compression ratio to 4x compression speedup (i
think even more), 30% decompression speedup, 10x RAM reduction

Release: I will not change existing snapshots - now will focus on
releasing new block snapshots and releasing new history snapshots
(Erigon3). If have time will re-compress existing snapshots later.
2022-10-05 17:54:48 +07:00
Alex Sharov
746b31def2
agg22 madv helpers (#668) 2022-10-05 13:17:23 +07:00
Alex Sharov
ca2ebac0f9
erigon3: step toward background snapshots build #663 2022-10-02 10:03:49 +07:00
Alex Sharov
784b6cc904
erigon3: build .vi after downloading (#659) 2022-09-29 12:14:45 +07:00
Alex Sharov
6c929b7771
erigon3: simplify history reader (fixing edge case of reading history from files) (#658) 2022-09-28 13:48:13 +07:00
Artem Tsebrovskiy
4f5232504f
E3 agg commitment (#647)
* added commitment to aggregator

* added commitment evaluation by updates, fixed mainnet roothash mismatch

* added ability to change starting state of hph

* replayable erigon23 with commitment

* possible fix for eliasfano index read after close

* fixed db pruning and restart

* Initial fixes

* Debug

* clear downHashedLen for branch nodes

* Fix key length, cleanup

* Cleanup

* Cleanup

* picked aggregator updates

* fixed empty cell hash for ProcessUpdate evaluation

* hashBuffer moved from Cell to HexPatriciaHashed

* fixed codeHash incorrect renewal

* lint

* removed valuemergefn from history

* fixed lint

* fixed test

* rewritten fuzz test on hph

* fix for Win tests - do not remove tmp dir after test

* win

* fixup after merge

* close aggregator after test

Co-authored-by: Alexey Sharp <alexeysharp@Alexeys-iMac.local>
Co-authored-by: Alex Sharp <alexsharp@Alexs-MacBook-Pro.local>
2022-09-26 15:59:24 +01:00
Alex Sharov
7790688724
erigon3: build .efi after download #654 2022-09-26 15:26:58 +07:00
Alex Sharov
417cea6485
erigon22: non-pointer btree (#653) 2022-09-26 09:42:44 +07:00
Alex Sharov
f05cd214bd
aggregator22: read dir without idx (#638) 2022-09-18 17:38:43 +07:00
Alex Sharov
aad257bc0c
erigon22: skip tmp files by regexp (#637) 2022-09-13 16:01:41 +07:00
Alex Sharov
4858acfb2e
fix lint (#632) 2022-09-09 21:07:39 +07:00
Alex Sharov
4fea8e9ba2
erigon22: history iterator v3 #630 2022-09-08 14:01:32 +07:00
Alex Sharov
e6276aeea8
erigon22: history iterator v2 (#628) 2022-09-08 11:09:54 +07:00
Alex Sharov
c22f737b87
Erigon22: use history iterator #627 2022-09-07 15:57:28 +07:00
Alex Sharov
f8060aa75d
erigon22: HistoryIterator1 v1 (#626) 2022-09-07 14:40:39 +07:00
Alex Sharov
841fe604f9
erigon22: fix infinity loop #624 2022-09-06 13:56:07 +07:00
Alex Sharov
775ace2e37
erigon22: historyReader22 and more tests #623 2022-09-06 13:54:58 +07:00
Alex Sharov
e40691a4ad
history22: small renames #608 2022-08-29 11:07:10 +07:00
Alex Sharov
588519a33b
erigon22: recent history read (#605) 2022-08-28 11:25:53 +07:00
Alex Sharov
cfd14d0297
erigon22: step toward /tests 2022-08-25 15:31:59 +07:00
Alex Sharov
c7cf5b6530
clean (#599) 2022-08-22 15:56:18 +07:00
alex.sharov
36778a2db3 save 2022-08-22 10:33:14 +07:00
Alex Sharov
d93972c581
domain: docs of tables format (#595) 2022-08-18 15:02:24 +07:00
Alex Sharov
59dfcc471c
erigon22: prune - check key existance (#588) 2022-08-15 14:33:32 +07:00
ledgerwatch
e160c1ad9c
Optimise state erigon2.2 reconstitution (#570)
* Start iterator1

* No parallel buildFiles and mergeFiles

* Optimise GetNoState

* Fixes

* Fix 2

* Another fix

* Fix

* More changes iter

* Provide keys in ScanIterator

* Tables for bitmaps

* Add X tables

* Change signature of GeNoState

* More on changes iterator

* Test for changed keys iterator

* ReconDb tables

* Changed key iterator

* Fix lint

* Fix lint

* uncovert

Co-authored-by: Alexey Sharp <alexeysharp@Alexeys-iMac.local>
Co-authored-by: Alex Sharp <alexsharp@Alexs-MacBook-Pro.local>
Co-authored-by: Alex Sharp <alexsharp@alexs-mbp.lan>
2022-08-14 14:56:47 +01:00
Alex Sharov
404276494a
state22.Unwind() (#586) 2022-08-14 17:53:53 +07:00
Alex Sharov
0b68b61b52
fix for loop 2022-08-14 10:21:38 +07:00
Alex Sharov
95e94b2eb5
erigon22: optimize index.add (#571)
* save

* save
2022-08-09 10:28:29 +07:00
Alex Sharov
2be46669d5
Progress type (#568) 2022-08-04 12:31:17 +07:00
ledgerwatch
fadc9b21d1
[erigon2.2] Split 2.2 and 2.3 prototype (#548)
* Introduce access functions to history

* Add missing functions

* Add missing functions

* Add missing functions

* Changeover in the aggregator

* Intermediate

* Fix domain tests

* Fix lint

* Fix lint

* Fix lint

* Close files

Co-authored-by: Alexey Sharp <alexeysharp@Alexeys-iMac.local>
2022-07-28 08:47:13 +01:00
Alex Sharov
471d790348
kv.Del() remove second parameter (#554)
* save

* save

* save

* save

* save

* save

* save

* save
2022-07-26 12:47:08 +07:00
ledgerwatch
596d10ea2e
Split aggregator to 2.2 and 2.3 versions (#539)
* Split History from Domain

* Add History.prune

* More on history

* Fix HistoryHistory test

* Merge history files

* Scan file test for history

* Add aggregator for erigon 2.2

* Change to generics, introduce contexts

* Delete to belong to Aggregator

* Fix lint

* Fix lint

* Fix lint

* Fix lint

* Use pointers to InvertedIndex again

* Remove prints

* Close embedded InvertedIndex

* Fix closing files

* Print

* Update ci.yml

* More printing

* Fix

* Make InvertedIndex pointer inside History

* Fix

* Update ci.yml

* Remove print

Co-authored-by: Alex Sharp <alexsharp@Alexs-MacBook-Pro.local>
Co-authored-by: Alexey Sharp <alexeysharp@Alexeys-iMac.local>
2022-07-23 09:06:52 +01:00