From patchwork Wed Jul 10 00:19:58 2024 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Andrew Pinski X-Patchwork-Id: 1958626 Return-Path: X-Original-To: incoming@patchwork.ozlabs.org Delivered-To: patchwork-incoming@legolas.ozlabs.org Authentication-Results: legolas.ozlabs.org; dkim=fail reason="signature verification failed" (2048-bit key; unprotected) header.d=quicinc.com header.i=@quicinc.com header.a=rsa-sha256 header.s=qcppdkim1 header.b=cz9+SXkn; dkim-atps=neutral Authentication-Results: legolas.ozlabs.org; spf=pass (sender SPF authorized) smtp.mailfrom=gcc.gnu.org (client-ip=2620:52:3:1:0:246e:9693:128c; helo=server2.sourceware.org; envelope-from=gcc-patches-bounces~incoming=patchwork.ozlabs.org@gcc.gnu.org; receiver=patchwork.ozlabs.org) Received: from server2.sourceware.org (server2.sourceware.org [IPv6:2620:52:3:1:0:246e:9693:128c]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature ECDSA (secp384r1) server-digest SHA384) (No client certificate requested) by legolas.ozlabs.org (Postfix) with ESMTPS id 4WJdnG6Vqqz1xqj for ; Wed, 10 Jul 2024 10:21:06 +1000 (AEST) Received: from server2.sourceware.org (localhost [IPv6:::1]) by sourceware.org (Postfix) with ESMTP id C85D138708B4 for ; Wed, 10 Jul 2024 00:21:04 +0000 (GMT) X-Original-To: gcc-patches@gcc.gnu.org Delivered-To: gcc-patches@gcc.gnu.org Received: from mx0b-0031df01.pphosted.com (mx0b-0031df01.pphosted.com [205.220.180.131]) by sourceware.org (Postfix) with ESMTPS id 5515E385DDD5 for ; Wed, 10 Jul 2024 00:20:35 +0000 (GMT) DMARC-Filter: OpenDMARC Filter v1.4.2 sourceware.org 5515E385DDD5 Authentication-Results: sourceware.org; dmarc=pass (p=none dis=none) header.from=quicinc.com Authentication-Results: sourceware.org; spf=pass smtp.mailfrom=quicinc.com ARC-Filter: OpenARC Filter v1.0.0 sourceware.org 5515E385DDD5 Authentication-Results: server2.sourceware.org; arc=none smtp.remote-ip=205.220.180.131 ARC-Seal: i=1; a=rsa-sha256; d=sourceware.org; s=key; t=1720570837; cv=none; b=F90MDXsX3+5UF5CWKqJes423jqEJLFa/Nr/Sf7CQKaqlFdwqJnmfJc+lMkzrrS3sw4A4erhfc1jQYECWx1TCb7tCJzNiyogiU+LEcKYXt8FIQndV2JKirrY4QZCMzVVuVkPrkeGXCROlX2iiSUINKjomercWZuiUIlU/CLwgKKY= ARC-Message-Signature: i=1; a=rsa-sha256; d=sourceware.org; s=key; t=1720570837; c=relaxed/simple; bh=Os9QfvlHDjurOalwbejwFNfFAp7qcpoQbKwQ1tGEmb8=; h=DKIM-Signature:From:To:Subject:Date:Message-ID:MIME-Version; b=LVifAofF7NSChpw/3xLPjqlijVRzSCBRgxNaezfvGHDjIJzmCsfmZ1l3OlHWyUxNCpW6Y7SwyVYBhmBhG68YXIYFEAv0P/OpzZOU9rVlhow4dic8FRoTQ5JvbEpmC9Zjilowoou1JEgRINlL5puoJYbYrBZ5Uieu8uvZ4qk4/vs= ARC-Authentication-Results: i=1; server2.sourceware.org Received: from pps.filterd (m0279868.ppops.net [127.0.0.1]) by mx0a-0031df01.pphosted.com (8.18.1.2/8.18.1.2) with ESMTP id 469CtIKN020904 for ; Wed, 10 Jul 2024 00:20:34 GMT DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=quicinc.com; h= cc:content-transfer-encoding:content-type:date:from:message-id :mime-version:subject:to; s=qcppdkim1; bh=hv5ziPkPt0ro58bZoG5piO E9EpVVmxkoo7RtttIZgzg=; b=cz9+SXknDbZ7BkRi6GWJNsLbGHJRtc+LIQcUcf LaOHBi2qAalrGWg6KWMOMbDB582DtnpfjdQHePCx/IKzWzdAQgtHqXyAQCQgsF05 WcBz6lL5/I3DynYmiVjD/4unDskX24LI9I1CKSR5ebL0JFiaJQn/6e5eulPmbowc o6IGsk/AAlUjhmHa6nxCjiocHOQ2uaI+oYNMa9cla759FVQXih/RsJQ36tYiTQAo p3W9XD3kceYyBpYOeXf5Zw0YBR8tCQerJOmia2jcmvhR0B6/JIWPpMiTSs5larKL ZWEuwllvYo18mJ7U3CdayfBV2FW20WyFf9CgqnbuCVTaCzlg== Received: from nasanppmta03.qualcomm.com (i-global254.qualcomm.com [199.106.103.254]) by mx0a-0031df01.pphosted.com (PPS) with ESMTPS id 406we8yq7s-1 (version=TLSv1.2 cipher=ECDHE-RSA-AES256-GCM-SHA384 bits=256 verify=NOT) for ; Wed, 10 Jul 2024 00:20:34 +0000 (GMT) Received: from nasanex01c.na.qualcomm.com (nasanex01c.na.qualcomm.com [10.45.79.139]) by NASANPPMTA03.qualcomm.com (8.17.1.19/8.17.1.19) with ESMTPS id 46A0KBBx026929 (version=TLSv1.2 cipher=ECDHE-RSA-AES256-GCM-SHA384 bits=256 verify=NOT) for ; Wed, 10 Jul 2024 00:20:12 GMT Received: from hu-apinski-lv.qualcomm.com (10.49.16.6) by nasanex01c.na.qualcomm.com (10.45.79.139) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.2.1544.9; Tue, 9 Jul 2024 17:20:11 -0700 From: Andrew Pinski To: CC: Andrew Pinski Subject: [PATCH] testsuite: Allow matching `{_1, { 0, 0, 0, 0 }}` for vect/slp-gap-1.c Date: Tue, 9 Jul 2024 17:19:58 -0700 Message-ID: <20240710001958.3228381-1-quic_apinski@quicinc.com> X-Mailer: git-send-email 2.34.1 MIME-Version: 1.0 X-Originating-IP: [10.49.16.6] X-ClientProxiedBy: nalasex01a.na.qualcomm.com (10.47.209.196) To nasanex01c.na.qualcomm.com (10.45.79.139) X-QCInternal: smtphost X-Proofpoint-Virus-Version: vendor=nai engine=6200 definitions=5800 signatures=585085 X-Proofpoint-ORIG-GUID: dOZK3LCeu0bGMiu6Zr5j2Xds8Ul7ChBI X-Proofpoint-GUID: dOZK3LCeu0bGMiu6Zr5j2Xds8Ul7ChBI X-Proofpoint-Virus-Version: vendor=baseguard engine=ICAP:2.0.293,Aquarius:18.0.1039,Hydra:6.0.680,FMLib:17.12.28.16 definitions=2024-07-09_11,2024-07-09_01,2024-05-17_01 X-Proofpoint-Spam-Details: rule=outbound_notspam policy=outbound score=0 adultscore=0 impostorscore=0 bulkscore=0 spamscore=0 suspectscore=0 lowpriorityscore=0 phishscore=0 priorityscore=1501 mlxlogscore=894 malwarescore=0 mlxscore=0 clxscore=1015 classifier=spam adjust=0 reason=mlx scancount=1 engine=8.19.0-2406140001 definitions=main-2407100001 X-Spam-Status: No, score=-13.4 required=5.0 tests=BAYES_00, DKIM_SIGNED, DKIM_VALID, DKIM_VALID_AU, DKIM_VALID_EF, GIT_PATCH_0, SPF_HELO_NONE, SPF_NONE, TXREP autolearn=ham autolearn_force=no version=3.4.6 X-Spam-Checker-Version: SpamAssassin 3.4.6 (2021-04-09) on server2.sourceware.org X-BeenThere: gcc-patches@gcc.gnu.org X-Mailman-Version: 2.1.30 Precedence: list List-Id: Gcc-patches mailing list List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: gcc-patches-bounces~incoming=patchwork.ozlabs.org@gcc.gnu.org While working on adding V4QI support to the aarch64 backend, vect/slp-gap-1.c started to fail but only because the regex was failing. Before it was loading use SI (int) and afterwards, we started to use V4QI. The generated code was the same and the generated gimple was almost the same. The regex was searching for `zero-padding trick` and it was still doing that but instead of directly 0, it was V4QI 0 (or rather `{ 0, 0, 0 }`). This extends regex to support both. Tested on x86_64-linux-gnu and aarch64-linux-gnu (with the support added). gcc/testsuite/ChangeLog: * gcc.dg/vect/slp-gap-1.c: Support matching `(_1, { 0, 0, 0, 0 }}` in addition to `{_1, 0}`. Signed-off-by: Andrew Pinski --- gcc/testsuite/gcc.dg/vect/slp-gap-1.c | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/gcc/testsuite/gcc.dg/vect/slp-gap-1.c b/gcc/testsuite/gcc.dg/vect/slp-gap-1.c index 9856da7a7f4..74bde8219d9 100644 --- a/gcc/testsuite/gcc.dg/vect/slp-gap-1.c +++ b/gcc/testsuite/gcc.dg/vect/slp-gap-1.c @@ -14,5 +14,7 @@ void pixel_sub_wxh(int16_t * __restrict diff, uint8_t *pix1, uint8_t *pix2) { /* We can vectorize this without peeling for gaps and thus without epilogue, but the only thing we can reliably scan is the zero-padding trick for the - partial loads. */ -/* { dg-final { scan-tree-dump-times "\{_\[0-9\]\+, 0" 6 "vect" { target { vect64 && { vect_unpack && vect_perm } } } } } */ + partial loads. + Note this will match `{_1, 0}` or `{_1, {0, 0, 0, 0}}`. Both are the same + in the end, the difference is the load is either via SI or V4QI. */ +/* { dg-final { scan-tree-dump-times "\{_\[0-9\]\+, (?:0\|{ 0(?:, 0)\+ )}" 6 "vect" { target { vect64 && { vect_unpack && vect_perm } } } } } */