[Mono-bugs] [Bug 507108] "Hello World" hangs/crashes on embedded PPC/Linux system with mono version 2.4, versions 2.2 and 1.2.6 are working fine

bugzilla_noreply at novell.com bugzilla_noreply at novell.com
Tue Jun 9 13:38:56 EDT 2009


http://bugzilla.novell.com/show_bug.cgi?id=507108

User harald.herrmann at ids.de added comment
http://bugzilla.novell.com/show_bug.cgi?id=507108#c11





--- Comment #11 from Harald Herrmann <harald.herrmann at ids.de>  2009-06-09 11:38:54 MDT ---
Meanwhile we ran our hello world app in mono with the -v option in gdb. Mono
was again on base of the 2.4 source tar file. Gdb session log is as follows:

ppc_6xx-gdb mono
GNU gdb Red Hat Linux (6.7-1rh)
Copyright (C) 2007 Free Software Foundation, Inc.
License GPLv3+: GNU GPL version 3 or later <http://gnu.org/licenses/gpl.html>
This is free software: you are free to change and redistribute it.
There is NO WARRANTY, to the extent permitted by law.  Type "show copying"
and "show warranty" for details.
This GDB was configured as "--host=i686-pc-linux-gnu --target=ppc-linux".
The target architecture is set automatically (currently powerpc:603)
.
(gdb) cu137
0x480152e0 in ?? () from /opt/eldk/ppc_6xx/lib/ld.so.1
(gdb) br mono_jit_runtime_invoke
Breakpoint 1 at 0x1001a0cc: file mini.c, line 4132.
(gdb) c
Continuing.
Error while mapping shared library sections:
/usr/local/lib/libgthread-2.0.so.0: No such file or directory.
Error while mapping shared library sections:
/usr/local/lib/libglib-2.0.so.0: No such file or directory.
[New Thread 12026]

