0

In windbg using sos I can dump all the appdomains and they have a stage on them. I can't find any documentation stating what each of these stages mean. I assume this is documented but the property must not be stage and windbg just calls it stage, or something to that effect. Does anyone know what these stages mean? Here is an example of what I am looking for.

--------------------------------------
Domain 259:          28166cd0
LowFrequencyHeap:   2816713c
HighFrequencyHeap:  28167188
StubHeap:           281671d4
Stage:              CLEARED
Name:               /LM/W3SVC/74/ROOT-256-132290063549532385
Assembly:           01aa3d18 [C:\Windows\Microsoft.Net\assembly\GAC_32\mscorlib\v4.0_4.0.0.0__b77a5c561934e089\mscorlib.dll]
ClassLoader:        00f3e068
SecurityDescriptor: 01a535a8

--------------------------------------
Domain 289:          fcc7d660
LowFrequencyHeap:   fcc7dacc
HighFrequencyHeap:  fcc7db18
StubHeap:           fcc7db64
Stage:              OPEN
SecurityDescriptor: fb7880a0
Name:               /LM/W3SVC/74/ROOT-286-132290069625091994
Assembly:           01aa3d18 [C:\Windows\Microsoft.Net\assembly\GAC_32\mscorlib\v4.0_4.0.0.0__b77a5c561934e089\mscorlib.dll]
ClassLoader:        00f3e068
SecurityDescriptor: 28125040

--------------------------------------
Domain 288:          fcc7ccd8
LowFrequencyHeap:   fcc7d144
HighFrequencyHeap:  fcc7d190
StubHeap:           fcc7d1dc
Stage:              HANDLETABLE_NOACCESS
Name:               /LM/W3SVC/74/ROOT-285-132290069408995078
Assembly:           01aa3d18 [C:\Windows\Microsoft.Net\assembly\GAC_32\mscorlib\v4.0_4.0.0.0__b77a5c561934e089\mscorlib.dll]
ClassLoader:        00f3e068
Max Young
  • 1,522
  • 1
  • 16
  • 42
  • 1
    Corresponds to the m_Stage variable in the CLR. Stages are creating, readyformanagedcode, active, open, unload_requested, exiting, exited, finalizing, finalized, handletable_noaccess, cleared, collected, closed. Seems to be in order of lifetime of an ad, although active and open are fuzzy. – Hans Passant Mar 19 '20 at 16:05
  • 1
    https://github.com/dotnet/runtime/blob/2024b63acd460edeb53b2ce6984710ab51c11f2f/src/coreclr/src/vm/appdomain.hpp#L3639 – Hans Passant Mar 19 '20 at 16:08
  • @HansPassant sorry I should have noted that I found that but it didn't seem to provide information on what they mean. I am not well versed enough in the runtime code to make much sense of how they are using these stages. – Max Young Mar 19 '20 at 16:15
  • 2
    You should have. It is not documented. Microsoft testers know what it means, sos was created for them. I linked to the CLR version that still had the appdomain plumbing in place, you can look at appdomain.cpp to see how m_Stage is getting assigned. – Hans Passant Mar 19 '20 at 16:37

0 Answers0