Received: from mailman by lists.gnu.org with tmda-scanned (Exim 4.43) id 1NwjSL-0006g9-Ay for qemu-devel@nongnu.org; Tue, 30 Mar 2010 17:58:41 -0400 Received: from [140.186.70.92] (port=40923 helo=eggs.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1NwjSI-0006fu-R0 for qemu-devel@nongnu.org; Tue, 30 Mar 2010 17:58:40 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.69) (envelope-from ) id 1NwjSG-0005cV-UR for qemu-devel@nongnu.org; Tue, 30 Mar 2010 17:58:38 -0400 Received: from gelbbaer.kn-bremen.de ([78.46.108.116]:34921 helo=smtp.kn-bremen.de) by eggs.gnu.org with esmtp (Exim 4.69) (envelope-from ) id 1NwjSG-0005cN-Mu for qemu-devel@nongnu.org; Tue, 30 Mar 2010 17:58:36 -0400 From: Juergen Lock Date: Tue, 30 Mar 2010 23:57:12 +0200 Subject: Re: [Qemu-devel] qemu git head 20100323 on FreeBSD - qemu-devel port update for testing Message-ID: <20100330215712.GA6901@triton8.kn-bremen.de> References: <20100325204423.GA46954@triton8.kn-bremen.de> <20100330191629.GA95521@triton8.kn-bremen.de> <201003302009.o2UK9lAv002282@triton8.kn-bremen.de> <4BB2600B.90002@twiddle.net> <20100330204548.GA4359@triton8.kn-bremen.de> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <20100330204548.GA4359@triton8.kn-bremen.de> List-Id: qemu-devel.nongnu.org List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , To: Juergen Lock Cc: qemu-devel@nongnu.org, Blue Swirl , freebsd-emulation@freebsd.org, Andreas Tobler , Richard Henderson , Toni On Tue, Mar 30, 2010 at 10:45:48PM +0200, Juergen Lock wrote: > On Tue, Mar 30, 2010 at 01:33:15PM -0700, Richard Henderson wrote: > > On 03/30/2010 01:09 PM, Juergen Lock wrote: > > > Oh sorry if that was not clear, things go into swap if I _replace_ the > > > endaddr ~0ul (which caused the assert) with the max value the assert > > > still tolerates i.e. > > > ((abi_ulong)1 << L1_MAP_ADDR_SPACE_BITS) - 1 > > > which in this case seems to be 0x7fffffffffff: > > > > Yes, I got that. And I see from ... > > > > > #3 0x0000000060012731 in page_set_flags (start=140737488224256, > > > end=18446744073709551615, flags=32) > > > > ... here that the range we're reserving is > > > > 0x7ffffffe0000 ... 0x7fffffffffff > > > > which is a mere 128k range. Which ought to allocate no more than > > a single leaf page table (and thus N-1 pages for the N-level table). > > > > Which doesn't answer the question of why you'd wind up running out > > of memory. > > Ah yeah our mails crossed each other :) Yeah I don't know... Ok found the problem: Reads from /compat/linux/proc/self/maps are broken i.e. return partial lines if (at least I think that's the reason) the mappings change between read() calls. (It got a line like this after the first line that originally caused the assert: fe0000-800000000000 rwxp 00020000 00:00 0 ) Well good that we now use kinfo_getvmmap(), I hope noone needs bsd-user on FreeBSD 6.x... Oh well... Juergen