Bug 376 - Crash on 10.5 and 10.6
Summary: Crash on 10.5 and 10.6
Status: RESOLVED NORESPONSE
Alias: None
Product: Runtime
Classification: Mono
Component: JIT ()
Version: unspecified
Hardware: Macintosh Mac OS
: Normal blocker
Target Milestone: ---
Assignee: Bugzilla
URL:
Depends on:
Blocks:
 
Reported: 2011-08-24 00:23 UTC by Prashanth Kamath
Modified: 2014-01-12 01:11 UTC (History)
4 users (show)

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


Attachments
Crash report from 10.5 on using 2.10.4 (1.38 KB, text/rtf)
2011-08-24 00:23 UTC, Prashanth Kamath
Details


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 NORESPONSE

Description Prashanth Kamath 2011-08-24 00:23:17 UTC
Created attachment 176 [details]
Crash report from 10.5 on using 2.10.4

My application worked fine on 10.5 and 10.6 using Mono 2.8.1. But it would not work on Lion. So I upgraded the mono version to 2.10.4. and Monobjc 2.0.55. The application is crashing as soon as you launch on some 10.5 and 10.6 systems. It works fine on others. I have attached the crash report.
Comment 1 Miguel de Icaza [MSFT] 2011-08-24 00:40:23 UTC
Please run your application with GDB, as described in:

http://www.mono-project.com/Debugging

And provide the relevant stack traces.
Comment 2 Prashanth Kamath 2011-08-27 01:17:55 UTC
I ran this against the gdb and I have pasted below the traces. Please let me know if you need anything more.


(gdb) run --debug --break  'System.Buffer:BlockCopy' /Applications/softest.app/softest   
Starting program: /Applications/SofTest.app/Contents/MacOS/SofTest --debug --break  'System.Buffer:BlockCopy' /Applications/softest.app/softest
dyld: Library not loaded: @executable_path/libgthread-2.0.0.dylib
  Referenced from: /Applications/SofTest.app/Contents/MacOS/SofTest
  Reason: no suitable image found.  Did find:
	/Applications/SofTest.app/Contents/MacOS/libgthread-2.0.0.dylib: unknown required load command 0x80000022
	/Applications/SofTest.app/Contents/MacOS/libgthread-2.0.0.dylib: unknown required load command 0x80000022

Program received signal SIGTRAP, Trace/breakpoint trap.
0x8fe01045 in __dyld_dyld_fatal_error ()
(gdb) call mono_pmip ($eip)
Unable to call function "mono_pmip" at 0x11652c0: no return type information available.
To call this function anyway, you can cast the return type explicitly (e.g. 'print (float) fabs (3.0)')
(gdb) call mono_debug_print_vars ($eip, 1)
Unable to call function "mono_debug_print_vars" at 0x11ea1d0: no return type information available.
To call this function anyway, you can cast the return type explicitly (e.g. 'print (float) fabs (3.0)')
(gdb) mono_stack

Program received signal EXC_BAD_ACCESS, Could not access memory.
Reason: KERN_PROTECTION_FAILURE at address: 0x00000000
0x0135ea21 in mono_thread_current ()
The program being debugged was signaled while in a function called from GDB.
GDB remains in the frame where the signal was received.
To change this behavior use "set unwindonsignal on"
Evaluation of the expression containing the function (mono_thread_current) will be abandoned.
(gdb) p mono_pmip (0x8fe01045)
Unable to call function "mono_pmip" at 0x11652c0: no return type information available.
To call this function anyway, you can cast the return type explicitly (e.g. 'print (float) fabs (3.0)')
(gdb) where
#0  0x0135ea21 in mono_thread_current ()
Cannot access memory at address 0x61726269
(gdb) p mono_pmip (0x0135ea21)
Unable to call function "mono_pmip" at 0x11652c0: no return type information available.
To call this function anyway, you can cast the return type explicitly (e.g. 'print (float) fabs (3.0)')
(gdb) p mono_pmip (0x61726269)
Unable to call function "mono_pmip" at 0x11652c0: no return type information available.
To call this function anyway, you can cast the return type explicitly (e.g. 'print (float) fabs (3.0)')
Comment 3 Miguel de Icaza [MSFT] 2011-08-29 15:34:23 UTC
Follow the instructions that GDB provided, for example, use:

