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
{{ message }}
Repository navigation
[clr-ios] FuncEval does not work on iOS because executable memory allocation fails #125959
FuncEval does not work on iOS because executable memory allocation fails. This has two causes: the PAL does not enable MAP_JIT on iOS, and the debugger heap crashes when VirtualAlloc returns NULL.
Impact
Property evaluation in the variables panel, Debug Console expressions, conditional breakpoints with expressions, and ToString() don't work.
Root cause
1. MAP_JIT not enabled for iOS
The PAL gates MAP_JIT support (virtual.cpp line 586) and PAL_JitWriteProtect (pal.h) on HOST_OSX. On iOS, HOST_IOS is defined but HOST_OSX is not, so VirtualAlloc with PAGE_EXECUTE_READWRITE always returns NULL and PAL_JitWriteProtect is a no-op.
2. AddNewPage crashes on NULL DebuggerHeapExecutableMemoryAllocator::AddNewPage does not check for VirtualAlloc returning NULL. It proceeds to placement-new on the NULL pointer, causing SIGSEGV.
changed the title [-][clr-ios] PAL does not enable MAP_JIT for iOS targets, and AddNewPage crashes when VirtualAlloc fails[/-][+][clr-ios] FuncEval does not work on iOS because executable memory allocation fails.[/+]on Mar 24, 2026
changed the title [-][clr-ios] FuncEval does not work on iOS because executable memory allocation fails.[/-][+][clr-ios] FuncEval does not work on iOS because executable memory allocation fails[/+]on Mar 24, 2026
Activity
dotnet-policy-service commentedon Mar 23, 2026
Tagging subscribers to this area: @agocke, @jeffschwMSFT, @elinor-fung
See info in area-owners.md if you want to be subscribed.
dotnet-policy-service commentedon Mar 23, 2026
Tagging subscribers to 'os-ios': @vitek-karas, @kotlarmilos, @steveisok, @akoeplinger
See info in area-owners.md if you want to be subscribed.
dotnet-policy-service commentedon Mar 23, 2026
Tagging subscribers to this area: @BrzVlad, @janvorli, @kg
See info in area-owners.md if you want to be subscribed.
jkotas commentedon Mar 23, 2026
What are these thunks? Can we get rid of them to pave the way for wasm?
[-][clr-ios] PAL does not enable MAP_JIT for iOS targets, and AddNewPage crashes when VirtualAlloc fails[/-][+][clr-ios] FuncEval does not work on iOS because executable memory allocation fails.[/+][-][clr-ios] FuncEval does not work on iOS because executable memory allocation fails.[/-][+][clr-ios] FuncEval does not work on iOS because executable memory allocation fails[/+][clr-interp] Add initial CoreCLR interpreter func-eval support (#126576)
[clr-interp] Add initial CoreCLR interpreter func-eval support (#126576)