ethereum / tests

Common tests for all Ethereum implementations

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

Question: what is a suitable stress test for a vm with shared memory/stack?

thedevbirb opened this issue · comments

Hi there! Sorry for bothering you.
On https://github.com/bluealloy/revm we're working on a shared stack between contexts (along with a shared memory already implemented). While discussing (bluealloy/revm#816 (comment)) we thought that maybe we can reuse some bytecode from here as a stress test.

In particular, we're looking for a test where we go both up and down in depth; the more calls and stressful it is, the better.
Right now, I've taken a look here https://github.com/ethereum/tests/tree/develop/src/GeneralStateTestsFiller/stCallCodes but they seems to do only a few calls (granted that I could have missed the good ones here).
I also thought that some of these could work https://github.com/ethereum/tests/tree/develop/src/GeneralStateTestsFiller/stCreate2 (e.g. Create2OnDepth1023.json).

In general, I'm asking if you happen to already know what tests would be good for this purpose.
Thanks a lot in advance for the help! 🙏

existing stack tests are only checking that it is possible to go to that depth and things are working.
I think here you better to develop a test that execute interesting (meaningful) code on many different stack levels

ah, there was Shaghai attack tests, in bcExploit with a huge revert.

Thanks a lot for the answer!