-
Notifications
You must be signed in to change notification settings - Fork 13
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
eth/tracers: replace hardcoded txGas with actual #7
eth/tracers: replace hardcoded txGas with actual #7
Conversation
* (mobile): Adds string representations for types * mobile: better interfaces add stringer to types Co-authored-by: sarath <sarath@melvault.com>
This change moves the RLPx protocol implementation into a separate package, p2p/rlpx. The new package can be used to establish RLPx connections for protocol testing purposes. Co-authored-by: Felix Lange <fjl@twurst.com>
…thereum#21545) This allows users to estimate gas on top of arbitrary blocks as well as pending and latest. Tracing on pending is useful for most users as it takes into account the current txpool while tracing on latest might be useful for users that have little to know knowledge of the current transactions in the network. If blockNrOrHash is not specified, estimateGas defaults to pending
* trie: support non-existent right proof * trie: improve test * trie: minor linter fix Co-authored-by: Péter Szilágyi <peterke@gmail.com>
…hereum#21601) * tried to fix * fix for js api * fix for nil pointer ex * rev space * rev space * input call formatter
This change adds a test framework for the "eth" protocol and some basic tests. The tests can be run using the './devp2p rlpx eth-test' command.
params: update CHTs for Geth v1.9.22
…terface (ethereum#21091) * accounts/abi: refactored abi.Unpack * accounts/abi/bind: fixed error * accounts/abi/bind: modified template * accounts/abi/bind: added ToStruct for conversion * accounts/abi: reenabled tests * accounts/abi: fixed tests * accounts/abi: fixed tests for packing/unpacking * accounts/abi: fixed tests * accounts/abi: added more logic to ToStruct * accounts/abi/bind: fixed template * accounts/abi/bind: fixed ToStruct conversion * accounts/abi/: removed unused code * accounts/abi: updated template * accounts/abi: refactored unused code * contracts/checkpointoracle: updated contracts to sol ^0.6.0 * accounts/abi: refactored reflection logic * accounts/abi: less code duplication in Unpack* * accounts/abi: fixed rebasing bug * fix a few typos in comments * rebase on master Co-authored-by: Guillaume Ballet <gballet@gmail.com>
* mobile: added constructor for big int * mobile: tiny nitpick
…thereum#21572) * Fix potential memory leak in price heap * core: nil free pointer slice (alternative version) Co-authored-by: Martin Holst Swende <martin@swende.se>
* ci: tooltips for javadoc for mobile app * f space
core/types: use stacktrie for derivesha trie: add stacktrie file trie: fix linter core/types: use stacktrie for derivesha rebased: adapt stacktrie to the newer version of DeriveSha Co-authored-by: Martin Holst Swende <martin@swende.se> More linter fixes review feedback: no key offset for nodes converted to hashes trie: use EncodeRLP for full nodes core/types: insert txs in order in derivesha trie: tests for derivesha with stacktrie trie: make stacktrie use pooled hashers trie: make stacktrie reuse tmp slice space trie: minor polishes on stacktrie trie/stacktrie: less rlp dancing core/types: explain the contorsions in DeriveSha ci: fix goimport errors trie: clear mem on subtrie hashing squashme: linter fix stracktrie: use pooling, less allocs (#3) trie: in-place hex prefix, reduce allocs and add rawNode.EncodeRLP Reintroduce the `[]node` method, add the missing `EncodeRLP` implementation for `rawNode` and calculate the hex prefix in place. Co-authored-by: Martin Holst Swende <martin@swende.se> Co-authored-by: Martin Holst Swende <martin@swende.se>
* accounts, signer: implement gnosis safe support * common/math: add type for marshalling big to dec * accounts, signer: properly sign gnosis requests * signer, clef: implement account_signGnosisTx * signer: fix auditlog print, change rpc-name (signGnosisTx to signGnosisSafeTx) * signer: pass validation-messages/warnings to the UI for gnonsis-safe txs * signer/core: minor change to validationmessages of typed data
* 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>
…hereum#21649) * core/state/snapshot: exit Geth if generator hits missing trie nodes * core/state/snapshot: error instead of hard die on generator fault * core/state/snapshot: don't enable logging on the tests
…rning structs (ethereum#22005) Fixes the template used when generating code, which in some scenarios would lead to panic instead of returning an error.
* doc: clarify abigen alias flag usage update the `abigen --alias` flag help info, give an example to make it more clear related issue: ethereum#21846 * Update cmd/abigen/main.go Co-authored-by: ligi <ligi@ligi.de> Co-authored-by: Martin Holst Swende <martin@swende.se> Co-authored-by: ligi <ligi@ligi.de>
This commit splits the eth package, separating the handling of eth and snap protocols. It also includes the capability to run snap sync (https://github.com/ethereum/devp2p/blob/master/caps/snap.md) , but does not enable it by default. Co-authored-by: Marius van der Wijden <m.vanderwijden@live.de> Co-authored-by: Martin Holst Swende <martin@swende.se>
* les: allow tx unindexing in les/4 light server mode * les: minor fixes * les: more small fixes * les: add meaningful constants for recentTxIndex handshake field
How about setting 'intrinsicGas' as another param on the ctx, instead of adding it to gasUsed. The way you did it makes certain usecases work better, and other usecases regress (if one doesn't care about intrinsic, but just wants the gas used by the execution).Also it's a bit unintuitive that the go-method CaptureEnd gets a gasUsed as input, but that's not what the JsTracer sees. So I'd pefert a second field personally
|
Makes sense, I'll do that
Just to clarify, you're saying we should compute intrinsicGas in |
Just to clarify, you're saying we should compute intrinsicGas in evm.go and pass it to CaptureEnd (in addition to the current gasUsed)? I can do that
Actually I didn't mean that, I meant that the js thingy would calculate it, like you did, and set it inside the javascript-object. But the other way might work aswell, but have larger ramifications.
|
Sorry I had misunderstood and thought this is a different point from Fixed that issue now, but I messed up the PR...I merged master into this branch to fix the conflicts but now it has a massive diff which makes it hard to review, sorry. Any ideas? |
Yep, here's what we do
Well, depending on how you have it configured. I recommend having
To push it to your branch |
7acf031
to
7b5bfae
Compare
eth/tracers: include tx gas in tracers usedGas eth/tracers: fix prestate tracer's sender balance eth/tracers: rm unnecessary import eth/tracers: pass intrinsicGas separately to tracer eth/tracers: fix tests broken by lack of txdata eth, eth/tracers: minor fix
7b5bfae
to
c4e1371
Compare
Thanks. I chose the easy way and used merge instead of rebase...I've now rebased but this PR still has the massive diff I think because it has a different history from Guillaume's branch. I created a fresh PR ethereum#22038 directly against master. Will close this afterwards. |
18d89f5
to
87dffcf
Compare
…er (#7) (ethereum#22989) Co-authored-by: Gary Rong <garyrong0905@gmail.com> Co-authored-by: Mikhail Kalinin <noblesse.knight@gmail.com>
So a few comments here:
isHomestead
andisIstanbul
values and didn't store them in thectx
map because that would expose them to js. So stored them in theTracer
struct insteadv3.1.2
? which version do you use?