Why is ContextStatefulPrecompileMut
not allowed in Precompiles?
#15091
Replies: 3 comments 4 replies
-
This example doc is slightly outdated, but this example specifically implements a precompile cache. Caching the result of a stateful precompile would mean that we then have to invalidate cached results if the state changed. Whereas caching stateless precompile results indefinitely is clearly valid |
Beta Was this translation helpful? Give feedback.
-
Hey @Rjected, we have been experimenting a bit lately with custom precompiles, but seems like it is a reth issue on calling precompiles. Seems like gas accounting is wrong somewhere:
You can reproduce this at your end by following this repository: https://github.com/supragya/reth-precompile-failures/tree/d7b15744f2c061d7051bf1165653011b31794c37 |
Beta Was this translation helpful? Give feedback.
-
Beta Was this translation helpful? Give feedback.
Uh oh!
There was an error while loading. Please reload this page.
-
The stateful-precompile example explicitly says:
Why so?
What if a precompile is not "pure", but intends to have side effects like doing an
sstore
internally. Is that not allowed?Beta Was this translation helpful? Give feedback.
All reactions