Make Async Profiler tests compatible with single threaded runtime.#127762
Make Async Profiler tests compatible with single threaded runtime.#127762lateralusX wants to merge 14 commits into
Conversation
|
Tagging subscribers to this area: @JulieLeeMSFT, @VSadov |
b3a77ba to
fe86a97
Compare
|
/azp run runtime-nativeaot-outerloop |
|
Azure Pipelines successfully started running 1 pipeline(s). |
|
/azp run runtime-nativeaot-outerloop |
|
Azure Pipelines successfully started running 1 pipeline(s). |
|
@MichalStrehovsky, I fixed up the async profiler tests in this PR and ran all on the NAOT outertloop pipeline, looking at the failure, they seem to be unrelated. Anything else that needs to be run from a NAOT perspective or all good? |
If these pass in runtime-nativeaot-outerloop, then LGTM! Thank you! |
Co-authored-by: Michal Strehovský <MichalStrehovsky@users.noreply.github.com>
Co-authored-by: Copilot Autofix powered by AI <175728472+Copilot@users.noreply.github.com>
|
/azp run runtime-nativeaot-outerloop |
|
Azure Pipelines successfully started running 1 pipeline(s). |
| int maxDynamicEventPayloadSize = wrapperIPs.Length * Serializer.MaxCompressedUInt64Size; | ||
| // [wrapperNameTemplateLength (compressed uint32)] | ||
| // [wrapperNameTemplate UTF8 bytes] | ||
| ReadOnlySpan<byte> templateBytes = ContinuationWrapper.NameTemplateUtf8; |
There was a problem hiding this comment.
Do you expect the names of the wrappers to change? Can the names of wrappers be part of the async profiler contract instead of sending a constant string in each metadata payload? It is common for diagnostic tools to have hardcoded managed type and method names.
There was a problem hiding this comment.
Probably not, but added it to have the flexibility since it felt bad to enforce the assumption as part of the contract, the metadata event is only emitted once per profiler session, so cheap.
Initial async profiler tests used some techniques to isolate tests running on thread pool, but that doesn't work on single threaded platforms like WASM.
With these changes we now have all tests running on CoreCLR, NativeAOT and 38 out of 48 tests running on CoreCLR WASM single threaded configuration.