Commit Graph

12553 Commits

Author SHA1 Message Date
Igor Mandrigin
300a515bff
Merge pull request #1003 from ledgerwatch/geth-1.9.20
Geth 1.9.20
2020-08-29 16:27:32 +02:00
Igor Mandrigin
9e3d4b8b2a linters 2020-08-29 15:43:33 +02:00
Igor Mandrigin
7396ccc37e linters 2020-08-29 15:37:27 +02:00
Igor Mandrigin
15e86b4b34 fix compilation issue 2020-08-29 15:30:06 +02:00
Igor Mandrigin
637493e8f1 Merge branch 'master' into geth-1.9.20 2020-08-29 15:28:03 +02:00
Igor Mandrigin
1e69e76f6d fix tests 2020-08-29 15:15:37 +02:00
Igor Mandrigin
bd61245ece test fixups 2020-08-29 14:35:39 +02:00
Igor Mandrigin
4b4326020c geth compiles 2020-08-29 14:03:41 +02:00
Igor Mandrigin
948cd29be7 fixes 2020-08-29 13:43:44 +02:00
Igor Mandrigin
78e466d06a fix imports 2020-08-29 13:31:46 +02:00
Felix Lange
e3cb3dc09c params: release Geth v1.9.20
# Conflicts:
#	params/version.go
2020-08-29 13:29:32 +02:00
Péter Szilágyi
a1c28a0178 params: update CHTs for v1.9.20 release 2020-08-29 13:28:59 +02:00
Shude Li
1fc802e7a7 graphql: add support for retrieving the chain id (#21451) 2020-08-29 13:28:52 +02:00
Péter Szilágyi
0dfcc3f6f8 core/rawdb: only complain loudly if truncating many items
# Conflicts:
#	core/rawdb/freezer_table.go
2020-08-29 13:28:46 +02:00
timcooijmans
b9bcd407d5 p2p/discover: avoid dropping unverified nodes when table is almost empty (#21396)
This change improves discovery behavior in small networks. Very small
networks would often fail to bootstrap because all member nodes were
dropping table content due to findnode failure. The check is now changed
to avoid dropping nodes on findnode failure when their bucket is almost
empty. It also relaxes the liveness check requirement for FINDNODE/v4
response nodes, returning unverified nodes as results when there aren't
any verified nodes yet.

The "findnode failed" log now reports whether the node was dropped
instead of the number of results. The value of the "results" was
always zero by definition.

Co-authored-by: Felix Lange <fjl@twurst.com>
# Conflicts:
#	p2p/discover/v4_udp.go
2020-08-29 13:28:18 +02:00
Péter Szilágyi
476cb0c4c1 core/state/snapshot: reduce disk layer depth during generation
# Conflicts:
#	core/state/snapshot/generate.go
#	core/state/snapshot/journal.go
#	core/state/snapshot/snapshot.go
2020-08-29 13:26:41 +02:00
Martin Holst Swende
fa3ee4bf6b eth: utilize sync bloom for getNodeData (#21445)
* eth/downloader, eth/handler: utilize sync bloom for getNodeData

* trie: handle if bloom is nil

* trie, downloader: check bloom nilness externally
# Conflicts:
#	eth/handler.go
2020-08-29 13:26:15 +02:00
Martin Holst Swende
991a1c063d core: do less lookups when writing fast-sync block bodies (#21468) 2020-08-29 13:25:33 +02:00
gary rong
550bd11f9d core, eth, les, trie: add a prefix to contract code (#21080)
# Conflicts:
#	cmd/evm/internal/t8ntool/execution.go
#	consensus/clique/clique.go
#	consensus/ethash/consensus.go
#	core/block_validator.go
#	core/blockchain.go
#	core/blockchain_test.go
#	core/genesis.go
#	core/rawdb/accessors_indexes_test.go
#	core/rawdb/accessors_metadata.go
#	core/rawdb/chain_iterator_test.go
#	core/rawdb/database.go
#	core/rawdb/schema.go
#	core/state/database.go
#	core/state/iterator_test.go
#	core/state/statedb.go
#	core/state/sync.go
#	core/state/sync_test.go
#	core/tx_pool_test.go
#	core/types/block_test.go
#	core/types/derive_sha.go
#	eth/downloader/downloader.go
#	eth/downloader/queue.go
#	eth/downloader/statesync.go
#	eth/fetcher/block_fetcher.go
#	eth/fetcher/block_fetcher_test.go
#	eth/handler.go
#	les/odr_requests.go
#	les/server_handler.go
#	light/odr.go
#	light/odr_test.go
#	light/trie.go
#	miner/worker.go
#	trie/database.go
#	trie/secure_trie.go
#	trie/sync.go
#	trie/sync_bloom.go
#	trie/sync_test.go
2020-08-29 13:25:20 +02:00
Martin Holst Swende
b670cc44a5 eth/downloader: fix rollback issue on short chains 2020-08-29 12:30:17 +02:00
Marius van der Wijden
f6ba57ebc1 metrics: zero temp variable in updateMeter (#21470)
* metrics: zero temp variable in  updateMeter

Previously the temp variable was not updated properly after summing it to count.
This meant we had astronomically high metrics, now we zero out the temp whenever we
sum it onto the snapshot count

* metrics: move temp variable to be aligned, unit tests

Moves the temp variable in MeterSnapshot to be 64-bit aligned because of the atomic bug.
Adds a unit test, that catches the previous bug.
2020-08-29 12:30:07 +02:00
Péter Szilágyi
f734b7a0eb travis, dockerfile, appveyor, build: bump to Go 1.15
# Conflicts:
#	Dockerfile
#	Dockerfile.alltools
#	build/checksums.txt
2020-08-29 12:29:55 +02:00
Péter Szilágyi
bfac425c87 core: define and test chain rewind corner cases (#21409)
* core: define and test chain reparation cornercases

* core: write up a variety of set-head tests

* core, eth: unify chain rollbacks, handle all the cases

* core: make linter smile

* core: remove commented out legacy code

* core, eth/downloader: fix review comments

* core: revert a removed recovery mechanism
# Conflicts:
#	core/blockchain.go
#	core/blockchain_test.go
#	core/headerchain.go
#	core/rawdb/database.go
#	core/rawdb/freezer.go
#	core/rawdb/schema.go
#	eth/downloader/downloader.go
#	eth/sync.go
#	trie/sync.go
2020-08-29 12:29:00 +02:00
Alex Sharov
46a5d9c275
clean (#1001) 2020-08-29 17:07:12 +07:00
Alex Sharov
ca0bc897dc
clear logs (#1000) 2020-08-29 17:06:53 +07:00
Alex Sharov
5ce73d438a
fix integration (#999) 2020-08-29 15:27:20 +07:00
Alex Sharov
8c9a55bb21
[To test on HDD] Write changesets to tx instead of mutation (#978)
* use mutation over tx

* clear

* add .CommitAndBegin() method

* multip put 2

* right sorting

* write non-random things to tx

* write non-random things to tx

* disable multi put 2

* clean

* clean

* remove multiput2

* clean

* clean

* clean

* clean

* clean

* add receipts
2020-08-29 08:32:51 +01:00
Alex Sharov
07ca5c643a
eth_syncing (#991)
* eth_syncing

* linters

* fix readme

* cleanup cli params

* go mod tidy

* remove memsize ui dep

* remove bloomfilter

* implement net_peerCount

* remove legacy flags
2020-08-29 08:24:50 +01:00
Alex Sharov
bdb2e354ce
restapi_to_follog_geth_cli_variables (#993) 2020-08-28 11:27:56 +01:00
ledgerwatch
335aedc7e3
Cut down the stateGrowth generation code (#973)
* Cut down the stateGrowth generation

* Fix NPE

* Fix for lastTimestamp

* Adjust to the current state

* Potential fix

* Fix for shorter keys in the state

* Extract code

* Iterate over code
2020-08-28 10:31:37 +01:00
Alex Sharov
d30df505c8
Don't read cwd in blockchain validator, remove debug code (#992)
* print cwd

* don't read cwd, remove debug code

* oops, overdelete

* clean
2020-08-28 10:30:22 +01:00
Alex Sharov
d73b036cff
python_bublic_print_cli (#994) 2020-08-28 14:19:34 +07:00
Alex Sharov
de16812a94
move tx limit from 16 to 32 blocks (#988) 2020-08-28 07:28:08 +01:00
Alex Sharov
df05a581dd
Add tx pool stage to transaction (#981)
* add tx_pool stage to tx

* clean

* don't call commit in read tx

* don't call commit in read tx

* clean

* more logs

* fix tx pool race

* more logs

* clean
2020-08-28 07:27:48 +01:00
Suhabe Bugrara
8b31944611
Control Flow Analysis (#990)
* First

* More on SA interpreter

* Fixup

* Add cfg action to hack binary that invokes the SaInterpreter. Added an operation handler for PUSH1

* refactor cfg tests into separate file

* Move cfg tests into separate file

* More refactoring into new file

* dataflow interpreter

* work on cfg0

* finish cfg0

* df works on base examples

* refactor into dataflow spec

* add bounded stack

* add harder example

* fix switch pass thru

* fix switch pass thru

* bug fix, and better printing

* manual merge

* restore call to test gencfg

* abstract interpretation based cfg analysis

* fix post signature

* use uint256 instead uint64, add post function

* preprocess stmts

* initial implementation of resolve

* fix resolve

* fix resolve

* print stmts for edges

* print stmts for edges

* print states

* print states

* bug fixes, debugging

* fix jumpi dest - first working impl

* reachability analysis to filter out dead edges

* add all transfer functions

* larger contract bytecodes from solc compiler

* simple solidity contract goes thru

* add deposit contract bytecode

* rename deposit contract test

* fix new contract arg

* Address non-determinism leading to imprecise results

* improve debugging output

* improve debugging output

* improve debugging output

* fix for bug causing incorrect analysis results

* fix for bug causing incorrect analysis results

* fix for bug causing incorrect analysis results

* add more test cases

* fix coverage bug

* debugging for non-termination

* fix bad fixpoint check

* fix data inference

* fix transfer function for halting stmts

* switch to deposit contract test, disable debugging

* add anly counter to viz, fix stmt.valid check

* show all preds, adjust anlycounter behavior

* dfs instead of bfs to fail earlier

* viz improvements

* add worklist size to viz

* add test case for private functions

* valueset analysis

* add more checks to fail earlier in the analysis to help debugging, improve debugging output, catch additional bad jumps

* delete old code

* delete old code

* delete old code

* fix up minor changes to jump table

* copy over comments from cgf-1 branch

* remove minor diffs

* add recompiled deposit contract

* graph viz

* cleanup/refactoring

* initial impl of viz

* script to run cfg anly and generate dot file

* div example

* accept bytecode from cmd line

* add minimal deposit contract example

* replace valueset analysis with stackset analysis

* get in sync with master

* sync with master

* fix linting

* fix linting

* fix linting

* reformatting

* fix linting

* fix linting

* fix linting

* fix linting

* fix linting

* fix linting

* fix linting

Co-authored-by: Alexey Akhunov <akhounov@gmail.com>
2020-08-28 07:26:49 +01:00
Marius van der Wijden
08d3993cef core: more detailed metering for reorgs (#21420) 2020-08-27 21:23:51 +02:00
Alex Sharov
af81bb0de6
[merge after release] Simplified loader (#979)
* v0

* more docs, less customization

* more docs, less customization

* more docs, less customization

* don't store db reference

* rely on fact that lmdb key/value valid until end of transaction

* clean

* clean
2020-08-27 19:21:50 +01:00
Chase Wright
9d3c641664
Update Supported JSON-RPC calls in README (#983)
* Update Supported JSON-RPC calls in README

* Fix Hyperlinks
* Update list

* Include net / net_version

* Rename net.go to net_api.go

* Fix hyperlink for renamed net_api.go file
2020-08-27 19:19:58 +01:00
Martin Holst Swende
cac316dc82 cmd/evm: statet8n output folder + tx hashes on trace filenames (#21406)
* t8ntool: add output basedir

* t8ntool: add txhash to trace filename

* t8ntool: don't default to '.' basedir, allow absolute paths
# Conflicts:
#	cmd/evm/internal/t8ntool/execution.go
#	cmd/evm/internal/t8ntool/transition.go
2020-08-27 17:41:02 +02:00
Péter Szilágyi
8d7d853961 build: drop disco, enable groovy on Ubuntu PPAs
# Conflicts:
#	build/ci.go
2020-08-27 17:38:36 +02:00
Giuseppe Bertone
5388193c2c core/state: fixed some comments (#21450)
# Conflicts:
#	core/state/state_object.go
#	core/state/statedb.go
#	core/state/statedb_test.go
2020-08-27 17:38:12 +02:00
Marius van der Wijden
ece9515974 metrics: make meter updates lock-free (#21446) 2020-08-27 17:35:40 +02:00
Martin Holst Swende
db716f5864 cmd/geth/tests: try to fix spurious travis failure in les tests (#21410)
* cmd/geth/tests: try to fix spurious travis failure in les tests

* cmd/geth: les_test - remove extraneous option during boot
# Conflicts:
#	cmd/geth/les_test.go
2020-08-27 17:35:34 +02:00
Péter Szilágyi
26477944e5 params: begin v1.9.20 release cycle
# Conflicts:
#	params/version.go
2020-08-27 17:35:14 +02:00
Igor Mandrigin
03c1b48180 calver: start 2020.09.01 release 2020-08-27 10:55:52 +02:00
Igor Mandrigin
12aae871fd skip_analysis: update block number 2020-08-27 10:35:32 +02:00
Alex Sharov
f54812184b
make all in Dockerfile (#980) 2020-08-27 13:45:24 +07:00
Alex Sharov
584a5581c8
show "Done!" message only if stage took more than 30 sec (#977) 2020-08-27 12:43:37 +07:00
Alex Sharov
714e5041e2
Better logs3 (#976) 2020-08-26 19:06:51 +07:00
Alex Sharov
9091ce62bb
KV reduce features amount (#975)
* move IdealBatchSize method to Batch object :-)
remove cursor.Walk
remove kv.IdealBatchSize

* remove bolt_db.go file

* move method NoValueCursor to tx object
2020-08-26 07:03:50 +01:00