Coder Social home page Coder Social logo

hangs upon execution about evmdis HOT 4 OPEN

arachnid avatar arachnid commented on September 28, 2024
hangs upon execution

from evmdis.

Comments (4)

Macil avatar Macil commented on September 28, 2024

Yeah I'm having the same behavior too. http://blog.curvegrid.com/daysofblock/2017/05/11/daysofblock-01-evmdis.html makes it look like you are in fact supposed to pass the input through stdin, but my results match up with you rather than that blog post.

from evmdis.

shoenseiwaso avatar shoenseiwaso commented on September 28, 2024

@nolash, you need to pipe the hex into evmdis, it won't take a file as a parameter. So your cat <binfile> | evmdis -log is the right idea. I suspect what's happening with the short output is your <binfile> has a newline on the end, which causes that output.

Compare the following. evmdis-issue-6-orig-crlf.hex has a newline on the end and evmdis-issue-6-orig.hex doesn't, otherwise they are identical. I copied the compiled Solidity hex code you pasted verbatim:

$ cat evmdis-issue-6-orig-crlf.hex | evmdis -log
2017/09/12 21:08:10 Entering block at 0 with stack height 0
# Stack: []
0x0	STOP()

$ cat evmdis-issue-6-orig.hex | evmdis -log
2017/09/12 21:06:51 Entering block at 0 with stack height 0
2017/09/12 21:06:51 Entering block at 55 with stack height 1
2017/09/12 21:06:51 Entering block at 66 with stack height 1
2017/09/12 21:06:51 Entering block at 105 with stack height 1
2017/09/12 21:06:51 Entering block at 110 with stack height 1
2017/09/12 21:06:51 Entering block at 115 with stack height 1
2017/09/12 21:06:51 Entering block at 132 with stack height 3
2017/09/12 21:06:51 Entering block at 138 with stack height 3
2017/09/12 21:06:51 Entering block at 124 with stack height 1
2017/09/12 21:06:51 Entering block at 71 with stack height 1
2017/09/12 21:06:51 Entering block at 76 with stack height 1
2017/09/12 21:06:51 Entering block at 81 with stack height 1
2017/09/12 21:06:51 Entering block at 126 with stack height 2
2017/09/12 21:06:51 Entering block at 87 with stack height 3
# Stack: []
0x4	MSTORE(0x40, 0x60)
0x2C	PUSH(CALLDATALOAD(0x0) / 0x100000000000000000000000000000000000000000000000000000000 & 0xFFFFFFFF)
0x32	DUP1
0x36	JUMPI(:label0, POP() == 0x7C2EFCBA)

# Stack: [@0x2C]
0x37	DUP1
0x40	JUMPI(:label3, 0xDB80813F == POP())

# Stack: [@0x2C]
0x42	PUSH(0x0)
<snip>

Hope that helps!

And obviously a future enhancement opportunity to improve the help text (evmdis -h), README and overall handling of newlines.

from evmdis.

shoenseiwaso avatar shoenseiwaso commented on September 28, 2024

@agentme could you check my previous comment and see if that helps?

from evmdis.

Macil avatar Macil commented on September 28, 2024

Yep, it was the newline at the end! Works great when I cut that out, thanks!

from evmdis.

Related Issues (14)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.