Breakpoint 1, mono_jit_runtime_invoke (method=0x102dd520, obj=0x482a1f88,
params=0xbfe1ca2c, exc=0x0) at mini.c:4132
4132        if (obj == NULL && !(method->flags & METHOD_ATTRIBUTE_STATIC) &&
!method->string_ctor && (method->wrapper_type == 0)) {
(gdb) c
Continuing.

Breakpoint 1, mono_jit_runtime_invoke (method=0x102ddab0, obj=0x482a1f50,
params=0xbfe1ca2c, exc=0x0) at mini.c:4132
4132        if (obj == NULL && !(method->flags & METHOD_ATTRIBUTE_STATIC) &&
!method->string_ctor && (method->wrapper_type == 0)) {
(gdb) c
Continuing.

Breakpoint 1, mono_jit_runtime_invoke (method=0x102ddc60, obj=0x482a1f18,
params=0xbfe1ca2c, exc=0x0) at mini.c:4132
4132        if (obj == NULL && !(method->flags & METHOD_ATTRIBUTE_STATIC) &&
!method->string_ctor && (method->wrapper_type == 0)) {
(gdb) c
Continuing.

Breakpoint 1, mono_jit_runtime_invoke (method=0x102b5590, obj=0x0,
params=0xbfe1ca28, exc=0x0) at mini.c:4132
4132        if (obj == NULL && !(method->flags & METHOD_ATTRIBUTE_STATIC) &&
!method->string_ctor && (method->wrapper_type == 0)) {
(gdb) c
Continuing.

Breakpoint 1, mono_jit_runtime_invoke (method=0x102e2fe8, obj=0x0, params=0x0,
exc=0xbfe1c6b8) at mini.c:4132
4132        if (obj == NULL && !(method->flags & METHOD_ATTRIBUTE_STATIC) &&
!method->string_ctor && (method->wrapper_type == 0)) {
(gdb) c
Continuing.

Breakpoint 1, mono_jit_runtime_invoke (method=0x102e4060, obj=0x0, params=0x0,
exc=0xbfe1c298) at mini.c:4132
4132        if (obj == NULL && !(method->flags & METHOD_ATTRIBUTE_STATIC) &&
!method->string_ctor && (method->wrapper_type == 0)) {
(gdb) n
4125    {
(gdb) n
4132        if (obj == NULL && !(method->flags & METHOD_ATTRIBUTE_STATIC) &&
!method->string_ctor && (method->wrapper_type == 0)) {
(gdb) n
4137        if (mono_method_needs_static_rgctx_invoke (method, FALSE))
(gdb) n
4142        invoke = mono_marshal_get_runtime_invoke (method);
(gdb) n
4143        runtime_invoke = mono_jit_compile_method (invoke);
(gdb) n
4148        vtable = mono_class_vtable (mono_domain_get (), method->klass);
(gdb) n
4149        g_assert (vtable);
(gdb) n
4150        mono_runtime_class_init (vtable);
(gdb) n
4152        if (method->klass->rank && (method->iflags &
METHOD_IMPL_ATTRIBUTE_INTERNAL_CALL) &&
(gdb) n
4160            compiled_method = mono_jit_compile_method (to_compile);
(gdb) n
4162        return runtime_invoke (obj, params, exc, compiled_method);
(gdb) print *method
$1 = {flags = 6161, iflags = 0, token = 100675966, klass = 0x102e3bd8,
signature = 0x102d15b8, name = 0x48209515 ".cctor", 
  inline_info = 0, inline_failure = 0, wrapper_type = 0, string_ctor = 0,
save_lmf = 0, dynamic = 0, is_generic = 0, 
  is_inflated = 0, skip_visibility = 0, verification_success = 0, slot = -1}
(gdb) n

Program received signal SIGSEGV, Segmentation fault.
0x4826e65c in ?? ()
(gdb) thread apply all bt

Thread 3 (Thread 12153):
#0  0x0fdac3b4 in sem_wait at GLIBC_2.0 () from
/opt/eldk/ppc_6xx/lib/libpthread.so.0
#1  0x100edb74 in finalizer_thread (unused=<value optimized out>) at gc.c:935
#2  0x10103070 in start_wrapper (data=<value optimized out>) at threads.c:623
#3  0x1016015c in thread_start_routine (args=0x102c7e88) at threads.c:286
#4  0x1018a234 in GC_start_routine (arg=0x48067f20) at pthread_support.c:1382
#5  0x0fda4a6c in start_thread () from /opt/eldk/ppc_6xx/lib/libpthread.so.0
#6  0x0fbec8a0 in clone () from /opt/eldk/ppc_6xx/lib/libc.so.6
Backtrace stopped: previous frame inner to this frame (corrupt stack?)

Thread 2 (Thread 12150):
#0  0x0fdadc94 in nanosleep () from /opt/eldk/ppc_6xx/lib/libpthread.so.0
#1  0x1014e4d4 in collection_thread (unused=<value optimized out>) at
collection.c:34
#2  0x0fda4a6c in start_thread () from /opt/eldk/ppc_6xx/lib/libpthread.so.0
#3  0x0fbec8a0 in clone () from /opt/eldk/ppc_6xx/lib/libc.so.6
Backtrace stopped: previous frame inner to this frame (corrupt stack?)

Thread 1 (Thread 12026):
#0  0x4826e65c in ?? ()
#1  0x4826dec8 in ?? ()
#2  0x4826dec8 in ?? ()
#3  0x4826d5c4 in ?? ()
#4  0x1001a17c in mono_jit_runtime_invoke (method=0xbfe1c1f0, obj=0x0,
params=0x0, exc=0xbfe1c298) at mini.c:4162
#5  0x101402cc in mono_runtime_invoke (method=0x102e4060, obj=0x0, params=0x0,
exc=0xbfe1c298) at object.c:2401
#6  0x10144e44 in mono_runtime_class_init_full (vtable=0x102b45b8,
raise_exception=1) at object.c:337
#7  0x10019bc4 in mono_jit_compile_method (method=0x102e4208) at mini.c:3954
#8  0x1013f008 in mono_compile_method (method=0x0) at object.c:529
#9  0x100197d0 in mono_jit_compile_method (method=0x102e41b8) at mini.c:3768
#10 0x1013f008 in mono_compile_method (method=0x0) at object.c:529
#11 0x10086ce4 in mono_magic_trampoline (regs=0xbfe1c40c, code=0x4826d768
"\200\177", m=0x102e41b8, 
    tramp=<value optimized out>) at mini-trampolines.c:292
#12 0x48025118 in ?? ()
#13 0x4826d768 in ?? ()
#14 0x4826d5c4 in ?? ()
#15 0x1001a17c in mono_jit_runtime_invoke (method=0xbfe1c5a0, obj=0x0,
params=0x0, exc=0xbfe1c6b8) at mini.c:4162
---Type <return> to continue, or q <return> to quit---
#16 0x101402cc in mono_runtime_invoke (method=0x102e2fe8, obj=0x0, params=0x0,
exc=0xbfe1c6b8) at object.c:2401
#17 0x10144e44 in mono_runtime_class_init_full (vtable=0x102b3f18,
raise_exception=1) at object.c:337
#18 0x10019bc4 in mono_jit_compile_method (method=0x102e3320) at mini.c:3954
#19 0x1013f008 in mono_compile_method (method=0x0) at object.c:529
#20 0x10086ce4 in mono_magic_trampoline (regs=0xbfe1c7cc, code=0x4826d4a8 "8`",
m=0x102e3320, tramp=<value optimized out>)
    at mini-trampolines.c:292
#21 0x48025118 in ?? ()
#22 0x4826d4a8 in ?? ()
#23 0x4826d39c in ?? ()
#24 0x1001a17c in mono_jit_runtime_invoke (method=0xbfe1c980, obj=0x0,
params=0xbfe1ca28, exc=0x0) at mini.c:4162
#25 0x101402cc in mono_runtime_invoke (method=0x102b5590, obj=0x0,
params=0xbfe1ca28, exc=0x0) at object.c:2401
#26 0x10146640 in mono_runtime_exec_main (method=0x102b5590, args=<value
optimized out>, exc=0x0) at object.c:3309
#27 0x10147e24 in mono_runtime_run_main (method=0x102b5590, argc=1,
argv=0xbfe1ce4c, exc=0x0) at object.c:3089
#28 0x10066484 in mono_jit_exec (domain=<value optimized out>, assembly=<value
optimized out>, argc=1, argv=0xbfe1ce4c)
    at driver.c:921
