Bug 5429 - Failed to compile mono-2-10/g3d6c70d
Summary: Failed to compile mono-2-10/g3d6c70d
Alias: None
Product: Runtime
Classification: Mono
Component: JIT ()
Version: unspecified
Hardware: PC Linux
: --- normal
Target Milestone: ---
Assignee: Bugzilla
Depends on:
Reported: 2012-05-31 01:02 UTC by ch cooli
Modified: 2012-06-02 05:24 UTC (History)
4 users (show)

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:

Description ch cooli 2012-05-31 01:02:05 UTC
Failed to compile mono-2-10/g3d6c70d (2012-05-31)
my last version currently using is mono-2-10/g5da868c (2012-04-28)

make[7]: Entering directory `/home/linux/mono/mcs/class/System'
make[7]: Leaving directory `/home/linux/mono/mcs/class/System'
make[7]: Entering directory `/home/linux/mono/mcs/class/System'
make all-local
make[8]: Entering directory `/home/linux/mono/mcs/class/System'
MCS     [net_2_0] System.dll
System.Diagnostics/XmlWriterTraceListener.cs(180,74): warning CS0612: `System.Xml.XmlConvert.ToString(System.DateTime)' is obsolete
System.Net.Sockets/Socket_2_1.cs(1643,38): warning CS0219: The variable `addresses' is assigned but its value is never used
System/UriBuilder.cs(233,39): warning CS0612: `System.Uri.Uri(string, bool)' is obsolete
System.Configuration/CustomizableFileSettingsProvider.cs(83,37): warning CS0649: Field `System.Configuration.CustomizableFileSettingsProvider.webConfigurationFileMapType' is never assigned to, and will always have its default value `null'
System.Diagnostics/TraceImpl.cs(45,28): warning CS0649: Field `System.Diagnostics.TraceImplSettings.IndentLevel' is never assigned to, and will always have its default value `0'
System.Net/HttpConnection.cs(63,28): warning CS0169: The private field `System.Net.HttpConnection.local_ep' is never used
System.Net/HttpWebRequest.cs(398,32): warning CS0414: The private field `System.Net.HttpWebRequest.colon' is assigned but its value is never used
Compilation succeeded - 7 warning(s)

  at Mono.Xml.MiniParser.Parse (Mono.Xml.MiniParser/IReader,Mono.Xml.MiniParser/IHandler) <0x00387>
  at Mono.Xml.SecurityParser.LoadXml (string) <0x00047>
  at Mono.Security.StrongNameManager.LoadConfig (string) <0x0009f>
  at Mono.Tools.SN.LoadConfig (bool) <0x000cb>
  at Mono.Tools.SN.Process (string[]) <0x00107>
  at Mono.Tools.SN.Main (string[]) <0x0003f>
  at (wrapper runtime-invoke) <Module>.runtime_invoke_int_object (object,intptr,intptr,intptr) <0xffffffff>

Native stacktrace:

	/home/linux/mono/mono/mini/mono() [0x49172e]
	/home/linux/mono/mono/mini/mono() [0x4e5dcf]
	/home/linux/mono/mono/mini/mono() [0x417559]
	/lib/libpthread.so.0(+0xf8f0) [0x2ab0196e18f0]
	/home/linux/mono/mono/mini/mono() [0x44364e]
	/home/linux/mono/mono/mini/mono() [0x41bed7]
	/home/linux/mono/mono/mini/mono() [0x41d74b]
	/home/linux/mono/mono/mini/mono() [0x41dfdd]
	/home/linux/mono/mono/mini/mono() [0x49541b]
	/home/linux/mono/mono/mini/mono() [0x495e6d]

Debug info from gdb:

[Thread debugging using libthread_db enabled]
[New Thread 0x2aaaabe50700 (LWP 25807)]
[New Thread 0x2aaaaacb1700 (LWP 25796)]
0x00002ab0196e148d in waitpid () from /lib/libpthread.so.0
  3 Thread 0x2aaaaacb1700 (LWP 25796)  0x00002ab0196dd85c in pthread_cond_wait@@GLIBC_2.3.2 () from /lib/libpthread.so.0
  2 Thread 0x2aaaabe50700 (LWP 25807)  0x00002ab0196dfb50 in sem_wait ()
   from /lib/libpthread.so.0
* 1 Thread 0x2ab019c73360 (LWP 25775)  0x00002ab0196e148d in waitpid ()
   from /lib/libpthread.so.0

Thread 3 (Thread 0x2aaaaacb1700 (LWP 25796)):
#0  0x00002ab0196dd85c in pthread_cond_wait@@GLIBC_2.3.2 ()
   from /lib/libpthread.so.0
#1  0x00000000005db638 in GC_wait_marker () at pthread_support.c:1863
#2  0x00000000005e4e3e in GC_help_marker (my_mark_no=3) at mark.c:1116
#3  0x00000000005da304 in GC_mark_thread (id=0x0) at pthread_support.c:552
#4  0x00002ab0196d89ca in start_thread () from /lib/libpthread.so.0
#5  0x00002ab0199d5cdd in clone () from /lib/libc.so.6
#6  0x0000000000000000 in ?? ()

