Bug 60756 - A crash with CEE_RET: value type stack: 0 vs. 8
Summary: A crash with CEE_RET: value type stack: 0 vs. 8
Status: RESOLVED FIXED
Alias: None
Product: Runtime
Classification: Mono
Component: Interpreter (show other bugs)
Version: unspecified
Hardware: PC All
: --- normal
Target Milestone: ---
Assignee: Bernhard Urban
URL:
Depends on:
Blocks:
 
Reported: 2017-11-19 09:16 UTC by Marek Safar
Modified: 2017-12-15 11:53 UTC (History)
3 users (show)

Tags:
Is this bug a regression?: ---
Last known good build:

Notice (2018-05-24): bugzilla.xamarin.com is now in read-only mode.

Please join us on Visual Studio Developer Community and in the Xamarin and Mono organizations on GitHub to continue tracking issues. Bugzilla will remain available for reference in read-only mode. We will continue to work on open Bugzilla bugs, copy them to the new locations as needed for follow-up, and add the new items under Related Links.

Our sincere thanks to everyone who has contributed on this bug tracker over the years. Thanks also for your understanding as we make these adjustments and improvements for the future.


Please create a new report on GitHub or Developer Community with your current version information, steps to reproduce, and relevant error messages or log files if you are hitting an issue that looks similar to this resolved bug and you do not yet see a matching new report.

Related Links:
Status:
RESOLVED FIXED

Description Marek Safar 2017-11-19 09:16:06 UTC
BB.get_Item: CEE_RET: value type stack: 0 vs. 8
  at ClassLibrary1.C.Main () [0x0002a] in /mnt/jenkins/workspace/test-mono-pull-request-interpreter/mcs/tests/test-ref-08.cs:68
  at (wrapper runtime-invoke) object.runtime_invoke_direct_void (object,intptr,intptr,intptr) [0x0004b] in <7976e1989cc34a7183fcebbf4abf8e80>:0
  at (wrapper managed-to-native) System.Reflection.MonoMethod.InternalInvoke (System.Reflection.MonoMethod,object,object[],System.Exception&) <0x00032>
  at System.Reflection.MonoMethod.Invoke (object,System.Reflection.BindingFlags,System.Reflection.Binder,object[],System.Globalization.CultureInfo) [0x00032] in /mnt/jenkins/workspace/test-mono-pull-request-interpreter/mcs/class/corlib/System.Reflection/MonoMethod.cs:305
  at System.Reflection.MethodBase.Invoke (object,object[]) [0x00000] in /mnt/jenkins/workspace/test-mono-pull-request-interpreter/mcs/class/referencesource/mscorlib/system/reflection/methodbase.cs:229
  at TestRunner.PositiveChecker/DomainTester.ExecuteFile (System.Reflection.MethodInfo,string) [0x00034] in /mnt/jenkins/workspace/test-mono-pull-request-interpreter/mcs/tools/compiler-tester/compiler-tester.cs:905
  at TestRunner.PositiveChecker/DomainTester.Test (string) [0x00007] in /mnt/jenkins/workspace/test-mono-pull-request-interpreter/mcs/tools/compiler-tester/compiler-tester.cs:923
  at TestRunner.PositiveChecker.ExecuteTestFile (TestRunner.TestCase,string) [0x00077] in /mnt/jenkins/workspace/test-mono-pull-request-interpreter/mcs/tools/compiler-tester/compiler-tester.cs:987
  at TestRunner.PositiveChecker.Check (TestRunner.TestCase) [0x000bb] in /mnt/jenkins/workspace/test-mono-pull-request-interpreter/mcs/tools/compiler-tester/compiler-tester.cs:960
  at TestRunner.Checker.Do (string) [0x00131] in /mnt/jenkins/workspace/test-mono-pull-request-interpreter/mcs/tools/compiler-tester/compiler-tester.cs:584
  at TestRunner.Tester.Main (string[]) [0x002db] in /mnt/jenkins/workspace/test-mono-pull-request-interpreter/mcs/tools/compiler-tester/compiler-tester.cs:1686
  at (wrapper runtime-invoke) <Module>.runtime_invoke_direct_int_string[] (object,intptr,intptr,intptr) [0x00055] in <6fa920b138d04890a5a2565d3912dd1f>:0
  at <unknown> <0xffffffff>
  at (wrapper managed-to-native) System.Reflection.MonoMethod.InternalInvoke (System.Reflection.MonoMethod,object,object[],System.Exception&) <0x00032>
  at System.Reflection.MonoMethod.Invoke (object,System.Reflection.BindingFlags,System.Reflection.Binder,object[],System.Globalization.CultureInfo) [0x00032] in /mnt/jenkins/workspace/test-mono-pull-request-interpreter/mcs/class/corlib/System.Reflection/MonoMethod.cs:305
  at System.Reflection.MethodBase.Invoke (object,object[]) [0x00000] in /mnt/jenkins/workspace/test-mono-pull-request-interpreter/mcs/class/referencesource/mscorlib/system/reflection/methodbase.cs:229
  at TestRunner.PositiveChecker/DomainTester.ExecuteFile (System.Reflection.MethodInfo,string) [0x00034] in /mnt/jenkins/workspace/test-mono-pull-request-interpreter/mcs/tools/compiler-tester/compiler-tester.cs:905
  at TestRunner.PositiveChecker/DomainTester.Test (string) [0x00007] in /mnt/jenkins/workspace/test-mono-pull-request-interpreter/mcs/tools/compiler-tester/compiler-tester.cs:923
  at TestRunner.PositiveChecker.ExecuteTestFile (TestRunner.TestCase,string) [0x00077] in /mnt/jenkins/workspace/test-mono-pull-request-interpreter/mcs/tools/compiler-tester/compiler-tester.cs:987
  at TestRunner.PositiveChecker.Check (TestRunner.TestCase) [0x000bb] in /mnt/jenkins/workspace/test-mono-pull-request-interpreter/mcs/tools/compiler-tester/compiler-tester.cs:960
  at TestRunner.Checker.Do (string) [0x00131] in /mnt/jenkins/workspace/test-mono-pull-request-interpreter/mcs/tools/compiler-tester/compiler-tester.cs:584
  at TestRunner.Tester.Main (string[]) [0x002db] in /mnt/jenkins/workspace/test-mono-pull-request-interpreter/mcs/tools/compiler-tester/compiler-tester.cs:1686
  at (wrapper runtime-invoke) <Module>.runtime_invoke_direct_int_string[] (object,intptr,intptr,intptr) [0x00055] in <6fa920b138d04890a5a2565d3912dd1f>:0

