-
Notifications
You must be signed in to change notification settings - Fork 822
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
Wasm runtime tracing #1852
Comments
We just recently added support for middleware in #1839. You could use it to inject function calls before each opcode, for example :) |
Thanks for the answer @syrusakbary! As far as I gathered:
I cannot seem to find/retrieve the actual For one, I am looking for the actual counter (that I presume is on the Instance) that changes as I call the different functions on the Instance.exports functions. I am also looking for a runtime attachable for actual operation tracing on calls. Are these possible? |
We just merged the metering example, which I think fixes the issue you commented #1867 Let me know if that resolves the issue! |
Yes! It solves the problem with the metric numbers! Great work. For anyone stumbling upon this issue: My other problem still stands, that is appending another function to the operators. While I can get the remaining point now and it shows a value of 8751485 or 46682 being used (or whatever called function and parameters result), the mutex that I introduced as a counter into the cost_function stays at a value of 314474. In my earlier comment this was the number 1226118 I changed the cost function to always give 1 (with the original function it is still 1226118). I should probably implement a custom middleware for that I presume? edit: changed problems to numbers in the first line. |
Is this issue solved? |
One half of it is, the other part is not a concern right now. Closing Issue. |
Hey!
Right now I am looking for tracking the opcode execution inside the runtime. The closest I managed to find was the Trap backtrace in the upcoming 1.0.0-alpha5 version. But in my case I want to track not just in the case of error, but even in the case of correct execution. Adding the tracing into the wasm code itself is not an option.
Am I just missing to find it, or it is actually not an feature? Is it planned? Any suggestions?
The text was updated successfully, but these errors were encountered: