runtime icon indicating copy to clipboard operation
runtime copied to clipboard

NativeAot: Enable GC event tracing on standalone GC

Open AustinWise opened this issue 1 year ago • 1 comments

Before this change, no GC events would be recorded when using dotnet trace on a NativeAOT program that uses standalone GC.

I copied the implementation from CoreCLR. The one change I made was to use a Crst instead of a spin lock.

Contributes to #90676

AustinWise avatar Jan 21 '24 00:01 AustinWise

Tagging subscribers to this area: @agocke, @MichalStrehovsky, @jkotas See info in area-owners.md if you want to be subscribed.

Issue Details

Before this change, no GC events would be recorded when using dotnet trace on a NativeAOT program that uses standalone GC.

I copied the implementation from CoreCLR. The one change I made was to use a Crst instead of a spin lock.

Contributes to #90676

Author: AustinWise
Assignees: -
Labels:

community-contribution, area-NativeAOT-coreclr

Milestone: -

ghost avatar Jan 21 '24 00:01 ghost

I experimented with the changes on Windows, here are the experiments:

Experiment 1: Capturing traces using dotnet-trace without clrgc. Experiment 2: Capturing traces using dotnet-trace with clrgc. Experiment 3: Capturing traces using ETW with clrgc.

All of these worked, in the sense that PerfView can show GCStats correctly on the captured trace.

cshung avatar Jan 22 '24 18:01 cshung