Skip to content
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

Support guest profiling for components #8773

Open
yoshuawuyts opened this issue Jun 11, 2024 · 0 comments
Open

Support guest profiling for components #8773

yoshuawuyts opened this issue Jun 11, 2024 · 0 comments

Comments

@yoshuawuyts
Copy link

Feature

Enable the following to work:

wasmtime serve ./my-component.wasm --profile=guest

Benefit

In general: profiling is useful and it's neat to be able to profile wasm components.

For me specifically though: I'm on MacOS and setting up native trace tools requires turning off security features in the kernel. I've not been able to do so successfully, so as a result I (somewhat embarrassingly) don't currently have a working perf command on my machine. Because wasmtime's guest profiler doesn't interact with the kernel at all, this seems like the ideal way to resolve it, basically by providing a portable, OS-agnostic profiling suite.

Implementation

There is a working guest profiler available already, but trying to run it on components gives the following error message:

Error: Cannot use the guest profiler with components

I don't really have insight in what it would take to implement support for components. But I figured it would be desirable - and I didn't see it being tracked already, so I figured we should. Folks with more knowledge about the challenges here should probably chime in though.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant