From owner-freebsd-sparc64@FreeBSD.ORG Sun Jan 19 23:51:21 2014 Return-Path: Delivered-To: sparc64@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [8.8.178.115]) (using TLSv1 with cipher ADH-AES256-SHA (256/256 bits)) (No client certificate requested) by hub.freebsd.org (Postfix) with ESMTPS id DBA35461; Sun, 19 Jan 2014 23:51:20 +0000 (UTC) Received: from mx.bsdtec.net (mx.bsdtec.net [174.34.171.65]) by mx1.freebsd.org (Postfix) with ESMTP id 96AD71845; Sun, 19 Jan 2014 23:51:20 +0000 (UTC) Received: from localhost (mx.bsdtec.net [172.16.32.2]) by mx.bsdtec.net (Postfix) with ESMTP id DD988489876; Sun, 19 Jan 2014 23:51:18 +0000 (UTC) Received: from mx.bsdtec.net ([172.16.32.2]) by localhost (mx.bsdtec.net [172.16.32.2]) (amavisd-new, port 10032) with ESMTP id 9TfVjevzsgS8; Sun, 19 Jan 2014 23:51:17 +0000 (UTC) Received: from localhost (mx.bsdtec.net [172.16.32.2]) by mx.bsdtec.net (Postfix) with ESMTP id 7E804489898; Sun, 19 Jan 2014 23:51:17 +0000 (UTC) X-Virus-Scanned: amavisd-new at bsdtec.net Received: from mx.bsdtec.net ([172.16.32.2]) by localhost (mx.bsdtec.net [172.16.32.2]) (amavisd-new, port 10026) with ESMTP id 9wZ4J1V3d1cA; Sun, 19 Jan 2014 23:51:17 +0000 (UTC) Received: from [192.168.1.110] (bsdtec.plus.com [84.92.41.141]) by mx.bsdtec.net (Postfix) with ESMTPSA id B4D7A489876; Sun, 19 Jan 2014 23:51:16 +0000 (UTC) Message-ID: <1390175474.8376.3.camel@atlas.lerwick.hopto.org> Subject: Re: Call for help: clang/llvm for sparc64 From: Craig Butler To: Roman Divacky Date: Sun, 19 Jan 2014 23:51:14 +0000 In-Reply-To: <20140117221330.GA2788@freebsd.org> References: <20140117183733.GA93251@freebsd.org> <1389984564.3414.5.camel@atlas.lerwick.hopto.org> <20140117221330.GA2788@freebsd.org> Content-Type: text/plain; charset="UTF-8" X-Mailer: Evolution 3.8.4-0ubuntu1 Mime-Version: 1.0 Content-Transfer-Encoding: 7bit Cc: sparc64@freebsd.org X-BeenThere: freebsd-sparc64@freebsd.org X-Mailman-Version: 2.1.17 Precedence: list List-Id: Porting FreeBSD to the Sparc List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sun, 19 Jan 2014 23:51:21 -0000 On Fri, 2014-01-17 at 23:13 +0100, Roman Divacky wrote: > fwiw, we have a small testcase and I filed a bug in upstream llvm > > http://llvm.org/bugs/show_bug.cgi?id=18521 > > A big thank you, to jmg@ for providing the testcase and analyzing the bug. > > Roman > > On Fri, Jan 17, 2014 at 06:49:24PM +0000, Craig Butler wrote: > > On Fri, 2014-01-17 at 19:37 +0100, Roman Divacky wrote: > > > We got further. It looks like the problem is TLS related. It's crashing > > > in __getCurrentRuneLocale(). > > > > > > And to correct myself - you need to do --enable-target=sparc (not sparc64) > > > and you need to compile with gcc48. > > > > > > Anyway, start using llvm on sparc64, it's getting usable :) So more usage > > > is better. > > > > > > On Fri, Jan 17, 2014 at 01:12:42PM +0000, Craig Butler wrote: > > > > Hi Roman and list. > > > > > > > > I've got some spare time and sparc64 kit in the rack. I can help out and walk through anything you need. > > > > > > > > Kind Regards > > > > > > > > Craig Butler > > > > > > > > Roman Divacky wrote: > > > > > > > > >Hi! > > > > > > > > > >LLVM is getting a sparc64 backend. It can even selfhost on linux. But it cant > > > > >on FreeBSD. I am wondering what causes that difference. > > > > > > > > > >A small test case where the difference can be seen is compiling tcsh from > > > > >base. The gethost utility used during the build just coredumps. I suspect > > > > >fixing that might get us on par with linux. > > > > > > > > > >So I am looking for someone who is willing to compile llvm/clang and > > > > >analyze whats wrong with gethost in tcsh compilation. > > > > > > > > > >This is how to do it (you need trunk llvm/clang): > > > > > > > > > >svn co http://llvm.org/svn/llvm-project/llvm/trunk llvm > > > > >cd llvm/ > > > > >svn co http://llvm.org/svn/llvm-project/cfe/trunk clang > > > > >cd ../ > > > > >CFLAGS=-fno-strict-aliasing CXXFLAGS=-fno-strict-aliasing ./configure --enable-optimized --enable-targets=sparc64 > > > > >make > > > > >make install > > > > > > > > > >will give you a clang binary that you can use for tcsh compilation: > > > > > > > > > >cd /usr/src/bin/csh > > > > >CC=clang make > > > > > > > > > >I am more than willing to help with llvm/clang side of this but I dont know > > > > >anything about sparc64 so I need help. But please contact me if you want to > > > > >help! > > > > > > > > > >Thanks, Roman > > > > Thanks Roman.. I'll compile gcc48 on my tinderbox and try again. > > > > Report back soon > > > > Regards > > > > Craig Butler Hello Folks For anyone else trying to build llvm/clang I have gcc48 pkgng available (should save a day of compiling) I have also found that clang checkout needs to happen in llvm/tools for the llvm build to pick it up. I needed to use gmake and gmake install because BSD make was complaining about "Error expanding embedded variable" Hopefully a llvm and clang build soon (still compiling!!) Kind Regards Craig Butler