Stream: git-wasmtime

Topic: wasmtime / PR #3687 Support vtune profiling of trampoline...


view this post on Zulip Wasmtime GitHub notifications bot (Jan 13 2022 at 18:12):

bnjbvr opened PR #3687 from profiling-trampolines to main:

This refactors the code as suggested to avoid duplication of demangling (and allows having a single crate depend on the demangling crate dependencies). Also implements supports for trampolines in vtune.

After poking at the code, my understanding was that module.trampolines() contained metadata about trampolines for exported wasm functions, while trampoline_load() would be called for trampolines into and out of imported wasm functions. Is that true @alexcrichton? Weirdly enough, even by adding some println statements to check if those trampolines were generated, I could only see the printed messages for module.trampolines(), not for the other one. Am I missing something in there?

view this post on Zulip Wasmtime GitHub notifications bot (Jan 13 2022 at 18:39):

alexcrichton submitted PR review.

view this post on Zulip Wasmtime GitHub notifications bot (Jan 13 2022 at 18:39):

alexcrichton submitted PR review.

view this post on Zulip Wasmtime GitHub notifications bot (Jan 13 2022 at 18:39):

alexcrichton created PR review comment:

Reading over this now, there's actually a fair bit supporting this map right here, but this map is only used for an assert that each item inserted is unique. I think that may mean perhaps that we could remove this entirely? (and not worry about MethodKind as a new enum)

view this post on Zulip Wasmtime GitHub notifications bot (Jan 17 2022 at 16:26):

bnjbvr updated PR #3687 from profiling-trampolines to main.

view this post on Zulip Wasmtime GitHub notifications bot (Jan 17 2022 at 16:27):

bnjbvr submitted PR review.

view this post on Zulip Wasmtime GitHub notifications bot (Jan 17 2022 at 16:27):

bnjbvr created PR review comment:

Indeed, the module id we feed ourselves and the signature index will always be different anyways, so this sanity check isn't worth the trouble.

Kept the mutex, though, because I'm unclear whether the ittapi function can be called from several threads at the same time :thinking:

view this post on Zulip Wasmtime GitHub notifications bot (Jan 17 2022 at 16:38):

bnjbvr updated PR #3687 from profiling-trampolines to main.

view this post on Zulip Wasmtime GitHub notifications bot (Jan 17 2022 at 17:05):

bnjbvr updated PR #3687 from profiling-trampolines to main.

view this post on Zulip Wasmtime GitHub notifications bot (Jan 17 2022 at 17:23):

bnjbvr updated PR #3687 from profiling-trampolines to main.

view this post on Zulip Wasmtime GitHub notifications bot (Jan 19 2022 at 15:06):

bnjbvr updated PR #3687 from profiling-trampolines to main.

view this post on Zulip Wasmtime GitHub notifications bot (Jan 19 2022 at 15:09):

bnjbvr requested alexcrichton for a review on PR #3687.

view this post on Zulip Wasmtime GitHub notifications bot (Jan 19 2022 at 15:49):

alexcrichton submitted PR review.

view this post on Zulip Wasmtime GitHub notifications bot (Jan 19 2022 at 15:49):

alexcrichton merged PR #3687.


Last updated: Oct 23 2024 at 20:03 UTC