Commit Graph

7351 Commits

Author SHA1 Message Date
Jeffrey Wilcke b196278044 core/vm: added JIT segmenting / optimisations
* multi-push segments
* static jumps segments
2015-10-16 22:30:42 +02:00
Jeffrey Wilcke 9d61d78de6 core/vm: abstracted instruction execution away from JIT
Moved the execution of instructions to the instruction it self. This
will allow for specialised instructions (e.g. segments) to be execution
in the same manner as regular instructions.
2015-10-16 22:17:35 +02:00
Jeffrey Wilcke 10ed107ba2 Merge pull request from obscuren/mipmap-bloom
core, eth/filters, miner, xeth: Optimised log filtering
2015-10-16 12:35:24 -07:00
Jeffrey Wilcke 6dc14788a2 core, eth/filters, miner, xeth: Optimised log filtering
Log filtering is now using a MIPmap like approach where addresses of
logs are added to a mapped bloom bin. The current levels for the MIP are
in ranges of 1.000.000, 500.000, 100.000, 50.000, 1.000. Logs are
therefor filtered in batches of 1.000.
2015-10-16 21:28:59 +02:00
Jeffrey Wilcke c5ef2afda5 Merge pull request from Gustav-Simonsson/ethash_godep
godeps: update ethash following GPU miner merge
2015-10-16 07:39:42 -07:00
Gustav Simonsson d5f56ad5c5 godeps: update ethash following GPU miner merge 2015-10-16 16:27:51 +02:00
Jeffrey Wilcke d5327ddc5f Merge pull request from Gustav-Simonsson/gpu_miner
all: Add GPU mining, disabled by default
2015-10-16 06:25:33 -07:00
Jeffrey Wilcke b747754009 Merge pull request from Gustav-Simonsson/state_new_error
core/state, core, miner: handle missing root error from state.New
2015-10-16 06:18:41 -07:00
Gustav Simonsson 1b1f293082 core/state, core, miner: handle missing root error from state.New 2015-10-16 02:22:06 +02:00
Jeffrey Wilcke f466243417 Merge pull request from Gustav-Simonsson/libsecp256k1_update
Update libsecp256k1, Go wrapper and tests
2015-10-15 10:46:57 -07:00
Jeffrey Wilcke 30f057aaf9 eth/filters: added benchmark 2015-10-15 19:45:44 +02:00
Jeffrey Wilcke cefe5c80b1 Merge pull request from karalabe/eventmux-post-race
core, eth, event, miner, xeth: fix event post / subscription race
2015-10-15 10:44:30 -07:00
Jeffrey Wilcke 2f1f2e4811 Merge pull request from Gustav-Simonsson/icap
common, crypto: add ICAP functions
2015-10-15 10:32:05 -07:00
Gustav Simonsson 2db9798646 common, crypto: add ICAP functions 2015-10-13 17:44:14 +02:00
Péter Szilágyi 402fd6e8c6 core, eth, event, miner, xeth: fix event post / subscription race 2015-10-12 16:22:03 +03:00
Jeffrey Wilcke 0de9b16b11 Merge pull request from karalabe/fix-vm-stack-logs
core/vm: copy stack element to prevent overwrites
2015-10-12 05:32:45 -07:00
Péter Szilágyi af9afb686b core/vm: copy stack element to prevent overwrites 2015-10-12 00:14:35 +03:00
Gustav Simonsson f32fa075f1 core/secp256k1: update libsecp256k1 Go wrapper and tests 2015-10-09 14:47:55 +02:00
Jeffrey Wilcke 315a422ba7 Merge pull request from obscuren/testnet
cmd, core, eth: added official testnet
2015-10-09 01:31:37 -07:00
Jeffrey Wilcke 1de796f101 cmd, core, eth: added official testnet 2015-10-08 22:01:39 +02:00
Jeffrey Wilcke 9e91579105 Merge pull request from karalabe/olympic-fix
cmd: properly initialize Olympic for all subcommands
2015-10-08 11:33:28 -07:00
Jeffrey Wilcke bba4dcb72f Merge pull request from Gustav-Simonsson/core_transfer
core, core/vm, cmd/evm: remove redundant balance check
2015-10-08 11:32:30 -07:00
Jeffrey Wilcke 37abbcb54b Merge pull request from Gustav-Simonsson/crypto_tests
crypto: correct sig validation, add missing unit tests of exported functions
2015-10-08 11:31:12 -07:00
Péter Szilágyi 2547c9c9b7 cmd: properly initialize Olympic for all subcommands 2015-10-07 18:25:33 +03:00
Gustav Simonsson ec6a548ee3 all: Add GPU mining, disabled by default 2015-10-07 13:19:30 +02:00
Jeffrey Wilcke 27528ad3d2 Merge pull request from bas-vk/historyfile
console/history respect datadir
2015-10-07 01:51:13 -07:00
Jeffrey Wilcke f8786defd0 Merge pull request from karalabe/genesis-block-receipts
core: fix , block receipts db entry for the genesis too
2015-10-07 01:50:37 -07:00
Gustav Simonsson e1616f77c7 core, core/vm, cmd/evm: remove redundant balance check 2015-10-06 12:42:34 +02:00
Jeffrey Wilcke 44fd395141 Merge pull request from obscuren/versioning
cmd/geth: dev version number
2015-10-05 12:35:42 -07:00
Jeffrey Wilcke 7b44b8aece cmd/geth: dev version number 2015-10-05 21:11:39 +02:00
Jeffrey Wilcke 13699e2dd9 Merge pull request from obscuren/head-write
core: fixed head write on block insertion
2015-10-05 11:00:57 -07:00
Jeffrey Wilcke 20ab29f885 core: fixed head write on block insertion
Due to a rebase this probably got overlooked / ignored. This fixes the
issue of a block insertion never writing the last block.
2015-10-05 17:00:59 +02:00
Jeffrey Wilcke 5b34fa538e Merge pull request from obscuren/core-refactor
core, core/vm: refactor
2015-10-05 07:14:01 -07:00
Jeffrey Wilcke 7c7692933c cmd/geth, cmd/utils, core, rpc: renamed to blockchain
* Renamed ChainManager to BlockChain
* Checkpointing is no longer required and never really properly worked
when the state was corrupted.
2015-10-04 01:13:56 +02:00
Jeffrey Wilcke 361082ec4b cmd/evm, core/vm, test: refactored VM and core
* Moved `vm.Transfer` to `core` package and changed execution to call
`env.Transfer` instead of `core.Transfer` directly.
* core/vm: byte code VM moved to jump table instead of switch
* Moved `vm.Transfer` to `core` package and changed execution to call
  `env.Transfer` instead of `core.Transfer` directly.
