DacpHeapSegmentData, struktura

Definiuje bufor transportu dla informacji o segmencie stert wyrzucania pamięci.

Note

Ten interfejs API został pierwotnie zaprojektowany do użytku wewnętrznego w środowisku uruchomieniowym. Mimo że jest ona teraz obsługiwana w przypadku używania innych firm, zalecamy pracę z interfejsami ICorDebug API i ICorProfiler , jeśli jest to możliwe.

Syntax

struct DacpHeapSegmentData
    : ZeroInit<DacpHeapSegmentData>
{
    CLRDATA_ADDRESS segmentAddr;
    CLRDATA_ADDRESS allocated;
    CLRDATA_ADDRESS committed;
    CLRDATA_ADDRESS reserved;
    CLRDATA_ADDRESS used;
    CLRDATA_ADDRESS mem;
    // pass this to request if non-null to get the next segments.
    CLRDATA_ADDRESS next;
    CLRDATA_ADDRESS gc_heap; // only filled in in server mode, otherwise NULL
    // computed field: if this is the ephemeral segment highMark includes the ephemeral generation
    CLRDATA_ADDRESS highAllocMark;

    size_t flags;
    CLRDATA_ADDRESS background_allocated;

    HRESULT Request(ISOSDacInterface *sos, CLRDATA_ADDRESS addr, const DacpGcHeapDetails& heap)
    {
        HRESULT hr = sos->GetHeapSegmentData(addr, this);

        // if this is the start segment, set highAllocMark too.
        if (SUCCEEDED(hr))
        {
            // TODO:  This needs to be put on the Dac side.
            if (this->segmentAddr == heap.generation_table[0].start_segment)
                highAllocMark = heap.alloc_allocated;
            else
                highAllocMark = allocated;
        }    
        return hr;
    }
};

Members

Członek Opis
segmentAddr Adres segmentu stert.
allocated Adres przydzielonej części segmentu.
committed Adres, do którego jest zatwierdzona pamięć dla segmentu.
reserved Adres, do którego pamięć jest zarezerwowana dla segmentu.
used Adres, do którego jest używana pamięć dla segmentu.
mem Adres początkowy pamięci segmentu.
next Adres następnego segmentu. Przekaż tę wartość do Request , jeśli ma wartość inną niż null, aby pobrać następny segment.
gc_heap Adres sterta GC. Ten element członkowski jest wypełniany tylko w trybie serwera; w przeciwnym razie jest to NULL.
highAllocMark Wysoki znacznik alokacji. Jeśli ten segment jest segmentem efemerycznym, ta wartość obejmuje generowanie efemeryczne.
flags Flagi segmentu stert.
background_allocated Adres przydzielony przez GC w tle dla segmentu.
Request Wypełnia strukturę przez wywołanie ISOSDacInterface::GetHeapSegmentData i obliczenia highAllocMark.

Remarks

Ta struktura znajduje się wewnątrz środowiska uruchomieniowego i nie jest uwidaczniona za pośrednictwem żadnych nagłówków ani plików biblioteki. Aby go użyć, zdefiniuj strukturę zgodnie z powyższymi definicjami.

Wymagania

Platformy: Zobacz Wymagania systemowe.
Nagłówek: Żaden
Biblioteka: Żaden
wersje platformy .NET: dostępne od wersji 4.7

Zobacz także