[Mono-dev] llvm issue

Bruno Lauzé brunolauze at msn.com
Wed Jan 22 22:31:05 UTC 2014


Here's the patches that makes everything works...
patch-configure.in : this fixes pthread at several places and ensure LLVM_ variables have a sed -e to replace lpthread to pthread 
patch-eglib_src_Makefile.am : there's an issue with the NEED_VASPRINTF detection i commented the fix to keep foo.c  ; definitively not the place ... 
patch-mcs_class_System_System.IO_KeventWatcher.cs: old patch for keven from romain.tartiere at gmail.com mono maintainer (bsd-sharp)
patch-mono_dis_util.c : there's a problem with HAVE_ISINF detection ; flushed the pragma here... definitively not the place ... 

patch-mono_mini_mini-llvm.c : The important patch - mini-llvm.c contains gsharevt code and libmono-llvm.so doesn't link it, since it's just returning false, i readded the functions locally... also mono_print_unwind_info is not linked from unwind.o and adding it pull up recursive dependency...
I am including romain tartiere to keep him in the loop if he wants to check those patches in bsd-sharp repo...
I don't say those patches are ok, to the contrary, i say those a hints at what is to be really fixed for FreeBSD...
there's still code pointing to libc.so instead of @LIBC@
but this fix the issues:
ln -s /lib/libc.so.7 /lib/libc.so
Here's the sys info :

uname -a:FreeBSD pcbsd 11.0-CURRENT FreeBSD 11.0-CURRENT #10 r260825M: Thu Jan 16 13:29:53 CST 2014     root at pcbsd:/usr/obj/usr/src/sys/GENERIC  amd64
mono --versionMono JIT compiler version 3.2.7 (master/738f9c3 Wed Jan 22 14:21:09 CST 2014)Copyright (C) 2002-2014 Novell, Inc, Xamarin Inc and Contributors. www.mono-project.com        TLS:           __thread        SIGSEGV:       altstack        Notification:  kqueue        Architecture:  amd64        Disabled:      none        Misc:          softdebug        LLVM:          yes(3.4-mono-/)        GC:            sgen
clang --versionMono C# compiler version 3.2.7.0root at pcbsd:/ # clang --versionFreeBSD clang version 3.4 (tags/RELEASE_34/final 197956) 20140101Target: x86_64-unknown-freebsd11.0Thread model: posix
llvm-config --version : 3.4-mono-/



Date: Wed, 22 Jan 2014 13:10:25 -0500
Subject: Re: [Mono-dev] llvm issue
From: kumpera at gmail.com
To: brunolauze at msn.com

We'd love to merge such change for FreeBSD :)

On Wed, Jan 22, 2014 at 12:24 PM, Bruno Lauzé <brunolauze at msn.com> wrote:




Good news,  i figured out why it was hanging with llvm.
It's seems part of the code is missing -pthread and/or using -lpthread
CFLAGS+= -pthread
CXXFLAGS+= -pthreadLDFLAGS+= -pthread
it seems llvm-config output -lpthread and not -pthreadreplace -lpthread to -pthread in  LLVM_CFLAGSreplace -lpthread to -pthread in  LLVM_LIBS

I don't know if someone is willing to see this in mono source or to keep it as external patch?

Date: Tue, 21 Jan 2014 14:16:37 -0500
Subject: Re: [Mono-dev] llvm issue
From: kumpera at gmail.com

To: brunolauze at msn.com
CC: mono-devel-list at lists.ximian.com


LLVM was never tests on FreeBSD, you'll have to debug it.

On Tue, Jan 21, 2014 at 8:35 AM, Bruno Lauzé <brunolauze at msn.com> wrote:





When I try to compile mono from git with llvm ; llvm installed from github.com/mono/llvm

I'm on FreeBSD HEAD.

Everything compiles smoothly but  now the mono-sgen process get stuck in "umtxn" state (kernel lock) on the first usage. (basic-profile-check.exe)

Whenever i remove --enable-llvm everything is fine again. This was working before around october. Any ideas what could have change to cause this?

Any suggestions where to look?


Thanks. 		 	   		  

_______________________________________________

Mono-devel-list mailing list

Mono-devel-list at lists.ximian.com

http://lists.ximian.com/mailman/listinfo/mono-devel-list



 		 	   		  

 		 	   		  
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.ximian.com/pipermail/mono-devel-list/attachments/20140122/8e07d578/attachment-0001.html>
-------------- next part --------------
A non-text attachment was scrubbed...
Name: patch-configure.in
Type: application/octet-stream
Size: 2529 bytes
Desc: not available
URL: <http://lists.ximian.com/pipermail/mono-devel-list/attachments/20140122/8e07d578/attachment-0003.obj>
-------------- next part --------------
A non-text attachment was scrubbed...
Name: patch-eglib_src_Makefile.am
Type: application/octet-stream
Size: 404 bytes
Desc: not available
URL: <http://lists.ximian.com/pipermail/mono-devel-list/attachments/20140122/8e07d578/attachment-0004.obj>
-------------- next part --------------
A non-text attachment was scrubbed...
Name: patch-mcs_class_System_System.IO_KeventWatcher.cs
Type: application/octet-stream
Size: 5519 bytes
Desc: not available
URL: <http://lists.ximian.com/pipermail/mono-devel-list/attachments/20140122/8e07d578/attachment-0005.obj>
-------------- next part --------------
An embedded and charset-unspecified text was scrubbed...
Name: patch-mono_dis_util.c
URL: <http://lists.ximian.com/pipermail/mono-devel-list/attachments/20140122/8e07d578/attachment-0002.c>
-------------- next part --------------
An embedded and charset-unspecified text was scrubbed...
Name: patch-mono_mini_mini-llvm.c
URL: <http://lists.ximian.com/pipermail/mono-devel-list/attachments/20140122/8e07d578/attachment-0003.c>


More information about the Mono-devel-list mailing list