-
Notifications
You must be signed in to change notification settings - Fork 38
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
Consider refactoring EIP 2930 access list lookups #200
Comments
If the addresses/storage keys are never accessed you still need to charge gas for them? At least EIP 2039 description says:
That would mean that you always need to iterate over the whole access list. On the other hand, gas cost would impose a limit on the size of the list.
At least the kernel only calls |
We always go through it anyway to parse each addresses / storage keys.
Yeah, but I think it may still be prohibitive (30M gas limit allows for something like ~16k storage keys). If they are badly spread, the overhead would be quite large.
When parsing the txn RLP and decoding the access list, we then call |
Ahh, I see. I was missing that part. I suppose the easiest solution would be to wait until we solve #172. |
This isn't as much of a bottleneck anymore since #172. We can always revisit the approach once killer txns are weighted and gas repricing is done. Closing for now. |
Transactions can include EIP 2930 access lists containing address / storage key pairs which should be eagerly loaded into memory. In some cases these storage keys are never actually used by a transaction. As such both the kernel and the trace protocol are inefficient, and this potentially provides a DOS vector for the prover. We should consider refactoring this logic.
Quoted from @Nashtare:
Yeah agree, we could try revamping this part to remove the overhead, especially as SLOADs are a bit heavy and could be seen as some DOS entry door for the prover. Would need to think more about it how sound it would be to store arbitrary dummy value in non-accessed storage slots.
The text was updated successfully, but these errors were encountered: