perfview
perfview copied to clipboard
fix the places where we are still using Gens.GenLargeObj incorrectly
there are still places that mention Gens.GenLargeObj but should include POH. in TraceManagedProcess.cs -
SurvivalPercentOnEnd- when we updateUserAllocatedandGenSizeBeforeMB.GetFreeListEfficiency- should filter out POHGetAllocedSinceLastGCMBGetUserAllocated- only in assertAllocedSinceLastGCBasedOnAllocTickMBGetUserAllocatedPerHeap- there's a remark about LOH; on new enough versions we always fill in size_before/size_after (but I don't remember if this was changed before or after we added POH)GetHeapSizeBeforeMB- this one needs to get all generations. however while changing it I discovered it problems withPerHeapHistories.PerHeapHistories.Countis still 0 for BGC atOnEndtime because BGC' OnEnd is called during the processing of theHeapStatsevent while for blocking GCs it's atRestartEEStop.PerHeapHistories.Countis still 0 for BGC'sHeapStatsevent because we have't calledfire_peventsyet. I think we should fix this on the runtime side and callfire_peventsbefore callingdo_post_gcinbgc_thread_function. also the handling ofPerHeapHistoriesis questionable, for example, we should not have this line
if (_event.PerHeapHistories == null) { _event.PerHeapHistories = new List<GCPerHeapHistory>(); }
in ProcessPerHeapHistory as it should always be allocated.