Stream: git-wasmtime

Topic: wasmtime / PR #7809 demange names in guest-profiler output


view this post on Zulip Wasmtime GitHub notifications bot (Jan 24 2024 at 14:37):

high-cloud opened PR #7809 from high-cloud:demangle_wip to bytecodealliance:main:

<!--
Please make sure you include the following information:

Our development process is documented in the Wasmtime book:
https://docs.wasmtime.dev/contributing-development-process.html

Please ensure all communication follows the code of conduct:
https://github.com/bytecodealliance/wasmtime/blob/main/CODE_OF_CONDUCT.md
-->
issue #7665

view this post on Zulip Wasmtime GitHub notifications bot (Jan 24 2024 at 14:37):

high-cloud requested alexcrichton for a review on PR #7809.

view this post on Zulip Wasmtime GitHub notifications bot (Jan 24 2024 at 14:37):

high-cloud requested wasmtime-core-reviewers for a review on PR #7809.

view this post on Zulip Wasmtime GitHub notifications bot (Jan 24 2024 at 14:57):

high-cloud updated PR #7809.

view this post on Zulip Wasmtime GitHub notifications bot (Jan 24 2024 at 15:00):

high-cloud updated PR #7809.

view this post on Zulip Wasmtime GitHub notifications bot (Jan 24 2024 at 16:45):

github-actions[bot] commented on PR #7809:

Subscribe to Label Action

cc @peterhuene

<details>
This issue or pull request has been labeled: "wasmtime:api"

Thus the following users have been cc'd because of the following labels:

To subscribe or unsubscribe from this label, edit the <code>.github/subscribe-to-label.json</code> configuration file.

Learn more.
</details>

view this post on Zulip Wasmtime GitHub notifications bot (Jan 24 2024 at 17:46):

jameysharp submitted PR review:

This is great, thank you!

I hesitated about the use of unwrap, but demangle_function_name can only fail if the writer fails, and I don't think the Write implementation for String can fail, so I'll sign off that this use is fine. We have another unwrap on the use of this function in CompiledModule::register_debug_and_profiling, anyway.

While looking at that, I just noticed that there's a demangle_function_name_or_index function which is very similar to what this whole match statement does. I think it's harmless to duplicate that here, with a slightly different format for the fallback case when there's no function name.

I'm going to merge this as-is. But if you want to open a follow-up PR, I think it would be an improvement to use demangle_function_name_or_index here.

view this post on Zulip Wasmtime GitHub notifications bot (Jan 24 2024 at 18:15):

jameysharp merged PR #7809.


Last updated: Oct 23 2024 at 20:03 UTC