From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from mailman by lists.gnu.org with tmda-scanned (Exim 4.43) id 1HypNr-0008Vi-MC for qemu-devel@nongnu.org; Thu, 14 Jun 2007 09:29:07 -0400 Received: from exim by lists.gnu.org with spam-scanned (Exim 4.43) id 1HypNp-0008Uw-W1 for qemu-devel@nongnu.org; Thu, 14 Jun 2007 09:29:07 -0400 Received: from [199.232.76.173] (helo=monty-python.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1HypNp-0008Up-No for qemu-devel@nongnu.org; Thu, 14 Jun 2007 09:29:05 -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 1HypNo-00086K-NZ for qemu-devel@nongnu.org; Thu, 14 Jun 2007 09:29:05 -0400 From: Paul Brook Subject: Re: [Qemu-devel] CPUTLBEntry Question Date: Thu, 14 Jun 2007 14:22:12 +0100 References: <812074ac0706131325t578dfd5eiaa5836b160a24679@mail.gmail.com> In-Reply-To: <812074ac0706131325t578dfd5eiaa5836b160a24679@mail.gmail.com> MIME-Version: 1.0 Content-Type: text/plain; charset="iso-8859-1" Content-Transfer-Encoding: 7bit Content-Disposition: inline Message-Id: <200706141422.13852.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: Ryan Riley > then QEMU crashes on startup. (It also crashes if I put that blah > entry on the beginning instead of the end.) I'm sure there's code > somewhere that must be making assumptions about the size of TLB entry, > but I'm at a loss for finding it. (I have noticed that the assembly > code in softmmu_header.h indexes to the addend based on addr_read or > addr_write, but adding a new member to the end of the structure > shouldn't impact that, right?) Wrong. The assembly implementation assumes CPUTLBEntry is 16 bytes (or to be exact 1 << CPU_TLB_ENTRY_BITS). The C implementation in softmmu_header.h will work with any layout. Paul