Skip to content

[Mono][Interpreter] Perf_Image_Load.Bitmap_FromStream benchmarks crash on Mono Interpreter #44263

Closed
@naricc

Description

@naricc

The Perf_Image_Load.Bitmap_FromStream benchmark from dotnet/performance is crashing on the mono interpreter. Full output below.

Directions for running the microbenchmark on the interpreter: https://paper.dropbox.com/doc/Run-microbenchmarks-with-Mono-interpreter--A~yVWHqsDL8ysnGEqXHLl6_0Ag-wqYCkxe1UnILk9wL1W1uI

[2020/11/04 18:55:10][INFO] // ***** BenchmarkRunner: End *****
[2020/11/04 18:55:10][INFO] // ** Remained 67 benchmark(s) to run **
[2020/11/04 18:55:10][INFO] Run time: 00:00:00 (0.21 sec), executed benchmarks: 1
[2020/11/04 18:55:10][INFO] 
[2020/11/04 18:55:10][INFO] // Found 1 benchmarks:
[2020/11/04 18:55:10][INFO] //   Perf_Image_Load.Bitmap_FromStream: Job-BFTLFC(PowerPlanMode=00000000-0000-0000-0000-000000000000, Arguments=/p:DebugType=portable, Toolchain=CoreRun, InvocationCount=1, IterationCount=1, IterationTime=250.0000 ms, MaxIterationCount=20, MinIterationCount=15, RunStrategy=ColdStart, UnrollFactor=1, WarmupCount=0) [format=Bmp]
[2020/11/04 18:55:10][INFO] 
[2020/11/04 18:55:10][INFO] // **************************
[2020/11/04 18:55:10][INFO] // Benchmark: Perf_Image_Load.Bitmap_FromStream: Job-BFTLFC(PowerPlanMode=00000000-0000-0000-0000-000000000000, Arguments=/p:DebugType=portable, Toolchain=CoreRun, InvocationCount=1, IterationCount=1, IterationTime=250.0000 ms, MaxIterationCount=20, MinIterationCount=15, RunStrategy=ColdStart, UnrollFactor=1, WarmupCount=0) [format=Bmp]
[2020/11/04 18:55:10][INFO] // *** Execute ***
[2020/11/04 18:55:10][INFO] // Launch: 1 / 1
[2020/11/04 18:55:10][INFO] // Execute: /home/helixbot/work/B93809E3/p/dotnet-mono/shared/Microsoft.NETCore.App/3d0b7245-6f2f-42eb-9c74-407991488faf/corerun "5af41243-b106-4258-b573-2366a38d6477.dll" --benchmarkName "System.Drawing.Tests.Perf_Image_Load.Bitmap_FromStream(format: Bmp)" --job "PowerPlanMode=00000000-0000-0000-0000-000000000000, Arguments=/p:DebugType=portable, Toolchain=CoreRun, InvocationCount=1, IterationCount=1, IterationTime=250.0000 ms, MaxIterationCount=20, MinIterationCount=15, RunStrategy=ColdStart, UnrollFactor=1, WarmupCount=0" --benchmarkId 42 in /home/helixbot/work/B93809E3/p/performance/artifacts/bin/MicroBenchmarks/Release/net6.0/5af41243-b106-4258-b573-2366a38d6477/bin/Release/net6.0/publish
[2020/11/04 18:55:10][INFO] Failed to set up high priority. Make sure you have the right permissions. Message: Permission denied
[2020/11/04 18:55:11][INFO] // BeforeAnythingElse
[2020/11/04 18:55:11][INFO] 
[2020/11/04 18:55:11][INFO] =================================================================
[2020/11/04 18:55:11][INFO] 	Native Crash Reporting
[2020/11/04 18:55:11][INFO] =================================================================
[2020/11/04 18:55:11][INFO] Got a SIGSEGV while executing native code. This usually indicates
[2020/11/04 18:55:11][INFO] a fatal error in the mono runtime or one of the native libraries
[2020/11/04 18:55:11][INFO] used by your application.
[2020/11/04 18:55:11][INFO] =================================================================
[2020/11/04 18:55:11][INFO] 
[2020/11/04 18:55:11][INFO] =================================================================
[2020/11/04 18:55:11][INFO] 	Native stacktrace:
[2020/11/04 18:55:11][INFO] =================================================================
[2020/11/04 18:55:11][INFO] 	0x7f2402ebece0 - Unknown
[2020/11/04 18:55:11][INFO] 	0x7f2402e6437e - Unknown
[2020/11/04 18:55:11][INFO] 	0x7f2402dc7993 - Unknown
[2020/11/04 18:55:11][INFO] 	0x7f2403f558a0 - Unknown
[2020/11/04 18:55:11][INFO] 	0x7f23f92a2b80 - Unknown
[2020/11/04 18:55:11][INFO] 	0x7f23f928bce9 - Unknown
[2020/11/04 18:55:11][INFO] 	0x41e28ca7 - Unknown
[2020/11/04 18:55:11][INFO] 
[2020/11/04 18:55:11][INFO] =================================================================
[2020/11/04 18:55:11][INFO] 	Telemetry Dumper:
[2020/11/04 18:55:11][INFO] =================================================================
[2020/11/04 18:55:11][INFO] Pkilling 0x139792606213888x from 0x139792668399424x
[2020/11/04 18:55:11][INFO] Pkilling 0x139792603064064x from 0x139792668399424x
[2020/11/04 18:55:11][INFO] Entering thread summarizer pause from 0x139792668399424x
[2020/11/04 18:55:11][INFO] Finished thread summarizer pause from 0x139792668399424x.
[2020/11/04 18:55:11][INFO] Failed to create breadcrumb file (null)/crash_hash_0x4f9862ffb
[2020/11/04 18:55:11][INFO] Could not exec mono-hang-watchdog, expected on path '/__w/1/s/artifacts/obj/mono/Linux.x64.Release/out/etc/../bin/mono-hang-watchdog' (errno 2)
[2020/11/04 18:55:11][INFO] 
[2020/11/04 18:55:11][INFO] Waiting for dumping threads to resume
[2020/11/04 18:55:14][INFO] 
[2020/11/04 18:55:14][INFO] =================================================================
[2020/11/04 18:55:14][INFO] 	Basic Fault Address Reporting
[2020/11/04 18:55:14][INFO] =================================================================
[2020/11/04 18:55:14][INFO] Memory around native instruction pointer (0x7f23f92a2b80):0x7f23f92a2b70  00 00 48 83 c4 60 5b 5d 41 5c 41 5d 41 5e c3 90  ..H..`[]A\A]A^..
[2020/11/04 18:55:14][INFO] 0x7f23f92a2b80  48 8b 76 08 48 89 fb e8 14 19 fe ff 85 c0 75 ce  H.v.H.........u.
[2020/11/04 18:55:14][INFO] 0x7f23f92a2b90  4c 8d 64 24 20 89 44 24 08 4c 89 e7 e8 3f c9 fd  L.d$ .D$.L...?..
[2020/11/04 18:55:14][INFO] 0x7f23f92a2ba0  ff 48 8b 53 10 48 8d 75 60 4c 89 e7 e8 1f d1 fd  .H.S.H.u`L......
[2020/11/04 18:55:14][INFO] 
[2020/11/04 18:55:14][INFO] =================================================================
[2020/11/04 18:55:14][INFO] 	Managed Stacktrace:
[2020/11/04 18:55:14][INFO] =================================================================
[2020/11/04 18:55:14][INFO] 	  at <unknown> <0xffffffff>
[2020/11/04 18:55:14][INFO] 	  at Gdip:GdipDrawBezier <0x00072>
[2020/11/04 18:55:14][INFO] 	  at System.Drawing.Graphics:DrawBezier <0x000a6>
[2020/11/04 18:55:14][INFO] 	  at System.Drawing.Graphics:DrawBezier <0x0005c>
[2020/11/04 18:55:14][INFO] 	  at ImageTestData:CreateTestImage <0x000a2>
[2020/11/04 18:55:14][INFO] 	  at ImageTestData:.ctor <0x00008>
[2020/11/04 18:55:14][INFO] 	  at System.Drawing.Tests.Perf_Image_Load:CreateTestCases <0x0001e>
[2020/11/04 18:55:14][INFO] 	  at System.Lazy`1:ViaFactory <0x00076>
[2020/11/04 18:55:14][INFO] 	  at System.Lazy`1:ExecutionAndPublication <0x00054>
[2020/11/04 18:55:14][INFO] 	  at System.Lazy`1:CreateValue <0x000c0>
[2020/11/04 18:55:14][INFO] 	  at System.Lazy`1:get_Value <0x00012>
[2020/11/04 18:55:14][INFO] 	  at System.Drawing.Tests.Perf_Image_Load:ImageFormats <0x0000e>
[2020/11/04 18:55:14][INFO] 	  at BenchmarkDotNet.Autogenerated.Runnable_42:.ctor <0x0010a>
[2020/11/04 18:55:14][INFO] 	  at BenchmarkDotNet.Autogenerated.Runnable_42:Run <0x0000e>
[2020/11/04 18:55:14][INFO] 	  at <Module>:runtime_invoke_direct_void_IHost_string <0x000b8>
[2020/11/04 18:55:14][INFO] 	  at <unknown> <0xffffffff>
[2020/11/04 18:55:14][INFO] 	  at System.Reflection.RuntimeMethodInfo:InternalInvoke <0x0003a>
[2020/11/04 18:55:14][INFO] 	  at System.Reflection.RuntimeMethodInfo:Invoke <0x00126>
[2020/11/04 18:55:14][INFO] 	  at System.Reflection.MethodBase:Invoke <0x0001c>
[2020/11/04 18:55:14][INFO] 	  at BenchmarkDotNet.Autogenerated.UniqueProgramName:AfterAssemblyLoadingAttached <0x000f4>
[2020/11/04 18:55:14][INFO] 	  at BenchmarkDotNet.Autogenerated.UniqueProgramName:Main <0x00008>
[2020/11/04 18:55:14][INFO] 	  at <Module>:runtime_invoke_direct_int_string[] <0x0009c>
[2020/11/04 18:55:14][INFO] =================================================================
[2020/11/04 18:55:15][INFO] 
[2020/11/04 18:55:15][INFO] =================================================================
[2020/11/04 18:55:15][INFO] 	External Debugger Dump:
[2020/11/04 18:55:15][INFO] =================================================================
[2020/11/04 18:55:15][INFO] [New LWP 5114]
[2020/11/04 18:55:15][INFO] [New LWP 5115]
[2020/11/04 18:55:15][INFO] [New LWP 5116]
[2020/11/04 18:55:15][INFO] [Thread debugging using libthread_db enabled]
[2020/11/04 18:55:15][INFO] Using host libthread_db library "/lib/x86_64-linux-gnu/libthread_db.so.1".
[2020/11/04 18:55:15][INFO] 0x00007f2403f5524a in __waitpid (pid=5118, stat_loc=0x7ffe8134c6fc, options=0) at ../sysdeps/unix/sysv/linux/waitpid.c:30
[2020/11/04 18:55:15][INFO] 30	../sysdeps/unix/sysv/linux/waitpid.c: No such file or directory.
[2020/11/04 18:55:15][INFO]   Id   Target Id         Frame
[2020/11/04 18:55:15][INFO] * 1    Thread 0x7f2404579740 (LWP 5113) "corerun" 0x00007f2403f5524a in __waitpid (pid=5118, stat_loc=0x7ffe8134c6fc, options=0) at ../sysdeps/unix/sysv/linux/waitpid.c:30
[2020/11/04 18:55:15][INFO]   2    Thread 0x7f24023ff700 (LWP 5114) "SGen worker" 0x00007f2403f509f3 in futex_wait_cancelable (private=<optimized out>, expected=0, futex_word=0x7f240320ba68 <work_cond+40>) at ../sysdeps/unix/sysv/linux/futex-internal.h:88
[2020/11/04 18:55:15][INFO]   3    Thread 0x7f2400a2b700 (LWP 5115) "corerun" 0x00007f2403327cf9 in __GI___poll (fds=0x7f23fc002d80, nfds=1, timeout=-1) at ../sysdeps/unix/sysv/linux/poll.c:29
[2020/11/04 18:55:15][INFO]   4    Thread 0x7f240072a700 (LWP 5116) "Finalizer" 0x00007f2403f536e6 in futex_abstimed_wait_cancelable (private=0, abstime=0x0, expected=0, futex_word=0x7f24031fc898 <finalizer_sem>) at ../sysdeps/unix/sysv/linux/futex-internal.h:205
[2020/11/04 18:55:15][INFO] 
[2020/11/04 18:55:15][INFO] Thread 4 (Thread 0x7f240072a700 (LWP 5116)):
[2020/11/04 18:55:15][INFO] #0  0x00007f2403f536e6 in futex_abstimed_wait_cancelable (private=0, abstime=0x0, expected=0, futex_word=0x7f24031fc898 <finalizer_sem>) at ../sysdeps/unix/sysv/linux/futex-internal.h:205
[2020/11/04 18:55:15][INFO] #1  do_futex_wait (sem=sem@entry=0x7f24031fc898 <finalizer_sem>, abstime=0x0) at sem_waitcommon.c:111
[2020/11/04 18:55:15][INFO] #2  0x00007f2403f537d8 in __new_sem_wait_slow (sem=0x7f24031fc898 <finalizer_sem>, abstime=0x0) at sem_waitcommon.c:181
[2020/11/04 18:55:15][INFO] #3  0x00007f2402d18da8 in mono_os_sem_wait (sem=<optimized out>, flags=MONO_SEM_FLAGS_ALERTABLE) at /__w/1/s/src/mono/mono/mini/../utils/mono-os-semaphore.h:204
[2020/11/04 18:55:15][INFO] #4  mono_coop_sem_wait (sem=<optimized out>, flags=MONO_SEM_FLAGS_ALERTABLE) at /__w/1/s/src/mono/mono/mini/../../mono/utils/mono-coop-semaphore.h:41
[2020/11/04 18:55:15][INFO] #5  finalizer_thread (unused=<optimized out>) at /__w/1/s/src/mono/mono/metadata/gc.c:970
[2020/11/04 18:55:15][INFO] #6  0x00007f2402cee10a in start_wrapper_internal (start_info=0x0, stack_ptr=<optimized out>) at /__w/1/s/src/mono/mono/metadata/threads.c:1242
[2020/11/04 18:55:15][INFO] #7  0x00007f2402cedf89 in start_wrapper (data=0x55e3179d9030) at /__w/1/s/src/mono/mono/metadata/threads.c:1317
[2020/11/04 18:55:15][INFO] #8  0x00007f2403f4a6db in start_thread (arg=0x7f240072a700) at pthread_create.c:463
[2020/11/04 18:55:15][INFO] #9  0x00007f2403334a3f in clone () at ../sysdeps/unix/sysv/linux/x86_64/clone.S:95
[2020/11/04 18:55:15][INFO] 
[2020/11/04 18:55:15][INFO] Thread 3 (Thread 0x7f2400a2b700 (LWP 5115)):
[2020/11/04 18:55:15][INFO] #0  0x00007f2403327cf9 in __GI___poll (fds=0x7f23fc002d80, nfds=1, timeout=-1) at ../sysdeps/unix/sysv/linux/poll.c:29
[2020/11/04 18:55:15][INFO] #1  0x00007f2402dad805 in ds_ipc_poll (poll_handles=<optimized out>, timeout_ms=4294967295, callback=0x7f2402db1220 <server_warning_callback>) at /__w/1/s/src/mono/mono/eventpipe/ds-ipc-posix.c:328
[2020/11/04 18:55:15][INFO] #2  0x00007f2402dad614 in ds_ipc_stream_factory_get_next_available_stream (callback=0x7f2402db1220 <server_warning_callback>) at /__w/1/s/src/mono/mono/eventpipe/ds-ipc.c:340
[2020/11/04 18:55:15][INFO] #3  0x00007f2402db06b7 in server_thread (data=<optimized out>) at /__w/1/s/src/mono/mono/eventpipe/ds-server.c:146
[2020/11/04 18:55:15][INFO] #4  0x00007f2403f4a6db in start_thread (arg=0x7f2400a2b700) at pthread_create.c:463
[2020/11/04 18:55:15][INFO] #5  0x00007f2403334a3f in clone () at ../sysdeps/unix/sysv/linux/x86_64/clone.S:95
[2020/11/04 18:55:15][INFO] 
[2020/11/04 18:55:15][INFO] Thread 2 (Thread 0x7f24023ff700 (LWP 5114)):
[2020/11/04 18:55:15][INFO] #0  0x00007f2403f509f3 in futex_wait_cancelable (private=<optimized out>, expected=0, futex_word=0x7f240320ba68 <work_cond+40>) at ../sysdeps/unix/sysv/linux/futex-internal.h:88
[2020/11/04 18:55:15][INFO] #1  __pthread_cond_wait_common (abstime=0x0, mutex=0x7f240320ba18 <lock>, cond=0x7f240320ba40 <work_cond>) at pthread_cond_wait.c:502
[2020/11/04 18:55:15][INFO] #2  __pthread_cond_wait (cond=0x7f240320ba40 <work_cond>, mutex=0x7f240320ba18 <lock>) at pthread_cond_wait.c:655
[2020/11/04 18:55:15][INFO] #3  0x00007f2402da1ed3 in mono_os_cond_wait (cond=<optimized out>, mutex=<optimized out>) at /__w/1/s/src/mono/mono/mini/../../mono/utils/mono-os-mutex.h:219
[2020/11/04 18:55:15][INFO] #4  get_work (worker_index=<optimized out>, work_context=<optimized out>, do_idle=<optimized out>, job=<optimized out>) at /__w/1/s/src/mono/mono/sgen/sgen-thread-pool.c:167
[2020/11/04 18:55:15][INFO] #5  thread_func (data=0x0) at /__w/1/s/src/mono/mono/sgen/sgen-thread-pool.c:198
[2020/11/04 18:55:15][INFO] #6  0x00007f2403f4a6db in start_thread (arg=0x7f24023ff700) at pthread_create.c:463
[2020/11/04 18:55:15][INFO] #7  0x00007f2403334a3f in clone () at ../sysdeps/unix/sysv/linux/x86_64/clone.S:95
[2020/11/04 18:55:15][INFO] 
[2020/11/04 18:55:15][INFO] Thread 1 (Thread 0x7f2404579740 (LWP 5113)):
[2020/11/04 18:55:15][INFO] #0  0x00007f2403f5524a in __waitpid (pid=5118, stat_loc=0x7ffe8134c6fc, options=0) at ../sysdeps/unix/sysv/linux/waitpid.c:30
[2020/11/04 18:55:15][INFO] #1  0x00007f2402ebef3a in dump_native_stacktrace (signal=<optimized out>, mctx=<optimized out>) at /__w/1/s/src/mono/mono/mini/mini-posix.c:1061
[2020/11/04 18:55:15][INFO] #2  mono_dump_native_crash_info (signal=0x7f2402f52513 "SIGSEGV", mctx=0x7ffe8134d268, info=<optimized out>) at /__w/1/s/src/mono/mono/mini/mini-posix.c:1105
[2020/11/04 18:55:15][INFO] #3  0x00007f2402e6437e in mono_handle_native_crash (signal=0x7f2402f52513 "SIGSEGV", mctx=0x7ffe8134d268, info=0x7ffe8134d530) at /__w/1/s/src/mono/mono/mini/mini-exceptions.c:3449
[2020/11/04 18:55:15][INFO] #4  0x00007f2402dc7993 in mono_sigsegv_signal_handler_debug (_dummy=11, _info=0x7ffe8134d530, context=0x7ffe8134d400, debug_fault_addr=0x441dc008) at /__w/1/s/src/mono/mono/mini/mini-runtime.c:3612
[2020/11/04 18:55:15][INFO] #5  <signal handler called>
[2020/11/04 18:55:15][INFO] #6  0x00007f23f92a2b80 in ?? () from /usr/lib/libgdiplus.so
[2020/11/04 18:55:15][INFO] #7  0x00007f23f928bce9 in ?? () from /usr/lib/libgdiplus.so
[2020/11/04 18:55:15][INFO] #8  0x0000000041e28ca7 in ?? ()
[2020/11/04 18:55:15][INFO] #9  0x00007f23f9288810 in ?? () from /usr/lib/libgdiplus.so
[2020/11/04 18:55:15][INFO] #10 0x00007ffe8134dcc0 in ?? ()
[2020/11/04 18:55:15][INFO] #11 0x00007ffe8134e300 in ?? ()
[2020/11/04 18:55:15][INFO] #12 0x00007f2402ecf781 in ves_pinvoke_method (imethod=0x55e317d508e8, sig=0x55e317dbea48, addr=0x7f23f9288810 <GdipDrawBezier>, context=0x55e3179c5190, parent_frame=0x7ffe8134de70, sp=0x7f240072b4f0, save_last_error=0, cache=0x55e317d50a88) at /__w/1/s/src/mono/mono/mini/interp/interp.c:1575
[2020/11/04 18:55:15][INFO] #13 0x00007f2402ec2614 in interp_exec_method (frame=<optimized out>, context=0x55e3179c5190, clause_args=0x5e8149452a267700) at /__w/1/s/src/mono/mono/mini/interp/interp.c:3664
[2020/11/04 18:55:15][INFO] Backtrace stopped: previous frame inner to this frame (corrupt stack?)
[2020/11/04 18:55:15][INFO] ExitCode != 0
[2020/11/04 18:55:15][INFO] // Benchmark Process 5113 has exited with code 134
[2020/11/04 18:55:15][INFO] No more Benchmark runs will be launched as NO measurements were obtained from the previous run!

Metadata

Metadata

Assignees

Type

No type

Projects

No projects

Milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions