maoni

.NET GC Architect, .NET Runtime Team

Loves working on #dotnet #dotnetcore GC and other perf stuff.

Post by this author

Garbage Collection at Food Courts

When I first started working on the GC, my predecessor was explaining the GC tuning to me. I told him that I thought it sounded like how I saw janitors work at food courts (I frequented food courts at the time 😀). And he concurred. What I said was if you observe at a food court, in order to be productive, the janitor tries to collect a ...

GC Handles

A customer asked me about analyzing perf related to GC handles. I feel like aside from pinned handles in general handles are not talked about much so this topic warrants some explanation, especially since this is a user facing feature. For some background info, GC handles are indeed generational so when we are doing ephemeral GCs we only need...

GC Perf Infrastructure – Part 1

We open sourced our new GC Perf Infrastructure! It’s now part of the dotnet performance repo. I’ve been meaning to write about it ‘cause some curious minds had been asking when they could use it after I blogged about it last time but didn’t get around to it till now. First of all, let me point out that the target audience of this ...

The history of the GC configs

Recently, Nick from Stack Overflow tweeted about his experience of using the .NET Core GC configs – he seemed quite happy with them (minus the fact they are not documented well which is something I’m talking to our doc folks about). I thought it’d be fun to tell you about the history of the GC configs ‘cause it’s almost the weekend ...

Finalization implementation details

Years ago I wrote a document on making finalization scanning concurrent. At the time there was an internal team that was using finalization as a way to resurrect objects and putting them back in their cache. While we’ve always advised to folks that finalization was for releasing native resources I couldn’t fault this team for using it the ...

GC Perf Infrastructure – Part 0

In this blog entry and some future ones I will be showing off functionalities that our new GC perf infrastructure provides. Andy and I have been working on it (he did all the work; I merely played the consultant role). We will be open sourcing it soon and I wanted to give you some examples of using it and you can add these to your repertoire ...

A portable way to get GC events in process and no admin privilege with 10 lines of code (and ability to dynamically enable/disable events)

I’ve been talking about doing managed heap performance analysis with ETW events for ages because ETW is just such a powerful tool. It has a well defined format so many components, from kernel modes to user mode ones, all emit ETW events which means you can have tools that just know how to parse the event format and correlate them. At ...

Making CPU configuration better for GC on machines with > 64 CPUs

If you are running Windows on a machine with > 64 CPUs, you’ll need to use this feature called the CPU groups for your process to be able to use more than 64 CPUs. At some point in the far distant past, people thought having more than 64 processors on a machine was inconceivable so they used a 64-bit number for the processor mask. And when ...

Running with Server GC in a Small Container Scenario Part 1 – Hard Limit for the GC Heap

I’ve checked in 2 configs related to specifying a hard limit for the GC heap memory usage so I wanted to describe them and how they are intended to be used. Feedback would be greatly appreciated. In order to talk about the new configs it’s important to understand what consists of the memory usage in a process. When it comes to memory ...

Running with Server GC in a Small Container Scenario Part 0

This week I was able to get some time to work on the container stuff with low memory limits. As many of you have expressed your dissatisfaction on how Server GC behaves with low memory limit specified on containers on github, I have to apologize that I am just doing this now. Really sorry that some of you guys have to suffer through this thus ...