From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from mailman by lists.gnu.org with tmda-scanned (Exim 4.43) id 1JtOJ7-0003fP-TL for qemu-devel@nongnu.org; Tue, 06 May 2008 10:38:17 -0400 Received: from exim by lists.gnu.org with spam-scanned (Exim 4.43) id 1JtOJ6-0003es-Hw for qemu-devel@nongnu.org; Tue, 06 May 2008 10:38:17 -0400 Received: from [199.232.76.173] (port=40671 helo=monty-python.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1JtOJ6-0003ee-5u for qemu-devel@nongnu.org; Tue, 06 May 2008 10:38:16 -0400 Received: from mail.codesourcery.com ([65.74.133.4]) by monty-python.gnu.org with esmtps (TLS-1.0:DHE_RSA_AES_256_CBC_SHA1:32) (Exim 4.60) (envelope-from ) id 1JtO03-0005R2-5c for qemu-devel@nongnu.org; Tue, 06 May 2008 10:18:35 -0400 From: Paul Brook Subject: Re: [Qemu-devel] [4351] Make the paged properties of the tb-jmp-cache hash function work for TARGET_PAGE_BITS ! = 12. Date: Tue, 6 May 2008 15:18:25 +0100 References: <200805061331.03281.paul@codesourcery.com> <20080506140310.GG26816@edgar.se.axis.com> In-Reply-To: <20080506140310.GG26816@edgar.se.axis.com> MIME-Version: 1.0 Content-Type: text/plain; charset="ansi_x3.4-1968" Content-Transfer-Encoding: 7bit Content-Disposition: inline Message-Id: <200805061518.25575.paul@codesourcery.com> Reply-To: qemu-devel@nongnu.org List-Id: qemu-devel.nongnu.org List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , To: qemu-devel@nongnu.org Cc: "Edgar E. Iglesias" > > > - return (tmp >> TB_JMP_PAGE_BITS) & TB_JMP_PAGE_MASK; > > > + return (tmp >> (TARGET_PAGE_BITS - TB_JMP_PAGE_BITS)) & > > > TB_JMP_PAGE_MASK; } > > > > I'm not sure what you're trying to achieve here, but this is definitely > > wrong. TARGET_PAGE_BITS may be less than TB_JMP_PAGE_BITS. > > I didn't find any page bits under 10 in the tree. Oops, sorry, my bad. I read TB_JMP_PAGE_BITS as TB_JMP_CACHE_BITS-1, not /2. Paul