From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from mailman by lists.gnu.org with tmda-scanned (Exim 4.43) id 1KhVsI-0007jF-0O for qemu-devel@nongnu.org; Sun, 21 Sep 2008 16:49:46 -0400 Received: from exim by lists.gnu.org with spam-scanned (Exim 4.43) id 1KhVsF-0007j2-H9 for qemu-devel@nongnu.org; Sun, 21 Sep 2008 16:49:44 -0400 Received: from [199.232.76.173] (port=54000 helo=monty-python.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1KhVsF-0007iy-C1 for qemu-devel@nongnu.org; Sun, 21 Sep 2008 16:49:43 -0400 Received: from fe02x01-cgp.akado.ru ([77.232.31.161]:49510 helo=akado.ru) by monty-python.gnu.org with esmtp (Exim 4.60) (envelope-from ) id 1KhVsE-0002dt-Qa for qemu-devel@nongnu.org; Sun, 21 Sep 2008 16:49:43 -0400 Date: Mon, 22 Sep 2008 00:49:06 +0400 (MSD) From: malc Subject: Re: [Qemu-devel] x86 MMX register access problem seen on Sparc host In-Reply-To: Message-ID: References: MIME-Version: 1.0 Content-Type: TEXT/PLAIN; charset=US-ASCII; format=flowed 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 On Sun, 21 Sep 2008, Blue Swirl wrote: > Hi, > > I get these warnings when compiling i386 targets on Sparc host using a > gcc 4.3 series compiler: > /src/qemu/target-i386/ops_sse.h: In function 'helper_pmovmskb_mmx': > /src/qemu/target-i386/ops_sse.h:982: warning: array subscript is above > array bounds > etc. > > The first line is the following: > val |= (s->XMM_B(0) >> 7); All the lines before #if SHIFT == 1 should be MMX_B really. > > In cpu.h, the macro is defined on big endian host as > #define XMM_B(n) _b[15 - (n)] > > But the type of Reg argument is MMXReg for pmovmskb_mmx and then the > _b array has only 8 items. > > -- mailto:av1474@comtv.ru