[Mono-dev] GC segfault on ARM

Brian Koropoff briank at marakicorp.com
Wed Aug 17 16:37:11 EDT 2005

I'm a consultant working under contract for Maraki Corp., a startup that 
will eventually be deploying Mono in an embedded ARM environment.  My 
job at this stage is to get the ARM JIT recently checked into SVN to run 
on our ARM boards and contribute back bug fixes/enhancements.  I 
currently have a functional big endian ARM linux system that I have used 
to successfully build the ARM JIT.  However, upon attempting to run a 
CIL executable, mono immediately segfaults.  A backtrace indicates that 
the segfault occurs in the Boehm GC:

Program received signal SIGSEGV, Segmentation fault.
[Switching to Thread 16384 (LWP 32700)]
GC_push_all_eager (bottom=0x0, top=0x1990a8 "") at mark.c:1468
1468            q = *p;
(gdb) bt
#0  GC_push_all_eager (bottom=0x0, top=0x1990a8 "") at mark.c:1468
#1  0x000b9ef8 in pthread_push_all_stacks () at pthread_stop_world.c:266
#2  0x000b9fac in GC_push_all_stacks () at pthread_stop_world.c:297
#3  0x000b5848 in GC_push_roots (all=1, cold_gc_frame=0xbefffa4c "")
   at mark_rts.c:643
#4  0x000b4c60 in $a () at mark.c:326
#5  0x000b4c60 in $a () at mark.c:326
Previous frame identical to this frame (corrupt stack?)

It's always possible that errant code elsewhere in Mono is corrupting GC 
data structures, so I'm looking into building an ARM version of valgrind 
or comparable debugging tool to test this.  I also plan to contact Hans 
Boehm in case it is a problem in the GC.  In any case, has anyone 
encountered this issue before?  Any help would be appreciated.

Brian Koropoff

More information about the Mono-devel-list mailing list