From owner-freebsd-current@FreeBSD.ORG Tue Jun 19 06:44:11 2007 Return-Path: X-Original-To: current@freebsd.org Delivered-To: freebsd-current@FreeBSD.ORG Received: from mx1.freebsd.org (mx1.freebsd.org [69.147.83.52]) by hub.freebsd.org (Postfix) with ESMTP id 481B316A41F for ; Tue, 19 Jun 2007 06:44:11 +0000 (UTC) (envelope-from youshi10@u.washington.edu) Received: from mxout5.cac.washington.edu (mxout5.cac.washington.edu [140.142.32.135]) by mx1.freebsd.org (Postfix) with ESMTP id 269FF13C455 for ; Tue, 19 Jun 2007 06:44:11 +0000 (UTC) (envelope-from youshi10@u.washington.edu) Received: from smtp.washington.edu (smtp.washington.edu [140.142.32.141] (may be forged)) by mxout5.cac.washington.edu (8.13.7+UW06.06/8.13.7+UW07.05) with ESMTP id l5J6i7OK000992 (version=TLSv1/SSLv3 cipher=DHE-RSA-AES256-SHA bits=256 verify=OK) for ; Mon, 18 Jun 2007 23:44:08 -0700 X-Auth-Received: from [192.168.10.45] (c-24-10-12-194.hsd1.ca.comcast.net [24.10.12.194]) (authenticated authid=youshi10) by smtp.washington.edu (8.13.7+UW06.06/8.13.7+UW07.03) with ESMTP id l5J6i7IR013009 (version=TLSv1/SSLv3 cipher=DHE-RSA-AES256-SHA bits=256 verify=NOT) for ; Mon, 18 Jun 2007 23:44:07 -0700 Message-ID: <46777B36.6080608@u.washington.edu> Date: Mon, 18 Jun 2007 23:44:06 -0700 From: Garrett Cooper User-Agent: Thunderbird 2.0.0.4 (Windows/20070604) MIME-Version: 1.0 To: current@freebsd.org References: In-Reply-To: Content-Type: text/plain; charset=ISO-8859-1; format=flowed Content-Transfer-Encoding: 7bit X-PMX-Version: 5.3.1.294258, Antispam-Engine: 2.5.1.298604, Antispam-Data: 2007.6.18.232232 X-Uwash-Spam: Gauge=IIIIIII, Probability=7%, Report='__CP_URI_IN_BODY 0, __CT 0, __CTE 0, __CT_TEXT_PLAIN 0, __FRAUD_419_BADTHINGS 0, __HAS_MSGID 0, __MIME_TEXT_ONLY 0, __MIME_VERSION 0, __SANE_MSGID 0, __USER_AGENT 0' Cc: Subject: Re: [AMD64] X.org build eats all the memory when compiled with GCC 4.2 X-BeenThere: freebsd-current@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: Discussions about the use of FreeBSD-current List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 19 Jun 2007 06:44:11 -0000 youshi10@u.washington.edu wrote: > On Mon, 18 Jun 2007, Kris Kennaway wrote: > >> On Mon, Jun 18, 2007 at 08:40:30AM -0400, Daniel Eischen wrote: >>> On Mon, 18 Jun 2007, Michiel Boland wrote: >>> >>>> On Sat, 16 Jun 2007, Garrett Cooper wrote: >>>> >>>>> Claus Guttesen wrote: >>>>>>> I recompiled X.org yesterday and hit the following problem >>>>>>> (1 week old -current, yesterdays packages, AMD64) -- when compiling >>>>>>> files in >>>>>>> /usr/ports/x11-servers/xorg-server/work/xorg-server-1.2.0/hw/xfree86/scanpci >>>>>>> >>>>>>> directory, there are huge .h files - about 4mb. when compiler >>>>>>> uses -O2 >>>>>>> or -O option it eats all available memory and then gets killed >>>>>>> by the >>>>>>> system. >>>>>>> Without -O/O2 option compile works just as expected. >>>>>>> >>>>>>> Now -- should I file a PR or it's known bug? >>>>>> >>>>>> No, but you should read the archives. Requires more than 1 GB of >>>>>> swap. >>>>>> >>>>> It's a known bug that isn't going to be fixed until gcc 4.2.1. >>>>> -Garrett >>>>> >>>> >>>> Well, until then, is it not possible to at least put the following >>>> patch >>>> in ports/x11-servers/xorg-server/files: >>> >>> [ ... ] >>> >>>> That would make a lot of people very happy. In particular those >>>> running >>>> amd64. >>> >>> Yes, it happens on i386 too. I think requiring more than 1GB of swap >>> is ridiculous. Please patch gcc or the port. >> >> You can test the new gcc snapshot here: >> >> http://people.freebsd.org/~kan/contrib-gcc421.tar.gz >> >> Just extract it over the top of /usr/src and rebuild world. Please >> confirm that it helps with this problem. >> >> Kris > > Ok, I'll give it a shot on my i386 and amd64 boxes when I get back > home tonight. > > FYI, from : > > > > I would like to try to keep the GCC 4.2.x release branch on the > time-driven release cycle for point releases that is part of the GCC > development plan. I left an embarrassing gap in the GCC 4.1.x release > cycle, and I plan to avoid that mistake for GCC 4.2.x. > > Therefore, I plan to make the GCC 4.2.1 release on or about July 13th. > As with the 4.2.0 release, I will be most concerned about P1 regressions > in 4.2.x, not present in 4.1.x. > > > > So the next release is just around the corner. Yay! > > Cheers, > -Garrett I'm double checking, but I'm pretty sure that snapshot does the trick. scanpci now compiles in 0.47 seconds and casually glancing at top it appears that memory usage doesn't go over 50 MB. This was done on a P4 machine with 2GB RAM synced yesterday and recompiled today with the gcc snapshot. I don't remember how much swap I had, but it was less than 2GB IIRC. That snapshot looks groovy and I'm really looking forward to the next release slipstreamed into base :). -Garrett