(gdb) p (char *) mono_pmip (...)

As it is, what yo provided is useless.
Comment 4 Prashanth Kamath 2011-08-30 12:35:12 UTC
Let me know if this works - 


run --debug --break  'System.Buffer:BlockCopy'  /Applications/SofTest.app/Contents/MacOS/SofTest
The program being debugged has been started already.
Start it from the beginning? (y or n) y
Starting program: /Applications/SofTest.app/Contents/MacOS/SofTest --debug --break  'System.Buffer:BlockCopy'  /Applications/SofTest.app/Contents/MacOS/SofTest
dyld: Library not loaded: @executable_path/libgthread-2.0.0.dylib
  Referenced from: /Applications/SofTest.app/Contents/MacOS/SofTest
  Reason: no suitable image found.  Did find:
	/Applications/SofTest.app/Contents/MacOS/libgthread-2.0.0.dylib: unknown required load command 0x80000022
	/Applications/SofTest.app/Contents/MacOS/libgthread-2.0.0.dylib: unknown required load command 0x80000022

Program received signal SIGTRAP, Trace/breakpoint trap.
0x8fe01045 in __dyld_dyld_fatal_error ()
(gdb) where
#0  0x8fe01045 in __dyld_dyld_fatal_error ()
#1  0x8fe07fd8 in __dyld__ZN4dyld5_mainEPK11mach_headermiPPKcS5_S5_ ()
#2  0x8fe01872 in __dyld__ZN13dyldbootstrap5startEPK11mach_headeriPPKcl ()
#3  0x8fe01037 in __dyld__dyld_start ()
(gdb) p (char *) mono_pmip (0x8fe01045)

Program received signal EXC_BAD_ACCESS, Could not access memory.
Reason: KERN_PROTECTION_FAILURE at address: 0x00000000
0x011652c5 in mono_pmip ()
The program being debugged was signaled while in a function called from GDB.
GDB has restored the context to what it was before the call.
To change this behavior use "set unwindonsignal off"
Evaluation of the expression containing the function (mono_pmip) will be abandoned.
(gdb) p (char *) mono_pmip (0x8fe07fd8)

Program received signal EXC_BAD_ACCESS, Could not access memory.
Reason: KERN_PROTECTION_FAILURE at address: 0x00000000
0x011652c5 in mono_pmip ()
The program being debugged was signaled while in a function called from GDB.
GDB has restored the context to what it was before the call.
To change this behavior use "set unwindonsignal off"
Evaluation of the expression containing the function (mono_pmip) will be abandoned.
(gdb) p (char *) mono_pmip (0x8fe01872)

Program received signal EXC_BAD_ACCESS, Could not access memory.
Reason: KERN_PROTECTION_FAILURE at address: 0x00000000
0x011652c5 in mono_pmip ()
The program being debugged was signaled while in a function called from GDB.
GDB has restored the context to what it was before the call.
To change this behavior use "set unwindonsignal off"
Evaluation of the expression containing the function (mono_pmip) will be abandoned.
Comment 5 Miguel de Icaza [MSFT] 2011-08-30 13:29:47 UTC
Sadly, not very useful.  

Please create a self-contained test case, with as little code as possible.   Remove as many libraries as you can.
Comment 6 Prashanth Kamath 2011-08-31 15:23:02 UTC
I am building my application the following way - 

xbuild myproject.proj

So how do I modify the xbuild to build it in debug mode ?. 

Can you help me ?.
Comment 7 Rodrigo Kumpera 2014-01-12 01:11:45 UTC
No test case was given.