Thread 1 (Thread 0x7f11ab24f740 (LWP 119580)):
#0  0x00007f11aa720489 in waitpid () from /lib/x86_64-linux-gnu/libpthread.so.0
#1  0x00000000004b544e in mono_handle_native_crash (signal=0x6f3ae6 "SIGABRT", ctx=<optimized out>, info=<optimized out>) at mini-exceptions.c:2806
#2  <signal handler called>
#3  0x00007f11aa185067 in raise () from /lib/x86_64-linux-gnu/libc.so.6
#4  0x00007f11aa186448 in abort () from /lib/x86_64-linux-gnu/libc.so.6
#5  0x00000000006ae7c4 in mono_log_write_logfile (log_domain=<optimized out>, level=<optimized out>, hdr=<optimized out>, message=0x7d28fb0 "BB.get_Item: CEE_RET: value type stack: 0 vs. 8") at mono-log-common.c:135
#6  0x00000000006c34a0 in monoeg_g_logv (log_domain=0x0, log_level=G_LOG_LEVEL_ERROR, format=<optimized out>, args=args@entry=0x7ffd01db0fa8) at goutput.c:115
#7  0x00000000006c3552 in monoeg_g_log (log_domain=<optimized out>, log_level=<optimized out>, format=<optimized out>) at goutput.c:125
#8  0x0000000000518f15 in generate (error=<optimized out>, generic_context=<optimized out>, is_bb_start=<optimized out>, rtm=<optimized out>, header=<optimized out>, method=<optimized out>) at interp/transform.c:2032
#9  mono_interp_transform_method (imethod=0x1d31c, context=0x1d31c, frame=0x8) at interp/transform.c:4565
#10 0x00000000004fd66e in do_transform_method (context=<optimized out>, frame=<optimized out>) at interp/interp.c:1972
#11 interp_exec_method_full (frame=0x7ffd01db1b60, context=0x7ffd01db6b00, start_with_ip=0x0, filter_exception=0x0, exit_at_finally=-1423640768, base_frame=0x7f11aa19b99a <vfprintf+22490>) at interp/interp.c:2293
#12 0x00000000004fe24f in interp_exec_method_full (frame=0x7ffd01db21e0, context=0x7ffd01db6b00, start_with_ip=0x7d423a6, filter_exception=0x7d3ef80, exit_at_finally=-1423640768, base_frame=0x7f11aa19b99a <vfprintf+22490>) at interp/interp.c:2690
#13 0x00000000004fdee6 in interp_exec_method_full (frame=0x7ffd01db2700, context=0x7ffd01db6b00, start_with_ip=0x7d418f6, filter_exception=0x7d418fa, exit_at_finally=-1423640768, exit_at_finally@entry=-1, base_frame=0x7f11aa19b99a <vfprintf+22490>, base_frame@entry=0x0) at interp/interp.c:2623
#14 0x000000000050aa25 in interp_exec_method (context=<optimized out>, frame=0x7ffd01db2700) at interp/interp.c:5154
#15 mono_interp_runtime_invoke (method=method@entry=0x7d463e8, obj=0x0, params=params@entry=0x0, exc=exc@entry=0x0, error=error@entry=0x7ffd01db2a70) at interp/interp.c:1455
#16 0x000000000042e09c in mono_jit_runtime_invoke (method=0x7d463e8, obj=0x0, params=0x0, exc=0x0, error=0x7ffd01db2a70) at mini-runtime.c:2637
#17 0x00000000005ea7ab in do_runtime_invoke (method=0x7d463e8, obj=<optimized out>, params=<optimized out>, exc=<optimized out>, error=0x7ffd01db2a70) at object.c:2843
#18 0x00000000005f25a1 in mono_runtime_try_invoke_array (method=method@entry=0x7d463e8, obj=obj@entry=0x0, params=params@entry=0x0, exc=exc@entry=0x0, error=error@entry=0x7ffd01db2a70) at object.c:5179
#19 0x00000000005f27c6 in mono_runtime_invoke_array_checked (method=method@entry=0x7d463e8, obj=obj@entry=0x0, params=params@entry=0x0, error=error@entry=0x7ffd01db2a70) at object.c:5058
#20 0x000000000059dfec in ves_icall_InternalInvoke (method=0x7f11a9c451b8, this_arg=0x0, params=0x0, exc=0x7ffd01db3260) at icall.c:3348
#21 0x000000004001019b in ?? ()
#22 0x0000000000000000 in ?? ()

