Share via


COR_GC_STATS Structure

Provides statistics about the garbage collection mechanism of the common language runtime (CLR).

typedef struct _COR_GC_STATS {
    ULONG   Flags; 
    SIZE_T  ExplicitGCCount;
    SIZE_T  GenCollectionsTaken[3];
    SIZE_T  CommittedKBytes; 
    SIZE_T  ReservedKBytes;
    SIZE_T  Gen0HeapSizeKBytes;
    SIZE_T  Gen1HeapSizeKBytes;
    SIZE_T  Gen2HeapSizeKBytes;
    SIZE_T  LargeObjectHeapSizeKBytes;
    SIZE_T  KBytesPromotedFromGen0;
    SIZE_T  KBytesPromotedFromGen1;
} COR_GC_STATS;

Members

Member

Description

Flags

Indicates which field values should be calculated and returned.

ExplicitGCCount

Indicates the number of garbage collections that were forced by external request.

GenCollectionsTaken

Indicates the number of garbage collections performed for each generation.

CommittedKBytes

The total number of kilobytes committed in all heaps.

ReservedKBytes

The total number of kilobytes reserved in all heaps.

Gen0HeapSizeKBytes

The size, in kilobytes, of the generation-zero heap.

Gen1HeapSizeKBytes

The size, in kilobytes, of the generation-one heap.

Gen2HeapSizeKBytes

The size, in kilobytes, of the generation-two heap.

LargeObjectHeapSizeKBytes

The size, in kilobytes, of the large object heap.

KBytesPromotedFromGen0

The size, in kilobytes, of the objects promoted from generation zero to generation one.

KBytesPromotedFromGen1

The size, in kilobytes, of the objects promoted from generation one to generation two.

Remarks

ICLRGCManager::GetStats requires an output parameter of type COR_GC_STATS.

Requirements

Platforms: Windows 2000, Windows XP, Windows Server 2003 family

Header: GCHost.idl

Library: Included as a resource in MSCorEE.dll

.NET Framework Version: 2.0, 1.1, 1.0

See Also

Concepts

Hosting Structures

Automatic Memory Management

Garbage Collection

Hosting the Common Language Runtime