Thread 2 (Thread 0x2aaaabe50700 (LWP 25807)):
#0  0x00002ab0196dfb50 in sem_wait () from /lib/libpthread.so.0
#1  0x00000000005c9458 in mono_sem_wait (sem=0x8efb40, alertable=1)
    at mono-semaphore.c:113
#2  0x000000000058e52b in finalizer_thread (unused=<value optimized out>)
    at gc.c:1077
#3  0x0000000000592f3b in start_wrapper_internal (data=<value optimized out>)
    at threads.c:784
#4  start_wrapper (data=<value optimized out>) at threads.c:832
#5  0x00000000005b6fd4 in thread_start_routine (args=0x195de70) at wthreads.c:287
#6  0x00000000005db29b in GC_start_routine (arg=0x2aaaab3bafc0)
    at pthread_support.c:1468
#7  0x00002ab0196d89ca in start_thread () from /lib/libpthread.so.0
#8  0x00002ab0199d5cdd in clone () from /lib/libc.so.6
#9  0x0000000000000000 in ?? ()

Thread 1 (Thread 0x2ab019c73360 (LWP 25775)):
#0  0x00002ab0196e148d in waitpid () from /lib/libpthread.so.0
#1  0x0000000000491872 in mono_handle_native_sigsegv (
    signal=<value optimized out>, ctx=<value optimized out>)
    at mini-exceptions.c:2192
#2  0x00000000004e5dcf in mono_arch_handle_altstack_exception (
    sigctx=0x2aaaaaaafbc0, fault_addr=<value optimized out>, stack_ovf=0)
    at exceptions-amd64.c:953
#3  0x0000000000417559 in mono_sigsegv_signal_handler (_dummy=11, 
    info=0x2aaaaaaafcf0, context=0x2aaaaaaafbc0) at mini.c:5940
#4  <signal handler called>
#5  0x000000000044364e in mono_method_to_ir (cfg=0x19f45c0, 
    method=<value optimized out>, start_bblock=<value optimized out>, 
---Type <return> to continue, or q <return> to quit---
Comment 1 Zoltan Varga 2012-05-31 06:37:59 UTC
Is this reproducible ? If yes, could you do a binary search among revisions to pinpoint the failing commit ?

Also, commits g3d6c70d and g5da868c doesn't seem to exist in our repo. Where are these commits from ?
Comment 2 ch cooli 2012-05-31 07:13:32 UTC
in https://github.com/mono/mono.git
branch mono-2-10
fail 3d6c70d28e9440285832375c514520f59082194f
ok 5da868cbe520df0e7dcd16f828989ef58d6b9566
Comment 3 ch cooli 2012-05-31 08:01:31 UTC
$ git bisect bad
0127f24037f50193e7771af0ba3eb24d44b43fdc is the first bad commit
Comment 4 Zoltan Varga 2012-05-31 09:01:55 UTC
That seems a pretty harmless commit, I'm not sure how that would cause crashes.
Comment 5 ch cooli 2012-05-31 11:39:57 UTC
I use Ubuntu 10.04 x64 in 2 machines. Both machines suffers from the same problem
Comment 6 ch cooli 2012-05-31 11:43:52 UTC
From the stack trace, it is obvious that it uses the mono runtime just compiled from g0127f240 to run the compiler to compile class libraries.
g0127f240 has modifications to mono runtime.
Comment 7 Zoltan Varga 2012-05-31 14:17:06 UTC
Yes, but those modifications shouldn't cause this crash.
Comment 8 ch cooli 2012-06-01 01:33:59 UTC
Since this commit is just a performance enhancement for mono 2.10 series,
could you
git revert 0127f24037f50193e7771af0ba3eb24d44b43fdc
as the problem exists on some machines?
Comment 9 Zoltan Varga 2012-06-01 04:55:40 UTC
I reverted that commit in b8d1e49bb73c27fb8b8387580ce65ad7bded2426. Does this fix the problem ?
Comment 10 ch cooli 2012-06-01 05:41:30 UTC
The revert fixed the problem. Thanks!
Comment 11 Zoltan Varga 2012-06-01 06:34:27 UTC
We need to find out why this patch causes a crash, it looks fine.
Comment 12 Zoltan Varga 2012-06-01 06:49:08 UTC
Should be fixed for real. Could you try the latest mono-2-10 branch (c895ea21a56aa970a531411935a9d369b9dc16a3) ?
Comment 13 ch cooli 2012-06-01 08:15:20 UTC
Why c895ea21a56aa970a531411935a9d369b9dc16a3 works? It is strange!
Comment 14 Zoltan Varga 2012-06-01 08:28:15 UTC
Does it work ? There was a missing prototype which caused random crashes on 64 bit systems.
Comment 15 ch cooli 2012-06-01 22:04:36 UTC
I found that the original commit includes an implicit function call to get the data, so it crash.

In recent master 4fb344d, "Add -Werror-implicit-function-declaration to CFLAGS later to avoid breaking configure tests." may prevent this, isn't it?

c895ea21a56aa970a531411935a9d369b9dc16a3 works now!
Comment 16 Zoltan Varga 2012-06-02 05:24:01 UTC