From patchwork Sun Oct 8 08:20:05 2023 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: "juzhe.zhong@rivai.ai" X-Patchwork-Id: 149707 Return-Path: Delivered-To: ouuuleilei@gmail.com Received: by 2002:a59:a888:0:b0:403:3b70:6f57 with SMTP id x8csp1270904vqo; Sun, 8 Oct 2023 01:20:54 -0700 (PDT) X-Google-Smtp-Source: AGHT+IHuGQioOkP1yMmbI1CE6hrpgj/Ywr8OAt2uoejmzKAk0xJS1ueXmxLn11RgLV610d9r0y0i X-Received: by 2002:aa7:df86:0:b0:52a:1d9c:83ff with SMTP id b6-20020aa7df86000000b0052a1d9c83ffmr11572115edy.1.1696753253894; Sun, 08 Oct 2023 01:20:53 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1696753253; cv=none; d=google.com; s=arc-20160816; b=GkwfwttzlCKSk1IrPEgSfrEh0dCz0Tfgruv9DkkYtpoj69ElfVQE8JkayxEi/djPNF capw9kSANRDt0HpVUCQPiPSGIpMPV6JSvhkJ/Z4kSMifJ52sPPeSRnfjn638rX3a3tWT v77HPWbzQ5Hw5UtQFI72/FLO9my+Sb7XOYrcqNN7QczwC4lRnoEnVWOh2GTGQAPAPSng o9anCO02RNInrh6GOPlLjokiPl4Cpu+ph6X/vN+uUuRAwlHFuHlzyn6o2gfjn8KZjbew 9CiuE/mEQqpxfbWyTmQOxV9jMod4H45skeANO2yf1xOP8PG32nP6/3DTpwyj/jB0kJqW vV2g== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=errors-to:list-subscribe:list-help:list-post:list-archive :list-unsubscribe:list-id:precedence:feedback-id :content-transfer-encoding:mime-version:message-id:date:subject:cc :to:from:dmarc-filter:delivered-to; bh=ZjDrZi/SeM/jVd135uVOvaPdAhaeNJF/RntcRG2YQeM=; fh=Ytz0BgUryGxSKnlvo5iIYZYov/AuWMbdn9WUJJDE2rE=; b=H4RlrWbzmrBsHXPTncVaSOlak2jrKkq+dsBZusZjnqejrIYDqBmnMBmxk0ggqvANVD W35rRUR1ARacdbpI3MwD8AlvMSV/nYV9FjdDpxHoSHv+hyLXD3TqWK/WKP+Li4mX4QSb 1WXXf09x8NXJy3UevU/j7mzM0+T3RRG0sTMG8lPJKdbc1Ie2VYIqlCLM3ZoBkE5949aC F/hO+Q+Eim9N51Y53XY8cCeUVJRm1sZq0F/VIvsQu24Oz91xD4Cqb1m/B8+pq6lJtGGA TYHEBzOTXbVjPFssuyfIW5GH8Jc8jEfz1d3ZG+YL49v032/a+s7EKqLCHJNiv55RhTG0 NWxQ== ARC-Authentication-Results: i=1; mx.google.com; spf=pass (google.com: domain of gcc-patches-bounces+ouuuleilei=gmail.com@gcc.gnu.org designates 2620:52:3:1:0:246e:9693:128c as permitted sender) smtp.mailfrom="gcc-patches-bounces+ouuuleilei=gmail.com@gcc.gnu.org" Received: from server2.sourceware.org (server2.sourceware.org. [2620:52:3:1:0:246e:9693:128c]) by mx.google.com with ESMTPS id j26-20020aa7c41a000000b00537fdb2a284si3372459edq.550.2023.10.08.01.20.53 for (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Sun, 08 Oct 2023 01:20:53 -0700 (PDT) Received-SPF: pass (google.com: domain of gcc-patches-bounces+ouuuleilei=gmail.com@gcc.gnu.org designates 2620:52:3:1:0:246e:9693:128c as permitted sender) client-ip=2620:52:3:1:0:246e:9693:128c; Authentication-Results: mx.google.com; spf=pass (google.com: domain of gcc-patches-bounces+ouuuleilei=gmail.com@gcc.gnu.org designates 2620:52:3:1:0:246e:9693:128c as permitted sender) smtp.mailfrom="gcc-patches-bounces+ouuuleilei=gmail.com@gcc.gnu.org" Received: from server2.sourceware.org (localhost [IPv6:::1]) by sourceware.org (Postfix) with ESMTP id 0ADD93856973 for ; Sun, 8 Oct 2023 08:20:45 +0000 (GMT) X-Original-To: gcc-patches@gcc.gnu.org Delivered-To: gcc-patches@gcc.gnu.org Received: from smtpbgbr2.qq.com (smtpbgbr2.qq.com [54.207.22.56]) by sourceware.org (Postfix) with ESMTPS id F200F3858D32 for ; Sun, 8 Oct 2023 08:20:17 +0000 (GMT) DMARC-Filter: OpenDMARC Filter v1.4.2 sourceware.org F200F3858D32 Authentication-Results: sourceware.org; dmarc=none (p=none dis=none) header.from=rivai.ai Authentication-Results: sourceware.org; spf=pass smtp.mailfrom=rivai.ai X-QQ-mid: bizesmtp75t1696753207tb1chxmy Received: from rios-cad121.hadoop.rioslab.org ( [58.60.1.9]) by bizesmtp.qq.com (ESMTP) with id ; Sun, 08 Oct 2023 16:20:06 +0800 (CST) X-QQ-SSF: 01400000000000G0V000000A0000000 X-QQ-FEAT: CR3LFp2JE4lVxmcETkzOhbJ6yAZTS1ZDLDG/E4s2vp5kZvN/RCh0cYTKLDAF3 pJXjZq1Zgc70qTVLulNTr7RPl4HY5uoBN3t4XxIktBwyt/Yn8vHeFVL5RShQI8i/y/vYDh8 7Bhi2CHImo8vPeR+av3NRkYMdQhByG6vg6gJrmtYjwRERRmm7z6S9YbRLF8yW1ZB9ZzbsY/ Z/sWvDuO4sf02LQKkW/Mtr52bztCQfLTHRpiY/GLbjZ25iNjx6fRLW+0oBnGuVV3moFUPf4 51kFREnsAYcLJirqZWPI+zYCDq/n2nIyc5EBb0ytUOSCidlqG2HMNB+y2DFwt73mExTWszK DMcqR5/bkpJuVhn54mxpm4/uVaAK2iS5ePJnKyLoAqFkyRDoBPx9tlT2jDoUyVtgvBGus0h X-QQ-GoodBg: 2 X-BIZMAIL-ID: 12617072987010225772 From: Juzhe-Zhong To: gcc-patches@gcc.gnu.org Cc: rguenther@suse.de, jeffreyalaw@gmail.com, Juzhe-Zhong Subject: [PATCH] TEST: Fix dump FAIL for RVV (RISCV-V vector) Date: Sun, 8 Oct 2023 16:20:05 +0800 Message-Id: <20231008082005.3410115-1-juzhe.zhong@rivai.ai> X-Mailer: git-send-email 2.36.3 MIME-Version: 1.0 X-QQ-SENDSIZE: 520 Feedback-ID: bizesmtp:rivai.ai:qybglogicsvrgz:qybglogicsvrgz7a-one-0 X-Spam-Status: No, score=-12.2 required=5.0 tests=BAYES_00, GIT_PATCH_0, KAM_DMARC_STATUS, RCVD_IN_DNSWL_NONE, RCVD_IN_MSPIKE_H2, SPF_HELO_PASS, SPF_PASS, 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+ouuuleilei=gmail.com@gcc.gnu.org X-getmail-retrieved-from-mailbox: INBOX X-GMAIL-THRID: 1779174739912761813 X-GMAIL-MSGID: 1779174739912761813 As this showed: https://godbolt.org/z/3K9oK7fx3 ARM SVE 2 times for FOLD_EXTRACT_LAST wheras RVV 4 times. This is because RISC-V doesn't enable vec_pack_trunc so we will failed conversion and fold_extract_last at the first time analysis. Then we succeed at the second time. So RVV has 4 times of showing "FOLD_EXTRACT_LAST:. gcc/testsuite/ChangeLog: * gcc.dg/vect/vect-cond-reduc-4.c: Add vect_pack_trunc variant. --- gcc/testsuite/gcc.dg/vect/vect-cond-reduc-4.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/gcc/testsuite/gcc.dg/vect/vect-cond-reduc-4.c b/gcc/testsuite/gcc.dg/vect/vect-cond-reduc-4.c index 8820075b1dc..8ea8c538713 100644 --- a/gcc/testsuite/gcc.dg/vect/vect-cond-reduc-4.c +++ b/gcc/testsuite/gcc.dg/vect/vect-cond-reduc-4.c @@ -42,6 +42,7 @@ main (void) } /* { dg-final { scan-tree-dump-times "LOOP VECTORIZED" 2 "vect" } } */ -/* { dg-final { scan-tree-dump-times "optimizing condition reduction with FOLD_EXTRACT_LAST" 2 "vect" { target vect_fold_extract_last } } } */ +/* { dg-final { scan-tree-dump-times "optimizing condition reduction with FOLD_EXTRACT_LAST" 2 "vect" { target { vect_fold_extract_last && vect_pack_trunc } } } } */ +/* { dg-final { scan-tree-dump-times "optimizing condition reduction with FOLD_EXTRACT_LAST" 4 "vect" { target { { vect_fold_extract_last } && { ! vect_pack_trunc } } } } } */ /* { dg-final { scan-tree-dump-times "condition expression based on integer induction." 2 "vect" { target { ! vect_fold_extract_last } } } } */