#29 0x10067918 in mono_main (argc=3, argv=<value optimized out>) at
driver.c:969
#30 0x10011020 in main (argc=0, argv=0x25) at main.c:34
(gdb) info registers
r0             0x4826dec8    1210506952
r1             0xbfe1bff0    3219242992
r2             0x48026b30    1208118064
r3             0x0    0
r4             0x25    37
r5             0xbfe1c298    3219243672
r6             0x4826dea0    1210506912
r7             0xfeff0000    4278124544
r8             0x2    2
r9             0x1    1
r10            0x4801f6b0    1208088240
r11            0xbfe1c030    3219243056
r12            0x24002822    603990050
r13            0x10297270    271151728
r14            0x0    0
r15            0xbfe1ce4c    3219246668
r16            0x0    0
r17            0x0    0
r18            0x0    0
r19            0x10290000    271122432
r20            0x35129ff    55650815
r21            0x0    0
r22            0x102e4060    271466592
r23            0x48066ee0    1208381152
r24            0x1    1
r25            0x1029176c    271128428
r26            0x0    0
r27            0xbfe1c298    3219243672
r28            0x0    0
r29            0x4826d548    1210504520
r30            0x25    37
r31            0xbfe1c1f0    3219243504
pc             0x4826e65c    1210508892
cr             0x24002822    603990050
lr             0x4826dec8    1210506952
ctr            0x4826e5a8    1210508712
---Type <return> to continue, or q <return> to quit---
xer            0x0    0
(gdb) 

The corresponding output of the mono runtime is:

# gdbserver :2002 mono -v /flash-data/HelloWorld.exe
Process mono created; pid = 12026
Listening on port 2002
Remote debugging from host 192.168.30.250
Method (wrapper runtime-invoke) object:runtime_invoke_void__this___object
(object,intptr,intptr,intptr) emitted at 0x4826d028 to 0x4826d194 (code length
364) [HelloWorld.exe]
Method System.OutOfMemoryException:.ctor (string) emitted at 0x4826d198 to
0x4826d1e4 (code length 76) [HelloWorld.exe]
Method System.SystemException:.ctor (string) emitted at 0x4826d1f0 to
0x4826d23c (code length 76) [HelloWorld.exe]
Method System.Exception:.ctor (string) emitted at 0x4826d248 to 0x4826d284
(code length 60) [HelloWorld.exe]
Method System.NullReferenceException:.ctor (string) emitted at 0x4826d288 to
0x4826d2d4 (code length 76) [HelloWorld.exe]
Method System.StackOverflowException:.ctor (string) emitted at 0x4826d2d8 to
0x4826d314 (code length 60) [HelloWorld.exe]
Method (wrapper runtime-invoke) HelloWorld:runtime_invoke_void_object
(object,intptr,intptr,intptr) emitted at 0x4826d318 to 0x4826d480 (code length
360) [HelloWorld.exe]
Method HelloWorld:Main (string[]) emitted at 0x4826d480 to 0x4826d4d0 (code
length 80) [HelloWorld.exe]
Method System.Console:WriteLine (string) emitted at 0x4826d4e8 to 0x4826d53c
(code length 84) [HelloWorld.exe]
Method (wrapper runtime-invoke) object:runtime_invoke_void
(object,intptr,intptr,intptr) emitted at 0x4826d548 to 0x4826d6a8 (code length
352) [HelloWorld.exe]
Method System.Console:.cctor () emitted at 0x4826d6c0 to 0x4826dc78 (code
length 1464) [HelloWorld.exe]
Method (wrapper managed-to-native) System.Text.Encoding:InternalCodePage (int&)
emitted at 0x4826dd30 to 0x4826de78 (code length 328) [HelloWorld.exe]
Method System.Text.Encoding:.cctor () emitted at 0x4826dea0 to 0x4826e59c (code
length 1788) [HelloWorld.exe]
Method (wrapper managed-to-native)
object:__icall_wrapper_mono_array_new_specific (intptr,int) emitted at
0x4826e5a8 to 0x4826e6f8 (code length 336) [HelloWorld.exe]

-- 
Configure bugmail: http://bugzilla.novell.com/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
You are the QA contact for the bug.
You are the assignee for the bug.


More information about the mono-bugs mailing list