From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 9222 invoked by alias); 16 Jun 2011 20:35:17 -0000 Received: (qmail 9082 invoked by uid 22791); 16 Jun 2011 20:35:15 -0000 X-SWARE-Spam-Status: No, hits=-2.1 required=5.0 tests=AWL,BAYES_00,DKIM_SIGNED,DKIM_VALID,DKIM_VALID_AU,FREEMAIL_FROM,RCVD_IN_DNSWL_LOW,RFC_ABUSE_POST,TW_MX X-Spam-Check-By: sourceware.org Received: from mail-pv0-f175.google.com (HELO mail-pv0-f175.google.com) (74.125.83.175) by sourceware.org (qpsmtpd/0.43rc1) with ESMTP; Thu, 16 Jun 2011 20:34:55 +0000 Received: by pvc30 with SMTP id 30so1438798pvc.20 for ; Thu, 16 Jun 2011 13:34:54 -0700 (PDT) MIME-Version: 1.0 Received: by 10.68.16.1 with SMTP id b1mr739899pbd.470.1308256493804; Thu, 16 Jun 2011 13:34:53 -0700 (PDT) Received: by 10.68.47.69 with HTTP; Thu, 16 Jun 2011 13:34:53 -0700 (PDT) In-Reply-To: References: <20110615095406.GI17079@tyan-ft48-01.lab.bos.redhat.com> Date: Thu, 16 Jun 2011 20:42:00 -0000 Message-ID: Subject: Re: [PATCH] Fix ICEs with -mxop __builtin_ia32_vpermil2p[sd]{,256} and __builtin_ia32_vprot[bwdq]i intrinsics (PR target/49411) From: Quentin Neill To: Jakub Jelinek Cc: Uros Bizjak , Sebastian Pop , "Fang, Changpeng" , gcc-patches@gcc.gnu.org Content-Type: text/plain; charset=ISO-8859-1 Content-Transfer-Encoding: quoted-printable X-IsSubscribed: yes Mailing-List: contact gcc-patches-help@gcc.gnu.org; run by ezmlm Precedence: bulk List-Id: List-Archive: List-Post: List-Help: Sender: gcc-patches-owner@gcc.gnu.org X-SW-Source: 2011-06/txt/msg01296.txt.bz2 On Wed, Jun 15, 2011 at 11:40 AM, Quentin Neill wrote: > On Wed, Jun 15, 2011 at 4:54 AM, Jakub Jelinek wrote: >> Hi! >> >> All of these _mm{,256}_permute2_p[sd] and _mm_roti_epi{8,16,32,64} >> intrinsics ICE if the last argument is constant integer, but not in the >> expected range. >> >> I could only find MSFT documentation for these intrinsics, where for >> *permute2* it says that the last argument must be 0, 1, 2 or 3, >> for *roti* it says that the last argument is integer rotation count, >> preferrably constant and that if count is negative, it performs right >> rotation instead of left rotation. >> This patch adjusts the builtins to match that, if we want to instead >> e.g. always mandate _mm_roti_epi* last argument is constant integer, >> or constant integer in the range -N+1 .. N-1 where N is the number >> after _mm_roti_epi, or in the range 0 .. N-1, it can be easily adjusted. >> >> Regtested on x86_64-linux {-m32,-m64}, unfortunately on a SandyBridge >> box, so I couldn't verify if xop-rotate[12]-int.c actually succeeds >> on xop capable HW. >> >> [snip] >> >> =A0 =A0 =A0 =A0Jakub >> > > I will test on AMD HW. > -- > Quentin Regtested on x86_64-linux on AMD Family 16h, and verified the xop-rotate[12]-int tests ran and passed. --=20 Quentin