Skip to content
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
15 changes: 13 additions & 2 deletions src/coreclr/vm/debuginfostore.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -1406,12 +1406,23 @@ void CompressDebugInfo::EnumMemoryRegions(CLRDataEnumMemoryFlags flags, PTR_BYTE
_ASSERTE(flagByte == 0);
}

NibbleReader r(pDebugInfo, 12 /* maximum size of compressed 2 UINT32s */);
NibbleReader r(pDebugInfo, 24 /* maximum size of compressed 4 UINT32s */);

ULONG cbBounds = r.ReadEncodedU32();
ULONG cbUninstrumentedBounds = 0;
if (cbBounds == DebugInfoBoundsHasInstrumentedBounds)
{
// This means we have instrumented bounds.
cbBounds = r.ReadEncodedU32();
cbUninstrumentedBounds = r.ReadEncodedU32();
}
ULONG cbVars = r.ReadEncodedU32();

pDebugInfo += r.GetNextByteIndex() + cbBounds + cbVars;
pDebugInfo += r.GetNextByteIndex() + cbBounds + cbUninstrumentedBounds + cbVars;

// NibbleReader reads in units of sizeof(NibbleChunkType)
// So we need to account for any partial chunk at the end.
pDebugInfo = AlignUp(dac_cast<TADDR>(pDebugInfo), sizeof(NibbleReader::NibbleChunkType));

DacEnumMemoryRegion(dac_cast<TADDR>(pStart), pDebugInfo - pStart);
}
Expand Down
Loading