-
Notifications
You must be signed in to change notification settings - Fork 765
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
Validate stack items after operations #222
Conversation
462d5ad
to
71c341c
Compare
This needs to be updated after #219 (or vice versa). |
71c341c
to
35e8ddc
Compare
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I think this will work well after #219 is properly finished and this one rebased. |
35e8ddc
to
a694a86
Compare
I took another look at this one. Still couldn't figure out what is causing the callback error that we are seeing here. gotta love async.... |
@jwasinger probably missed one of the functions since there were so many rebases over 1.5 years :) |
46ded1f
to
332b5ca
Compare
I think I should have fixed this now. |
Hi @axic , @jwasinger , I looked at this PR, I found out that SWAP opcode has this configuration: // name, baseCost, offStack, onStack, dynamic
0x90: ['SWAP', 3, 0, 0, false], onStack is 0, swap opcode returns the swaped element https://github.com/ethereumjs/ethereumjs-vm/blob/master/lib/opFns.js#L483 , which has to be pushed again to the stack. I changed onStack from 0 to 1 for the SWAP opcode, and the failed tests went from 868 to 43. The remaining failing tests are related to the async opcodes (CALL, CALLCODE, and DELEGATECALL) |
@hugo-dc good find! I think though that |
332b5ca
to
6033239
Compare
@hugo-dc @jwasinger rebased after the other fix, this should work now? |
isn't |
@axic I confirm all state tests are passing after the fix 👍 |
This helped find some of the bugs already fixed, though it may be useful in the future too.