You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Assert failure in CompressDebugInfo::Compress — called with m_ILToNativeMapSize = 0 but m_pILToNativeMap != nullptr. Crashes across all interpreter legs.
Root Cause
PR #127469 changed InterpCompiler::EmitCodeIns() in src/coreclr/interpreter/compiler.cpp to only emit IL-to-native mappings for instructions that have the INTERP_INST_FLAG_EMPTY_IL_STACK flag set (~line 1058). However, the m_pILToNativeMap array is unconditionally allocated (~line 1181) based on total instruction count.
When a method has no instructions with INTERP_INST_FLAG_EMPTY_IL_STACK:
m_pILToNativeMap is allocated → non-null pointer
m_ILToNativeMapSize stays at 0 (no mappings emitted)
setBoundaries is called (~line 1262) with (count=0, buffer=non-null)
CompressDebugInfo::Compress asserts on the contradictory state
Potential Fix
Option A (minimal): Guard before setBoundaries call:
if (m_ILToNativeMapSize == 0)
{
m_pILToNativeMap = nullptr;
}
Option B (cleaner): Defer the array allocation until after the emission loop, sizing it to the actual count of instructions with INTERP_INST_FLAG_EMPTY_IL_STACK rather than total instruction count.
Activity
dotnet-policy-service commentedon May 1, 2026
Tagging subscribers to this area: @JulieLeeMSFT, @jakobbotsch
See info in area-owners.md if you want to be subscribed.
dotnet-policy-service commentedon May 1, 2026
Tagging subscribers to this area: @JulieLeeMSFT, @BrzVlad, @janvorli, @kg
See info in area-owners.md if you want to be subscribed.
JulieLeeMSFT commentedon May 1, 2026
CC @vitek-karas @BrzVlad @janvorli.
mangod9 commentedon May 2, 2026
Some analysis, FYI @tommcdon
Interpreter Assert —
CompressDebugInfo::Compressprecondition violationAffected legs: All interpreter CI legs (windows x64/x86/arm64, linux x64/arm64)
Regression from: PR #127469
Symptoms
Assert failure in
CompressDebugInfo::Compress— called withm_ILToNativeMapSize = 0butm_pILToNativeMap != nullptr. Crashes across all interpreter legs.Root Cause
PR #127469 changed
InterpCompiler::EmitCodeIns()insrc/coreclr/interpreter/compiler.cppto only emit IL-to-native mappings for instructions that have theINTERP_INST_FLAG_EMPTY_IL_STACKflag set (~line 1058). However, them_pILToNativeMaparray is unconditionally allocated (~line 1181) based on total instruction count.When a method has no instructions with
INTERP_INST_FLAG_EMPTY_IL_STACK:m_pILToNativeMapis allocated → non-null pointerm_ILToNativeMapSizestays at 0 (no mappings emitted)setBoundariesis called (~line 1262) with(count=0, buffer=non-null)CompressDebugInfo::Compressasserts on the contradictory statePotential Fix
Option A (minimal): Guard before
setBoundariescall:Option B (cleaner): Defer the array allocation until after the emission loop, sizing it to the actual count of instructions with
INTERP_INST_FLAG_EMPTY_IL_STACKrather than total instruction count.Pass null to setBoundaries if the il to native map is empty (#128428)
Pass null to setBoundaries if the il to native map is empty (#128428)