duneanalytics / duneanalytics/evm.codes
Incorrect gas calculations for `CALL*` gas stipend
Nobody has claimed this yet.
- Dominant language
- TypeScript
- Stars
- 827
- Forks
- 199
- Avg merge
- 15m
- Merged PRs (30d)
- 1
Description
The gas calculator on the site for CALL* family opcodes is not correct; it subtracts the "gas stipend" cost from the total externally-observable cost of making the call. This means that the results of gas calculations for CALL* opcodes are 2300 lower than they should be (confirmed by testing against evmone).
I believe the fix should just be to delete this line from the call gas calculator; the stipend amount is only relevant when constructing the message to be sent to the callee account, not to the external gas calculations for the whole call.
Contributor guide
No contributing guide indexed for this repository
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
Research direction
Start in util/gas.ts at the call gas calculator around line 195. Compare the site's CALL* gas results with evmone, then verify that the externally observable call cost no longer includes the 2300 gas stipend and that the calculator reports the corrected values.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- typescript
- Domain
- blockchain
- Issue type
- Bug
- Difficulty
- 1/5
- Estimated time
- Under an hour
- Activity status
- Stale
- Clarity
- Clearly specified
- Newbie friendliness
- 45/100