From owner-freebsd-sparc64@FreeBSD.ORG Sun Jun 12 11:57:33 2011 Return-Path: Delivered-To: freebsd-sparc64@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id CDC64106564A for ; Sun, 12 Jun 2011 11:57:33 +0000 (UTC) (envelope-from marius@alchemy.franken.de) Received: from alchemy.franken.de (alchemy.franken.de [194.94.249.214]) by mx1.freebsd.org (Postfix) with ESMTP id 4D1698FC17 for ; Sun, 12 Jun 2011 11:57:32 +0000 (UTC) Received: from alchemy.franken.de (localhost [127.0.0.1]) by alchemy.franken.de (8.14.4/8.14.4/ALCHEMY.FRANKEN.DE) with ESMTP id p5CBvR47070583; Sun, 12 Jun 2011 13:57:28 +0200 (CEST) (envelope-from marius@alchemy.franken.de) Received: (from marius@localhost) by alchemy.franken.de (8.14.4/8.14.4/Submit) id p5CBvRrs070582; Sun, 12 Jun 2011 13:57:27 +0200 (CEST) (envelope-from marius) Date: Sun, 12 Jun 2011 13:57:27 +0200 From: Marius Strobl To: Peter Jeremy Message-ID: <20110612115727.GA70559@alchemy.franken.de> References: <20110526234728.GA69750@server.vk2pj.dyndns.org> <20110527120659.GA78000@alchemy.franken.de> <20110601231237.GA5267@server.vk2pj.dyndns.org> Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <20110601231237.GA5267@server.vk2pj.dyndns.org> User-Agent: Mutt/1.4.2.3i Cc: freebsd-sparc64@freebsd.org Subject: Re: 'make -j16 universe' gives SIReset X-BeenThere: freebsd-sparc64@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: Porting FreeBSD to the Sparc List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sun, 12 Jun 2011 11:57:33 -0000 On Thu, Jun 02, 2011 at 09:12:37AM +1000, Peter Jeremy wrote: > > (BTW "make universe" seems to have issues cross-building x86 > derivatives). I'm now trying that on -current. For got to say that I think that nwhitehorn@ fixed cross-building x86 some time ago but I'm unsure whether these changes have made it back into stable/8 so far. Marius From owner-freebsd-sparc64@FreeBSD.ORG Sun Jun 12 13:31:10 2011 Return-Path: Delivered-To: freebsd-sparc64@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 75DFF106566C for ; Sun, 12 Jun 2011 13:31:10 +0000 (UTC) (envelope-from nwhitehorn@banshee.munuc.org) Received: from banshee.munuc.org (cl-106.chi-02.us.sixxs.net [IPv6:2001:4978:f:69::2]) by mx1.freebsd.org (Postfix) with ESMTP id 42D128FC14 for ; Sun, 12 Jun 2011 13:31:10 +0000 (UTC) Received: from nwhitehorn (helo=localhost) by banshee.munuc.org with local-esmtp (Exim 4.74 (FreeBSD)) (envelope-from ) id 1QVkks-000Dpv-EA; Sun, 12 Jun 2011 08:31:06 -0500 Date: Sun, 12 Jun 2011 08:31:06 -0500 (CDT) From: Nathan Whitehorn X-X-Sender: nwhitehorn@banshee.munuc.org To: Marius Strobl In-Reply-To: <20110612115727.GA70559@alchemy.franken.de> Message-ID: References: <20110526234728.GA69750@server.vk2pj.dyndns.org> <20110527120659.GA78000@alchemy.franken.de> <20110601231237.GA5267@server.vk2pj.dyndns.org> <20110612115727.GA70559@alchemy.franken.de> User-Agent: Alpine 2.00 (BSF 1167 2008-08-23) MIME-Version: 1.0 Content-Type: TEXT/PLAIN; charset=US-ASCII; format=flowed Sender: Nathan Whitehorn X-SA-Exim-Connect-IP: X-SA-Exim-Mail-From: nwhitehorn@banshee.munuc.org X-SA-Exim-Scanned: No (on banshee.munuc.org); SAEximRunCond expanded to false Cc: freebsd-sparc64@freebsd.org Subject: Re: 'make -j16 universe' gives SIReset X-BeenThere: freebsd-sparc64@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: Porting FreeBSD to the Sparc List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sun, 12 Jun 2011 13:31:10 -0000 On Sun, 12 Jun 2011, Marius Strobl wrote: > On Thu, Jun 02, 2011 at 09:12:37AM +1000, Peter Jeremy wrote: >> >> (BTW "make universe" seems to have issues cross-building x86 >> derivatives). I'm now trying that on -current. > > For got to say that I think that nwhitehorn@ fixed cross-building x86 > some time ago but I'm unsure whether these changes have made it back > into stable/8 so far. > I never actually fixed it entirely. The point where I got stuck is that btxld has inline x86 assembly in it, so it isn't possible to build on non-x86 platforms. -Nathan From owner-freebsd-sparc64@FreeBSD.ORG Mon Jun 13 00:19:44 2011 Return-Path: Delivered-To: sparc64@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 9324E106566B; Mon, 13 Jun 2011 00:19:44 +0000 (UTC) (envelope-from tinderbox@freebsd.org) Received: from freebsd-current.sentex.ca (freebsd-current.sentex.ca [64.7.128.98]) by mx1.freebsd.org (Postfix) with ESMTP id 65F4F8FC0C; Mon, 13 Jun 2011 00:19:44 +0000 (UTC) Received: from freebsd-current.sentex.ca (localhost [127.0.0.1]) by freebsd-current.sentex.ca (8.14.4/8.14.4) with ESMTP id p5D0Jhp1081938; Sun, 12 Jun 2011 20:19:43 -0400 (EDT) (envelope-from tinderbox@freebsd.org) Received: (from tinderbox@localhost) by freebsd-current.sentex.ca (8.14.4/8.14.4/Submit) id p5D0JhfM081933; Mon, 13 Jun 2011 00:19:43 GMT (envelope-from tinderbox@freebsd.org) Date: Mon, 13 Jun 2011 00:19:43 GMT Message-Id: <201106130019.p5D0JhfM081933@freebsd-current.sentex.ca> X-Authentication-Warning: freebsd-current.sentex.ca: tinderbox set sender to FreeBSD Tinderbox using -f Sender: FreeBSD Tinderbox From: FreeBSD Tinderbox To: FreeBSD Tinderbox , , Precedence: bulk Cc: Subject: [head tinderbox] failure on sparc64/sparc64 X-BeenThere: freebsd-sparc64@freebsd.org X-Mailman-Version: 2.1.5 List-Id: Porting FreeBSD to the Sparc List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Mon, 13 Jun 2011 00:19:44 -0000 TB --- 2011-06-12 23:22:17 - tinderbox 2.7 running on freebsd-current.sentex.ca TB --- 2011-06-12 23:22:17 - starting HEAD tinderbox run for sparc64/sparc64 TB --- 2011-06-12 23:22:17 - cleaning the object tree TB --- 2011-06-12 23:22:31 - cvsupping the source tree TB --- 2011-06-12 23:22:31 - /usr/bin/csup -z -r 3 -g -L 1 -h cvsup.sentex.ca /tinderbox/HEAD/sparc64/sparc64/supfile TB --- 2011-06-12 23:22:46 - building world TB --- 2011-06-12 23:22:46 - MAKEOBJDIRPREFIX=/obj TB --- 2011-06-12 23:22:46 - PATH=/usr/bin:/usr/sbin:/bin:/sbin TB --- 2011-06-12 23:22:46 - TARGET=sparc64 TB --- 2011-06-12 23:22:46 - TARGET_ARCH=sparc64 TB --- 2011-06-12 23:22:46 - TZ=UTC TB --- 2011-06-12 23:22:46 - __MAKE_CONF=/dev/null TB --- 2011-06-12 23:22:46 - cd /src TB --- 2011-06-12 23:22:46 - /usr/bin/make -B buildworld >>> World build started on Sun Jun 12 23:22:46 UTC 2011 >>> Rebuilding the temporary build tree >>> stage 1.1: legacy release compatibility shims >>> stage 1.2: bootstrap tools >>> stage 2.1: cleaning up the object tree >>> stage 2.2: rebuilding the object tree >>> stage 2.3: build tools >>> stage 3: cross tools >>> stage 4.1: building includes >>> stage 4.2: building libraries >>> stage 4.3: make dependencies >>> stage 4.4: building everything [...] cc -O2 -pipe -I/src/usr.sbin/makefs -I/src/usr.sbin/makefs/../../sys/fs/cd9660/ -I/src/usr.sbin/makefs/../../sys/ufs/ffs -I/src/usr.sbin/makefs/compat -DHAVE_STRUCT_STAT_ST_FLAGS=1 -DHAVE_STRUCT_STAT_ST_GEN=1 -I/src/usr.sbin/makefs/../mtree -std=gnu99 -fstack-protector -Wsystem-headers -Werror -Wall -Wno-format-y2k -Wno-uninitialized -Wno-pointer-sign -c /src/usr.sbin/makefs/ffs/ffs_alloc.c cc -O2 -pipe -I/src/usr.sbin/makefs -I/src/usr.sbin/makefs/../../sys/fs/cd9660/ -I/src/usr.sbin/makefs/../../sys/ufs/ffs -I/src/usr.sbin/makefs/compat -DHAVE_STRUCT_STAT_ST_FLAGS=1 -DHAVE_STRUCT_STAT_ST_GEN=1 -I/src/usr.sbin/makefs/../mtree -std=gnu99 -fstack-protector -Wsystem-headers -Werror -Wall -Wno-format-y2k -Wno-uninitialized -Wno-pointer-sign -c /src/usr.sbin/makefs/ffs/ffs_balloc.c cc -O2 -pipe -I/src/usr.sbin/makefs -I/src/usr.sbin/makefs/../../sys/fs/cd9660/ -I/src/usr.sbin/makefs/../../sys/ufs/ffs -I/src/usr.sbin/makefs/compat -DHAVE_STRUCT_STAT_ST_FLAGS=1 -DHAVE_STRUCT_STAT_ST_GEN=1 -I/src/usr.sbin/makefs/../mtree -std=gnu99 -fstack-protector -Wsystem-headers -Werror -Wall -Wno-format-y2k -Wno-uninitialized -Wno-pointer-sign -c /src/usr.sbin/makefs/ffs/ffs_bswap.c cc1: warnings being treated as errors In file included from /src/usr.sbin/makefs/ffs/ffs_bswap.c:51: /obj/sparc64.sparc64/src/tmp/usr/include/ufs/ffs/ffs_extern.h:169: warning: data definition has no type or storage class /obj/sparc64.sparc64/src/tmp/usr/include/ufs/ffs/ffs_extern.h:169: warning: parameter names (without types) in function declaration /obj/sparc64.sparc64/src/tmp/usr/include/ufs/ffs/ffs_extern.h:172: error: expected specifier-qualifier-list before 'LIST_ENTRY' *** Error code 1 Stop in /src/usr.sbin/makefs. *** Error code 1 Stop in /src/usr.sbin. *** Error code 1 Stop in /src. *** Error code 1 Stop in /src. *** Error code 1 Stop in /src. TB --- 2011-06-13 00:19:43 - WARNING: /usr/bin/make returned exit code 1 TB --- 2011-06-13 00:19:43 - ERROR: failed to build world TB --- 2011-06-13 00:19:43 - 2662.22 user 591.94 system 3445.93 real http://tinderbox.freebsd.org/tinderbox-head-HEAD-sparc64-sparc64.full From owner-freebsd-sparc64@FreeBSD.ORG Mon Jun 13 11:07:12 2011 Return-Path: Delivered-To: freebsd-sparc64@FreeBSD.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 978951065672 for ; Mon, 13 Jun 2011 11:07:12 +0000 (UTC) (envelope-from owner-bugmaster@FreeBSD.org) Received: from freefall.freebsd.org (freefall.freebsd.org [IPv6:2001:4f8:fff6::28]) by mx1.freebsd.org (Postfix) with ESMTP id 860B08FC0A for ; Mon, 13 Jun 2011 11:07:12 +0000 (UTC) Received: from freefall.freebsd.org (localhost [127.0.0.1]) by freefall.freebsd.org (8.14.4/8.14.4) with ESMTP id p5DB7Cuv092194 for ; Mon, 13 Jun 2011 11:07:12 GMT (envelope-from owner-bugmaster@FreeBSD.org) Received: (from gnats@localhost) by freefall.freebsd.org (8.14.4/8.14.4/Submit) id p5DB7Btm092192 for freebsd-sparc64@FreeBSD.org; Mon, 13 Jun 2011 11:07:11 GMT (envelope-from owner-bugmaster@FreeBSD.org) Date: Mon, 13 Jun 2011 11:07:11 GMT Message-Id: <201106131107.p5DB7Btm092192@freefall.freebsd.org> X-Authentication-Warning: freefall.freebsd.org: gnats set sender to owner-bugmaster@FreeBSD.org using -f From: FreeBSD bugmaster To: freebsd-sparc64@FreeBSD.org Cc: Subject: Current problem reports assigned to freebsd-sparc64@FreeBSD.org X-BeenThere: freebsd-sparc64@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: Porting FreeBSD to the Sparc List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Mon, 13 Jun 2011 11:07:12 -0000 Note: to view an individual PR, use: http://www.freebsd.org/cgi/query-pr.cgi?pr=(number). The following is a listing of current problems submitted by FreeBSD users. These represent problem reports covering all versions including experimental development code and obsolete releases. S Tracker Resp. Description -------------------------------------------------------------------------------- f sparc/145211 sparc64 [panic] Memory modified after free o sparc/142102 sparc64 [nfs] [panic] FreeBSD 8.0 kernel panics on sparc64 whe o sparc/141918 sparc64 [ehci] ehci_interrupt: unrecoverable error, controller s sparc/139134 sparc64 kernel output corruption f sparc/108732 sparc64 ping(8) reports 14 digit time on sparc64 s sparc/107087 sparc64 [hang] system is hung during boot from CD o sparc/105048 sparc64 [trm] trm(4) panics on sparc64 o sparc/104428 sparc64 [nullfs] nullfs panics on E4500 (but not E420) o sparc/80890 sparc64 [panic] kmem_malloc(73728): kmem_map too small running o sparc/71729 sparc64 printf in kernel thread causes panic on SPARC 10 problems total. From owner-freebsd-sparc64@FreeBSD.ORG Mon Jun 13 23:51:56 2011 Return-Path: Delivered-To: freebsd-sparc64@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 957D71065670 for ; Mon, 13 Jun 2011 23:51:56 +0000 (UTC) (envelope-from peterjeremy@acm.org) Received: from mail35.syd.optusnet.com.au (mail35.syd.optusnet.com.au [211.29.133.51]) by mx1.freebsd.org (Postfix) with ESMTP id 2959F8FC08 for ; Mon, 13 Jun 2011 23:51:55 +0000 (UTC) Received: from server.vk2pj.dyndns.org (c220-239-116-103.belrs4.nsw.optusnet.com.au [220.239.116.103]) by mail35.syd.optusnet.com.au (8.13.1/8.13.1) with ESMTP id p5DNpksC013126 (version=TLSv1/SSLv3 cipher=DHE-RSA-AES256-SHA bits=256 verify=NO); Tue, 14 Jun 2011 09:51:48 +1000 X-Bogosity: Ham, spamicity=0.000000 Received: from server.vk2pj.dyndns.org (localhost.vk2pj.dyndns.org [127.0.0.1]) by server.vk2pj.dyndns.org (8.14.4/8.14.4) with ESMTP id p5DNpkJq013371; Tue, 14 Jun 2011 09:51:46 +1000 (EST) (envelope-from peter@server.vk2pj.dyndns.org) Received: (from peter@localhost) by server.vk2pj.dyndns.org (8.14.4/8.14.4/Submit) id p5DNpjZC013370; Tue, 14 Jun 2011 09:51:45 +1000 (EST) (envelope-from peter) Date: Tue, 14 Jun 2011 09:51:44 +1000 From: Peter Jeremy To: Marius Strobl Message-ID: <20110613235144.GA12470@server.vk2pj.dyndns.org> References: <20110526234728.GA69750@server.vk2pj.dyndns.org> <20110527120659.GA78000@alchemy.franken.de> <20110601231237.GA5267@server.vk2pj.dyndns.org> <20110608224801.GB35494@alchemy.franken.de> MIME-Version: 1.0 Content-Type: multipart/signed; micalg=pgp-sha1; protocol="application/pgp-signature"; boundary="82I3+IH0IqGh5yIs" Content-Disposition: inline In-Reply-To: <20110608224801.GB35494@alchemy.franken.de> X-PGP-Key: http://members.optusnet.com.au/peterjeremy/pubkey.asc User-Agent: Mutt/1.5.21 (2010-09-15) Cc: freebsd-sparc64@freebsd.org Subject: Re: 'make -j16 universe' gives SIReset X-BeenThere: freebsd-sparc64@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: Porting FreeBSD to the Sparc List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Mon, 13 Jun 2011 23:51:56 -0000 --82I3+IH0IqGh5yIs Content-Type: text/plain; charset=us-ascii Content-Disposition: inline Content-Transfer-Encoding: quoted-printable On 2011-Jun-09 00:48:01 +0200, Marius Strobl wr= ote: >This might be due to the excessive use of sched_lock by SCHED_4BSD >and the MD code, f.e. more CPUs means less TLB contexts per CPU which >in turn means more flushes that are protect by sched_lock. I have noticed that systat reports very high trap & fault counts. > It would >be great if the machine wouldn't lock up so you could check what >exactly is holding the mutex so long. Agreed. >I think meanwhile I had a sound idea how to achieve the necessary level >of protection in the MD code using just atomic operations instead of >sched_lock, which further down would also allow the use of SCHED_ULE. Sounds good - let me know if there's anything I can do to help. >> I tried adding this and the system survived a "make -j30 universe" on >> -stable (BTW "make universe" seems to have issues cross-building x86 >> derivatives). I'm now trying that on -current. I'm not sure what the >> implications of the above change are. >>=20 > >What was the outcome of these tests? I got a "spinlock held too long" panic that should have gone to DDB but the system wouldn't respond to anything other than a RSC reset. >Nevertheless it also would be interesting to know if you end up >with a corrupt kernel stack with DDB, KDB and r222840 in place, >especially in case disabling superscalar dispatch doesn't solve >the problem. I'm building r223035 with DDB & KDB and will see how that goes. --=20 Peter Jeremy --82I3+IH0IqGh5yIs Content-Type: application/pgp-signature -----BEGIN PGP SIGNATURE----- Version: GnuPG v2.0.17 (FreeBSD) iEYEARECAAYFAk32opAACgkQ/opHv/APuIfDjwCglHNX72XewKJU2nvc732O35Bn +T8An06Ah+gMKdgE73uTKdyAjYSkeF7H =Tpfy -----END PGP SIGNATURE----- --82I3+IH0IqGh5yIs-- From owner-freebsd-sparc64@FreeBSD.ORG Tue Jun 14 05:47:49 2011 Return-Path: Delivered-To: freebsd-sparc64@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id DFD11106566B for ; Tue, 14 Jun 2011 05:47:49 +0000 (UTC) (envelope-from peterjeremy@acm.org) Received: from mail11.syd.optusnet.com.au (mail11.syd.optusnet.com.au [211.29.132.192]) by mx1.freebsd.org (Postfix) with ESMTP id 70F628FC15 for ; Tue, 14 Jun 2011 05:47:49 +0000 (UTC) Received: from server.vk2pj.dyndns.org (c220-239-116-103.belrs4.nsw.optusnet.com.au [220.239.116.103]) by mail11.syd.optusnet.com.au (8.13.1/8.13.1) with ESMTP id p5E5lgak011872 (version=TLSv1/SSLv3 cipher=DHE-RSA-AES256-SHA bits=256 verify=NO); Tue, 14 Jun 2011 15:47:43 +1000 X-Bogosity: Ham, spamicity=0.000000 Received: from server.vk2pj.dyndns.org (localhost.vk2pj.dyndns.org [127.0.0.1]) by server.vk2pj.dyndns.org (8.14.4/8.14.4) with ESMTP id p5E5lfCv015211; Tue, 14 Jun 2011 15:47:41 +1000 (EST) (envelope-from peter@server.vk2pj.dyndns.org) Received: (from peter@localhost) by server.vk2pj.dyndns.org (8.14.4/8.14.4/Submit) id p5E5lfdT015210; Tue, 14 Jun 2011 15:47:41 +1000 (EST) (envelope-from peter) Date: Tue, 14 Jun 2011 15:47:41 +1000 From: Peter Jeremy To: Marius Strobl Message-ID: <20110614054741.GA14793@server.vk2pj.dyndns.org> References: <20110526234728.GA69750@server.vk2pj.dyndns.org> <20110527120659.GA78000@alchemy.franken.de> <20110601231237.GA5267@server.vk2pj.dyndns.org> <20110608224801.GB35494@alchemy.franken.de> <20110613235144.GA12470@server.vk2pj.dyndns.org> MIME-Version: 1.0 Content-Type: multipart/signed; micalg=pgp-sha1; protocol="application/pgp-signature"; boundary="2oS5YaxWCcQjTEyO" Content-Disposition: inline In-Reply-To: <20110613235144.GA12470@server.vk2pj.dyndns.org> X-PGP-Key: http://members.optusnet.com.au/peterjeremy/pubkey.asc User-Agent: Mutt/1.5.21 (2010-09-15) Cc: freebsd-sparc64@freebsd.org Subject: Re: 'make -j16 universe' gives SIReset X-BeenThere: freebsd-sparc64@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: Porting FreeBSD to the Sparc List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 14 Jun 2011 05:47:50 -0000 --2oS5YaxWCcQjTEyO Content-Type: text/plain; charset=us-ascii Content-Disposition: inline Content-Transfer-Encoding: quoted-printable On 2011-Jun-14 09:51:44 +1000, Peter Jeremy = wrote: >On 2011-Jun-09 00:48:01 +0200, Marius Strobl w= rote: >>Nevertheless it also would be interesting to know if you end up >>with a corrupt kernel stack with DDB, KDB and r222840 in place, >>especially in case disabling superscalar dispatch doesn't solve >>the problem. > >I'm building r223035 with DDB & KDB and will see how that goes. Same problem - "spin lock held too long" on sched lock. I get the stack backtrace then "KDB: enter: panic" then nothing. Just to check, I tried "sysctl debug.kdb.enter=3D1" and that works as expected. --=20 Peter Jeremy --2oS5YaxWCcQjTEyO Content-Type: application/pgp-signature -----BEGIN PGP SIGNATURE----- Version: GnuPG v2.0.17 (FreeBSD) iEYEARECAAYFAk329f0ACgkQ/opHv/APuIciXACeOSbOlSu02LO3OolnyLZlTThi 6a4AniuuP7H9Sj7o3Ch50Iu9iPO1vSdz =QCEa -----END PGP SIGNATURE----- --2oS5YaxWCcQjTEyO-- From owner-freebsd-sparc64@FreeBSD.ORG Tue Jun 14 21:40:56 2011 Return-Path: Delivered-To: freebsd-sparc64@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id B71E2106566B for ; Tue, 14 Jun 2011 21:40:56 +0000 (UTC) (envelope-from peterjeremy@acm.org) Received: from mail12.syd.optusnet.com.au (mail12.syd.optusnet.com.au [211.29.132.193]) by mx1.freebsd.org (Postfix) with ESMTP id 2EF898FC0A for ; Tue, 14 Jun 2011 21:40:55 +0000 (UTC) Received: from server.vk2pj.dyndns.org (c220-239-116-103.belrs4.nsw.optusnet.com.au [220.239.116.103]) by mail12.syd.optusnet.com.au (8.13.1/8.13.1) with ESMTP id p5ELerR0023472 (version=TLSv1/SSLv3 cipher=DHE-RSA-AES256-SHA bits=256 verify=NO); Wed, 15 Jun 2011 07:40:54 +1000 X-Bogosity: Ham, spamicity=0.000000 Received: from server.vk2pj.dyndns.org (localhost.vk2pj.dyndns.org [127.0.0.1]) by server.vk2pj.dyndns.org (8.14.4/8.14.4) with ESMTP id p5ELeqdn091138; Wed, 15 Jun 2011 07:40:52 +1000 (EST) (envelope-from peter@server.vk2pj.dyndns.org) Received: (from peter@localhost) by server.vk2pj.dyndns.org (8.14.4/8.14.4/Submit) id p5ELeqcn091137; Wed, 15 Jun 2011 07:40:52 +1000 (EST) (envelope-from peter) Date: Wed, 15 Jun 2011 07:40:52 +1000 From: Peter Jeremy To: Nathan Whitehorn Message-ID: <20110614214052.GA91014@server.vk2pj.dyndns.org> References: <20110526234728.GA69750@server.vk2pj.dyndns.org> <20110527120659.GA78000@alchemy.franken.de> <20110601231237.GA5267@server.vk2pj.dyndns.org> <20110612115727.GA70559@alchemy.franken.de> MIME-Version: 1.0 Content-Type: multipart/signed; micalg=pgp-sha1; protocol="application/pgp-signature"; boundary="T4sUOijqQbZv57TR" Content-Disposition: inline In-Reply-To: X-PGP-Key: http://members.optusnet.com.au/peterjeremy/pubkey.asc User-Agent: Mutt/1.5.21 (2010-09-15) Cc: freebsd-sparc64@freebsd.org Subject: Re: 'make -j16 universe' gives SIReset X-BeenThere: freebsd-sparc64@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: Porting FreeBSD to the Sparc List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 14 Jun 2011 21:40:56 -0000 --T4sUOijqQbZv57TR Content-Type: text/plain; charset=us-ascii Content-Disposition: inline Content-Transfer-Encoding: quoted-printable On 2011-Jun-12 08:31:06 -0500, Nathan Whitehorn wr= ote: >I never actually fixed it entirely. The point where I got stuck is that >btxld has inline x86 assembly in it, so it isn't possible to build on >non-x86 platforms. That's no different to much of the rest of the i386/i386 tree. Shouldn't it be being built using x86 cross tools? --=20 Peter Jeremy --T4sUOijqQbZv57TR Content-Type: application/pgp-signature -----BEGIN PGP SIGNATURE----- Version: GnuPG v2.0.17 (FreeBSD) iEYEARECAAYFAk331WQACgkQ/opHv/APuIfcegCgutyYOq8H3PyOrvuFT83dE40H 3JAAnioDmGXRWvzsETDGUZeXV8b/AnKE =oPmp -----END PGP SIGNATURE----- --T4sUOijqQbZv57TR-- From owner-freebsd-sparc64@FreeBSD.ORG Tue Jun 14 21:50:09 2011 Return-Path: Delivered-To: freebsd-sparc64@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 8F633106564A for ; Tue, 14 Jun 2011 21:50:09 +0000 (UTC) (envelope-from peterjeremy@acm.org) Received: from mail34.syd.optusnet.com.au (mail34.syd.optusnet.com.au [211.29.133.218]) by mx1.freebsd.org (Postfix) with ESMTP id 236FA8FC12 for ; Tue, 14 Jun 2011 21:50:08 +0000 (UTC) Received: from server.vk2pj.dyndns.org (c220-239-116-103.belrs4.nsw.optusnet.com.au [220.239.116.103]) by mail34.syd.optusnet.com.au (8.13.1/8.13.1) with ESMTP id p5ELo25M009904 (version=TLSv1/SSLv3 cipher=DHE-RSA-AES256-SHA bits=256 verify=NO); Wed, 15 Jun 2011 07:50:03 +1000 X-Bogosity: Ham, spamicity=0.000000 Received: from server.vk2pj.dyndns.org (localhost.vk2pj.dyndns.org [127.0.0.1]) by server.vk2pj.dyndns.org (8.14.4/8.14.4) with ESMTP id p5ELo1wG091213; Wed, 15 Jun 2011 07:50:01 +1000 (EST) (envelope-from peter@server.vk2pj.dyndns.org) Received: (from peter@localhost) by server.vk2pj.dyndns.org (8.14.4/8.14.4/Submit) id p5ELo0SY091204; Wed, 15 Jun 2011 07:50:00 +1000 (EST) (envelope-from peter) Date: Wed, 15 Jun 2011 07:49:59 +1000 From: Peter Jeremy To: Marius Strobl Message-ID: <20110614214959.GB91014@server.vk2pj.dyndns.org> References: <20110526234728.GA69750@server.vk2pj.dyndns.org> <20110527120659.GA78000@alchemy.franken.de> <20110601231237.GA5267@server.vk2pj.dyndns.org> <20110608224801.GB35494@alchemy.franken.de> <20110613235144.GA12470@server.vk2pj.dyndns.org> MIME-Version: 1.0 Content-Type: multipart/signed; micalg=pgp-sha1; protocol="application/pgp-signature"; boundary="JYK4vJDZwFMowpUq" Content-Disposition: inline In-Reply-To: <20110613235144.GA12470@server.vk2pj.dyndns.org> X-PGP-Key: http://members.optusnet.com.au/peterjeremy/pubkey.asc User-Agent: Mutt/1.5.21 (2010-09-15) Cc: freebsd-sparc64@freebsd.org Subject: Re: 'make -j16 universe' gives SIReset X-BeenThere: freebsd-sparc64@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: Porting FreeBSD to the Sparc List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 14 Jun 2011 21:50:09 -0000 --JYK4vJDZwFMowpUq Content-Type: text/plain; charset=us-ascii Content-Disposition: inline Content-Transfer-Encoding: quoted-printable On 2011-Jun-14 09:51:44 +1000, Peter Jeremy = wrote: >I'm building r223035 with DDB & KDB and will see how that goes. I had another try with WITNESS & INVARIANTS and got a different panic: panic: blockable sleep lock (sleep mutex) system map @ /usr/src/sys/vm/vm_m= ap.c:3651 cpuid =3D 13 KDB: stack backtrace: panic() at panic+0x1c8 witness_checkorder() at witness_checkorder+0x108 _mtx_lock_flags() at _mtx_lock_flags+0x110 _vm_map_lock_read() at _vm_map_lock_read+0x1c vm_map_lookup() at vm_map_lookup+0x4c vm_fault_hold() at vm_fault_hold+0x94 vm_fault() at vm_fault+0x14 trap_pfault() at trap_pfault+0x338 trap() at trap+0x3a8 -- fast data access mmu miss tar=3D0x2000 %o7=3D0xc055e038 -- intr_vector_stray() at intr_vector_stray+0x8 sched_switch() at sched_switch+0x290 mi_switch() at mi_switch+0x2a8 sleepq_switch() at sleepq_switch+0x1cc sleepq_catch_signals() at sleepq_catch_signals+0x130 sleepq_timedwait_sig() at sleepq_timedwait_sig+0x8 _cv_timedwait_sig() at _cv_timedwait_sig+0x344 seltdwait() at seltdwait+0x74 kern_select() at kern_select+0x618 select() at select+0x44 syscallenter() at syscallenter+0x270 syscall() at syscall+0x74 -- syscall (93, FreeBSD ELF64, select) %o7=3D0x1099dc -- userland() at 0x14bde8 user trace: trap %o7=3D0x1099dc pc 0x14bde8, sp 0x7fdffffc8d1 pc 0x26c800, sp 0x26c800 done KDB: enter: panic Unfortunately, still no DDB - just a hang --=20 Peter Jeremy --JYK4vJDZwFMowpUq Content-Type: application/pgp-signature -----BEGIN PGP SIGNATURE----- Version: GnuPG v2.0.17 (FreeBSD) iEYEARECAAYFAk3314cACgkQ/opHv/APuIeK2wCgvSVBAIcg2V0sYTNV12BEuTE0 eMMAnjAx9jHYSd0ApbsNbB9Thndx3Fxs =3tW5 -----END PGP SIGNATURE----- --JYK4vJDZwFMowpUq-- From owner-freebsd-sparc64@FreeBSD.ORG Wed Jun 15 00:24:51 2011 Return-Path: Delivered-To: freebsd-sparc64@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 1EF66106564A for ; Wed, 15 Jun 2011 00:24:51 +0000 (UTC) (envelope-from nwhitehorn@freebsd.org) Received: from mail.icecube.wisc.edu (trout.icecube.wisc.edu [128.104.255.119]) by mx1.freebsd.org (Postfix) with ESMTP id E53A68FC08 for ; Wed, 15 Jun 2011 00:24:50 +0000 (UTC) Received: from localhost (localhost.localdomain [127.0.0.1]) by mail.icecube.wisc.edu (Postfix) with ESMTP id 643115813A; Tue, 14 Jun 2011 19:07:15 -0500 (CDT) X-Virus-Scanned: amavisd-new at icecube.wisc.edu Received: from mail.icecube.wisc.edu ([127.0.0.1]) by localhost (trout.icecube.wisc.edu [127.0.0.1]) (amavisd-new, port 10030) with ESMTP id AJOtcE43PL5X; Tue, 14 Jun 2011 19:07:15 -0500 (CDT) Received: from wanderer.tachypleus.net (i3-dhcp-172-16-223-128.icecube.wisc.edu [172.16.223.128]) by mail.icecube.wisc.edu (Postfix) with ESMTP id 3B57F5811A; Tue, 14 Jun 2011 19:07:15 -0500 (CDT) Message-ID: <4DF7F7B3.6000404@freebsd.org> Date: Tue, 14 Jun 2011 19:07:15 -0500 From: Nathan Whitehorn User-Agent: Mozilla/5.0 (X11; U; FreeBSD amd64; en-US; rv:1.9.2.17) Gecko/20110516 Thunderbird/3.1.10 MIME-Version: 1.0 To: Peter Jeremy References: <20110526234728.GA69750@server.vk2pj.dyndns.org> <20110527120659.GA78000@alchemy.franken.de> <20110601231237.GA5267@server.vk2pj.dyndns.org> <20110612115727.GA70559@alchemy.franken.de> <20110614214052.GA91014@server.vk2pj.dyndns.org> In-Reply-To: <20110614214052.GA91014@server.vk2pj.dyndns.org> Content-Type: text/plain; charset=ISO-8859-1; format=flowed Content-Transfer-Encoding: 7bit Cc: freebsd-sparc64@freebsd.org Subject: Re: 'make -j16 universe' gives SIReset X-BeenThere: freebsd-sparc64@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: Porting FreeBSD to the Sparc List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Wed, 15 Jun 2011 00:24:51 -0000 On 06/14/11 16:40, Peter Jeremy wrote: > On 2011-Jun-12 08:31:06 -0500, Nathan Whitehorn wrote: >> I never actually fixed it entirely. The point where I got stuck is that >> btxld has inline x86 assembly in it, so it isn't possible to build on >> non-x86 platforms. > > That's no different to much of the rest of the i386/i386 tree. Shouldn't > it be being built using x86 cross tools? > The problem is that btxld is the linker used for the boot loader, so it *is* a cross tool. -Nathan From owner-freebsd-sparc64@FreeBSD.ORG Wed Jun 15 01:28:07 2011 Return-Path: Delivered-To: freebsd-sparc@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 3875E106566B for ; Wed, 15 Jun 2011 01:28:07 +0000 (UTC) (envelope-from articlerobot@exwantyouback.com) Received: from voda18.voda18.com (voda18.voda18.com [75.126.104.139]) by mx1.freebsd.org (Postfix) with ESMTP id 18D738FC0A for ; Wed, 15 Jun 2011 01:28:06 +0000 (UTC) Received: from pc-242-191-161-190.cm.vtr.net ([190.161.191.242] helo=mail.exwantyouback.com) by voda18.voda18.com with esmtpa (Exim 4.69) (envelope-from ) id 1QWed5-0000vX-0v for freebsd-sparc@freebsd.org; Tue, 14 Jun 2011 20:10:48 -0500 From: "Digne" To: freebsd-sparc@freebsd.org Content-Transfer-Encoding: 8bit Content-Type: text/plain; charset="UTF-8" Date: Wed, 15 Jun 2011 04:10:43 +0300 X-AntiAbuse: This header was added to track abuse, please include it with any abuse report X-AntiAbuse: Primary Hostname - voda18.voda18.com X-AntiAbuse: Original Domain - freebsd.org X-AntiAbuse: Originator/Caller UID/GID - [47 12] / [47 12] X-AntiAbuse: Sender Address Domain - exwantyouback.com Message-Id: <20110615012807.3875E106566B@hub.freebsd.org> Cc: Subject: Vai tev iet pie sirds, ka tvirtulis =?utf-8?q?piespie=C5=BEas?= ?! X-BeenThere: freebsd-sparc64@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list Reply-To: Digne List-Id: Porting FreeBSD to the Sparc List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Wed, 15 Jun 2011 01:28:07 -0000 Nu ja, es tagad strādāju foršā vietā un man gribētos tev tā kā bikucīt pažēloties... mans salons ir noteicis trakas cenas, tikai 20 Ls un jārīkojas mums, masierītēm, ir nevis masieru formās, bet mazās strinģenēs.. skaties pats: http://www.edensalon.in Sibilla From owner-freebsd-sparc64@FreeBSD.ORG Wed Jun 15 23:12:32 2011 Return-Path: Delivered-To: freebsd-sparc64@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 49A85106566B for ; Wed, 15 Jun 2011 23:12:32 +0000 (UTC) (envelope-from marius@alchemy.franken.de) Received: from alchemy.franken.de (alchemy.franken.de [194.94.249.214]) by mx1.freebsd.org (Postfix) with ESMTP id BAC048FC14 for ; Wed, 15 Jun 2011 23:12:31 +0000 (UTC) Received: from alchemy.franken.de (localhost [127.0.0.1]) by alchemy.franken.de (8.14.4/8.14.4/ALCHEMY.FRANKEN.DE) with ESMTP id p5FNCQjx093443; Thu, 16 Jun 2011 01:12:26 +0200 (CEST) (envelope-from marius@alchemy.franken.de) Received: (from marius@localhost) by alchemy.franken.de (8.14.4/8.14.4/Submit) id p5FNCQUQ093442; Thu, 16 Jun 2011 01:12:26 +0200 (CEST) (envelope-from marius) Date: Thu, 16 Jun 2011 01:12:26 +0200 From: Marius Strobl To: Peter Jeremy Message-ID: <20110615231226.GY7064@alchemy.franken.de> References: <20110526234728.GA69750@server.vk2pj.dyndns.org> <20110527120659.GA78000@alchemy.franken.de> <20110601231237.GA5267@server.vk2pj.dyndns.org> <20110608224801.GB35494@alchemy.franken.de> <20110613235144.GA12470@server.vk2pj.dyndns.org> <20110614214959.GB91014@server.vk2pj.dyndns.org> Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <20110614214959.GB91014@server.vk2pj.dyndns.org> User-Agent: Mutt/1.4.2.3i Cc: freebsd-sparc64@freebsd.org Subject: Re: 'make -j16 universe' gives SIReset X-BeenThere: freebsd-sparc64@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: Porting FreeBSD to the Sparc List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Wed, 15 Jun 2011 23:12:32 -0000 On Wed, Jun 15, 2011 at 07:49:59AM +1000, Peter Jeremy wrote: > On 2011-Jun-14 09:51:44 +1000, Peter Jeremy wrote: > >I'm building r223035 with DDB & KDB and will see how that goes. > > I had another try with WITNESS & INVARIANTS and got a different panic: > panic: blockable sleep lock (sleep mutex) system map @ /usr/src/sys/vm/vm_map.c:3651 > cpuid = 13 > KDB: stack backtrace: > panic() at panic+0x1c8 > witness_checkorder() at witness_checkorder+0x108 > _mtx_lock_flags() at _mtx_lock_flags+0x110 > _vm_map_lock_read() at _vm_map_lock_read+0x1c > vm_map_lookup() at vm_map_lookup+0x4c > vm_fault_hold() at vm_fault_hold+0x94 > vm_fault() at vm_fault+0x14 > trap_pfault() at trap_pfault+0x338 > trap() at trap+0x3a8 > -- fast data access mmu miss tar=0x2000 %o7=0xc055e038 -- > intr_vector_stray() at intr_vector_stray+0x8 > sched_switch() at sched_switch+0x290 > mi_switch() at mi_switch+0x2a8 > sleepq_switch() at sleepq_switch+0x1cc > sleepq_catch_signals() at sleepq_catch_signals+0x130 > sleepq_timedwait_sig() at sleepq_timedwait_sig+0x8 > _cv_timedwait_sig() at _cv_timedwait_sig+0x344 > seltdwait() at seltdwait+0x74 > kern_select() at kern_select+0x618 > select() at select+0x44 > syscallenter() at syscallenter+0x270 > syscall() at syscall+0x74 > -- syscall (93, FreeBSD ELF64, select) %o7=0x1099dc -- > userland() at 0x14bde8 > user trace: trap %o7=0x1099dc > pc 0x14bde8, sp 0x7fdffffc8d1 > pc 0x26c800, sp 0x26c800 > done > KDB: enter: panic > > Unfortunately, still no DDB - just a hang This backtrace shows two things that just shouldn't happen hardware-wise: a) The CPU issues an stray interrupt vector. This would explain the SIRs you were seeing without the patch which tries to make these non-fatal. b) The CPU faults on an address which is covered by an locked TLB slot. The funny thing is that the CPU then actually still manages to panic; if something like b) occurs I'd expect it to be in a totally unusable state. I'm not sure what to do about these as it still looks like broken hardware or a silicon bug to me but at least the public errata doesn't mention something like that and the OpenSolaris source doesn't seem to work around something like these in an obvious way either. The only thing I can think of is to try whether just ignoring the stray interrupt vectors with the below patch avoids any further issues. You'll need to revert sparc64_intr_vector_stray.diff for that or at least the exception.S part. Marius Index: exception.S =================================================================== --- exception.S (revision 223042) +++ exception.S (working copy) @@ -578,7 +578,7 @@ andcc %g1, IRSR_BUSY, %g0 bnz,a,pt %xcc, intr_vector nop - sir + retry .align 32 .endm From owner-freebsd-sparc64@FreeBSD.ORG Wed Jun 15 23:34:50 2011 Return-Path: Delivered-To: freebsd-sparc64@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id DFC721065670 for ; Wed, 15 Jun 2011 23:34:50 +0000 (UTC) (envelope-from marius@alchemy.franken.de) Received: from alchemy.franken.de (alchemy.franken.de [194.94.249.214]) by mx1.freebsd.org (Postfix) with ESMTP id 7A2298FC08 for ; Wed, 15 Jun 2011 23:34:49 +0000 (UTC) Received: from alchemy.franken.de (localhost [127.0.0.1]) by alchemy.franken.de (8.14.4/8.14.4/ALCHEMY.FRANKEN.DE) with ESMTP id p5FNYjhI093521; Thu, 16 Jun 2011 01:34:45 +0200 (CEST) (envelope-from marius@alchemy.franken.de) Received: (from marius@localhost) by alchemy.franken.de (8.14.4/8.14.4/Submit) id p5FNYjWt093520; Thu, 16 Jun 2011 01:34:45 +0200 (CEST) (envelope-from marius) Date: Thu, 16 Jun 2011 01:34:45 +0200 From: Marius Strobl To: Peter Jeremy Message-ID: <20110615233445.GZ7064@alchemy.franken.de> References: <20110526234728.GA69750@server.vk2pj.dyndns.org> <20110527120659.GA78000@alchemy.franken.de> <20110601231237.GA5267@server.vk2pj.dyndns.org> <20110608224801.GB35494@alchemy.franken.de> <20110613235144.GA12470@server.vk2pj.dyndns.org> Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <20110613235144.GA12470@server.vk2pj.dyndns.org> User-Agent: Mutt/1.4.2.3i Cc: freebsd-sparc64@freebsd.org Subject: Re: 'make -j16 universe' gives SIReset X-BeenThere: freebsd-sparc64@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: Porting FreeBSD to the Sparc List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Wed, 15 Jun 2011 23:34:51 -0000 On Tue, Jun 14, 2011 at 09:51:44AM +1000, Peter Jeremy wrote: > On 2011-Jun-09 00:48:01 +0200, Marius Strobl wrote: > >This might be due to the excessive use of sched_lock by SCHED_4BSD > >and the MD code, f.e. more CPUs means less TLB contexts per CPU which > >in turn means more flushes that are protect by sched_lock. > > I have noticed that systat reports very high trap & fault counts. That's basically expected; on USIII and later FreeBSD just flushes all unlocked TLB entries when we need to flush the userland mappings and accept TLB misses for the kernel ones instead of traversing the TLBs for userland mappings and removing just those. Actually OpenSolaris just does the same thing and IIRC there actually isn't a way to traverse the large TLBs. Given that the TLB contexts are divided evenly among the cores this means the more flushes and misses the more cores are in the machine. Previously FreeBSD shared the contexts which meant TLB shootdown IPIs even for non-shared PMAPs. So the question is whether there's some point at which that approach actually costs less performance than accepting TLB misses. This seems unlikely though and AFAIK the current approach actually is inspired by Solaris Internals. > > I got a "spinlock held too long" panic that should have gone to DDB > but the system wouldn't respond to anything other than a RSC reset. > You could try whether the below patch sufficiently reduces the lock coverage to avoid these. For stable/8 you'll probably need to apply the second chunk by hand. Marius Index: pmap.c =================================================================== --- pmap.c (revision 223042) +++ pmap.c (working copy) @@ -2217,11 +2217,10 @@ pmap_activate(struct thread *td) struct pmap *pm; int context; + critical_enter(); vm = td->td_proc->p_vmspace; pm = vmspace_pmap(vm); - mtx_lock_spin(&sched_lock); - context = PCPU_GET(tlb_ctx); if (context == PCPU_GET(tlb_ctx_max)) { tlb_flush_user(); @@ -2229,17 +2228,18 @@ pmap_activate(struct thread *td) } PCPU_SET(tlb_ctx, context + 1); + mtx_lock_spin(&sched_lock); pm->pm_context[curcpu] = context; CPU_OR(&pm->pm_active, PCPU_PTR(cpumask)); PCPU_SET(pmap, pm); + mtx_unlock_spin(&sched_lock); stxa(AA_DMMU_TSB, ASI_DMMU, pm->pm_tsb); stxa(AA_IMMU_TSB, ASI_IMMU, pm->pm_tsb); stxa(AA_DMMU_PCXR, ASI_DMMU, (ldxa(AA_DMMU_PCXR, ASI_DMMU) & TLB_CXR_PGSZ_MASK) | context); flush(KERNBASE); - - mtx_unlock_spin(&sched_lock); + critical_exit(); } void From owner-freebsd-sparc64@FreeBSD.ORG Thu Jun 16 00:36:16 2011 Return-Path: Delivered-To: sparc64@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 17E0D1065670; Thu, 16 Jun 2011 00:36:16 +0000 (UTC) (envelope-from tinderbox@freebsd.org) Received: from freebsd-current.sentex.ca (freebsd-current.sentex.ca [64.7.128.98]) by mx1.freebsd.org (Postfix) with ESMTP id B610E8FC1D; Thu, 16 Jun 2011 00:36:15 +0000 (UTC) Received: from freebsd-current.sentex.ca (localhost [127.0.0.1]) by freebsd-current.sentex.ca (8.14.4/8.14.4) with ESMTP id p5G0aEH6049756; Wed, 15 Jun 2011 20:36:14 -0400 (EDT) (envelope-from tinderbox@freebsd.org) Received: (from tinderbox@localhost) by freebsd-current.sentex.ca (8.14.4/8.14.4/Submit) id p5G0aEXd049743; Thu, 16 Jun 2011 00:36:14 GMT (envelope-from tinderbox@freebsd.org) Date: Thu, 16 Jun 2011 00:36:14 GMT Message-Id: <201106160036.p5G0aEXd049743@freebsd-current.sentex.ca> X-Authentication-Warning: freebsd-current.sentex.ca: tinderbox set sender to FreeBSD Tinderbox using -f Sender: FreeBSD Tinderbox From: FreeBSD Tinderbox To: FreeBSD Tinderbox , , Precedence: bulk Cc: Subject: [head tinderbox] failure on sparc64/sparc64 X-BeenThere: freebsd-sparc64@freebsd.org X-Mailman-Version: 2.1.5 List-Id: Porting FreeBSD to the Sparc List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Thu, 16 Jun 2011 00:36:16 -0000 TB --- 2011-06-16 00:06:25 - tinderbox 2.7 running on freebsd-current.sentex.ca TB --- 2011-06-16 00:06:25 - starting HEAD tinderbox run for sparc64/sparc64 TB --- 2011-06-16 00:06:25 - cleaning the object tree TB --- 2011-06-16 00:06:39 - cvsupping the source tree TB --- 2011-06-16 00:06:39 - /usr/bin/csup -z -r 3 -g -L 1 -h cvsup.sentex.ca /tinderbox/HEAD/sparc64/sparc64/supfile TB --- 2011-06-16 00:07:04 - building world TB --- 2011-06-16 00:07:04 - MAKEOBJDIRPREFIX=/obj TB --- 2011-06-16 00:07:04 - PATH=/usr/bin:/usr/sbin:/bin:/sbin TB --- 2011-06-16 00:07:04 - TARGET=sparc64 TB --- 2011-06-16 00:07:04 - TARGET_ARCH=sparc64 TB --- 2011-06-16 00:07:04 - TZ=UTC TB --- 2011-06-16 00:07:04 - __MAKE_CONF=/dev/null TB --- 2011-06-16 00:07:04 - cd /src TB --- 2011-06-16 00:07:04 - /usr/bin/make -B buildworld >>> World build started on Thu Jun 16 00:07:05 UTC 2011 >>> Rebuilding the temporary build tree >>> stage 1.1: legacy release compatibility shims >>> stage 1.2: bootstrap tools >>> stage 2.1: cleaning up the object tree >>> stage 2.2: rebuilding the object tree >>> stage 2.3: build tools >>> stage 3: cross tools >>> stage 4.1: building includes >>> stage 4.2: building libraries [...] cc -O2 -pipe -ffreestanding -Wformat -I/src/lib/libstand -DBZ_NO_STDIO -DBZ_NO_COMPRESS -DHAVE_MEMCPY -I/src/lib/libstand/../libz -std=gnu99 -Wsystem-headers -Werror -Wall -Wno-format-y2k -Wno-uninitialized -Wno-pointer-sign -c /src/lib/libstand/sbrk.c cc -O2 -pipe -ffreestanding -Wformat -I/src/lib/libstand -DBZ_NO_STDIO -DBZ_NO_COMPRESS -DHAVE_MEMCPY -I/src/lib/libstand/../libz -std=gnu99 -Wsystem-headers -Werror -Wall -Wno-format-y2k -Wno-uninitialized -Wno-pointer-sign -c /src/lib/libstand/twiddle.c cc -O2 -pipe -ffreestanding -Wformat -I/src/lib/libstand -DBZ_NO_STDIO -DBZ_NO_COMPRESS -DHAVE_MEMCPY -I/src/lib/libstand/../libz -std=gnu99 -Wsystem-headers -Werror -Wall -Wno-format-y2k -Wno-uninitialized -Wno-pointer-sign -c /src/lib/libstand/zalloc.c cc1: warnings being treated as errors /src/lib/libstand/zalloc.c: In function 'zfree': /src/lib/libstand/zalloc.c:157: warning: format '%d' expects type 'int', but argument 3 has type 'iaddr_t' /src/lib/libstand/zalloc.c:181: warning: format '%d' expects type 'int', but argument 3 has type 'iaddr_t' /src/lib/libstand/zalloc.c:212: warning: format '%d' expects type 'int', but argument 3 has type 'iaddr_t' *** Error code 1 Stop in /src/lib/libstand. *** Error code 1 Stop in /src/lib. *** Error code 1 Stop in /src. *** Error code 1 Stop in /src. *** Error code 1 Stop in /src. *** Error code 1 Stop in /src. TB --- 2011-06-16 00:36:14 - WARNING: /usr/bin/make returned exit code 1 TB --- 2011-06-16 00:36:14 - ERROR: failed to build world TB --- 2011-06-16 00:36:14 - 1270.96 user 310.14 system 1789.30 real http://tinderbox.freebsd.org/tinderbox-head-HEAD-sparc64-sparc64.full From owner-freebsd-sparc64@FreeBSD.ORG Thu Jun 16 04:36:44 2011 Return-Path: Delivered-To: sparc64@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 4E86A106566B; Thu, 16 Jun 2011 04:36:44 +0000 (UTC) (envelope-from tinderbox@freebsd.org) Received: from freebsd-current.sentex.ca (freebsd-current.sentex.ca [64.7.128.98]) by mx1.freebsd.org (Postfix) with ESMTP id EAA7D8FC12; Thu, 16 Jun 2011 04:36:43 +0000 (UTC) Received: from freebsd-current.sentex.ca (localhost [127.0.0.1]) by freebsd-current.sentex.ca (8.14.4/8.14.4) with ESMTP id p5G4aheH001008; Thu, 16 Jun 2011 00:36:43 -0400 (EDT) (envelope-from tinderbox@freebsd.org) Received: (from tinderbox@localhost) by freebsd-current.sentex.ca (8.14.4/8.14.4/Submit) id p5G4ah5k001007; Thu, 16 Jun 2011 04:36:43 GMT (envelope-from tinderbox@freebsd.org) Date: Thu, 16 Jun 2011 04:36:43 GMT Message-Id: <201106160436.p5G4ah5k001007@freebsd-current.sentex.ca> X-Authentication-Warning: freebsd-current.sentex.ca: tinderbox set sender to FreeBSD Tinderbox using -f Sender: FreeBSD Tinderbox From: FreeBSD Tinderbox To: FreeBSD Tinderbox , , Precedence: bulk Cc: Subject: [head tinderbox] failure on sparc64/sparc64 X-BeenThere: freebsd-sparc64@freebsd.org X-Mailman-Version: 2.1.5 List-Id: Porting FreeBSD to the Sparc List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Thu, 16 Jun 2011 04:36:44 -0000 TB --- 2011-06-16 04:08:45 - tinderbox 2.7 running on freebsd-current.sentex.ca TB --- 2011-06-16 04:08:45 - starting HEAD tinderbox run for sparc64/sparc64 TB --- 2011-06-16 04:08:45 - cleaning the object tree TB --- 2011-06-16 04:08:48 - cvsupping the source tree TB --- 2011-06-16 04:08:48 - /usr/bin/csup -z -r 3 -g -L 1 -h cvsup.sentex.ca /tinderbox/HEAD/sparc64/sparc64/supfile TB --- 2011-06-16 04:09:15 - building world TB --- 2011-06-16 04:09:15 - MAKEOBJDIRPREFIX=/obj TB --- 2011-06-16 04:09:15 - PATH=/usr/bin:/usr/sbin:/bin:/sbin TB --- 2011-06-16 04:09:15 - TARGET=sparc64 TB --- 2011-06-16 04:09:15 - TARGET_ARCH=sparc64 TB --- 2011-06-16 04:09:15 - TZ=UTC TB --- 2011-06-16 04:09:15 - __MAKE_CONF=/dev/null TB --- 2011-06-16 04:09:15 - cd /src TB --- 2011-06-16 04:09:15 - /usr/bin/make -B buildworld >>> World build started on Thu Jun 16 04:09:15 UTC 2011 >>> Rebuilding the temporary build tree >>> stage 1.1: legacy release compatibility shims >>> stage 1.2: bootstrap tools >>> stage 2.1: cleaning up the object tree >>> stage 2.2: rebuilding the object tree >>> stage 2.3: build tools >>> stage 3: cross tools >>> stage 4.1: building includes >>> stage 4.2: building libraries [...] cc -O2 -pipe -ffreestanding -Wformat -I/src/lib/libstand -DBZ_NO_STDIO -DBZ_NO_COMPRESS -DHAVE_MEMCPY -I/src/lib/libstand/../libz -std=gnu99 -Wsystem-headers -Werror -Wall -Wno-format-y2k -Wno-uninitialized -Wno-pointer-sign -c /src/lib/libstand/sbrk.c cc -O2 -pipe -ffreestanding -Wformat -I/src/lib/libstand -DBZ_NO_STDIO -DBZ_NO_COMPRESS -DHAVE_MEMCPY -I/src/lib/libstand/../libz -std=gnu99 -Wsystem-headers -Werror -Wall -Wno-format-y2k -Wno-uninitialized -Wno-pointer-sign -c /src/lib/libstand/twiddle.c cc -O2 -pipe -ffreestanding -Wformat -I/src/lib/libstand -DBZ_NO_STDIO -DBZ_NO_COMPRESS -DHAVE_MEMCPY -I/src/lib/libstand/../libz -std=gnu99 -Wsystem-headers -Werror -Wall -Wno-format-y2k -Wno-uninitialized -Wno-pointer-sign -c /src/lib/libstand/zalloc.c cc1: warnings being treated as errors /src/lib/libstand/zalloc.c: In function 'zfree': /src/lib/libstand/zalloc.c:157: warning: format '%d' expects type 'int', but argument 3 has type 'iaddr_t' /src/lib/libstand/zalloc.c:181: warning: format '%d' expects type 'int', but argument 3 has type 'iaddr_t' /src/lib/libstand/zalloc.c:212: warning: format '%d' expects type 'int', but argument 3 has type 'iaddr_t' *** Error code 1 Stop in /src/lib/libstand. *** Error code 1 Stop in /src/lib. *** Error code 1 Stop in /src. *** Error code 1 Stop in /src. *** Error code 1 Stop in /src. *** Error code 1 Stop in /src. TB --- 2011-06-16 04:36:43 - WARNING: /usr/bin/make returned exit code 1 TB --- 2011-06-16 04:36:43 - ERROR: failed to build world TB --- 2011-06-16 04:36:43 - 1243.49 user 308.49 system 1677.98 real http://tinderbox.freebsd.org/tinderbox-head-HEAD-sparc64-sparc64.full From owner-freebsd-sparc64@FreeBSD.ORG Thu Jun 16 07:00:30 2011 Return-Path: Delivered-To: sparc64@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id AF44C106564A; Thu, 16 Jun 2011 07:00:30 +0000 (UTC) (envelope-from yanegomi@gmail.com) Received: from mail-vx0-f182.google.com (mail-vx0-f182.google.com [209.85.220.182]) by mx1.freebsd.org (Postfix) with ESMTP id 2F8328FC18; Thu, 16 Jun 2011 07:00:29 +0000 (UTC) Received: by vxc34 with SMTP id 34so1317128vxc.13 for ; Thu, 16 Jun 2011 00:00:29 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=gamma; h=domainkey-signature:mime-version:in-reply-to:references:date :message-id:subject:from:to:cc:content-type; bh=9AZK0gXOwxalbyVFfi2HNb0QXB7AtKQRRF+TFtmYkKM=; b=EbX8zIzdmd2huTJVSCh+RmwIBNzC/g59OspPrBCnXQ/kCz3CGaDSKdQSOsdT8pY2xC o7P0mPj1IioVSwwSHw4TQYJkH5tQ9MsPC+viK5dB3oteIZO/BgEaRAq2pVs8x/Y75BJY vtkoCGh5/OCIrm4jfxrJKI2gSLRm6MY0ad4Gs= DomainKey-Signature: a=rsa-sha1; c=nofws; d=gmail.com; s=gamma; h=mime-version:in-reply-to:references:date:message-id:subject:from:to :cc:content-type; b=NTIIZe2gIlOI+3advVsl19xBxi4+UC24frrBNeVoAkmkZOMStYAuRe0hD8GvNhjIxB OCNrBDiOFeuZ9syD2+LmrAknncD8lZ8FSue/siYTkdE6sasx5U9SfFBkX/8Y/b1Sh3f3 l0qlEn00MeZtdIiDEc7CRMPsDgemLHD8kw/Ok= MIME-Version: 1.0 Received: by 10.220.210.69 with SMTP id gj5mr211966vcb.58.1308207629215; Thu, 16 Jun 2011 00:00:29 -0700 (PDT) Received: by 10.220.189.202 with HTTP; Thu, 16 Jun 2011 00:00:29 -0700 (PDT) In-Reply-To: <201106160436.p5G4ah5k001007@freebsd-current.sentex.ca> References: <201106160436.p5G4ah5k001007@freebsd-current.sentex.ca> Date: Thu, 16 Jun 2011 00:00:29 -0700 Message-ID: From: Garrett Cooper To: rodrigc@FreeBSD.org Content-Type: multipart/mixed; boundary=0022154700ae08283d04a5ced37c Cc: current@freebsd.org, sparc64@freebsd.org Subject: Re: [head tinderbox] failure on sparc64/sparc64 X-BeenThere: freebsd-sparc64@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: Porting FreeBSD to the Sparc List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Thu, 16 Jun 2011 07:00:30 -0000 --0022154700ae08283d04a5ced37c Content-Type: text/plain; charset=ISO-8859-1 Content-Transfer-Encoding: quoted-printable On Wed, Jun 15, 2011 at 9:36 PM, FreeBSD Tinderbox wrote: > TB --- 2011-06-16 04:08:45 - tinderbox 2.7 running on freebsd-current.sen= tex.ca > TB --- 2011-06-16 04:08:45 - starting HEAD tinderbox run for sparc64/spar= c64 > TB --- 2011-06-16 04:08:45 - cleaning the object tree > TB --- 2011-06-16 04:08:48 - cvsupping the source tree > TB --- 2011-06-16 04:08:48 - /usr/bin/csup -z -r 3 -g -L 1 -h cvsup.sente= x.ca /tinderbox/HEAD/sparc64/sparc64/supfile > TB --- 2011-06-16 04:09:15 - building world > TB --- 2011-06-16 04:09:15 - MAKEOBJDIRPREFIX=3D/obj > TB --- 2011-06-16 04:09:15 - PATH=3D/usr/bin:/usr/sbin:/bin:/sbin > TB --- 2011-06-16 04:09:15 - TARGET=3Dsparc64 > TB --- 2011-06-16 04:09:15 - TARGET_ARCH=3Dsparc64 > TB --- 2011-06-16 04:09:15 - TZ=3DUTC > TB --- 2011-06-16 04:09:15 - __MAKE_CONF=3D/dev/null > TB --- 2011-06-16 04:09:15 - cd /src > TB --- 2011-06-16 04:09:15 - /usr/bin/make -B buildworld >>>> World build started on Thu Jun 16 04:09:15 UTC 2011 >>>> Rebuilding the temporary build tree >>>> stage 1.1: legacy release compatibility shims >>>> stage 1.2: bootstrap tools >>>> stage 2.1: cleaning up the object tree >>>> stage 2.2: rebuilding the object tree >>>> stage 2.3: build tools >>>> stage 3: cross tools >>>> stage 4.1: building includes >>>> stage 4.2: building libraries > [...] > cc -O2 -pipe =A0-ffreestanding -Wformat -I/src/lib/libstand -DBZ_NO_STDIO= -DBZ_NO_COMPRESS -DHAVE_MEMCPY -I/src/lib/libstand/../libz -std=3Dgnu99 -W= system-headers -Werror -Wall -Wno-format-y2k -Wno-uninitialized -Wno-pointe= r-sign -c /src/lib/libstand/sbrk.c > cc -O2 -pipe =A0-ffreestanding -Wformat -I/src/lib/libstand -DBZ_NO_STDIO= -DBZ_NO_COMPRESS -DHAVE_MEMCPY -I/src/lib/libstand/../libz -std=3Dgnu99 -W= system-headers -Werror -Wall -Wno-format-y2k -Wno-uninitialized -Wno-pointe= r-sign -c /src/lib/libstand/twiddle.c > cc -O2 -pipe =A0-ffreestanding -Wformat -I/src/lib/libstand -DBZ_NO_STDIO= -DBZ_NO_COMPRESS -DHAVE_MEMCPY -I/src/lib/libstand/../libz -std=3Dgnu99 -W= system-headers -Werror -Wall -Wno-format-y2k -Wno-uninitialized -Wno-pointe= r-sign -c /src/lib/libstand/zalloc.c > cc1: warnings being treated as errors > /src/lib/libstand/zalloc.c: In function 'zfree': > /src/lib/libstand/zalloc.c:157: warning: format '%d' expects type 'int', = but argument 3 has type 'iaddr_t' > /src/lib/libstand/zalloc.c:181: warning: format '%d' expects type 'int', = but argument 3 has type 'iaddr_t' > /src/lib/libstand/zalloc.c:212: warning: format '%d' expects type 'int', = but argument 3 has type 'iaddr_t' > *** Error code 1 > > Stop in /src/lib/libstand. > *** Error code 1 Could someone please fix the tinderbox compile on sparc64 with this file via this patch? Thanks! -Garrett --0022154700ae08283d04a5ced37c Content-Type: text/x-patch; charset=US-ASCII; name="unbreak-libstand-zalloc-compile.patch" Content-Disposition: attachment; filename="unbreak-libstand-zalloc-compile.patch" Content-Transfer-Encoding: base64 X-Attachment-Id: f_gozczzuh1 SW5kZXg6IGxpYi9saWJzdGFuZC96YWxsb2MuYwo9PT09PT09PT09PT09PT09PT09PT09PT09PT09 PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09Ci0tLSBsaWIvbGlic3RhbmQv emFsbG9jLmMJKHJldmlzaW9uIDIyMzEzOCkKKysrIGxpYi9saWJzdGFuZC96YWxsb2MuYwkod29y a2luZyBjb3B5KQpAQCAtMTU0LDcgKzE1NCw3IEBACiAgICAgaWYgKChjaGFyICopcHRyIDwgKGNo YXIgKiltcC0+bXBfQmFzZSB8fCAKIAkoY2hhciAqKXB0ciArIGJ5dGVzID4gKGNoYXIgKiltcC0+ bXBfRW5kIHx8CiAJKChpYWRkcl90KXB0ciAmIE1FTU5PREVfU0laRV9NQVNLKSAhPSAwKQotCXBh bmljKCJ6ZnJlZSglcCwlZCk6IHdpbGQgcG9pbnRlciIsIHB0ciwgYnl0ZXMpOworCXBhbmljKCJ6 ZnJlZSglcCwlanUpOiB3aWxkIHBvaW50ZXIiLCBwdHIsIGJ5dGVzKTsKIAogICAgIC8qCiAgICAg ICogZnJlZSB0aGUgc2VnbWVudApAQCAtMTc4LDcgKzE3OCw3IEBACiAJCSAqIHJhbmdlIGNoZWNr CiAJCSAqLwogCQlpZiAoKGNoYXIgKilwdHIgKyBieXRlcyA+IChjaGFyICopbW4pCi0JCSAgICBw YW5pYygiemZyZWUoJXAsJWQpOiBjb3JydXB0IG1lbWxpc3QxIixwdHIsIGJ5dGVzKTsKKwkJICAg IHBhbmljKCJ6ZnJlZSglcCwlanUpOiBjb3JydXB0IG1lbWxpc3QxIiwgcHRyLCBieXRlcyk7CiAK IAkJLyoKIAkJICogbWVyZ2UgYWdhaW5zdCBuZXh0IGFyZWEgb3IgY3JlYXRlIGluZGVwZW5kYW50 IGFyZWEKQEAgLTIwOSw3ICsyMDksNyBAQAogCQkvKiBOT1QgUkVBQ0hFRCAqLwogCSAgICB9CiAJ ICAgIGlmICgoY2hhciAqKXB0ciA8IChjaGFyICopbW4gKyBtbi0+bXJfQnl0ZXMpCi0JCXBhbmlj KCJ6ZnJlZSglcCwlZCk6IGNvcnJ1cHQgbWVtbGlzdDIiLCBwdHIsIGJ5dGVzKTsKKwkJcGFuaWMo InpmcmVlKCVwLCVqdSk6IGNvcnJ1cHQgbWVtbGlzdDIiLCBwdHIsIGJ5dGVzKTsKIAl9CiAJLyoK IAkgKiBXZSBhcmUgYmV5b25kIHRoZSBsYXN0IE1lbU5vZGUsIGFwcGVuZCBuZXcgTWVtTm9kZS4g IE1lcmdlIGFnYWluc3QK --0022154700ae08283d04a5ced37c-- From owner-freebsd-sparc64@FreeBSD.ORG Thu Jun 16 07:31:40 2011 Return-Path: Delivered-To: freebsd-sparc64@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 6E3D2106566C; Thu, 16 Jun 2011 07:31:40 +0000 (UTC) (envelope-from nwf@cs.jhu.edu) Received: from blaze.cs.jhu.edu (blaze.cs.jhu.edu [128.220.13.50]) by mx1.freebsd.org (Postfix) with ESMTP id 4205B8FC13; Thu, 16 Jun 2011 07:31:39 +0000 (UTC) Received: from gradx.cs.jhu.edu (gradx.cs.jhu.edu [128.220.13.52]) by blaze.cs.jhu.edu (8.14.3/8.14.3) with ESMTP id p5G7Vc0i003347 (version=TLSv1/SSLv3 cipher=DHE-RSA-AES256-SHA bits=256 verify=NOT); Thu, 16 Jun 2011 03:31:39 -0400 (EDT) Received: from gradx.cs.jhu.edu (localhost [127.0.0.1]) by gradx.cs.jhu.edu (8.14.3/8.13.1) with ESMTP id p5G7VcSh021746; Thu, 16 Jun 2011 03:31:38 -0400 Received: (from nwf@localhost) by gradx.cs.jhu.edu (8.14.3/8.13.8/Submit) id p5G7VclU021745; Thu, 16 Jun 2011 03:31:38 -0400 Date: Thu, 16 Jun 2011 03:31:38 -0400 From: Nathaniel W Filardo To: freebsd-current@freebsd.org, freebsd-sparc64@freebsd.org Message-ID: <20110616073138.GL31996@gradx.cs.jhu.edu> MIME-Version: 1.0 Content-Type: multipart/signed; micalg=pgp-sha1; protocol="application/pgp-signature"; boundary="Kc9HNjpzOXVc7FFU" Content-Disposition: inline User-Agent: Mutt/1.5.20 (2009-08-17) Cc: Subject: TLS bug? X-BeenThere: freebsd-sparc64@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: Porting FreeBSD to the Sparc List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Thu, 16 Jun 2011 07:31:40 -0000 --Kc9HNjpzOXVc7FFU Content-Type: text/plain; charset=us-ascii Content-Disposition: inline Content-Transfer-Encoding: quoted-printable I have a few applications (bonnie++ and mysql, specifically, both from ports) which trip over the assertion in lib/libc/stdlib/malloc.c:/^_malloc_thread_cleanup that > assert(tcache !=3D (void *)(uintptr_t)1); I have patched malloc.c thus: > --- a/lib/libc/stdlib/malloc.c > +++ b/lib/libc/stdlib/malloc.c > @@ -1108,7 +1108,7 @@ static __thread arena_t *arenas_map TLS_M= ODEL; > =20 > #ifdef MALLOC_TCACHE > /* Map of thread-specific caches. */ > -static __thread tcache_t *tcache_tls TLS_MODEL; > +__thread tcache_t *tcache_tls TLS_MODEL; > =20 > /* > * Number of cache slots for each bin in the thread cache, or 0 if tcache > * is > @@ -6184,10 +6184,17 @@ _malloc_thread_cleanup(void) > #ifdef MALLOC_TCACHE > tcache_t *tcache =3D tcache_tls; > =20 > + fprintf(stderr, "_m_t_c for %d:%lu with %p\n",=20 > + getpid(), > + (unsigned long) _pthread_self(), > + tcache); > + > if (tcache !=3D NULL) { > - assert(tcache !=3D (void *)(uintptr_t)1); > - tcache_destroy(tcache); > - tcache_tls =3D (void *)(uintptr_t)1; > + /* assert(tcache !=3D (void *)(uintptr_t)1); */ > + if((uintptr_t)tcache !=3D (uintptr_t)1) { > + tcache_destroy(tcache); > + tcache_tls =3D (void *)(uintptr_t)1; > + } and libthr/thread/thr_create.c thus: > --- a/lib/libthr/thread/thr_create.c > +++ b/lib/libthr/thread/thr_create.c > @@ -243,6 +243,8 @@ create_stack(struct pthread_attr *pattr) > return (ret); > } > =20 > +extern __thread void *tcache_tls; > + > static void > thread_start(struct pthread *curthread) > { > @@ -280,6 +282,11 @@ thread_start(struct pthread *curthread) > curthread->attr.stacksize_attr; > #endif > =20 > + fprintf(stderr, "t_s for %d:%lu with %p\n", > + getpid(), > + (unsigned long) _pthread_self(), > + tcache_tls); > + > /* Run the current thread's start routine with argument: */ > _pthread_exit(curthread->start_routine(curthread->arg)); > =20 to attempt to debug this issue. With those changes in place, bonnie++'s execution looks like this: >[...] > Writing a byte at a time...done > Writing intelligently...done > Rewriting...done > Reading a byte at a time...done > Reading intelligently...done > t_s for 79654:1086343168 with 0x0 > t_s for 79654:1086345216 with 0x0 > t_s for 79654:1086346240 with 0x0 > t_s for 79654:1086347264 with 0x0 > t_s for 79654:1086344192 with 0x0 > start 'em...done...done...done...done..._m_t_c for 79654:1086344192 with > 0x41404400 > _m_t_c for 79654:1086346240 with 0x40d2c400 > _m_t_c for 79654:1086343168 with 0x41404200 > _m_t_c for 79654:1086345216 with 0x41804200 > done... > _m_t_c for 79654:1086347264 with 0x41004200 > Create files in sequential order...done. > Stat files in sequential order...done. > Delete files in sequential order...done. > Create files in random order...done. > Stat files in random order...done. > Delete files in random order...done. > 1.96,1.96,hydra.priv.oc.ietfng.org,1,1308217772,10M,,7,81,2644,7,3577,14,= 34,93,+++++,+++,773.7,61,16,,, > ,,2325,74,13016,99,2342,86,3019,91,11888,99,2184,89,16397ms,1237ms,671ms,= 2009ms,177us,1305ms,489ms,1029 > us,270ms,140ms,53730us,250ms > Writing a byte at a time...done > Writing intelligently...done > Rewriting...done > Reading a byte at a time...done > Reading intelligently...done > t_s for 79654:1086343168 with 0x1 > t_s for 79654:1086346240 with 0x1 > t_s for 79654:1086345216 with 0x1 > t_s for 79654:1086347264 with 0x1 > t_s for 79654:1086344192 with 0x1 > start 'em...done...done...done...done...done... > _m_t_c for 79654:1086347264 with 0x1 > _m_t_c for 79654:1086344192 with 0x1 > _m_t_c for 79654:1086343168 with 0x1 >[...] So what seems to be happening is that the TLS area is being set up incorrectly, eventually: rather than zeroing the tcache_tls value, it is being set to 1, which means no tcache is ever allocated, so when we get around to exiting, the assert trips. Unfortunately, setting a breakpoint on __libc_allocate_tls seems to do bad things to the kernel (inducing a SIR without any panic message). I am somewhat at a loss; help? Thanks in advance! --nwf; --Kc9HNjpzOXVc7FFU Content-Type: application/pgp-signature Content-Disposition: inline -----BEGIN PGP SIGNATURE----- Version: GnuPG v1.4.10 (GNU/Linux) iEYEARECAAYFAk35sVoACgkQTeQabvr9Tc8AJwCfc+etLWF1W7/G4+eMtBqB7RgH 3joAni4+9lulaoiqgiSFFDNXnNXlR8Yj =kSUy -----END PGP SIGNATURE----- --Kc9HNjpzOXVc7FFU-- From owner-freebsd-sparc64@FreeBSD.ORG Thu Jun 16 07:38:18 2011 Return-Path: Delivered-To: sparc64@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 1D13F106564A; Thu, 16 Jun 2011 07:38:18 +0000 (UTC) (envelope-from avatar@mmlab.cse.yzu.edu.tw) Received: from www.mmlab.cse.yzu.edu.tw (www.mmlab.cse.yzu.edu.tw [140.138.150.166]) by mx1.freebsd.org (Postfix) with ESMTP id 7AC818FC18; Thu, 16 Jun 2011 07:38:17 +0000 (UTC) Received: by www.mmlab.cse.yzu.edu.tw (qmail, from userid 1000) id D6F132EC686B; Thu, 16 Jun 2011 15:20:12 +0800 (CST) DKIM-Signature: v=1; a=rsa-sha256; c=simple/simple; d=mmlab.cse.yzu.edu.tw; s=test; t=1308208812; bh=dRoAUMgKwH5uVynT4Ixa8iiZLt2ZnzYtXHyhcOQBhmE=; h=Date:From:To:cc:Subject:In-Reply-To:Message-ID:References: MIME-Version:Content-Type; b=S5QcjMw60gMM7kc6jwBAB/Pdl5SZHZaozlaqaa6+qX5AYgPpKmTphDM/15MF9fAu+ S4NA0j06aWlvdInmR2hyTBQEzW4Tp6yZVoLp7mEY2dLBeXcyoFNlI9zlS2YhH4G0I6 t2OVlRSUeVaYEmUJyVVy4T4Zw6WcaSJvuvpTrqdw= Received: from localhost (localhost [127.0.0.1]) by www.mmlab.cse.yzu.edu.tw (qmail) with ESMTP id D67782EC6866; Thu, 16 Jun 2011 15:20:12 +0800 (CST) Date: Thu, 16 Jun 2011 15:20:12 +0800 (CST) From: Tai-hwa Liang To: Garrett Cooper In-Reply-To: Message-ID: <11061615185315.43025@www.mmlab.cse.yzu.edu.tw> References: <201106160436.p5G4ah5k001007@freebsd-current.sentex.ca> MIME-Version: 1.0 Content-Type: MULTIPART/MIXED; BOUNDARY="3425325993-1692132936-1308208812=:43025" Cc: rodrigc@FreeBSD.org, current@freebsd.org, sparc64@freebsd.org Subject: Re: [head tinderbox] failure on sparc64/sparc64 X-BeenThere: freebsd-sparc64@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: Porting FreeBSD to the Sparc List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Thu, 16 Jun 2011 07:38:18 -0000 This message is in MIME format. The first part should be readable text, while the remaining parts are likely unreadable without MIME-aware tools. --3425325993-1692132936-1308208812=:43025 Content-Type: TEXT/PLAIN; charset=big5; format=flowed Content-Transfer-Encoding: 8BIT On Thu, 16 Jun 2011, Garrett Cooper wrote: > On Wed, Jun 15, 2011 at 9:36 PM, FreeBSD Tinderbox > wrote: >> TB --- 2011-06-16 04:08:45 - tinderbox 2.7 running on freebsd-current.sentex.ca >> TB --- 2011-06-16 04:08:45 - starting HEAD tinderbox run for sparc64/sparc64 [...] >> cc -O2 -pipe -ffreestanding -Wformat -I/src/lib/libstand -DBZ_NO_STDIO -DBZ_NO_COMPRESS -DHAVE_MEMCPY -I/src/lib/libstand/../libz -std=gnu99 -Wsystem-headers -Werror -Wall -Wno-format-y2k -Wno-uninitialized -Wno-pointer-sign -c /src/lib/libstand/twiddle.c >> cc -O2 -pipe -ffreestanding -Wformat -I/src/lib/libstand -DBZ_NO_STDIO -DBZ_NO_COMPRESS -DHAVE_MEMCPY -I/src/lib/libstand/../libz -std=gnu99 -Wsystem-headers -Werror -Wall -Wno-format-y2k -Wno-uninitialized -Wno-pointer-sign -c /src/lib/libstand/zalloc.c >> cc1: warnings being treated as errors >> /src/lib/libstand/zalloc.c: In function 'zfree': >> /src/lib/libstand/zalloc.c:157: warning: format '%d' expects type 'int', but argument 3 has type 'iaddr_t' >> /src/lib/libstand/zalloc.c:181: warning: format '%d' expects type 'int', but argument 3 has type 'iaddr_t' >> /src/lib/libstand/zalloc.c:212: warning: format '%d' expects type 'int', but argument 3 has type 'iaddr_t' >> *** Error code 1 >> >> Stop in /src/lib/libstand. >> *** Error code 1 > > Could someone please fix the tinderbox compile on sparc64 with this > file via this patch? Committed as r223139. Thanks, Tai-hwa Liang --3425325993-1692132936-1308208812=:43025-- From owner-freebsd-sparc64@FreeBSD.ORG Thu Jun 16 07:53:20 2011 Return-Path: Delivered-To: freebsd-sparc64@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 570B0106566B; Thu, 16 Jun 2011 07:53:20 +0000 (UTC) (envelope-from nwf@cs.jhu.edu) Received: from blaze.cs.jhu.edu (blaze.cs.jhu.edu [128.220.13.50]) by mx1.freebsd.org (Postfix) with ESMTP id 11E828FC1C; Thu, 16 Jun 2011 07:53:19 +0000 (UTC) Received: from gradx.cs.jhu.edu (gradx.cs.jhu.edu [128.220.13.52]) by blaze.cs.jhu.edu (8.14.3/8.14.3) with ESMTP id p5G7rJn8005689 (version=TLSv1/SSLv3 cipher=DHE-RSA-AES256-SHA bits=256 verify=NOT); Thu, 16 Jun 2011 03:53:19 -0400 (EDT) Received: from gradx.cs.jhu.edu (localhost [127.0.0.1]) by gradx.cs.jhu.edu (8.14.3/8.13.1) with ESMTP id p5G7rJ9D023154; Thu, 16 Jun 2011 03:53:19 -0400 Received: (from nwf@localhost) by gradx.cs.jhu.edu (8.14.3/8.13.8/Submit) id p5G7rJvC023153; Thu, 16 Jun 2011 03:53:19 -0400 Date: Thu, 16 Jun 2011 03:53:19 -0400 From: Nathaniel W Filardo To: freebsd-current@freebsd.org, freebsd-sparc64@freebsd.org Message-ID: <20110616075319.GM31996@gradx.cs.jhu.edu> References: <20110616073138.GL31996@gradx.cs.jhu.edu> MIME-Version: 1.0 Content-Type: multipart/signed; micalg=pgp-sha1; protocol="application/pgp-signature"; boundary="CaPKgh3XHpq3rEUV" Content-Disposition: inline In-Reply-To: <20110616073138.GL31996@gradx.cs.jhu.edu> User-Agent: Mutt/1.5.20 (2009-08-17) Cc: Subject: Re: TLS bug? X-BeenThere: freebsd-sparc64@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: Porting FreeBSD to the Sparc List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Thu, 16 Jun 2011 07:53:20 -0000 --CaPKgh3XHpq3rEUV Content-Type: text/plain; charset=us-ascii Content-Disposition: inline Content-Transfer-Encoding: quoted-printable Atcht; it's late. I forgot to mention that this system is a sparc64 V240 2-way SMP machine. It's running a kernel from 9.0-CURRENT r222833+262af52: Tue Jun 7 18:47:35 EDT 2011 and a userland from a little later. Sorry about that. --nwf; On Thu, Jun 16, 2011 at 03:31:38AM -0400, Nathaniel W Filardo wrote: > I have a few applications (bonnie++ and mysql, specifically, both from > ports) which trip over the assertion in > lib/libc/stdlib/malloc.c:/^_malloc_thread_cleanup that > > assert(tcache !=3D (void *)(uintptr_t)1); >=20 > I have patched malloc.c thus: >=20 > > --- a/lib/libc/stdlib/malloc.c > > +++ b/lib/libc/stdlib/malloc.c > > @@ -1108,7 +1108,7 @@ static __thread arena_t *arenas_map TLS= _MODEL; > > =20 > > #ifdef MALLOC_TCACHE > > /* Map of thread-specific caches. */ > > -static __thread tcache_t *tcache_tls TLS_MODEL; > > +__thread tcache_t *tcache_tls TLS_MODEL; > > =20 > > /* > > * Number of cache slots for each bin in the thread cache, or 0 if tca= che > > * is > > @@ -6184,10 +6184,17 @@ _malloc_thread_cleanup(void) > > #ifdef MALLOC_TCACHE > > tcache_t *tcache =3D tcache_tls; > > =20 > > + fprintf(stderr, "_m_t_c for %d:%lu with %p\n",=20 > > + getpid(), > > + (unsigned long) _pthread_self(), > > + tcache); > > + > > if (tcache !=3D NULL) { > > - assert(tcache !=3D (void *)(uintptr_t)1); > > - tcache_destroy(tcache); > > - tcache_tls =3D (void *)(uintptr_t)1; > > + /* assert(tcache !=3D (void *)(uintptr_t)1); */ > > + if((uintptr_t)tcache !=3D (uintptr_t)1) { > > + tcache_destroy(tcache); > > + tcache_tls =3D (void *)(uintptr_t)1; > > + } >=20 > and libthr/thread/thr_create.c thus: >=20 > > --- a/lib/libthr/thread/thr_create.c > > +++ b/lib/libthr/thread/thr_create.c > > @@ -243,6 +243,8 @@ create_stack(struct pthread_attr *pattr) > > return (ret); > > } > > =20 > > +extern __thread void *tcache_tls; > > + > > static void > > thread_start(struct pthread *curthread) > > { > > @@ -280,6 +282,11 @@ thread_start(struct pthread *curthread) > > curthread->attr.stacksize_attr; > > #endif > > =20 > > + fprintf(stderr, "t_s for %d:%lu with %p\n", > > + getpid(), > > + (unsigned long) _pthread_self(), > > + tcache_tls); > > + > > /* Run the current thread's start routine with argument: */ > > _pthread_exit(curthread->start_routine(curthread->arg)); > > =20 >=20 > to attempt to debug this issue. With those changes in place, bonnie++'s > execution looks like this: >=20 > >[...] > > Writing a byte at a time...done > > Writing intelligently...done > > Rewriting...done > > Reading a byte at a time...done > > Reading intelligently...done > > t_s for 79654:1086343168 with 0x0 > > t_s for 79654:1086345216 with 0x0 > > t_s for 79654:1086346240 with 0x0 > > t_s for 79654:1086347264 with 0x0 > > t_s for 79654:1086344192 with 0x0 > > start 'em...done...done...done...done..._m_t_c for 79654:1086344192 with > > 0x41404400 > > _m_t_c for 79654:1086346240 with 0x40d2c400 > > _m_t_c for 79654:1086343168 with 0x41404200 > > _m_t_c for 79654:1086345216 with 0x41804200 > > done... > > _m_t_c for 79654:1086347264 with 0x41004200 > > Create files in sequential order...done. > > Stat files in sequential order...done. > > Delete files in sequential order...done. > > Create files in random order...done. > > Stat files in random order...done. > > Delete files in random order...done. > > 1.96,1.96,hydra.priv.oc.ietfng.org,1,1308217772,10M,,7,81,2644,7,3577,1= 4,34,93,+++++,+++,773.7,61,16,,, > > ,,2325,74,13016,99,2342,86,3019,91,11888,99,2184,89,16397ms,1237ms,671m= s,2009ms,177us,1305ms,489ms,1029 > > us,270ms,140ms,53730us,250ms > > Writing a byte at a time...done > > Writing intelligently...done > > Rewriting...done > > Reading a byte at a time...done > > Reading intelligently...done > > t_s for 79654:1086343168 with 0x1 > > t_s for 79654:1086346240 with 0x1 > > t_s for 79654:1086345216 with 0x1 > > t_s for 79654:1086347264 with 0x1 > > t_s for 79654:1086344192 with 0x1 > > start 'em...done...done...done...done...done... > > _m_t_c for 79654:1086347264 with 0x1 > > _m_t_c for 79654:1086344192 with 0x1 > > _m_t_c for 79654:1086343168 with 0x1 > >[...] >=20 > So what seems to be happening is that the TLS area is being set up > incorrectly, eventually: rather than zeroing the tcache_tls value, it is > being set to 1, which means no tcache is ever allocated, so when we get > around to exiting, the assert trips. >=20 > Unfortunately, setting a breakpoint on __libc_allocate_tls seems to do bad > things to the kernel (inducing a SIR without any panic message). I am > somewhat at a loss; help? >=20 > Thanks in advance! > --nwf; --CaPKgh3XHpq3rEUV Content-Type: application/pgp-signature Content-Disposition: inline -----BEGIN PGP SIGNATURE----- Version: GnuPG v1.4.10 (GNU/Linux) iEYEARECAAYFAk35tm8ACgkQTeQabvr9Tc9dUgCfdsS2tRyv7XQLe3ZIxtARb08g ikwAnRJGMKWSWPd8KL0C4PzKAahNfjT0 =pMJ3 -----END PGP SIGNATURE----- --CaPKgh3XHpq3rEUV-- From owner-freebsd-sparc64@FreeBSD.ORG Thu Jun 16 08:07:59 2011 Return-Path: Delivered-To: sparc64@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id E497A106566C; Thu, 16 Jun 2011 08:07:59 +0000 (UTC) (envelope-from tinderbox@freebsd.org) Received: from freebsd-current.sentex.ca (freebsd-current.sentex.ca [64.7.128.98]) by mx1.freebsd.org (Postfix) with ESMTP id 90F868FC13; Thu, 16 Jun 2011 08:07:59 +0000 (UTC) Received: from freebsd-current.sentex.ca (localhost [127.0.0.1]) by freebsd-current.sentex.ca (8.14.4/8.14.4) with ESMTP id p5G87wWu057358; Thu, 16 Jun 2011 04:07:58 -0400 (EDT) (envelope-from tinderbox@freebsd.org) Received: (from tinderbox@localhost) by freebsd-current.sentex.ca (8.14.4/8.14.4/Submit) id p5G87wnM057346; Thu, 16 Jun 2011 08:07:58 GMT (envelope-from tinderbox@freebsd.org) Date: Thu, 16 Jun 2011 08:07:58 GMT Message-Id: <201106160807.p5G87wnM057346@freebsd-current.sentex.ca> X-Authentication-Warning: freebsd-current.sentex.ca: tinderbox set sender to FreeBSD Tinderbox using -f Sender: FreeBSD Tinderbox From: FreeBSD Tinderbox To: FreeBSD Tinderbox , , Precedence: bulk Cc: Subject: [head tinderbox] failure on sparc64/sparc64 X-BeenThere: freebsd-sparc64@freebsd.org X-Mailman-Version: 2.1.5 List-Id: Porting FreeBSD to the Sparc List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Thu, 16 Jun 2011 08:08:00 -0000 TB --- 2011-06-16 07:39:20 - tinderbox 2.7 running on freebsd-current.sentex.ca TB --- 2011-06-16 07:39:20 - starting HEAD tinderbox run for sparc64/sparc64 TB --- 2011-06-16 07:39:20 - cleaning the object tree TB --- 2011-06-16 07:39:24 - cvsupping the source tree TB --- 2011-06-16 07:39:24 - /usr/bin/csup -z -r 3 -g -L 1 -h cvsup.sentex.ca /tinderbox/HEAD/sparc64/sparc64/supfile TB --- 2011-06-16 07:39:35 - building world TB --- 2011-06-16 07:39:35 - MAKEOBJDIRPREFIX=/obj TB --- 2011-06-16 07:39:35 - PATH=/usr/bin:/usr/sbin:/bin:/sbin TB --- 2011-06-16 07:39:35 - TARGET=sparc64 TB --- 2011-06-16 07:39:35 - TARGET_ARCH=sparc64 TB --- 2011-06-16 07:39:35 - TZ=UTC TB --- 2011-06-16 07:39:35 - __MAKE_CONF=/dev/null TB --- 2011-06-16 07:39:35 - cd /src TB --- 2011-06-16 07:39:35 - /usr/bin/make -B buildworld >>> World build started on Thu Jun 16 07:39:37 UTC 2011 >>> Rebuilding the temporary build tree >>> stage 1.1: legacy release compatibility shims >>> stage 1.2: bootstrap tools >>> stage 2.1: cleaning up the object tree >>> stage 2.2: rebuilding the object tree >>> stage 2.3: build tools >>> stage 3: cross tools >>> stage 4.1: building includes >>> stage 4.2: building libraries [...] cc -O2 -pipe -ffreestanding -Wformat -I/src/lib/libstand -DBZ_NO_STDIO -DBZ_NO_COMPRESS -DHAVE_MEMCPY -I/src/lib/libstand/../libz -std=gnu99 -Wsystem-headers -Werror -Wall -Wno-format-y2k -Wno-uninitialized -Wno-pointer-sign -c /src/lib/libstand/sbrk.c cc -O2 -pipe -ffreestanding -Wformat -I/src/lib/libstand -DBZ_NO_STDIO -DBZ_NO_COMPRESS -DHAVE_MEMCPY -I/src/lib/libstand/../libz -std=gnu99 -Wsystem-headers -Werror -Wall -Wno-format-y2k -Wno-uninitialized -Wno-pointer-sign -c /src/lib/libstand/twiddle.c cc -O2 -pipe -ffreestanding -Wformat -I/src/lib/libstand -DBZ_NO_STDIO -DBZ_NO_COMPRESS -DHAVE_MEMCPY -I/src/lib/libstand/../libz -std=gnu99 -Wsystem-headers -Werror -Wall -Wno-format-y2k -Wno-uninitialized -Wno-pointer-sign -c /src/lib/libstand/zalloc.c cc1: warnings being treated as errors /src/lib/libstand/zalloc.c: In function 'zfree': /src/lib/libstand/zalloc.c:157: warning: format '%d' expects type 'int', but argument 3 has type 'iaddr_t' /src/lib/libstand/zalloc.c:181: warning: format '%d' expects type 'int', but argument 3 has type 'iaddr_t' /src/lib/libstand/zalloc.c:212: warning: format '%d' expects type 'int', but argument 3 has type 'iaddr_t' *** Error code 1 Stop in /src/lib/libstand. *** Error code 1 Stop in /src/lib. *** Error code 1 Stop in /src. *** Error code 1 Stop in /src. *** Error code 1 Stop in /src. *** Error code 1 Stop in /src. TB --- 2011-06-16 08:07:58 - WARNING: /usr/bin/make returned exit code 1 TB --- 2011-06-16 08:07:58 - ERROR: failed to build world TB --- 2011-06-16 08:07:58 - 1270.95 user 310.62 system 1718.09 real http://tinderbox.freebsd.org/tinderbox-head-HEAD-sparc64-sparc64.full From owner-freebsd-sparc64@FreeBSD.ORG Thu Jun 16 11:15:44 2011 Return-Path: Delivered-To: sparc64@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id B4CEC106566B; Thu, 16 Jun 2011 11:15:44 +0000 (UTC) (envelope-from tinderbox@freebsd.org) Received: from freebsd-current.sentex.ca (freebsd-current.sentex.ca [64.7.128.98]) by mx1.freebsd.org (Postfix) with ESMTP id 6BD5A8FC0A; Thu, 16 Jun 2011 11:15:43 +0000 (UTC) Received: from freebsd-current.sentex.ca (localhost [127.0.0.1]) by freebsd-current.sentex.ca (8.14.4/8.14.4) with ESMTP id p5GBFh88070634; Thu, 16 Jun 2011 07:15:43 -0400 (EDT) (envelope-from tinderbox@freebsd.org) Received: (from tinderbox@localhost) by freebsd-current.sentex.ca (8.14.4/8.14.4/Submit) id p5GBFhPF070633; Thu, 16 Jun 2011 11:15:43 GMT (envelope-from tinderbox@freebsd.org) Date: Thu, 16 Jun 2011 11:15:43 GMT Message-Id: <201106161115.p5GBFhPF070633@freebsd-current.sentex.ca> X-Authentication-Warning: freebsd-current.sentex.ca: tinderbox set sender to FreeBSD Tinderbox using -f Sender: FreeBSD Tinderbox From: FreeBSD Tinderbox To: FreeBSD Tinderbox , , Precedence: bulk Cc: Subject: [head tinderbox] failure on sparc64/sparc64 X-BeenThere: freebsd-sparc64@freebsd.org X-Mailman-Version: 2.1.5 List-Id: Porting FreeBSD to the Sparc List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Thu, 16 Jun 2011 11:15:44 -0000 TB --- 2011-06-16 10:49:44 - tinderbox 2.7 running on freebsd-current.sentex.ca TB --- 2011-06-16 10:49:44 - starting HEAD tinderbox run for sparc64/sparc64 TB --- 2011-06-16 10:49:44 - cleaning the object tree TB --- 2011-06-16 10:49:49 - cvsupping the source tree TB --- 2011-06-16 10:49:49 - /usr/bin/csup -z -r 3 -g -L 1 -h cvsup.sentex.ca /tinderbox/HEAD/sparc64/sparc64/supfile TB --- 2011-06-16 10:50:21 - building world TB --- 2011-06-16 10:50:21 - MAKEOBJDIRPREFIX=/obj TB --- 2011-06-16 10:50:21 - PATH=/usr/bin:/usr/sbin:/bin:/sbin TB --- 2011-06-16 10:50:21 - TARGET=sparc64 TB --- 2011-06-16 10:50:21 - TARGET_ARCH=sparc64 TB --- 2011-06-16 10:50:21 - TZ=UTC TB --- 2011-06-16 10:50:21 - __MAKE_CONF=/dev/null TB --- 2011-06-16 10:50:21 - cd /src TB --- 2011-06-16 10:50:21 - /usr/bin/make -B buildworld >>> World build started on Thu Jun 16 10:50:22 UTC 2011 >>> Rebuilding the temporary build tree >>> stage 1.1: legacy release compatibility shims >>> stage 1.2: bootstrap tools >>> stage 2.1: cleaning up the object tree >>> stage 2.2: rebuilding the object tree >>> stage 2.3: build tools >>> stage 3: cross tools >>> stage 4.1: building includes >>> stage 4.2: building libraries [...] cc -O2 -pipe -ffreestanding -Wformat -I/src/lib/libstand -DBZ_NO_STDIO -DBZ_NO_COMPRESS -DHAVE_MEMCPY -I/src/lib/libstand/../libz -std=gnu99 -Wsystem-headers -Werror -Wall -Wno-format-y2k -Wno-uninitialized -Wno-pointer-sign -c /src/lib/libstand/random.c cc -O2 -pipe -ffreestanding -Wformat -I/src/lib/libstand -DBZ_NO_STDIO -DBZ_NO_COMPRESS -DHAVE_MEMCPY -I/src/lib/libstand/../libz -std=gnu99 -Wsystem-headers -Werror -Wall -Wno-format-y2k -Wno-uninitialized -Wno-pointer-sign -c /src/lib/libstand/sbrk.c cc -O2 -pipe -ffreestanding -Wformat -I/src/lib/libstand -DBZ_NO_STDIO -DBZ_NO_COMPRESS -DHAVE_MEMCPY -I/src/lib/libstand/../libz -std=gnu99 -Wsystem-headers -Werror -Wall -Wno-format-y2k -Wno-uninitialized -Wno-pointer-sign -c /src/lib/libstand/twiddle.c cc -O2 -pipe -ffreestanding -Wformat -I/src/lib/libstand -DBZ_NO_STDIO -DBZ_NO_COMPRESS -DHAVE_MEMCPY -I/src/lib/libstand/../libz -std=gnu99 -Wsystem-headers -Werror -Wall -Wno-format-y2k -Wno-uninitialized -Wno-pointer-sign -c /src/lib/libstand/zalloc.c cc -O2 -pipe -ffreestanding -Wformat -I/src/lib/libstand -DBZ_NO_STDIO -DBZ_NO_COMPRESS -DHAVE_MEMCPY -I/src/lib/libstand/../libz -std=gnu99 -Wsystem-headers -Werror -Wall -Wno-format-y2k -Wno-uninitialized -Wno-pointer-sign -c /src/lib/libstand/zalloc_malloc.c cc1: warnings being treated as errors /src/lib/libstand/zalloc_malloc.c: In function 'Free': /src/lib/libstand/zalloc_malloc.c:113: warning: format '%d' expects type 'int', but argument 3 has type 'long unsigned int' *** Error code 1 Stop in /src/lib/libstand. *** Error code 1 Stop in /src/lib. *** Error code 1 Stop in /src. *** Error code 1 Stop in /src. *** Error code 1 Stop in /src. *** Error code 1 Stop in /src. TB --- 2011-06-16 11:15:43 - WARNING: /usr/bin/make returned exit code 1 TB --- 2011-06-16 11:15:43 - ERROR: failed to build world TB --- 2011-06-16 11:15:43 - 1248.03 user 284.82 system 1559.34 real http://tinderbox.freebsd.org/tinderbox-head-HEAD-sparc64-sparc64.full From owner-freebsd-sparc64@FreeBSD.ORG Thu Jun 16 12:45:07 2011 Return-Path: Delivered-To: sparc64@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 69C7E106566B; Thu, 16 Jun 2011 12:45:07 +0000 (UTC) (envelope-from tinderbox@freebsd.org) Received: from freebsd-current.sentex.ca (freebsd-current.sentex.ca [64.7.128.98]) by mx1.freebsd.org (Postfix) with ESMTP id 14B948FC17; Thu, 16 Jun 2011 12:45:06 +0000 (UTC) Received: from freebsd-current.sentex.ca (localhost [127.0.0.1]) by freebsd-current.sentex.ca (8.14.4/8.14.4) with ESMTP id p5GCj63I053721; Thu, 16 Jun 2011 08:45:06 -0400 (EDT) (envelope-from tinderbox@freebsd.org) Received: (from tinderbox@localhost) by freebsd-current.sentex.ca (8.14.4/8.14.4/Submit) id p5GCj6fD053720; Thu, 16 Jun 2011 12:45:06 GMT (envelope-from tinderbox@freebsd.org) Date: Thu, 16 Jun 2011 12:45:06 GMT Message-Id: <201106161245.p5GCj6fD053720@freebsd-current.sentex.ca> X-Authentication-Warning: freebsd-current.sentex.ca: tinderbox set sender to FreeBSD Tinderbox using -f Sender: FreeBSD Tinderbox From: FreeBSD Tinderbox To: FreeBSD Tinderbox , , Precedence: bulk Cc: Subject: [head tinderbox] failure on sparc64/sparc64 X-BeenThere: freebsd-sparc64@freebsd.org X-Mailman-Version: 2.1.5 List-Id: Porting FreeBSD to the Sparc List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Thu, 16 Jun 2011 12:45:07 -0000 TB --- 2011-06-16 12:19:27 - tinderbox 2.7 running on freebsd-current.sentex.ca TB --- 2011-06-16 12:19:27 - starting HEAD tinderbox run for sparc64/sparc64 TB --- 2011-06-16 12:19:27 - cleaning the object tree TB --- 2011-06-16 12:19:30 - cvsupping the source tree TB --- 2011-06-16 12:19:30 - /usr/bin/csup -z -r 3 -g -L 1 -h cvsup.sentex.ca /tinderbox/HEAD/sparc64/sparc64/supfile TB --- 2011-06-16 12:19:44 - building world TB --- 2011-06-16 12:19:44 - MAKEOBJDIRPREFIX=/obj TB --- 2011-06-16 12:19:44 - PATH=/usr/bin:/usr/sbin:/bin:/sbin TB --- 2011-06-16 12:19:44 - TARGET=sparc64 TB --- 2011-06-16 12:19:44 - TARGET_ARCH=sparc64 TB --- 2011-06-16 12:19:44 - TZ=UTC TB --- 2011-06-16 12:19:44 - __MAKE_CONF=/dev/null TB --- 2011-06-16 12:19:44 - cd /src TB --- 2011-06-16 12:19:44 - /usr/bin/make -B buildworld >>> World build started on Thu Jun 16 12:19:45 UTC 2011 >>> Rebuilding the temporary build tree >>> stage 1.1: legacy release compatibility shims >>> stage 1.2: bootstrap tools >>> stage 2.1: cleaning up the object tree >>> stage 2.2: rebuilding the object tree >>> stage 2.3: build tools >>> stage 3: cross tools >>> stage 4.1: building includes >>> stage 4.2: building libraries [...] cc -O2 -pipe -ffreestanding -Wformat -I/src/lib/libstand -DBZ_NO_STDIO -DBZ_NO_COMPRESS -DHAVE_MEMCPY -I/src/lib/libstand/../libz -std=gnu99 -Wsystem-headers -Werror -Wall -Wno-format-y2k -Wno-uninitialized -Wno-pointer-sign -c /src/lib/libstand/random.c cc -O2 -pipe -ffreestanding -Wformat -I/src/lib/libstand -DBZ_NO_STDIO -DBZ_NO_COMPRESS -DHAVE_MEMCPY -I/src/lib/libstand/../libz -std=gnu99 -Wsystem-headers -Werror -Wall -Wno-format-y2k -Wno-uninitialized -Wno-pointer-sign -c /src/lib/libstand/sbrk.c cc -O2 -pipe -ffreestanding -Wformat -I/src/lib/libstand -DBZ_NO_STDIO -DBZ_NO_COMPRESS -DHAVE_MEMCPY -I/src/lib/libstand/../libz -std=gnu99 -Wsystem-headers -Werror -Wall -Wno-format-y2k -Wno-uninitialized -Wno-pointer-sign -c /src/lib/libstand/twiddle.c cc -O2 -pipe -ffreestanding -Wformat -I/src/lib/libstand -DBZ_NO_STDIO -DBZ_NO_COMPRESS -DHAVE_MEMCPY -I/src/lib/libstand/../libz -std=gnu99 -Wsystem-headers -Werror -Wall -Wno-format-y2k -Wno-uninitialized -Wno-pointer-sign -c /src/lib/libstand/zalloc.c cc -O2 -pipe -ffreestanding -Wformat -I/src/lib/libstand -DBZ_NO_STDIO -DBZ_NO_COMPRESS -DHAVE_MEMCPY -I/src/lib/libstand/../libz -std=gnu99 -Wsystem-headers -Werror -Wall -Wno-format-y2k -Wno-uninitialized -Wno-pointer-sign -c /src/lib/libstand/zalloc_malloc.c cc1: warnings being treated as errors /src/lib/libstand/zalloc_malloc.c: In function 'Free': /src/lib/libstand/zalloc_malloc.c:113: warning: format '%d' expects type 'int', but argument 3 has type 'long unsigned int' *** Error code 1 Stop in /src/lib/libstand. *** Error code 1 Stop in /src/lib. *** Error code 1 Stop in /src. *** Error code 1 Stop in /src. *** Error code 1 Stop in /src. *** Error code 1 Stop in /src. TB --- 2011-06-16 12:45:06 - WARNING: /usr/bin/make returned exit code 1 TB --- 2011-06-16 12:45:06 - ERROR: failed to build world TB --- 2011-06-16 12:45:06 - 1248.24 user 281.82 system 1539.14 real http://tinderbox.freebsd.org/tinderbox-head-HEAD-sparc64-sparc64.full From owner-freebsd-sparc64@FreeBSD.ORG Thu Jun 16 12:55:42 2011 Return-Path: Delivered-To: freebsd-sparc64@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id E7B7E1065672 for ; Thu, 16 Jun 2011 12:55:41 +0000 (UTC) (envelope-from peterjeremy@acm.org) Received: from mail15.syd.optusnet.com.au (mail15.syd.optusnet.com.au [211.29.132.196]) by mx1.freebsd.org (Postfix) with ESMTP id 768348FC21 for ; Thu, 16 Jun 2011 12:55:40 +0000 (UTC) Received: from server.vk2pj.dyndns.org (c220-239-116-103.belrs4.nsw.optusnet.com.au [220.239.116.103]) by mail15.syd.optusnet.com.au (8.13.1/8.13.1) with ESMTP id p5GCtXxG011153 (version=TLSv1/SSLv3 cipher=DHE-RSA-AES256-SHA bits=256 verify=NO); Thu, 16 Jun 2011 22:55:35 +1000 X-Bogosity: Ham, spamicity=0.000000 Received: from server.vk2pj.dyndns.org (localhost.vk2pj.dyndns.org [127.0.0.1]) by server.vk2pj.dyndns.org (8.14.4/8.14.4) with ESMTP id p5GCtXsI074328; Thu, 16 Jun 2011 22:55:33 +1000 (EST) (envelope-from peter@server.vk2pj.dyndns.org) Received: (from peter@localhost) by server.vk2pj.dyndns.org (8.14.4/8.14.4/Submit) id p5GCtVTx074327; Thu, 16 Jun 2011 22:55:31 +1000 (EST) (envelope-from peter) Date: Thu, 16 Jun 2011 22:55:31 +1000 From: Peter Jeremy To: Marius Strobl Message-ID: <20110616125531.GA74096@server.vk2pj.dyndns.org> References: <20110526234728.GA69750@server.vk2pj.dyndns.org> <20110527120659.GA78000@alchemy.franken.de> <20110601231237.GA5267@server.vk2pj.dyndns.org> <20110608224801.GB35494@alchemy.franken.de> <20110613235144.GA12470@server.vk2pj.dyndns.org> <20110614214959.GB91014@server.vk2pj.dyndns.org> <20110615231226.GY7064@alchemy.franken.de> MIME-Version: 1.0 Content-Type: multipart/signed; micalg=pgp-sha1; protocol="application/pgp-signature"; boundary="AhhlLboLdkugWU4S" Content-Disposition: inline In-Reply-To: <20110615231226.GY7064@alchemy.franken.de> X-PGP-Key: http://members.optusnet.com.au/peterjeremy/pubkey.asc User-Agent: Mutt/1.5.21 (2010-09-15) Cc: freebsd-sparc64@freebsd.org Subject: Re: 'make -j16 universe' gives SIReset X-BeenThere: freebsd-sparc64@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: Porting FreeBSD to the Sparc List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Thu, 16 Jun 2011 12:55:42 -0000 --AhhlLboLdkugWU4S Content-Type: text/plain; charset=us-ascii Content-Disposition: inline Content-Transfer-Encoding: quoted-printable On 2011-Jun-16 01:12:26 +0200, Marius Strobl wr= ote: >This backtrace shows two things that just shouldn't happen hardware-wise: >a) The CPU issues an stray interrupt vector. This would explain the SIRs > you were seeing without the patch which tries to make these non-fatal. >b) The CPU faults on an address which is covered by an locked TLB slot. > >The funny thing is that the CPU then actually still manages to panic; if >something like b) occurs I'd expect it to be in a totally unusable state. >I'm not sure what to do about these as it still looks like broken hardware >or a silicon bug to me but at least the public errata doesn't mention >something like that and the OpenSolaris source doesn't seem to work >around something like these in an obvious way either. The only thing I >can think of is to try whether just ignoring the stray interrupt vectors >with the below patch avoids any further issues. You'll need to revert >sparc64_intr_vector_stray.diff for that or at least the exception.S >part. I guess it's possible that neither Solaris nor SunVTS is tripping over a hardware fault but I'm not sure how to prove or disprove that. Just in case it was something I'd done, I reverted to a completely stock -current (slightly newer than r223035 but I don't have the exact revision) and that gave me a SIR during "make -j32 universe". I then changed the DCR_DTPE to DCR_SI and that also gave SIR. I then added your original stray interrupt code and that managed to complete a "make -j32 universe" without problem (which it's never managed before) - I left it running that in a loop and will check tomorrow. It does look like the issue is sensitive to code layout. I'll try your latest suggestions tomorrow. --=20 Peter Jeremy --AhhlLboLdkugWU4S Content-Type: application/pgp-signature -----BEGIN PGP SIGNATURE----- Version: GnuPG v2.0.17 (FreeBSD) iEYEARECAAYFAk35/UMACgkQ/opHv/APuIdgigCcCYfteqPtr0GlAfb7WFgkDKb7 tpMAoMAdsw0Sf+WBRe02ZoTanSGquIbM =mtWp -----END PGP SIGNATURE----- --AhhlLboLdkugWU4S-- From owner-freebsd-sparc64@FreeBSD.ORG Thu Jun 16 14:14:48 2011 Return-Path: Delivered-To: sparc64@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id A5376106564A; Thu, 16 Jun 2011 14:14:48 +0000 (UTC) (envelope-from tinderbox@freebsd.org) Received: from freebsd-current.sentex.ca (freebsd-current.sentex.ca [64.7.128.98]) by mx1.freebsd.org (Postfix) with ESMTP id 597CA8FC1E; Thu, 16 Jun 2011 14:14:47 +0000 (UTC) Received: from freebsd-current.sentex.ca (localhost [127.0.0.1]) by freebsd-current.sentex.ca (8.14.4/8.14.4) with ESMTP id p5GEElEQ036786; Thu, 16 Jun 2011 10:14:47 -0400 (EDT) (envelope-from tinderbox@freebsd.org) Received: (from tinderbox@localhost) by freebsd-current.sentex.ca (8.14.4/8.14.4/Submit) id p5GEElZS036785; Thu, 16 Jun 2011 14:14:47 GMT (envelope-from tinderbox@freebsd.org) Date: Thu, 16 Jun 2011 14:14:47 GMT Message-Id: <201106161414.p5GEElZS036785@freebsd-current.sentex.ca> X-Authentication-Warning: freebsd-current.sentex.ca: tinderbox set sender to FreeBSD Tinderbox using -f Sender: FreeBSD Tinderbox From: FreeBSD Tinderbox To: FreeBSD Tinderbox , , Precedence: bulk Cc: Subject: [head tinderbox] failure on sparc64/sparc64 X-BeenThere: freebsd-sparc64@freebsd.org X-Mailman-Version: 2.1.5 List-Id: Porting FreeBSD to the Sparc List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Thu, 16 Jun 2011 14:14:48 -0000 TB --- 2011-06-16 13:49:11 - tinderbox 2.7 running on freebsd-current.sentex.ca TB --- 2011-06-16 13:49:11 - starting HEAD tinderbox run for sparc64/sparc64 TB --- 2011-06-16 13:49:11 - cleaning the object tree TB --- 2011-06-16 13:49:14 - cvsupping the source tree TB --- 2011-06-16 13:49:14 - /usr/bin/csup -z -r 3 -g -L 1 -h cvsup.sentex.ca /tinderbox/HEAD/sparc64/sparc64/supfile TB --- 2011-06-16 13:49:27 - building world TB --- 2011-06-16 13:49:27 - MAKEOBJDIRPREFIX=/obj TB --- 2011-06-16 13:49:27 - PATH=/usr/bin:/usr/sbin:/bin:/sbin TB --- 2011-06-16 13:49:27 - TARGET=sparc64 TB --- 2011-06-16 13:49:27 - TARGET_ARCH=sparc64 TB --- 2011-06-16 13:49:27 - TZ=UTC TB --- 2011-06-16 13:49:27 - __MAKE_CONF=/dev/null TB --- 2011-06-16 13:49:27 - cd /src TB --- 2011-06-16 13:49:27 - /usr/bin/make -B buildworld >>> World build started on Thu Jun 16 13:49:28 UTC 2011 >>> Rebuilding the temporary build tree >>> stage 1.1: legacy release compatibility shims >>> stage 1.2: bootstrap tools >>> stage 2.1: cleaning up the object tree >>> stage 2.2: rebuilding the object tree >>> stage 2.3: build tools >>> stage 3: cross tools >>> stage 4.1: building includes >>> stage 4.2: building libraries [...] cc -O2 -pipe -ffreestanding -Wformat -I/src/lib/libstand -DBZ_NO_STDIO -DBZ_NO_COMPRESS -DHAVE_MEMCPY -I/src/lib/libstand/../libz -std=gnu99 -Wsystem-headers -Werror -Wall -Wno-format-y2k -Wno-uninitialized -Wno-pointer-sign -c /src/lib/libstand/random.c cc -O2 -pipe -ffreestanding -Wformat -I/src/lib/libstand -DBZ_NO_STDIO -DBZ_NO_COMPRESS -DHAVE_MEMCPY -I/src/lib/libstand/../libz -std=gnu99 -Wsystem-headers -Werror -Wall -Wno-format-y2k -Wno-uninitialized -Wno-pointer-sign -c /src/lib/libstand/sbrk.c cc -O2 -pipe -ffreestanding -Wformat -I/src/lib/libstand -DBZ_NO_STDIO -DBZ_NO_COMPRESS -DHAVE_MEMCPY -I/src/lib/libstand/../libz -std=gnu99 -Wsystem-headers -Werror -Wall -Wno-format-y2k -Wno-uninitialized -Wno-pointer-sign -c /src/lib/libstand/twiddle.c cc -O2 -pipe -ffreestanding -Wformat -I/src/lib/libstand -DBZ_NO_STDIO -DBZ_NO_COMPRESS -DHAVE_MEMCPY -I/src/lib/libstand/../libz -std=gnu99 -Wsystem-headers -Werror -Wall -Wno-format-y2k -Wno-uninitialized -Wno-pointer-sign -c /src/lib/libstand/zalloc.c cc -O2 -pipe -ffreestanding -Wformat -I/src/lib/libstand -DBZ_NO_STDIO -DBZ_NO_COMPRESS -DHAVE_MEMCPY -I/src/lib/libstand/../libz -std=gnu99 -Wsystem-headers -Werror -Wall -Wno-format-y2k -Wno-uninitialized -Wno-pointer-sign -c /src/lib/libstand/zalloc_malloc.c cc1: warnings being treated as errors /src/lib/libstand/zalloc_malloc.c: In function 'Free': /src/lib/libstand/zalloc_malloc.c:113: warning: format '%d' expects type 'int', but argument 3 has type 'long unsigned int' *** Error code 1 Stop in /src/lib/libstand. *** Error code 1 Stop in /src/lib. *** Error code 1 Stop in /src. *** Error code 1 Stop in /src. *** Error code 1 Stop in /src. *** Error code 1 Stop in /src. TB --- 2011-06-16 14:14:47 - WARNING: /usr/bin/make returned exit code 1 TB --- 2011-06-16 14:14:47 - ERROR: failed to build world TB --- 2011-06-16 14:14:47 - 1249.51 user 282.36 system 1536.09 real http://tinderbox.freebsd.org/tinderbox-head-HEAD-sparc64-sparc64.full From owner-freebsd-sparc64@FreeBSD.ORG Thu Jun 16 15:46:19 2011 Return-Path: Delivered-To: sparc64@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 606D61065672; Thu, 16 Jun 2011 15:46:19 +0000 (UTC) (envelope-from tinderbox@freebsd.org) Received: from freebsd-current.sentex.ca (freebsd-current.sentex.ca [64.7.128.98]) by mx1.freebsd.org (Postfix) with ESMTP id 168BB8FC15; Thu, 16 Jun 2011 15:46:18 +0000 (UTC) Received: from freebsd-current.sentex.ca (localhost [127.0.0.1]) by freebsd-current.sentex.ca (8.14.4/8.14.4) with ESMTP id p5GFkIaV019879; Thu, 16 Jun 2011 11:46:18 -0400 (EDT) (envelope-from tinderbox@freebsd.org) Received: (from tinderbox@localhost) by freebsd-current.sentex.ca (8.14.4/8.14.4/Submit) id p5GFkIS6019878; Thu, 16 Jun 2011 15:46:18 GMT (envelope-from tinderbox@freebsd.org) Date: Thu, 16 Jun 2011 15:46:18 GMT Message-Id: <201106161546.p5GFkIS6019878@freebsd-current.sentex.ca> X-Authentication-Warning: freebsd-current.sentex.ca: tinderbox set sender to FreeBSD Tinderbox using -f Sender: FreeBSD Tinderbox From: FreeBSD Tinderbox To: FreeBSD Tinderbox , , Precedence: bulk Cc: Subject: [head tinderbox] failure on sparc64/sparc64 X-BeenThere: freebsd-sparc64@freebsd.org X-Mailman-Version: 2.1.5 List-Id: Porting FreeBSD to the Sparc List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Thu, 16 Jun 2011 15:46:19 -0000 TB --- 2011-06-16 15:20:17 - tinderbox 2.7 running on freebsd-current.sentex.ca TB --- 2011-06-16 15:20:17 - starting HEAD tinderbox run for sparc64/sparc64 TB --- 2011-06-16 15:20:17 - cleaning the object tree TB --- 2011-06-16 15:20:24 - cvsupping the source tree TB --- 2011-06-16 15:20:24 - /usr/bin/csup -z -r 3 -g -L 1 -h cvsup.sentex.ca /tinderbox/HEAD/sparc64/sparc64/supfile TB --- 2011-06-16 15:21:06 - building world TB --- 2011-06-16 15:21:06 - MAKEOBJDIRPREFIX=/obj TB --- 2011-06-16 15:21:06 - PATH=/usr/bin:/usr/sbin:/bin:/sbin TB --- 2011-06-16 15:21:06 - TARGET=sparc64 TB --- 2011-06-16 15:21:06 - TARGET_ARCH=sparc64 TB --- 2011-06-16 15:21:06 - TZ=UTC TB --- 2011-06-16 15:21:06 - __MAKE_CONF=/dev/null TB --- 2011-06-16 15:21:06 - cd /src TB --- 2011-06-16 15:21:06 - /usr/bin/make -B buildworld >>> World build started on Thu Jun 16 15:21:06 UTC 2011 >>> Rebuilding the temporary build tree >>> stage 1.1: legacy release compatibility shims >>> stage 1.2: bootstrap tools >>> stage 2.1: cleaning up the object tree >>> stage 2.2: rebuilding the object tree >>> stage 2.3: build tools >>> stage 3: cross tools >>> stage 4.1: building includes >>> stage 4.2: building libraries [...] cc -O2 -pipe -ffreestanding -Wformat -I/src/lib/libstand -DBZ_NO_STDIO -DBZ_NO_COMPRESS -DHAVE_MEMCPY -I/src/lib/libstand/../libz -std=gnu99 -Wsystem-headers -Werror -Wall -Wno-format-y2k -Wno-uninitialized -Wno-pointer-sign -c /src/lib/libstand/random.c cc -O2 -pipe -ffreestanding -Wformat -I/src/lib/libstand -DBZ_NO_STDIO -DBZ_NO_COMPRESS -DHAVE_MEMCPY -I/src/lib/libstand/../libz -std=gnu99 -Wsystem-headers -Werror -Wall -Wno-format-y2k -Wno-uninitialized -Wno-pointer-sign -c /src/lib/libstand/sbrk.c cc -O2 -pipe -ffreestanding -Wformat -I/src/lib/libstand -DBZ_NO_STDIO -DBZ_NO_COMPRESS -DHAVE_MEMCPY -I/src/lib/libstand/../libz -std=gnu99 -Wsystem-headers -Werror -Wall -Wno-format-y2k -Wno-uninitialized -Wno-pointer-sign -c /src/lib/libstand/twiddle.c cc -O2 -pipe -ffreestanding -Wformat -I/src/lib/libstand -DBZ_NO_STDIO -DBZ_NO_COMPRESS -DHAVE_MEMCPY -I/src/lib/libstand/../libz -std=gnu99 -Wsystem-headers -Werror -Wall -Wno-format-y2k -Wno-uninitialized -Wno-pointer-sign -c /src/lib/libstand/zalloc.c cc -O2 -pipe -ffreestanding -Wformat -I/src/lib/libstand -DBZ_NO_STDIO -DBZ_NO_COMPRESS -DHAVE_MEMCPY -I/src/lib/libstand/../libz -std=gnu99 -Wsystem-headers -Werror -Wall -Wno-format-y2k -Wno-uninitialized -Wno-pointer-sign -c /src/lib/libstand/zalloc_malloc.c cc1: warnings being treated as errors /src/lib/libstand/zalloc_malloc.c: In function 'Free': /src/lib/libstand/zalloc_malloc.c:113: warning: format '%d' expects type 'int', but argument 3 has type 'long unsigned int' *** Error code 1 Stop in /src/lib/libstand. *** Error code 1 Stop in /src/lib. *** Error code 1 Stop in /src. *** Error code 1 Stop in /src. *** Error code 1 Stop in /src. *** Error code 1 Stop in /src. TB --- 2011-06-16 15:46:18 - WARNING: /usr/bin/make returned exit code 1 TB --- 2011-06-16 15:46:18 - ERROR: failed to build world TB --- 2011-06-16 15:46:18 - 1249.61 user 284.80 system 1560.80 real http://tinderbox.freebsd.org/tinderbox-head-HEAD-sparc64-sparc64.full From owner-freebsd-sparc64@FreeBSD.ORG Thu Jun 16 19:07:42 2011 Return-Path: Delivered-To: sparc64@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id EA6D71065676; Thu, 16 Jun 2011 19:07:42 +0000 (UTC) (envelope-from tinderbox@freebsd.org) Received: from freebsd-current.sentex.ca (freebsd-current.sentex.ca [64.7.128.98]) by mx1.freebsd.org (Postfix) with ESMTP id 8CC468FC14; Thu, 16 Jun 2011 19:07:42 +0000 (UTC) Received: from freebsd-current.sentex.ca (localhost [127.0.0.1]) by freebsd-current.sentex.ca (8.14.4/8.14.4) with ESMTP id p5GJ7fDF035248; Thu, 16 Jun 2011 15:07:41 -0400 (EDT) (envelope-from tinderbox@freebsd.org) Received: (from tinderbox@localhost) by freebsd-current.sentex.ca (8.14.4/8.14.4/Submit) id p5GJ7fAj035247; Thu, 16 Jun 2011 19:07:41 GMT (envelope-from tinderbox@freebsd.org) Date: Thu, 16 Jun 2011 19:07:41 GMT Message-Id: <201106161907.p5GJ7fAj035247@freebsd-current.sentex.ca> X-Authentication-Warning: freebsd-current.sentex.ca: tinderbox set sender to FreeBSD Tinderbox using -f Sender: FreeBSD Tinderbox From: FreeBSD Tinderbox To: FreeBSD Tinderbox , , Precedence: bulk Cc: Subject: [head tinderbox] failure on sparc64/sparc64 X-BeenThere: freebsd-sparc64@freebsd.org X-Mailman-Version: 2.1.5 List-Id: Porting FreeBSD to the Sparc List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Thu, 16 Jun 2011 19:07:43 -0000 TB --- 2011-06-16 18:42:14 - tinderbox 2.7 running on freebsd-current.sentex.ca TB --- 2011-06-16 18:42:14 - starting HEAD tinderbox run for sparc64/sparc64 TB --- 2011-06-16 18:42:14 - cleaning the object tree TB --- 2011-06-16 18:42:19 - cvsupping the source tree TB --- 2011-06-16 18:42:19 - /usr/bin/csup -z -r 3 -g -L 1 -h cvsup.sentex.ca /tinderbox/HEAD/sparc64/sparc64/supfile TB --- 2011-06-16 18:42:33 - building world TB --- 2011-06-16 18:42:33 - MAKEOBJDIRPREFIX=/obj TB --- 2011-06-16 18:42:33 - PATH=/usr/bin:/usr/sbin:/bin:/sbin TB --- 2011-06-16 18:42:33 - TARGET=sparc64 TB --- 2011-06-16 18:42:33 - TARGET_ARCH=sparc64 TB --- 2011-06-16 18:42:33 - TZ=UTC TB --- 2011-06-16 18:42:33 - __MAKE_CONF=/dev/null TB --- 2011-06-16 18:42:33 - cd /src TB --- 2011-06-16 18:42:33 - /usr/bin/make -B buildworld >>> World build started on Thu Jun 16 18:42:33 UTC 2011 >>> Rebuilding the temporary build tree >>> stage 1.1: legacy release compatibility shims >>> stage 1.2: bootstrap tools >>> stage 2.1: cleaning up the object tree >>> stage 2.2: rebuilding the object tree >>> stage 2.3: build tools >>> stage 3: cross tools >>> stage 4.1: building includes >>> stage 4.2: building libraries [...] /src/lib/libstand/qdivrem.c:222: warning: left shift count >= width of type /src/lib/libstand/qdivrem.c:233: warning: left shift count >= width of type /src/lib/libstand/qdivrem.c:234: warning: left shift count >= width of type /src/lib/libstand/qdivrem.c:234: warning: left shift count >= width of type /src/lib/libstand/qdivrem.c:237: warning: left shift count >= width of type /src/lib/libstand/qdivrem.c:248: warning: left shift count >= width of type /src/lib/libstand/qdivrem.c:251: warning: left shift count >= width of type /src/lib/libstand/qdivrem.c:265: warning: left shift count >= width of type *** Error code 1 Stop in /src/lib/libstand. *** Error code 1 Stop in /src/lib. *** Error code 1 Stop in /src. *** Error code 1 Stop in /src. *** Error code 1 Stop in /src. *** Error code 1 Stop in /src. TB --- 2011-06-16 19:07:41 - WARNING: /usr/bin/make returned exit code 1 TB --- 2011-06-16 19:07:41 - ERROR: failed to build world TB --- 2011-06-16 19:07:41 - 1220.72 user 275.48 system 1527.39 real http://tinderbox.freebsd.org/tinderbox-head-HEAD-sparc64-sparc64.full From owner-freebsd-sparc64@FreeBSD.ORG Fri Jun 17 18:07:18 2011 Return-Path: Delivered-To: freebsd-sparc64@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 3AEDC106566B; Fri, 17 Jun 2011 18:07:18 +0000 (UTC) (envelope-from marius@alchemy.franken.de) Received: from alchemy.franken.de (alchemy.franken.de [194.94.249.214]) by mx1.freebsd.org (Postfix) with ESMTP id 94E2B8FC12; Fri, 17 Jun 2011 18:07:17 +0000 (UTC) Received: from alchemy.franken.de (localhost [127.0.0.1]) by alchemy.franken.de (8.14.4/8.14.4/ALCHEMY.FRANKEN.DE) with ESMTP id p5HI7D8j005658; Fri, 17 Jun 2011 20:07:13 +0200 (CEST) (envelope-from marius@alchemy.franken.de) Received: (from marius@localhost) by alchemy.franken.de (8.14.4/8.14.4/Submit) id p5HI7Dgm005657; Fri, 17 Jun 2011 20:07:13 +0200 (CEST) (envelope-from marius) Date: Fri, 17 Jun 2011 20:07:13 +0200 From: Marius Strobl To: Nathaniel W Filardo Message-ID: <20110617180713.GA5300@alchemy.franken.de> References: <20110616073138.GL31996@gradx.cs.jhu.edu> <20110616075319.GM31996@gradx.cs.jhu.edu> Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <20110616075319.GM31996@gradx.cs.jhu.edu> User-Agent: Mutt/1.4.2.3i Cc: freebsd-current@freebsd.org, freebsd-sparc64@freebsd.org Subject: Re: TLS bug? X-BeenThere: freebsd-sparc64@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: Porting FreeBSD to the Sparc List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Fri, 17 Jun 2011 18:07:18 -0000 On Thu, Jun 16, 2011 at 03:53:19AM -0400, Nathaniel W Filardo wrote: > Atcht; it's late. I forgot to mention that this system is a sparc64 V240 > 2-way SMP machine. It's running a kernel from 9.0-CURRENT r222833+262af52: > Tue Jun 7 18:47:35 EDT 2011 and a userland from a little later. > > Sorry about that. > --nwf; > > On Thu, Jun 16, 2011 at 03:31:38AM -0400, Nathaniel W Filardo wrote: > > I have a few applications (bonnie++ and mysql, specifically, both from > > ports) which trip over the assertion in > > lib/libc/stdlib/malloc.c:/^_malloc_thread_cleanup that > > > assert(tcache != (void *)(uintptr_t)1); > > > > I have patched malloc.c thus: > > > > > --- a/lib/libc/stdlib/malloc.c > > > +++ b/lib/libc/stdlib/malloc.c > > > @@ -1108,7 +1108,7 @@ static __thread arena_t *arenas_map TLS_MODEL; > > > > > > #ifdef MALLOC_TCACHE > > > /* Map of thread-specific caches. */ > > > -static __thread tcache_t *tcache_tls TLS_MODEL; > > > +__thread tcache_t *tcache_tls TLS_MODEL; > > > > > > /* > > > * Number of cache slots for each bin in the thread cache, or 0 if tcache > > > * is > > > @@ -6184,10 +6184,17 @@ _malloc_thread_cleanup(void) > > > #ifdef MALLOC_TCACHE > > > tcache_t *tcache = tcache_tls; > > > > > > + fprintf(stderr, "_m_t_c for %d:%lu with %p\n", > > > + getpid(), > > > + (unsigned long) _pthread_self(), > > > + tcache); > > > + > > > if (tcache != NULL) { > > > - assert(tcache != (void *)(uintptr_t)1); > > > - tcache_destroy(tcache); > > > - tcache_tls = (void *)(uintptr_t)1; > > > + /* assert(tcache != (void *)(uintptr_t)1); */ > > > + if((uintptr_t)tcache != (uintptr_t)1) { > > > + tcache_destroy(tcache); > > > + tcache_tls = (void *)(uintptr_t)1; > > > + } > > > > and libthr/thread/thr_create.c thus: > > > > > --- a/lib/libthr/thread/thr_create.c > > > +++ b/lib/libthr/thread/thr_create.c > > > @@ -243,6 +243,8 @@ create_stack(struct pthread_attr *pattr) > > > return (ret); > > > } > > > > > > +extern __thread void *tcache_tls; > > > + > > > static void > > > thread_start(struct pthread *curthread) > > > { > > > @@ -280,6 +282,11 @@ thread_start(struct pthread *curthread) > > > curthread->attr.stacksize_attr; > > > #endif > > > > > > + fprintf(stderr, "t_s for %d:%lu with %p\n", > > > + getpid(), > > > + (unsigned long) _pthread_self(), > > > + tcache_tls); > > > + > > > /* Run the current thread's start routine with argument: */ > > > _pthread_exit(curthread->start_routine(curthread->arg)); > > > > > > > to attempt to debug this issue. With those changes in place, bonnie++'s > > execution looks like this: > > > > >[...] > > > Writing a byte at a time...done > > > Writing intelligently...done > > > Rewriting...done > > > Reading a byte at a time...done > > > Reading intelligently...done > > > t_s for 79654:1086343168 with 0x0 > > > t_s for 79654:1086345216 with 0x0 > > > t_s for 79654:1086346240 with 0x0 > > > t_s for 79654:1086347264 with 0x0 > > > t_s for 79654:1086344192 with 0x0 > > > start 'em...done...done...done...done..._m_t_c for 79654:1086344192 with > > > 0x41404400 > > > _m_t_c for 79654:1086346240 with 0x40d2c400 > > > _m_t_c for 79654:1086343168 with 0x41404200 > > > _m_t_c for 79654:1086345216 with 0x41804200 > > > done... > > > _m_t_c for 79654:1086347264 with 0x41004200 > > > Create files in sequential order...done. > > > Stat files in sequential order...done. > > > Delete files in sequential order...done. > > > Create files in random order...done. > > > Stat files in random order...done. > > > Delete files in random order...done. > > > 1.96,1.96,hydra.priv.oc.ietfng.org,1,1308217772,10M,,7,81,2644,7,3577,14,34,93,+++++,+++,773.7,61,16,,, > > > ,,2325,74,13016,99,2342,86,3019,91,11888,99,2184,89,16397ms,1237ms,671ms,2009ms,177us,1305ms,489ms,1029 > > > us,270ms,140ms,53730us,250ms > > > Writing a byte at a time...done > > > Writing intelligently...done > > > Rewriting...done > > > Reading a byte at a time...done > > > Reading intelligently...done > > > t_s for 79654:1086343168 with 0x1 > > > t_s for 79654:1086346240 with 0x1 > > > t_s for 79654:1086345216 with 0x1 > > > t_s for 79654:1086347264 with 0x1 > > > t_s for 79654:1086344192 with 0x1 > > > start 'em...done...done...done...done...done... > > > _m_t_c for 79654:1086347264 with 0x1 > > > _m_t_c for 79654:1086344192 with 0x1 > > > _m_t_c for 79654:1086343168 with 0x1 > > >[...] > > > > So what seems to be happening is that the TLS area is being set up > > incorrectly, eventually: rather than zeroing the tcache_tls value, it is > > being set to 1, which means no tcache is ever allocated, so when we get > > around to exiting, the assert trips. > > > > Unfortunately, setting a breakpoint on __libc_allocate_tls seems to do bad > > things to the kernel (inducing a SIR without any panic message). I am > > somewhat at a loss; help? > > Using bonnie++ I can't reproduce this (didn't try mysql) but I have some TLS fixes for libthr I forgot about but could be relevant here (most actually date back to 2008 when the base binutils didn't support GNUTLS for sparc64 so I couldn't test them easily). Could you please give a libthr build with the following patch a try? http://people.freebsd.org/~marius/libthr_sparc64.diff Marius From owner-freebsd-sparc64@FreeBSD.ORG Fri Jun 17 21:35:37 2011 Return-Path: Delivered-To: freebsd-sparc64@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id B66FB1065673; Fri, 17 Jun 2011 21:35:37 +0000 (UTC) (envelope-from marius@alchemy.franken.de) Received: from alchemy.franken.de (alchemy.franken.de [194.94.249.214]) by mx1.freebsd.org (Postfix) with ESMTP id D19EF8FC23; Fri, 17 Jun 2011 21:35:35 +0000 (UTC) Received: from alchemy.franken.de (localhost [127.0.0.1]) by alchemy.franken.de (8.14.4/8.14.4/ALCHEMY.FRANKEN.DE) with ESMTP id p5HLZXiB006758; Fri, 17 Jun 2011 23:35:33 +0200 (CEST) (envelope-from marius@alchemy.franken.de) Received: (from marius@localhost) by alchemy.franken.de (8.14.4/8.14.4/Submit) id p5HLZWqk006757; Fri, 17 Jun 2011 23:35:32 +0200 (CEST) (envelope-from marius) Date: Fri, 17 Jun 2011 23:35:32 +0200 From: Marius Strobl To: Nathaniel W Filardo , jasone@freebsd.org Message-ID: <20110617213532.GG7064@alchemy.franken.de> References: <20110616073138.GL31996@gradx.cs.jhu.edu> <20110616075319.GM31996@gradx.cs.jhu.edu> <20110617180713.GA5300@alchemy.franken.de> <20110617193129.GC4764@gradx.cs.jhu.edu> Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <20110617193129.GC4764@gradx.cs.jhu.edu> User-Agent: Mutt/1.4.2.3i Cc: freebsd-current@freebsd.org, freebsd-sparc64@freebsd.org Subject: Re: TLS bug? X-BeenThere: freebsd-sparc64@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: Porting FreeBSD to the Sparc List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Fri, 17 Jun 2011 21:35:37 -0000 On Fri, Jun 17, 2011 at 03:31:29PM -0400, Nathaniel W Filardo wrote: > On Fri, Jun 17, 2011 at 08:07:13PM +0200, Marius Strobl wrote: > > Using bonnie++ I can't reproduce this (didn't try mysql) but I have > > I seem to have good luck reproducing it with "-r 5 -s 10 -x 10" by about the > third iteration. Ok, with these parameters I can reproduce it. > > > some TLS fixes for libthr I forgot about but could be relevant here > > (most actually date back to 2008 when the base binutils didn't support > > GNUTLS for sparc64 so I couldn't test them easily). Could you please > > give a libthr build with the following patch a try? > > http://people.freebsd.org/~marius/libthr_sparc64.diff > > Concurrent runs both with and without those diffs still asserted. > Interestingly, libc's .tbss section, even after the assertion, is still full > of zeros, so it looks like something stranger than a wild-write back to > .tbss. I'll go diving through the tls allocation code again when I get a > minute. > In combination with the below patch bonnie++ survived 100 iterations here. I'm not sure what this means though as I don't have much knowledge about TLS, I merely implemented the necessary relocations. Could be that malloc() actually requires the initial exec model for variant II. Unfortunately, it's not documented why it was added for x86. Jason, can you shed some light on this? Marius Index: malloc.c =================================================================== --- malloc.c (revision 219535) +++ malloc.c (working copy) @@ -234,7 +234,7 @@ #ifdef __sparc64__ # define LG_QUANTUM 4 # define LG_SIZEOF_PTR 3 -# define TLS_MODEL /* default */ +# define TLS_MODEL __attribute__((tls_model("initial-exec"))) #endif #ifdef __amd64__ # define LG_QUANTUM 4