* Byte code VM now shares the same code as the JITVM
* Renamed Context to Contract
* Changed initialiser of state transition & unexported methods
* Removed the Execution object and refactor `Call`, `CallCode` &
  `Create` in to their own functions instead of being methods.
* Removed the hard dep on the state for the VM. The VM now
  depends on a Database interface returned by the environment. In the
  process the core now depends less on the statedb by usage of the env
* Moved `Log` from package `core/state` to package `core/vm`.
2015-10-04 01:13:54 +02:00
Jeffrey Wilcke f7a71996fb core, event/filter, xeth: refactored filter system
Moved the filtering system from `event` to `eth/filters` package and
removed the `core.Filter` object. The `filters.Filter` object now
requires a `common.Database` rather than a `eth.Backend` and invokes the
`core.GetBlockByX` directly rather than thru a "manager".
2015-10-02 22:47:43 +02:00
Jeffrey Wilcke 8b865fa9bf Merge pull request from karalabe/honor-eth-capabilities
eth/downloader: match capabilities when querying idle peers
2015-10-02 03:49:56 -07:00
Jeffrey Wilcke 0d78f96205 Merge pull request from obscuren/deadlock-chainmanager-fix
core: deadlock in chainmanager after posting RemovedTransactionEvent
2015-10-02 03:39:43 -07:00
Péter Szilágyi 47f62a67aa eth/downloader: match capabilities when querying idle peers 2015-10-02 13:20:41 +03:00
Jeffrey Wilcke a6cc02f68f core: deadlock in chainmanager after posting RemovedTransactionEvent
This PR solves an issue with the chain manager posting a
`RemovedTransactionEvent`, the tx pool will try to
acquire the chainmanager lock which has previously been locked prior to
posting `RemovedTransactionEvent`. This results in a deadlock in the
core.
2015-10-02 12:20:18 +02:00
Jeffrey Wilcke 49ae538506 Merge pull request from fjl/lean-trie
core, trie: new trie
2015-10-01 04:34:38 -07:00
Jeffrey Wilcke 581c0901af Merge pull request from karalabe/andorid-path-fix
common: fix , secondary datadir paths to fall back to
2015-10-01 04:03:04 -07:00
Péter Szilágyi 74578ab22b common: fix , secondary datadir paths to fall back to 2015-10-01 12:26:19 +03:00
Jeffrey Wilcke e3ac56d502 Merge pull request from fjl/fix-discover-refresh-race
p2p/discover: fix race involving the seed node iterator
2015-09-30 08:21:40 -07:00
Felix Lange 32dda97602 p2p/discover: ignore packet version numbers
The strict matching can get in the way of protocol upgrades.
2015-09-30 16:23:03 +02:00
Felix Lange 631bf36102 p2p/discover: remove unused lastLookup field 2015-09-30 16:23:03 +02:00
Felix Lange b4374436f3 p2p/discover: fix race involving the seed node iterator
nodeDB.querySeeds was not safe for concurrent use but could be called
concurrenty on multiple goroutines in the following case:

- the table was empty
- a timed refresh started
- a lookup was started and initiated refresh

These conditions are unlikely to coincide during normal use, but are
much more likely to occur all at once when the user's machine just woke
from sleep. The root cause of the issue is that querySeeds reused the
same leveldb iterator until it was exhausted.

This commit moves the refresh scheduling logic into its own goroutine
(so only one refresh is ever active) and changes querySeeds to not use
a persistent iterator. The seed node selection is now more random and
ignores nodes that have not been contacted in the last 5 days.
2015-09-30 16:23:03 +02:00
Jeffrey Wilcke 46ad5a5f5b Merge pull request from obscuren/filter-nil-fix
xeth: fixed nil pointer of filter retrieval
2015-09-30 03:06:36 -07:00
Jeffrey Wilcke 9b94076717 Merge pull request from karalabe/badhasherror-formatting-loop
core: fix a formatting loop in BadHashError
2015-09-29 02:26:01 -07:00
Péter Szilágyi b8b996be74 core: fix a formatting loop in BadHashError 2015-09-29 09:11:38 +03:00