From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from mx0a-001b2d01.pphosted.com (mx0a-001b2d01.pphosted.com [148.163.156.1]) by sourceware.org (Postfix) with ESMTPS id A5FC5383802D for ; Mon, 2 Aug 2021 13:31:47 +0000 (GMT) DMARC-Filter: OpenDMARC Filter v1.4.1 sourceware.org A5FC5383802D Received: from pps.filterd (m0098399.ppops.net [127.0.0.1]) by mx0a-001b2d01.pphosted.com (8.16.0.43/8.16.0.43) with SMTP id 172D3YDl013837; Mon, 2 Aug 2021 09:31:46 -0400 Received: from ppma02wdc.us.ibm.com (aa.5b.37a9.ip4.static.sl-reverse.com [169.55.91.170]) by mx0a-001b2d01.pphosted.com with ESMTP id 3a5ke5cjwh-1 (version=TLSv1.2 cipher=ECDHE-RSA-AES256-GCM-SHA384 bits=256 verify=NOT); Mon, 02 Aug 2021 09:31:46 -0400 Received: from pps.filterd (ppma02wdc.us.ibm.com [127.0.0.1]) by ppma02wdc.us.ibm.com (8.16.1.2/8.16.1.2) with SMTP id 172DCcJD030420; Mon, 2 Aug 2021 13:31:45 GMT Received: from b01cxnp22035.gho.pok.ibm.com (b01cxnp22035.gho.pok.ibm.com [9.57.198.25]) by ppma02wdc.us.ibm.com with ESMTP id 3a4x5b3vpt-1 (version=TLSv1.2 cipher=ECDHE-RSA-AES256-GCM-SHA384 bits=256 verify=NOT); Mon, 02 Aug 2021 13:31:45 +0000 Received: from b01ledav001.gho.pok.ibm.com (b01ledav001.gho.pok.ibm.com [9.57.199.106]) by b01cxnp22035.gho.pok.ibm.com (8.14.9/8.14.9/NCO v10.0) with ESMTP id 172DVjls38863198 (version=TLSv1/SSLv3 cipher=DHE-RSA-AES256-GCM-SHA384 bits=256 verify=OK); Mon, 2 Aug 2021 13:31:45 GMT Received: from b01ledav001.gho.pok.ibm.com (unknown [127.0.0.1]) by IMSVA (Postfix) with ESMTP id DF5F128060; Mon, 2 Aug 2021 13:31:44 +0000 (GMT) Received: from b01ledav001.gho.pok.ibm.com (unknown [127.0.0.1]) by IMSVA (Postfix) with ESMTP id 864C028064; Mon, 2 Aug 2021 13:31:44 +0000 (GMT) Received: from Bills-MacBook-Pro.local (unknown [9.211.91.192]) by b01ledav001.gho.pok.ibm.com (Postfix) with ESMTP; Mon, 2 Aug 2021 13:31:44 +0000 (GMT) Reply-To: wschmidt@linux.ibm.com Subject: Re: [PATCH 42/55] rs6000: Handle gimple folding of target built-ins From: Bill Schmidt To: will schmidt , gcc-patches@gcc.gnu.org Cc: segher@kernel.crashing.org References: <91c28178ab7912df2a6b8f8299ef6563a69781b5.1623941442.git.wschmidt@linux.ibm.com> <60e83e75-6c86-2c78-492b-1d56ac1857a6@linux.ibm.com> Message-ID: Date: Mon, 2 Aug 2021 08:31:43 -0500 User-Agent: Mozilla/5.0 (Macintosh; Intel Mac OS X 10.15; rv:78.0) Gecko/20100101 Thunderbird/78.12.0 MIME-Version: 1.0 In-Reply-To: <60e83e75-6c86-2c78-492b-1d56ac1857a6@linux.ibm.com> Content-Type: text/plain; charset=utf-8; format=flowed Content-Transfer-Encoding: 8bit Content-Language: en-GB X-TM-AS-GCONF: 00 X-Proofpoint-GUID: WLCpSUE5GMAOqEpew2opCiKV_KTdr2bu X-Proofpoint-ORIG-GUID: WLCpSUE5GMAOqEpew2opCiKV_KTdr2bu X-Proofpoint-Virus-Version: vendor=fsecure engine=2.50.10434:6.0.391, 18.0.790 definitions=2021-08-02_05:2021-08-02, 2021-08-02 signatures=0 X-Proofpoint-Spam-Details: rule=outbound_notspam policy=outbound score=0 impostorscore=0 phishscore=0 priorityscore=1501 clxscore=1015 bulkscore=0 mlxlogscore=999 suspectscore=0 mlxscore=0 lowpriorityscore=0 adultscore=0 spamscore=0 malwarescore=0 classifier=spam adjust=0 reason=mlx scancount=1 engine=8.12.0-2107140000 definitions=main-2108020088 X-Spam-Status: No, score=-6.2 required=5.0 tests=BAYES_00, DKIM_SIGNED, DKIM_VALID, DKIM_VALID_EF, NICE_REPLY_A, RCVD_IN_MSPIKE_H3, RCVD_IN_MSPIKE_WL, SPF_HELO_NONE, SPF_PASS, TXREP autolearn=ham autolearn_force=no version=3.4.4 X-Spam-Checker-Version: SpamAssassin 3.4.4 (2020-01-24) on server2.sourceware.org X-BeenThere: gcc-patches@gcc.gnu.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: Gcc-patches mailing list List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Mon, 02 Aug 2021 13:31:48 -0000 Hi Will, On 7/29/21 7:42 AM, Bill Schmidt wrote: > On 7/28/21 4:21 PM, will schmidt wrote: >> On Thu, 2021-06-17 at 10:19 -0500, Bill Schmidt via Gcc-patches wrote: >> >> >> + /* Vector compares; EQ, NE, GE, GT, LE. */ >> + case RS6000_BIF_VCMPEQUB: >> + case RS6000_BIF_VCMPEQUH: >> + case RS6000_BIF_VCMPEQUW: >> + case RS6000_BIF_VCMPEQUD: >> + fold_compare_helper (gsi, EQ_EXPR, stmt); >> + return true; >> + >> + case RS6000_BIF_VCMPNEB: >> + case RS6000_BIF_VCMPNEH: >> + case RS6000_BIF_VCMPNEW: >> + fold_compare_helper (gsi, NE_EXPR, stmt); >> + return true; >> + >> Noting that entries for _CMPNET,_VCMPEQUT, etc are missing from this >> version versus the non-new version of this function. >> I believe thiswas/is deliberate and by design. >> Same with entries for P10V_BUILTIN_CMPLE_1TI, etc below. > > Indeed not!  This is something I missed when new code was added after I > posted the original patch series.  I'll reinstate the quadword > compares.  Thanks for spotting this! Interestingly, when the quadword compares are expanded at GIMPLE time, we generate worse code involving individual 64-bit compares.  For the time being, I will not expand these at GIMPLE time; independently, this bears looking at to see why expressions like (uint128_1 < uint128_2) will generate poor code. Bill > > Bill >