Message ID | 20231106223531.3271166-1-juzhe.zhong@rivai.ai |
---|---|
State | Accepted |
Headers |
Return-Path: <gcc-patches-bounces+ouuuleilei=gmail.com@gcc.gnu.org> Delivered-To: ouuuleilei@gmail.com Received: by 2002:a59:8f47:0:b0:403:3b70:6f57 with SMTP id j7csp2967851vqu; Mon, 6 Nov 2023 14:36:06 -0800 (PST) X-Google-Smtp-Source: AGHT+IGA9/UieHJrsEecJRZksNp+1xqoA6PDUXaI7fRrAkWN6mZ2rZzRp2elaQ3hylrOMomCeGCE X-Received: by 2002:a05:620a:4891:b0:778:8ce5:f657 with SMTP id ea17-20020a05620a489100b007788ce5f657mr21672235qkb.20.1699310166589; Mon, 06 Nov 2023 14:36:06 -0800 (PST) ARC-Seal: i=2; a=rsa-sha256; t=1699310166; cv=pass; d=google.com; s=arc-20160816; b=GEuOL/O5Xns7H05jMcZEuid925wiQwPJp8v1bC+TdP1niSWHXDdOfUD/gbRvBff35M Cure/HiDyvKe+9GTseRgv5vJVM2d69+WeuCEXQkxkzJuZgcjAcEESPk+kG7audXDYagE MB73O2Zc8jDpR7YocUt0Rvzy8TqSLuqjIxY7dPLYX2Cnq3Ikb0srG8B/AHAbGyRw1ild cdPRPcBC6K7UdTDJx0KqiFTZ9S7ecx5h7wU+Vx5ptj/6yw0j9I88ejWHNXwRXw6AWlW1 a+K56gvkAa3MS209WDi/apXqnqwUCy1Ls9aITG4T7OYLdzclIk7eCOoLELgeD1RsmIom lvGw== ARC-Message-Signature: i=2; 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:arc-filter:dmarc-filter:delivered-to; bh=qoGHAEMuxYbUnV7aLg3HqAlgDXrtsNnAZ8z8ARxujps=; fh=aiNth+pJ2dvKNW3npvMjL2thrslXjqLc41AzrCXI5a8=; b=UXOEUu2JKYabb6JehO9Bnsy4JxH+r2Qfs8Y5Ihv4/NGKXFFvpCAGUSlg2oKx+ViwPK oJZiiMP8v3e0aQiSQ07jJzaWF6MiO4dtBtvUdxgDp1oOr+fooBfN7I7rUpN+xHxz/tHu GDcUhcm5xd1xlEcb3PPJcaHyMSR8vyZcnfLnm+oGQGvsH4IZ1kx2g/gQOTyqxpeltRdw WgDyrFlcNUQHjLEyxI6hs1gtzT16XnkcvP/l4Mc4xK8HgZhZ/nr9yv2mZ1BfPuyPXbRm OHQetDuszIbCExXTWHO1SaF4zNHzIsbNp+mNCT7lM0EjsN86TI/LwkZ3LBOqdoim3JYZ oR2Q== ARC-Authentication-Results: i=2; mx.google.com; arc=pass (i=1); spf=pass (google.com: domain of gcc-patches-bounces+ouuuleilei=gmail.com@gcc.gnu.org designates 8.43.85.97 as permitted sender) smtp.mailfrom="gcc-patches-bounces+ouuuleilei=gmail.com@gcc.gnu.org" Received: from server2.sourceware.org (server2.sourceware.org. [8.43.85.97]) by mx.google.com with ESMTPS id x28-20020a05620a0b5c00b0077771d8a8f2si6071511qkg.570.2023.11.06.14.36.06 for <ouuuleilei@gmail.com> (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Mon, 06 Nov 2023 14:36:06 -0800 (PST) Received-SPF: pass (google.com: domain of gcc-patches-bounces+ouuuleilei=gmail.com@gcc.gnu.org designates 8.43.85.97 as permitted sender) client-ip=8.43.85.97; Authentication-Results: mx.google.com; arc=pass (i=1); spf=pass (google.com: domain of gcc-patches-bounces+ouuuleilei=gmail.com@gcc.gnu.org designates 8.43.85.97 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 543C33861863 for <ouuuleilei@gmail.com>; Mon, 6 Nov 2023 22:36:06 +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 CD81138618F5 for <gcc-patches@gcc.gnu.org>; Mon, 6 Nov 2023 22:35:41 +0000 (GMT) DMARC-Filter: OpenDMARC Filter v1.4.2 sourceware.org CD81138618F5 Authentication-Results: sourceware.org; dmarc=none (p=none dis=none) header.from=rivai.ai Authentication-Results: sourceware.org; spf=pass smtp.mailfrom=rivai.ai ARC-Filter: OpenARC Filter v1.0.0 sourceware.org CD81138618F5 Authentication-Results: server2.sourceware.org; arc=none smtp.remote-ip=54.207.22.56 ARC-Seal: i=1; a=rsa-sha256; d=sourceware.org; s=key; t=1699310144; cv=none; b=UknVkMktC8JBksv9xwhn5c3IBC2UBcJ/Nq+fBtnYCWi1yWPSYDu/Wgk7YGBF24We8z/ZxgTa3UnaFAw60ydM5vSKYvRA2flivUiLuRKGyHo5BZET5pOPCgUborzmWGK0AyasQG5Yb7tQUMA8smNZ8XgAsrZ/XXlviAJUZjXrEeo= ARC-Message-Signature: i=1; a=rsa-sha256; d=sourceware.org; s=key; t=1699310144; c=relaxed/simple; bh=DBohW3pvdoXW/AG5tDPk2065uOXW+G7qo5EuMg0Chxs=; h=From:To:Subject:Date:Message-Id:MIME-Version; b=arNiC4Lo3PXiR7iXi9z64QG28Z8caIAxXmtSkHql5vrpC2RCodlDUCKR0OKdY4G5y+ApkHL3E/Ankc8YHLKpz5XXh5ALrtmY0Gv1wtGOA5bliNA24JIdihB3zj9FwLSV+oryIl2E7Mx2Nw8ImQP/tYvzeSfXTHV9OyjFF6D9GSM= ARC-Authentication-Results: i=1; server2.sourceware.org X-QQ-mid: bizesmtp90t1699310133tmfe8az3 Received: from rios-cad121.hadoop.rioslab.org ( [58.60.1.9]) by bizesmtp.qq.com (ESMTP) with id ; Tue, 07 Nov 2023 06:35:32 +0800 (CST) X-QQ-SSF: 01400000000000G0V000B00A0000000 X-QQ-FEAT: 6LJTjlC9C7N+Ia56tCau3fiX01QBM/HYgVbQ+1V7fEOxuH1sCeWM8OyWz16Ia K1iG0sXFrBtnnVuyqMX/mo+zdg0OsILHL1VPdbczlxmryjVM2HQkP7NG992VOUBbo3KJm/s kshVovh3F1JgWdNYRSMAPlEaVqDeNrUd6YsjMZWZ9wtN3zavLyaT55lUqnV6CrmI+oNl/mv ZSR16FGTTA6OqK/Pl772QhmLEvSWqUJ8yNRXdpdNqKy6nZP6yAMFn+HIhdM8r2jPDs+92Je N7bWFuUAGb0vVYBliR9ysdxyikZzxrRJkCZQw8yTXnyVthHpmEUI/tGsrLLAZXJqej49jG2 AMAaCcQTVwzgT1I+q35GlfuPq25JV2hvqXYBmxGhdEFmAw+g+v5m0MfzTaBlOQmwAlUg/68 X-QQ-GoodBg: 2 X-BIZMAIL-ID: 5822394262857816854 From: Juzhe-Zhong <juzhe.zhong@rivai.ai> To: gcc-patches@gcc.gnu.org Cc: jeffreyalaw@gmail.com, rguenther@suse.de, Juzhe-Zhong <juzhe.zhong@rivai.ai> Subject: [PATCH] test: Fix XPASS of bb-slp-43.c for RVV Date: Tue, 7 Nov 2023 06:35:31 +0800 Message-Id: <20231106223531.3271166-1-juzhe.zhong@rivai.ai> X-Mailer: git-send-email 2.36.3 MIME-Version: 1.0 Content-Transfer-Encoding: 8bit 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, T_SCC_BODY_TEXT_LINE 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 <gcc-patches.gcc.gnu.org> List-Unsubscribe: <https://gcc.gnu.org/mailman/options/gcc-patches>, <mailto:gcc-patches-request@gcc.gnu.org?subject=unsubscribe> List-Archive: <https://gcc.gnu.org/pipermail/gcc-patches/> List-Post: <mailto:gcc-patches@gcc.gnu.org> List-Help: <mailto:gcc-patches-request@gcc.gnu.org?subject=help> List-Subscribe: <https://gcc.gnu.org/mailman/listinfo/gcc-patches>, <mailto:gcc-patches-request@gcc.gnu.org?subject=subscribe> Errors-To: gcc-patches-bounces+ouuuleilei=gmail.com@gcc.gnu.org X-getmail-retrieved-from-mailbox: INBOX X-GMAIL-THRID: 1781855827987209574 X-GMAIL-MSGID: 1781855857302659686 |
Series |
test: Fix XPASS of bb-slp-43.c for RVV
|
|
Checks
Context | Check | Description |
---|---|---|
snail/gcc-patch-check | success | Github commit url |
Commit Message
juzhe.zhong@rivai.ai
Nov. 6, 2023, 10:35 p.m. UTC
RVV is variable length vector but also has 256 bit VLS mode vector. This test is vectorized as: f: vsetivli zero,8,e32,m2,ta,ma vle32.v v2,0(a0) vmv.v.i v4,1 vle16.v v1,0(a1) vmseq.vv v0,v2,v4 vsetvli zero,zero,e16,m1,ta,ma vmseq.vi v1,v1,2 vsetvli zero,zero,e32,m2,ta,ma vmv.v.i v2,0 vmand.mm v0,v0,v1 vmerge.vvm v2,v2,v4,v0 vse32.v v2,0(a0) ret Use 256 bit vector, so remove XFAIL for 256 bits vector. gcc/testsuite/ChangeLog: * gcc.dg/vect/bb-slp-43.c: Fix XPASS for RVV. --- gcc/testsuite/gcc.dg/vect/bb-slp-43.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-)
Comments
On 11/6/23 15:35, Juzhe-Zhong wrote: > RVV is variable length vector but also has 256 bit VLS mode vector. > This test is vectorized as: > > f: > vsetivli zero,8,e32,m2,ta,ma > vle32.v v2,0(a0) > vmv.v.i v4,1 > vle16.v v1,0(a1) > vmseq.vv v0,v2,v4 > vsetvli zero,zero,e16,m1,ta,ma > vmseq.vi v1,v1,2 > vsetvli zero,zero,e32,m2,ta,ma > vmv.v.i v2,0 > vmand.mm v0,v0,v1 > vmerge.vvm v2,v2,v4,v0 > vse32.v v2,0(a0) > ret > > Use 256 bit vector, so remove XFAIL for 256 bits vector. > > gcc/testsuite/ChangeLog: > > * gcc.dg/vect/bb-slp-43.c: Fix XPASS for RVV. So will this create a FAIL if someone runs the testsuite with the autovec preference set to scalable? Or are the fallbacks to VLS still available when we prefer scalable vectors? jeff
>> So will this create a FAIL if someone runs the testsuite with the >> autovec preference set to scalable? No, it won't. Since it is always -fno-vect-cost-model. When a scalable vector doesn't have 256bit vector, it always XFAIL, for example, ARM SVE. >> Or are the fallbacks to VLS still >> available when we prefer scalable vectors? Yes. since it is -fno-vect-cost-model. juzhe.zhong@rivai.ai From: Jeff Law Date: 2023-11-07 11:23 To: Juzhe-Zhong; gcc-patches CC: rguenther Subject: Re: [PATCH] test: Fix XPASS of bb-slp-43.c for RVV On 11/6/23 15:35, Juzhe-Zhong wrote: > RVV is variable length vector but also has 256 bit VLS mode vector. > This test is vectorized as: > > f: > vsetivli zero,8,e32,m2,ta,ma > vle32.v v2,0(a0) > vmv.v.i v4,1 > vle16.v v1,0(a1) > vmseq.vv v0,v2,v4 > vsetvli zero,zero,e16,m1,ta,ma > vmseq.vi v1,v1,2 > vsetvli zero,zero,e32,m2,ta,ma > vmv.v.i v2,0 > vmand.mm v0,v0,v1 > vmerge.vvm v2,v2,v4,v0 > vse32.v v2,0(a0) > ret > > Use 256 bit vector, so remove XFAIL for 256 bits vector. > > gcc/testsuite/ChangeLog: > > * gcc.dg/vect/bb-slp-43.c: Fix XPASS for RVV. So will this create a FAIL if someone runs the testsuite with the autovec preference set to scalable? Or are the fallbacks to VLS still available when we prefer scalable vectors? jeff
On 11/6/23 20:30, juzhe.zhong@rivai.ai wrote: > >> So will this create a FAIL if someone runs the testsuite with the >>> autovec preference set to scalable? > No, it won't. Since it is always -fno-vect-cost-model. > When a scalable vector doesn't have 256bit vector, it always XFAIL, for > example, ARM SVE. > >>> Or are the fallbacks to VLS still >>> available when we prefer scalable vectors? > Yes. since it is -fno-vect-cost-model. OK. Thanks for clarifying. This is fine for the trunk. jeff
Thanks Jeff. Just finish bootstrap +regression passed. Committed. juzhe.zhong@rivai.ai From: Jeff Law Date: 2023-11-07 11:49 To: juzhe.zhong@rivai.ai; gcc-patches CC: rguenther Subject: Re: [PATCH] test: Fix XPASS of bb-slp-43.c for RVV On 11/6/23 20:30, juzhe.zhong@rivai.ai wrote: > >> So will this create a FAIL if someone runs the testsuite with the >>> autovec preference set to scalable? > No, it won't. Since it is always -fno-vect-cost-model. > When a scalable vector doesn't have 256bit vector, it always XFAIL, for > example, ARM SVE. > >>> Or are the fallbacks to VLS still >>> available when we prefer scalable vectors? > Yes. since it is -fno-vect-cost-model. OK. Thanks for clarifying. This is fine for the trunk. jeff
diff --git a/gcc/testsuite/gcc.dg/vect/bb-slp-43.c b/gcc/testsuite/gcc.dg/vect/bb-slp-43.c index a65d9513c4d..dad2d24262d 100644 --- a/gcc/testsuite/gcc.dg/vect/bb-slp-43.c +++ b/gcc/testsuite/gcc.dg/vect/bb-slp-43.c @@ -14,4 +14,4 @@ f (int *restrict x, short *restrict y) } /* { dg-final { scan-tree-dump-not "mixed mask and nonmask" "slp2" } } */ -/* { dg-final { scan-tree-dump-not "vector operands from scalars" "slp2" { target { { vect_int && vect_bool_cmp } && { vect_unpack && vect_hw_misalign } } xfail vect_variable_length } } } */ +/* { dg-final { scan-tree-dump-not "vector operands from scalars" "slp2" { target { { vect_int && vect_bool_cmp } && { vect_unpack && vect_hw_misalign } } xfail { vect_variable_length && { ! vect256 } } } } } */