[Mono-winforms-list] Re: Error running monostub.exe.so after following directions

2a5gjx302@sneakemail.com 2a5gjx302@sneakemail.com
Sun, 27 Apr 2003 12:09:20 -0500


At 09:18 PM 27/04/2003 +0200, Alexandre Pigolkine wrote:
>On Sun, 2003-04-27 at 18:03, 2a5gjx302@sneakemail.com wrote:
>> Forgot to include the output text itself :-)
>> 
>> linsux:/c/mono# runwine Test.exe
>> parsing configuration file
>> initializing JIT engine
>> Initializing Boehm GC library...
>> exclusion ranges overlap
>
>I have this if monostub uses new libmono.so
>Can you please check that monostub.exe.so depends on liboldmono.so.0
>by ldd monostub.exe.so
I checked this, and it is definitely depending on oldmono and not the new
mono library.

>> wine: Unhandled exception, starting debugger...
>> Couldn't start process '10 0x40 '
>> Couldn't start process '10 0x40 '
>...
I guess WINE doesn't know how to invoke a debugger on my system :-)

>Alexandre


At 09:12 PM 27/04/2003 +0200, Alexandre Pigolkine wrote:
>Hmm, unexpected behaviour :(
>
>For a moment I think that monostub cannot get some symbols 
>from gc.dll.
>
>Can you do following, please: 
>
>In the System.Windows.Forms folder, file monogc.c:
>
>change line
>#define TRACE printf_stub
>
>to
>
>#define TRACE printf
>
>rebuild monostub, and send me output from program.
>
>Alexandre

I also isolated the code that outputs that error. The only place that emits
it is a function in mark_rts.c which is part of the GC. I added code to
that to emit trace information about static root exclusion ranges. Here is
the output with your change as well:

linsux:/c/mono# runwine Test.exe
parsing configuration file
initializing JIT engine
Initializing Boehm GC library...
adding exclusion range: 1084673760 1084731984
success
adding exclusion range: 1084671040 1084671360
success
GC_malloc start
GC_malloc end
(previous 2 lines repeated 2 more times)
GC_register_finalizer
GC_register_finalizer end
GC_malloc start
GC_malloc end
(previous 2 lines repeated 35 more times)
exclusion ranges overlap
wine: unhandled exception, starting debugger...
Segmentation fault
linsux:/c/mono# 

Notice that my debugging code doesn't show up in the second instance. At
first, I assumed this to mean that stderr had been redirected, since the
chance of control flow randomly jumping onto the line 'ABORT("exclusion
ranges overlap")' is exceedingly low. Unfortunately, without my debugging
code's output, it was difficult to see exactly what was going on. So, I
modified my debug code to append to a file instead of writing to the
standard error. The error file contained only the two above trace lines.

Having thought about it in more depth, it seems as though the other GC
library is being used for GC calls from the main mono interpreter, while
the WINE GC library is being used only by monogc.c directly.

What now? :-)

Jonathan