From patchwork Thu Jul 8 22:45:43 2010 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Michael Meissner X-Patchwork-Id: 58310 Return-Path: X-Original-To: incoming@patchwork.ozlabs.org Delivered-To: patchwork-incoming@bilbo.ozlabs.org Received: from sourceware.org (server1.sourceware.org [209.132.180.131]) by ozlabs.org (Postfix) with SMTP id 1429BB6F14 for ; Fri, 9 Jul 2010 08:45:59 +1000 (EST) Received: (qmail 31972 invoked by alias); 8 Jul 2010 22:45:56 -0000 Received: (qmail 31960 invoked by uid 22791); 8 Jul 2010 22:45:54 -0000 X-SWARE-Spam-Status: No, hits=-1.4 required=5.0 tests=AWL, BAYES_00, NO_DNS_FOR_FROM, T_RP_MATCHES_RCVD X-Spam-Check-By: sourceware.org Received: from e7.ny.us.ibm.com (HELO e7.ny.us.ibm.com) (32.97.182.137) by sourceware.org (qpsmtpd/0.43rc1) with ESMTP; Thu, 08 Jul 2010 22:45:47 +0000 Received: from d01relay03.pok.ibm.com (d01relay03.pok.ibm.com [9.56.227.235]) by e7.ny.us.ibm.com (8.14.4/8.13.1) with ESMTP id o68MXSE1002009 for ; Thu, 8 Jul 2010 18:33:28 -0400 Received: from d01av02.pok.ibm.com (d01av02.pok.ibm.com [9.56.224.216]) by d01relay03.pok.ibm.com (8.13.8/8.13.8/NCO v10.0) with ESMTP id o68Mji8B145254 for ; Thu, 8 Jul 2010 18:45:45 -0400 Received: from d01av02.pok.ibm.com (loopback [127.0.0.1]) by d01av02.pok.ibm.com (8.14.4/8.13.1/NCO v10.0 AVout) with ESMTP id o68MjiT1002266 for ; Thu, 8 Jul 2010 19:45:44 -0300 Received: from hungry-tiger.westford.ibm.com (dyn9033037152.westford.ibm.com [9.33.37.152]) by d01av02.pok.ibm.com (8.14.4/8.13.1/NCO v10.0 AVin) with ESMTP id o68MjidM002262; Thu, 8 Jul 2010 19:45:44 -0300 Received: from hungry-tiger.westford.ibm.com (hungry-tiger.westford.ibm.com [127.0.0.1]) by hungry-tiger.westford.ibm.com (Postfix) with ESMTP id 38B6034CF; Thu, 8 Jul 2010 18:45:44 -0400 (EDT) Received: (from meissner@localhost) by hungry-tiger.westford.ibm.com (8.14.3/8.14.3/Submit) id o68MjhpZ021982; Thu, 8 Jul 2010 18:45:43 -0400 Date: Thu, 8 Jul 2010 18:45:43 -0400 From: Michael Meissner To: gcc-patches@gcc.gnu.org, dje.gcc@gmail.com Subject: [PATCH] Fix target/44877 (powerpc vectorization failure) Message-ID: <20100708224543.GA21020@hungry-tiger.westford.ibm.com> Mail-Followup-To: Michael Meissner , gcc-patches@gcc.gnu.org, dje.gcc@gmail.com MIME-Version: 1.0 Content-Disposition: inline User-Agent: Mutt/1.5.20 (2009-08-17) X-IsSubscribed: yes Mailing-List: contact gcc-patches-help@gcc.gnu.org; run by ezmlm Precedence: bulk List-Id: List-Unsubscribe: List-Archive: List-Post: List-Help: Sender: gcc-patches-owner@gcc.gnu.org Delivered-To: mailing list gcc-patches@gcc.gnu.org This patch fixes target/44877 which allows dealII to be compiled on powerpc systems with either Altivec or VSX vector instruction sets. I have done a bootstrap with the compiler and verified that there are no regressions in the C, C++, and fortran testsuites. Is this ok to install? Index: gcc/config/rs6000/rs6000.c =================================================================== --- gcc/config/rs6000/rs6000.c (revision 161930) +++ gcc/config/rs6000/rs6000.c (working copy) @@ -11522,7 +11522,7 @@ rs6000_expand_builtin (tree exp, rtx tar gcc_assert (TARGET_ALTIVEC); arg = CALL_EXPR_ARG (exp, 0); - gcc_assert (TREE_CODE (TREE_TYPE (arg)) == POINTER_TYPE); + gcc_assert (POINTER_TYPE_P (TREE_TYPE (arg))); op = expand_expr (arg, NULL_RTX, Pmode, EXPAND_NORMAL); addr = memory_address (mode, op); if (fcode == ALTIVEC_BUILTIN_MASK_FOR_STORE)