Select to view content in your preferred language

Layers from .mmpk files crash WPF app

668
1
10-14-2021 12:41 PM
TomBara
New Contributor

Hi, we have WPF (.NET Framework 4.8) with Esri.ArcGISRuntime, Esri.ArcGISRuntime.runtimes.win, and Esri.ArcGISRuntime.WPF (all 100.11 versions). We are loading layers from .mmpk files and displaying them on a map. When the app is published in debug mode, all works fine. When the app is published in release mode, it crashes within a few seconds of either panning the map or zooming in and out. The more graphics a layer has, the quicker the app crashes. When .vtpk files (with exact same information) are used instead of  the .mmpk files, the app works fine.

A dump file generated by the crash has this information indicating that the problem happens in the runtimecore.dll:

CONTEXT: (.ecxr)
eax=0000000c ebx=00000000 ecx=0ad80d70 edx=0ad80d70 esi=0000000c edi=0ad80d70
eip=11f1cd86 esp=2fa8d188 ebp=2fa8d18c iopl=0 nv up ei pl nz na po nc
cs=0023 ss=002b ds=002b es=002b fs=0053 gs=002b efl=00010202
runtimecore!SkBaseDevice::SkBaseDevice+0x16:
11f1cd86 8b0e mov ecx,dword ptr [esi] ds:002b:0000000c=????????
Resetting default scope

EXCEPTION_RECORD: (.exr -1)
ExceptionAddress: 11f1cd86 (runtimecore!SkBaseDevice::SkBaseDevice+0x00000016)
ExceptionCode: c0000005 (Access violation)
ExceptionFlags: 00000000
NumberParameters: 2
Parameter[0]: 00000000
Parameter[1]: 0000000c
Attempt to read from address 0000000c

PROCESS_NAME: MyProgram.exe

READ_ADDRESS: 0000000c

ERROR_CODE: (NTSTATUS) 0xc0000005 - The instruction at 0x%p referenced memory at 0x%p. The memory could not be %s.

EXCEPTION_CODE_STR: c0000005

EXCEPTION_PARAMETER1: 00000000

EXCEPTION_PARAMETER2: 0000000c

STACK_TEXT:
2fa8d18c 11f2ac12 0000000c 2fa8f4ac 42898de6 runtimecore!SkBaseDevice::SkBaseDevice+0x16
2fa8d1c4 11eecdbb 00000000 2fa8f4ac 00000000 runtimecore!SkBitmapDevice::SkBitmapDevice+0x42
2fa8d220 1115ae36 00000000 00000000 00000000 runtimecore!SkCanvas::SkCanvas+0x13b
2fa8f4fc 11156eeb 00000000 2fa8f550 2cc22660 runtimecore!esri::Map_renderer::Canvas_layer::Render_properties::Display_list_collection::set_display_list+0x216
2fa8f584 11159426 2d88dc7c 4289aa26 ffffffff runtimecore!esri::Map_renderer::Canvas_drawable::draw_layer_+0x2ab
2fa8f604 100936a2 112f0f19 4289aa7a 2d542278 runtimecore!<lambda_63269ec17a9a1afc93e0e5efc624ae6d>::operator()+0xc6
2fa8f608 112f0f19 4289aa7a 2d542278 2d542288 runtimecore!std::_Func_impl_no_alloc<<lambda_fbfe540b7589c2b09cbd9ad0d74b0839>,unsigned char>::_Do_call+0x12
2fa8f658 112ee982 2d319a18 4289aab2 05f751d0 runtimecore!pplx::task<unsigned char>::_InitialTaskHandle<void,<lambda_63269ec17a9a1afc93e0e5efc624ae6d>,pplx::details::_TypeSelectorNoAsync>::_Init+0xd9
2fa8f690 10092677 4289aa8e 318b4130 2fa8f6d8 runtimecore!pplx::details::_PPLTaskHandle<unsigned char,pplx::task<unsigned char>::_InitialTaskHandle<void,<lambda_63269ec17a9a1afc93e0e5efc624ae6d>,pplx::details::_TypeSelectorNoAsync>,pplx::details::_TaskProcHandle>::invoke+0x92
2fa8f6ac 11e20e15 2d319a18 4289aac6 05f751c0 runtimecore!pplx::details::_TaskProcHandle::_RunChoreBridge+0x37
2fa8f6e4 11e20d1a 318b4130 4289ab3e 11e241d0 runtimecore!esri::common::concurrency::Core_scheduler::invoke_+0x35
2fa8f71c 11e2420d 318b4130 4289ab66 0b0107c8 runtimecore!esri::common::concurrency::Core_scheduler::bridge_proc_+0x8a
2fa8f744 77d16cd4 2fa8f858 318083b8 0b0107c8 runtimecore!esri::common::concurrency::`anonymous namespace'::Scheduler_param::work_callback+0x3d
2fa8f778 77d15d72 2fa8f858 0b010840 d6fa7cdb ntdll!TppWorkpExecuteCallback+0x144
2fa8f92c 77bffa29 05b06e88 77bffa10 2fa8f998 ntdll!TppWorkerThread+0x472
2fa8f93c 77d47a9e 05b06e88 d6fa7c6f 00000000 kernel32!BaseThreadInitThunk+0x19
2fa8f998 77d47a6e ffffffff 77d68a66 00000000 ntdll!__RtlUserThreadStart+0x2f
2fa8f9a8 00000000 77d15900 05b06e88 00000000 ntdll!_RtlUserThreadStart+0x1b


SYMBOL_NAME: runtimecore!SkBaseDevice::SkBaseDevice+16

MODULE_NAME: runtimecore

IMAGE_NAME: runtimecore.dll

STACK_COMMAND: ~55s ; .ecxr ; kb

FAILURE_BUCKET_ID: NULL_CLASS_PTR_READ_c0000005_runtimecore.dll!SkBaseDevice::SkBaseDevice

OS_VERSION: 10.0.19041.1

BUILDLAB_STR: vb_release

OSPLATFORM_TYPE: x86

OSNAME: Windows 10

IMAGE_VERSION: 100.11.0.3114

Can you tell if this is a bug or a problem with how we laod layers? 

0 Kudos
1 Reply
MarkBockenhauer
Esri Regular Contributor

Could you share the mobile map package, it could help with figuring out the problem.

0 Kudos