From patchwork Mon Oct 22 18:33:18 2018 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Bill Schmidt X-Patchwork-Id: 987845 Return-Path: X-Original-To: incoming@patchwork.ozlabs.org Delivered-To: patchwork-incoming@bilbo.ozlabs.org Authentication-Results: ozlabs.org; spf=pass (mailfrom) smtp.mailfrom=gcc.gnu.org (client-ip=209.132.180.131; helo=sourceware.org; envelope-from=gcc-patches-return-488052-incoming=patchwork.ozlabs.org@gcc.gnu.org; receiver=) Authentication-Results: ozlabs.org; dmarc=none (p=none dis=none) header.from=linux.ibm.com Authentication-Results: ozlabs.org; dkim=pass (1024-bit key; unprotected) header.d=gcc.gnu.org header.i=@gcc.gnu.org header.b="KyuoXuDD"; dkim-atps=neutral Received: from sourceware.org (server1.sourceware.org [209.132.180.131]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by ozlabs.org (Postfix) with ESMTPS id 42f4sW68QGz9sCh for ; Tue, 23 Oct 2018 05:33:34 +1100 (AEDT) DomainKey-Signature: a=rsa-sha1; c=nofws; d=gcc.gnu.org; h=list-id :list-unsubscribe:list-archive:list-post:list-help:sender:to:cc :from:subject:date:mime-version:content-type :content-transfer-encoding:message-id; q=dns; s=default; b=Aqvui XqDFBhI3SiJQQkoiJC5iXQ8TP76p4qZb+flJqOkrGTRFKCqQxw5wh9KdTZxIOD3m WS0nJgiOFrW96lhQLENRDrc8np8Me5uBoOi4kSNCY2N5NmOegByhk8RrxktP5PLg rgGwAAlmbdsuAb+PVYNYhLQEtY1YeXzYql0Bqs= DKIM-Signature: v=1; a=rsa-sha1; c=relaxed; d=gcc.gnu.org; h=list-id :list-unsubscribe:list-archive:list-post:list-help:sender:to:cc :from:subject:date:mime-version:content-type :content-transfer-encoding:message-id; s=default; bh=pP94UzK7lAv /vJn7zfsQ0XfNQug=; b=KyuoXuDDz+jPJnm+eF3+tYaXMEB9/R31k84DHyJAhIP DHEeL4wSDcKxdNjckHG+5CYdduo0InUllMDqjx0jCFZXTq0ufPlHOxqVEc1gk/hI YoVu+xKv2JEqhdxU7quWzPvgZgOCYfkIKeiMVPHGvDHGD2PKzLMqOKtFnA+BmwWg = Received: (qmail 73673 invoked by alias); 22 Oct 2018 18:33:27 -0000 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 Received: (qmail 71970 invoked by uid 89); 22 Oct 2018 18:33:26 -0000 Authentication-Results: sourceware.org; auth=none X-Spam-SWARE-Status: No, score=-10.9 required=5.0 tests=AWL, BAYES_00, GIT_PATCH_2, GIT_PATCH_3, KHOP_DYNAMIC, RCVD_IN_DNSWL_LOW, SPF_PASS autolearn=ham version=3.3.2 spammy= X-HELO: mx0a-001b2d01.pphosted.com Received: from mx0a-001b2d01.pphosted.com (HELO mx0a-001b2d01.pphosted.com) (148.163.156.1) by sourceware.org (qpsmtpd/0.93/v0.84-503-g423c35a) with ESMTP; Mon, 22 Oct 2018 18:33:25 +0000 Received: from pps.filterd (m0098393.ppops.net [127.0.0.1]) by mx0a-001b2d01.pphosted.com (8.16.0.22/8.16.0.22) with SMTP id w9MIUK3q127247 for ; Mon, 22 Oct 2018 14:33:23 -0400 Received: from e31.co.us.ibm.com (e31.co.us.ibm.com [32.97.110.149]) by mx0a-001b2d01.pphosted.com with ESMTP id 2n9gy7rap8-1 (version=TLSv1.2 cipher=AES256-GCM-SHA384 bits=256 verify=NOT) for ; Mon, 22 Oct 2018 14:33:23 -0400 Received: from localhost by e31.co.us.ibm.com with IBM ESMTP SMTP Gateway: Authorized Use Only! Violators will be prosecuted for from ; Mon, 22 Oct 2018 12:33:22 -0600 Received: from b03cxnp08027.gho.boulder.ibm.com (9.17.130.19) by e31.co.us.ibm.com (192.168.1.131) with IBM ESMTP SMTP Gateway: Authorized Use Only! Violators will be prosecuted; (version=TLSv1/SSLv3 cipher=AES256-GCM-SHA384 bits=256/256) Mon, 22 Oct 2018 12:33:20 -0600 Received: from b03ledav005.gho.boulder.ibm.com (b03ledav005.gho.boulder.ibm.com [9.17.130.236]) by b03cxnp08027.gho.boulder.ibm.com (8.14.9/8.14.9/NCO v10.0) with ESMTP id w9MIXJ9352428988 (version=TLSv1/SSLv3 cipher=DHE-RSA-AES256-GCM-SHA384 bits=256 verify=FAIL); Mon, 22 Oct 2018 11:33:19 -0700 Received: from b03ledav005.gho.boulder.ibm.com (unknown [127.0.0.1]) by IMSVA (Postfix) with ESMTP id 09DFCBE05D; Mon, 22 Oct 2018 18:33:19 +0000 (GMT) Received: from b03ledav005.gho.boulder.ibm.com (unknown [127.0.0.1]) by IMSVA (Postfix) with ESMTP id CD296BE058; Mon, 22 Oct 2018 18:33:18 +0000 (GMT) Received: from bigmac.rchland.ibm.com (unknown [9.10.86.17]) by b03ledav005.gho.boulder.ibm.com (Postfix) with ESMTP; Mon, 22 Oct 2018 18:33:18 +0000 (GMT) To: GCC Patches Cc: Segher Boessenkool From: Bill Schmidt Subject: [PATCH, rs6000] Don't use deprecated __vector long in intrinsic compatibility headers Date: Mon, 22 Oct 2018 13:33:18 -0500 User-Agent: Mozilla/5.0 (Macintosh; Intel Mac OS X 10.13; rv:52.0) Gecko/20100101 Thunderbird/52.9.1 MIME-Version: 1.0 x-cbid: 18102218-8235-0000-0000-00000E19FF61 X-IBM-SpamModules-Scores: X-IBM-SpamModules-Versions: BY=3.00009917; HX=3.00000242; KW=3.00000007; PH=3.00000004; SC=3.00000268; SDB=6.01106447; UDB=6.00572979; IPR=6.00886531; MB=3.00023860; MTD=3.00000008; XFM=3.00000015; UTC=2018-10-22 18:33:21 X-IBM-AV-DETECTION: SAVI=unused REMOTE=unused XFE=unused x-cbparentid: 18102218-8236-0000-0000-0000431797FA Message-Id: <8febe16d-e0e1-a430-90bb-a6937894e270@linux.ibm.com> Hi, We should never use __vector long in the intrinsics compatibility headers, since this has different meanings on 32- and 64-bit targets. This patch corrects a number of places where this previously slipped through. Bootstrapped and tested on powerpc64le-linux-gnu with no regressions. Is this okay for trunk? Thanks, Bill 2018-10-22 Bill Schmidt Jinsong Ji * config/rs6000/emmintrin.h (_mm_cvtpd_epi32): Change deprecated __vector long to __vector long long. (_mm_cvtpd_ps): Likewise. (_mm_cvttpd_epi32): Likewise. (_mm_cvtpi32_pd): Likewise. (_mm_unpackhi_epi64): Likewise. (_mm_unpacklo_epi64): Likewise. Index: gcc/config/rs6000/emmintrin.h =================================================================== --- gcc/config/rs6000/emmintrin.h (revision 265389) +++ gcc/config/rs6000/emmintrin.h (working copy) @@ -888,7 +888,8 @@ _mm_cvtpd_epi32 (__m128d __A) #ifdef _ARCH_PWR8 temp = vec_mergeo (temp, temp); - result = (__v4si)vec_vpkudum ((__vector long)temp, (__vector long)vzero); + result = (__v4si)vec_vpkudum ((__vector long long)temp, + (__vector long long)vzero); #else { const __v16qu pkperm = {0x00, 0x01, 0x02, 0x03, 0x08, 0x09, 0x0a, 0x0b, @@ -922,7 +923,8 @@ _mm_cvtpd_ps (__m128d __A) #ifdef _ARCH_PWR8 temp = vec_mergeo (temp, temp); - result = (__v4sf)vec_vpkudum ((__vector long)temp, (__vector long)vzero); + result = (__v4sf)vec_vpkudum ((__vector long long)temp, + (__vector long long)vzero); #else { const __v16qu pkperm = {0x00, 0x01, 0x02, 0x03, 0x08, 0x09, 0x0a, 0x0b, @@ -950,7 +952,8 @@ _mm_cvttpd_epi32 (__m128d __A) #ifdef _ARCH_PWR8 temp = vec_mergeo (temp, temp); - result = (__v4si)vec_vpkudum ((__vector long)temp, (__vector long)vzero); + result = (__v4si)vec_vpkudum ((__vector long long)temp, + (__vector long long)vzero); #else { const __v16qu pkperm = {0x00, 0x01, 0x02, 0x03, 0x08, 0x09, 0x0a, 0x0b, @@ -986,7 +989,7 @@ _mm_cvtpi32_pd (__m64 __A) temp = (__v4si)vec_splats (__A); tmp2 = (__v2di)vec_unpackl (temp); - result = vec_ctf ((__vector signed long)tmp2, 0); + result = vec_ctf ((__vector signed long long)tmp2, 0); return (__m128d)result; } #endif @@ -1289,7 +1292,8 @@ _mm_unpackhi_epi32 (__m128i __A, __m128i __B) extern __inline __m128i __attribute__((__gnu_inline__, __always_inline__, __artificial__)) _mm_unpackhi_epi64 (__m128i __A, __m128i __B) { - return (__m128i) vec_mergel ((__vector long)__A, (__vector long)__B); + return (__m128i) vec_mergel ((__vector long long)__A, + (__vector long long)__B); } extern __inline __m128i __attribute__((__gnu_inline__, __always_inline__, __artificial__)) @@ -1313,7 +1317,8 @@ _mm_unpacklo_epi32 (__m128i __A, __m128i __B) extern __inline __m128i __attribute__((__gnu_inline__, __always_inline__, __artificial__)) _mm_unpacklo_epi64 (__m128i __A, __m128i __B) { - return (__m128i) vec_mergeh ((__vector long)__A, (__vector long)__B); + return (__m128i) vec_mergeh ((__vector long long)__A, + (__vector long long)__B); } extern __inline __m128i __attribute__((__gnu_inline__, __always_inline__, __artificial__))