From owner-freebsd-current@FreeBSD.ORG Sat Nov 22 17:01:42 2014 Return-Path: Delivered-To: freebsd-current@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [8.8.178.115]) (using TLSv1.2 with cipher AECDH-AES256-SHA (256/256 bits)) (No client certificate requested) by hub.freebsd.org (Postfix) with ESMTPS id 94596965 for ; Sat, 22 Nov 2014 17:01:42 +0000 (UTC) Received: from tensor.andric.com (tensor.andric.com [87.251.56.140]) (using TLSv1 with cipher DHE-RSA-CAMELLIA256-SHA (256/256 bits)) (Client CN "tensor.andric.com", Issuer "COMODO RSA Domain Validation Secure Server CA" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4EA6F91C for ; Sat, 22 Nov 2014 17:01:41 +0000 (UTC) Received: from [IPv6:2001:7b8:3a7::b130:3e2f:8715:b8f9] (unknown [IPv6:2001:7b8:3a7:0:b130:3e2f:8715:b8f9]) (using TLSv1 with cipher DHE-RSA-AES256-SHA (256/256 bits)) (No client certificate requested) by tensor.andric.com (Postfix) with ESMTPSA id 5AF67B80A; Sat, 22 Nov 2014 18:01:31 +0100 (CET) Subject: Re: How much memory do I need for buildworld? Mime-Version: 1.0 (Mac OS X Mail 8.1 \(1993\)) Content-Type: multipart/signed; boundary="Apple-Mail=_B193BAA1-52EF-4874-A31C-E0CF6B8FACD5"; protocol="application/pgp-signature"; micalg=pgp-sha1 X-Pgp-Agent: GPGMail 2.5b1 From: Dimitry Andric In-Reply-To: Date: Sat, 22 Nov 2014 18:01:23 +0100 Message-Id: <5EBF0BB1-1E2A-4517-A7BB-22FD3150FF06@FreeBSD.org> References: To: Rostislav Krasny X-Mailer: Apple Mail (2.1993) Cc: freebsd-current@freebsd.org X-BeenThere: freebsd-current@freebsd.org X-Mailman-Version: 2.1.18-1 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: Sat, 22 Nov 2014 17:01:42 -0000 --Apple-Mail=_B193BAA1-52EF-4874-A31C-E0CF6B8FACD5 Content-Transfer-Encoding: quoted-printable Content-Type: text/plain; charset=us-ascii On 22 Nov 2014, at 16:51, Rostislav Krasny wrote: > I've a fresh FreeBSD 10.1 installed on an old 32-bit machine. I've > checked out revision 274850 of the base sources and ran 'make > buildworld'. After some time it has failed: >=20 > =3D=3D=3D> lib/clang/libllvmx86disassembler (depend) > tblgen -gen-disassembler -I > = /usr/src/lib/clang/libllvmx86disassembler/../../../contrib/llvm/include > -I = /usr/src/lib/clang/libllvmx86disassembler/../../../contrib/llvm/lib/Target= /X86 > -d X86GenDisassemblerTables.inc.d -o X86GenDisassemblerTables.inc.h > = /usr/src/lib/clang/libllvmx86disassembler/../../../contrib/llvm/lib/Target= /X86/X86.td > *** Signal 9 >=20 > Stop. > make[4]: stopped in /usr/src/lib/clang/libllvmx86disassembler > *** Error code 1 >=20 >=20 > According to /var/log/messages it was killed because of out of memory: >=20 > Nov 22 16:55:13 mercury kernel: swap_pager: out of swap space > Nov 22 16:55:13 mercury kernel: swap_pager_getswapspace(16): failed > Nov 22 16:55:13 mercury kernel: pid 22841 (tblgen), uid 0, was killed: > out of swap space >=20 > This machine has 256MB of RAM and one 64MB swap partition. This is most likely the problem: you need more RAM for this particular instance of tblgen. On my -CURRENT i386 box, it takes ~369MiB of RSS to build the X86 disassembler tables. I'm surprised you didn't run into OOM problems earlier, with so little memory. For such "router" like machines, it is obviously easier to do the build on a fast desktop machine, then install over NFS, or rsync /usr/src and /usr/obj to the target machine. > Previously > I used FreeBSD 7.4-CURRENT on this machine with two swap partitions of > 64MB each and never had such a problem. I use it as a router, i.e. > there is no X and no other memory greedy processes. Yes, 7.4 is much smaller, and does not have any big C++ programs in it, so a buildworld is more likely to succeed on small memory machines. > Could it be related to an llvm bug fixed by following commit? >=20 > http://svnweb.freebsd.org/base?view=3Drevision&revision=3D274696 No, this is unlikely. This problem only occurred 1) in the compiler itself, 2) very specific ports, and 3) when compiling with debug info enabled. -Dimitry --Apple-Mail=_B193BAA1-52EF-4874-A31C-E0CF6B8FACD5 Content-Transfer-Encoding: 7bit Content-Disposition: attachment; filename=signature.asc Content-Type: application/pgp-signature; name=signature.asc Content-Description: Message signed with OpenPGP using GPGMail -----BEGIN PGP SIGNATURE----- Version: GnuPG/MacGPG2 v2.0.26 iEYEARECAAYFAlRwwWkACgkQsF6jCi4glqMNHQCg3vLIGho553FMm50mRgLFRWvx dNwAoJyvpjuhMi0W7rpSYcIarAD+Yrxj =ShNo -----END PGP SIGNATURE----- --Apple-Mail=_B193BAA1-52EF-4874-A31C-E0CF6B8FACD5--