=================================================================
Got a SIGABRT while executing native code. This usually indicates
a fatal error in the mono runtime or one of the native libraries 
used by your application.
=================================================================
Comment 1 Ludovic Henry 2017-11-20 16:09:12 UTC
How do you reproduce?
Comment 2 Marek Safar 2017-11-20 16:11:33 UTC
You run mcs/tests/test-ref-08.exe with the interpreter
Comment 3 Marek Safar 2017-11-20 16:11:41 UTC
You run mcs/tests/test-ref-08.exe with the interpreter
Comment 4 Marek Safar 2017-11-22 23:21:23 UTC
In mono/mono/mcs/tests$ 

csc test-ref-08.cs
mono --interp test-ref-08.exe

BB.get_Item: CEE_RET: value type stack: 0 vs. 8
Stacktrace:

  at <unknown> <0xffffffff>
  at ClassLibrary1.C.Main () <0x0003e>
  at (wrapper runtime-invoke) object.runtime_invoke_direct_void (object,intptr,intptr,intptr) <0x0006e>

Native stacktrace:

	0   mono                                0x0000000109e002f1 mono_handle_native_crash + 257
	1   libsystem_platform.dylib            0x00007fff6b98ef5a _sigtramp + 26
	2   ???                                 0x00007fbdc9e1e820 0x0 + 140453112571936
	3   libsystem_c.dylib                   0x00007fff6b7ba30a abort + 127
	4   mono                                0x000000010a00a67f mono_log_write_logfile + 351
	5   mono                                0x000000010a022a1e monoeg_g_log + 206
	6   mono                                0x0000000109e74e10 generate + 89632
	7   mono                                0x0000000109e5eb8a mono_interp_transform_method + 2506
Comment 5 Bernhard Urban 2017-12-10 19:32:58 UTC
https://github.com/mono/mono/pull/6212