From patchwork Thu Feb 9 21:52:41 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: 55100 Return-Path: Delivered-To: ouuuleilei@gmail.com Received: by 2002:adf:eb09:0:0:0:0:0 with SMTP id s9csp593879wrn; Thu, 9 Feb 2023 13:53:36 -0800 (PST) X-Google-Smtp-Source: AK7set8hDbreg9fifcDXyFSCqnrO5eDyRuom90nlHiiMEmCHa0zBHBHx9W5hB1IQUmEvoapw+cHq X-Received: by 2002:a50:9eca:0:b0:4aa:a5b3:15e6 with SMTP id a68-20020a509eca000000b004aaa5b315e6mr13396155edf.0.1675979616253; Thu, 09 Feb 2023 13:53:36 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1675979616; cv=none; d=google.com; s=arc-20160816; b=x+D8wOmRKfQsFZNitC9aUbyKu3tZnHm/xEA0TSdNO4PZj4w8tsIGFXJXyzeJPuI1en 9Alx4bhJ7qNbHUEyTvmj4kAu3kiyaYfZIcWxYoh0YT4Vx47f5qBl/Cqb4xt4tQyn3YCq By2r+PeBaveG5r+NJQ/8D6mEdm9MzMTt1Wu8/5h7yxdYL18NDyWJGCaff6YZz2sidIjU n4q6Y2fDCqu7tRQwX/2cmdY6op/cv0dIYFRNSkxfEalcZXNVBVUGyXNYKag1fu9NZFZJ 3m+azwC3OVX5eUwpz4Qo5tjCif77kxhCSvJA2bdrVDMkA8lZ111HlFC3i7da0Mo7Irb3 6q3Q== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=sender: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=OVLmDieAwQJDkc02X0ytrRVjIbw0Ali/TmuiMjypRWc=; b=ntAssiy1iuvnaillfhLj0Yn3zecsBo3g8U1UQ/jTDORty3rRyMdj7cX8JG6JLnM/Nl TJFpTsDMILOI7WqWIREDpYvEgU5DXh3l32EUCeEIJkPDnrcEcovgomldsdBEXtJhdpxx u2C0CAOeeLDGnL5gtfPaw/7jnOpNz//oEghduYf9scpYmmugEitKVAFUzSkY0yqq0sjC LyNlEnVAIlXREWljMC6j4wq1lWeHEnw85u4cWMcuDp59Ia0pH58h4Tez49p+jagvjIdV qQ0C8+5C3Sdcj5sG9mJWseRUv5nJRe54I6QmLRkRX+PvTp4CSENwRmQ5T8Ra+lJ7daQu oCEg== ARC-Authentication-Results: i=1; mx.google.com; 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 sourceware.org (ip-8-43-85-97.sourceware.org. [8.43.85.97]) by mx.google.com with ESMTPS id m7-20020aa7c487000000b004ab201f810dsi2054411edq.84.2023.02.09.13.53.35 for (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Thu, 09 Feb 2023 13:53:36 -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; 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 4CAC73857400 for ; Thu, 9 Feb 2023 21:53:34 +0000 (GMT) X-Original-To: gcc-patches@gcc.gnu.org Delivered-To: gcc-patches@gcc.gnu.org Received: from smtpbgbr1.qq.com (smtpbgbr1.qq.com [54.207.19.206]) by sourceware.org (Postfix) with ESMTPS id 6D20C3858C50 for ; Thu, 9 Feb 2023 21:52:49 +0000 (GMT) DMARC-Filter: OpenDMARC Filter v1.4.2 sourceware.org 6D20C3858C50 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: bizesmtp84t1675979563thgb6827 Received: from rios-cad5.localdomain ( [58.60.1.11]) by bizesmtp.qq.com (ESMTP) with id ; Fri, 10 Feb 2023 05:52:42 +0800 (CST) X-QQ-SSF: 01400000002000E0L000B00A0000000 X-QQ-FEAT: 1NnPYUNQDAya9iaIXCrh50zSPNM01GnAut9M2CGQgd03QkjyBSNAMrdDeB+AW MNLVZxy8ha5WD62u+T+R7WWSIjxvglW5Luht3wRxnnlX5TAnQUJqZhGBFuedHZXneLX9pCx 1MydsUfefOa+wuO0qI7s2OMuh2x7502zYFYCYD8vGuc0ehZTQ1hv1zAA96LscsaPJbr6x5S 468vGxd0iWe8AdHdRGXqrDc04eV/9d8ZMopzLwWahAZjYS1h8U6TJ9fWASCUidU2huwejtP syPAkJXZZo3G9O0uNlCAPz0J87vNz4iyQ1GHif1SOanxQhihMKB2H0URseQdd1rqq/C0uyd TpHM5HCN3EYME8mDCcq/bvrNf0txprHKKL4M5uowMMRWMN0NOM= X-QQ-GoodBg: 2 From: juzhe.zhong@rivai.ai To: gcc-patches@gcc.gnu.org Cc: kito.cheng@gmail.com, Ju-Zhe Zhong Subject: [PATCH] RISC-V: Add vnsra C API tests Date: Fri, 10 Feb 2023 05:52:41 +0800 Message-Id: <20230209215241.23872-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:qybglogicsvr:qybglogicsvr7 X-Spam-Status: No, score=-12.8 required=5.0 tests=BAYES_00, GIT_PATCH_0, KAM_DMARC_STATUS, KAM_SHORT, 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.29 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 Sender: "Gcc-patches" X-getmail-retrieved-from-mailbox: =?utf-8?q?INBOX?= X-GMAIL-THRID: =?utf-8?q?1757392001919374276?= X-GMAIL-MSGID: =?utf-8?q?1757392001919374276?= From: Ju-Zhe Zhong gcc/testsuite/ChangeLog: * gcc.target/riscv/rvv/base/vnsra_wv-1.c: New test. * gcc.target/riscv/rvv/base/vnsra_wv-2.c: New test. * gcc.target/riscv/rvv/base/vnsra_wv-3.c: New test. * gcc.target/riscv/rvv/base/vnsra_wv_m-1.c: New test. * gcc.target/riscv/rvv/base/vnsra_wv_m-2.c: New test. * gcc.target/riscv/rvv/base/vnsra_wv_m-3.c: New test. * gcc.target/riscv/rvv/base/vnsra_wv_mu-1.c: New test. * gcc.target/riscv/rvv/base/vnsra_wv_mu-2.c: New test. * gcc.target/riscv/rvv/base/vnsra_wv_mu-3.c: New test. * gcc.target/riscv/rvv/base/vnsra_wv_tu-1.c: New test. * gcc.target/riscv/rvv/base/vnsra_wv_tu-2.c: New test. * gcc.target/riscv/rvv/base/vnsra_wv_tu-3.c: New test. * gcc.target/riscv/rvv/base/vnsra_wv_tum-1.c: New test. * gcc.target/riscv/rvv/base/vnsra_wv_tum-2.c: New test. * gcc.target/riscv/rvv/base/vnsra_wv_tum-3.c: New test. * gcc.target/riscv/rvv/base/vnsra_wv_tumu-1.c: New test. * gcc.target/riscv/rvv/base/vnsra_wv_tumu-2.c: New test. * gcc.target/riscv/rvv/base/vnsra_wv_tumu-3.c: New test. * gcc.target/riscv/rvv/base/vnsra_wx-1.c: New test. * gcc.target/riscv/rvv/base/vnsra_wx-2.c: New test. * gcc.target/riscv/rvv/base/vnsra_wx-3.c: New test. * gcc.target/riscv/rvv/base/vnsra_wx_m-1.c: New test. * gcc.target/riscv/rvv/base/vnsra_wx_m-2.c: New test. * gcc.target/riscv/rvv/base/vnsra_wx_m-3.c: New test. * gcc.target/riscv/rvv/base/vnsra_wx_mu-1.c: New test. * gcc.target/riscv/rvv/base/vnsra_wx_mu-2.c: New test. * gcc.target/riscv/rvv/base/vnsra_wx_mu-3.c: New test. * gcc.target/riscv/rvv/base/vnsra_wx_tu-1.c: New test. * gcc.target/riscv/rvv/base/vnsra_wx_tu-2.c: New test. * gcc.target/riscv/rvv/base/vnsra_wx_tu-3.c: New test. * gcc.target/riscv/rvv/base/vnsra_wx_tum-1.c: New test. * gcc.target/riscv/rvv/base/vnsra_wx_tum-2.c: New test. * gcc.target/riscv/rvv/base/vnsra_wx_tum-3.c: New test. * gcc.target/riscv/rvv/base/vnsra_wx_tumu-1.c: New test. * gcc.target/riscv/rvv/base/vnsra_wx_tumu-2.c: New test. * gcc.target/riscv/rvv/base/vnsra_wx_tumu-3.c: New test. --- .../gcc.target/riscv/rvv/base/vnsra_wv-1.c | 111 ++++++++++++++++++ .../gcc.target/riscv/rvv/base/vnsra_wv-2.c | 111 ++++++++++++++++++ .../gcc.target/riscv/rvv/base/vnsra_wv-3.c | 111 ++++++++++++++++++ .../gcc.target/riscv/rvv/base/vnsra_wv_m-1.c | 111 ++++++++++++++++++ .../gcc.target/riscv/rvv/base/vnsra_wv_m-2.c | 111 ++++++++++++++++++ .../gcc.target/riscv/rvv/base/vnsra_wv_m-3.c | 111 ++++++++++++++++++ .../gcc.target/riscv/rvv/base/vnsra_wv_mu-1.c | 111 ++++++++++++++++++ .../gcc.target/riscv/rvv/base/vnsra_wv_mu-2.c | 111 ++++++++++++++++++ .../gcc.target/riscv/rvv/base/vnsra_wv_mu-3.c | 111 ++++++++++++++++++ .../gcc.target/riscv/rvv/base/vnsra_wv_tu-1.c | 111 ++++++++++++++++++ .../gcc.target/riscv/rvv/base/vnsra_wv_tu-2.c | 111 ++++++++++++++++++ .../gcc.target/riscv/rvv/base/vnsra_wv_tu-3.c | 111 ++++++++++++++++++ .../riscv/rvv/base/vnsra_wv_tum-1.c | 111 ++++++++++++++++++ .../riscv/rvv/base/vnsra_wv_tum-2.c | 111 ++++++++++++++++++ .../riscv/rvv/base/vnsra_wv_tum-3.c | 111 ++++++++++++++++++ .../riscv/rvv/base/vnsra_wv_tumu-1.c | 111 ++++++++++++++++++ .../riscv/rvv/base/vnsra_wv_tumu-2.c | 111 ++++++++++++++++++ .../riscv/rvv/base/vnsra_wv_tumu-3.c | 111 ++++++++++++++++++ .../gcc.target/riscv/rvv/base/vnsra_wx-1.c | 111 ++++++++++++++++++ .../gcc.target/riscv/rvv/base/vnsra_wx-2.c | 111 ++++++++++++++++++ .../gcc.target/riscv/rvv/base/vnsra_wx-3.c | 111 ++++++++++++++++++ .../gcc.target/riscv/rvv/base/vnsra_wx_m-1.c | 111 ++++++++++++++++++ .../gcc.target/riscv/rvv/base/vnsra_wx_m-2.c | 111 ++++++++++++++++++ .../gcc.target/riscv/rvv/base/vnsra_wx_m-3.c | 111 ++++++++++++++++++ .../gcc.target/riscv/rvv/base/vnsra_wx_mu-1.c | 111 ++++++++++++++++++ .../gcc.target/riscv/rvv/base/vnsra_wx_mu-2.c | 111 ++++++++++++++++++ .../gcc.target/riscv/rvv/base/vnsra_wx_mu-3.c | 111 ++++++++++++++++++ .../gcc.target/riscv/rvv/base/vnsra_wx_tu-1.c | 111 ++++++++++++++++++ .../gcc.target/riscv/rvv/base/vnsra_wx_tu-2.c | 111 ++++++++++++++++++ .../gcc.target/riscv/rvv/base/vnsra_wx_tu-3.c | 111 ++++++++++++++++++ .../riscv/rvv/base/vnsra_wx_tum-1.c | 111 ++++++++++++++++++ .../riscv/rvv/base/vnsra_wx_tum-2.c | 111 ++++++++++++++++++ .../riscv/rvv/base/vnsra_wx_tum-3.c | 111 ++++++++++++++++++ .../riscv/rvv/base/vnsra_wx_tumu-1.c | 111 ++++++++++++++++++ .../riscv/rvv/base/vnsra_wx_tumu-2.c | 111 ++++++++++++++++++ .../riscv/rvv/base/vnsra_wx_tumu-3.c | 111 ++++++++++++++++++ 36 files changed, 3996 insertions(+) create mode 100644 gcc/testsuite/gcc.target/riscv/rvv/base/vnsra_wv-1.c create mode 100644 gcc/testsuite/gcc.target/riscv/rvv/base/vnsra_wv-2.c create mode 100644 gcc/testsuite/gcc.target/riscv/rvv/base/vnsra_wv-3.c create mode 100644 gcc/testsuite/gcc.target/riscv/rvv/base/vnsra_wv_m-1.c create mode 100644 gcc/testsuite/gcc.target/riscv/rvv/base/vnsra_wv_m-2.c create mode 100644 gcc/testsuite/gcc.target/riscv/rvv/base/vnsra_wv_m-3.c create mode 100644 gcc/testsuite/gcc.target/riscv/rvv/base/vnsra_wv_mu-1.c create mode 100644 gcc/testsuite/gcc.target/riscv/rvv/base/vnsra_wv_mu-2.c create mode 100644 gcc/testsuite/gcc.target/riscv/rvv/base/vnsra_wv_mu-3.c create mode 100644 gcc/testsuite/gcc.target/riscv/rvv/base/vnsra_wv_tu-1.c create mode 100644 gcc/testsuite/gcc.target/riscv/rvv/base/vnsra_wv_tu-2.c create mode 100644 gcc/testsuite/gcc.target/riscv/rvv/base/vnsra_wv_tu-3.c create mode 100644 gcc/testsuite/gcc.target/riscv/rvv/base/vnsra_wv_tum-1.c create mode 100644 gcc/testsuite/gcc.target/riscv/rvv/base/vnsra_wv_tum-2.c create mode 100644 gcc/testsuite/gcc.target/riscv/rvv/base/vnsra_wv_tum-3.c create mode 100644 gcc/testsuite/gcc.target/riscv/rvv/base/vnsra_wv_tumu-1.c create mode 100644 gcc/testsuite/gcc.target/riscv/rvv/base/vnsra_wv_tumu-2.c create mode 100644 gcc/testsuite/gcc.target/riscv/rvv/base/vnsra_wv_tumu-3.c create mode 100644 gcc/testsuite/gcc.target/riscv/rvv/base/vnsra_wx-1.c create mode 100644 gcc/testsuite/gcc.target/riscv/rvv/base/vnsra_wx-2.c create mode 100644 gcc/testsuite/gcc.target/riscv/rvv/base/vnsra_wx-3.c create mode 100644 gcc/testsuite/gcc.target/riscv/rvv/base/vnsra_wx_m-1.c create mode 100644 gcc/testsuite/gcc.target/riscv/rvv/base/vnsra_wx_m-2.c create mode 100644 gcc/testsuite/gcc.target/riscv/rvv/base/vnsra_wx_m-3.c create mode 100644 gcc/testsuite/gcc.target/riscv/rvv/base/vnsra_wx_mu-1.c create mode 100644 gcc/testsuite/gcc.target/riscv/rvv/base/vnsra_wx_mu-2.c create mode 100644 gcc/testsuite/gcc.target/riscv/rvv/base/vnsra_wx_mu-3.c create mode 100644 gcc/testsuite/gcc.target/riscv/rvv/base/vnsra_wx_tu-1.c create mode 100644 gcc/testsuite/gcc.target/riscv/rvv/base/vnsra_wx_tu-2.c create mode 100644 gcc/testsuite/gcc.target/riscv/rvv/base/vnsra_wx_tu-3.c create mode 100644 gcc/testsuite/gcc.target/riscv/rvv/base/vnsra_wx_tum-1.c create mode 100644 gcc/testsuite/gcc.target/riscv/rvv/base/vnsra_wx_tum-2.c create mode 100644 gcc/testsuite/gcc.target/riscv/rvv/base/vnsra_wx_tum-3.c create mode 100644 gcc/testsuite/gcc.target/riscv/rvv/base/vnsra_wx_tumu-1.c create mode 100644 gcc/testsuite/gcc.target/riscv/rvv/base/vnsra_wx_tumu-2.c create mode 100644 gcc/testsuite/gcc.target/riscv/rvv/base/vnsra_wx_tumu-3.c diff --git a/gcc/testsuite/gcc.target/riscv/rvv/base/vnsra_wv-1.c b/gcc/testsuite/gcc.target/riscv/rvv/base/vnsra_wv-1.c new file mode 100644 index 00000000000..699d2a41238 --- /dev/null +++ b/gcc/testsuite/gcc.target/riscv/rvv/base/vnsra_wv-1.c @@ -0,0 +1,111 @@ +/* { dg-do compile } */ +/* { dg-options "-march=rv64gcv -mabi=lp64d -O3 -fno-schedule-insns -fno-schedule-insns2" } */ + +#include "riscv_vector.h" + +vint8mf8_t test___riscv_vnsra_wv_i8mf8(vint16mf4_t op1,vuint8mf8_t shift,size_t vl) +{ + return __riscv_vnsra_wv_i8mf8(op1,shift,vl); +} + + +vint8mf4_t test___riscv_vnsra_wv_i8mf4(vint16mf2_t op1,vuint8mf4_t shift,size_t vl) +{ + return __riscv_vnsra_wv_i8mf4(op1,shift,vl); +} + + +vint8mf2_t test___riscv_vnsra_wv_i8mf2(vint16m1_t op1,vuint8mf2_t shift,size_t vl) +{ + return __riscv_vnsra_wv_i8mf2(op1,shift,vl); +} + + +vint8m1_t test___riscv_vnsra_wv_i8m1(vint16m2_t op1,vuint8m1_t shift,size_t vl) +{ + return __riscv_vnsra_wv_i8m1(op1,shift,vl); +} + + +vint8m2_t test___riscv_vnsra_wv_i8m2(vint16m4_t op1,vuint8m2_t shift,size_t vl) +{ + return __riscv_vnsra_wv_i8m2(op1,shift,vl); +} + + +vint8m4_t test___riscv_vnsra_wv_i8m4(vint16m8_t op1,vuint8m4_t shift,size_t vl) +{ + return __riscv_vnsra_wv_i8m4(op1,shift,vl); +} + + +vint16mf4_t test___riscv_vnsra_wv_i16mf4(vint32mf2_t op1,vuint16mf4_t shift,size_t vl) +{ + return __riscv_vnsra_wv_i16mf4(op1,shift,vl); +} + + +vint16mf2_t test___riscv_vnsra_wv_i16mf2(vint32m1_t op1,vuint16mf2_t shift,size_t vl) +{ + return __riscv_vnsra_wv_i16mf2(op1,shift,vl); +} + + +vint16m1_t test___riscv_vnsra_wv_i16m1(vint32m2_t op1,vuint16m1_t shift,size_t vl) +{ + return __riscv_vnsra_wv_i16m1(op1,shift,vl); +} + + +vint16m2_t test___riscv_vnsra_wv_i16m2(vint32m4_t op1,vuint16m2_t shift,size_t vl) +{ + return __riscv_vnsra_wv_i16m2(op1,shift,vl); +} + + +vint16m4_t test___riscv_vnsra_wv_i16m4(vint32m8_t op1,vuint16m4_t shift,size_t vl) +{ + return __riscv_vnsra_wv_i16m4(op1,shift,vl); +} + + +vint32mf2_t test___riscv_vnsra_wv_i32mf2(vint64m1_t op1,vuint32mf2_t shift,size_t vl) +{ + return __riscv_vnsra_wv_i32mf2(op1,shift,vl); +} + + +vint32m1_t test___riscv_vnsra_wv_i32m1(vint64m2_t op1,vuint32m1_t shift,size_t vl) +{ + return __riscv_vnsra_wv_i32m1(op1,shift,vl); +} + + +vint32m2_t test___riscv_vnsra_wv_i32m2(vint64m4_t op1,vuint32m2_t shift,size_t vl) +{ + return __riscv_vnsra_wv_i32m2(op1,shift,vl); +} + + +vint32m4_t test___riscv_vnsra_wv_i32m4(vint64m8_t op1,vuint32m4_t shift,size_t vl) +{ + return __riscv_vnsra_wv_i32m4(op1,shift,vl); +} + + + +/* { dg-final { scan-assembler-times {vsetvli\s+zero,\s*[a-x0-9]+,\s*e8,\s*mf8,\s*t[au],\s*m[au]\s+vnsra\.wv\s+v[0-9]+,\s*v[0-9]+,\s*v[0-9]+} 1 } } */ +/* { dg-final { scan-assembler-times {vsetvli\s+zero,\s*[a-x0-9]+,\s*e8,\s*mf4,\s*t[au],\s*m[au]\s+vnsra\.wv\s+v[0-9]+,\s*v[0-9]+,\s*v[0-9]+} 1 } } */ +/* { dg-final { scan-assembler-times {vsetvli\s+zero,\s*[a-x0-9]+,\s*e8,\s*mf2,\s*t[au],\s*m[au]\s+vnsra\.wv\s+v[0-9]+,\s*v[0-9]+,\s*v[0-9]+} 1 } } */ +/* { dg-final { scan-assembler-times {vsetvli\s+zero,\s*[a-x0-9]+,\s*e8,\s*m1,\s*t[au],\s*m[au]\s+vnsra\.wv\s+v[0-9]+,\s*v[0-9]+,\s*v[0-9]+} 1 } } */ +/* { dg-final { scan-assembler-times {vsetvli\s+zero,\s*[a-x0-9]+,\s*e8,\s*m2,\s*t[au],\s*m[au]\s+vnsra\.wv\s+v[0-9]+,\s*v[0-9]+,\s*v[0-9]+} 1 } } */ +/* { dg-final { scan-assembler-times {vsetvli\s+zero,\s*[a-x0-9]+,\s*e8,\s*m4,\s*t[au],\s*m[au]\s+vnsra\.wv\s+v[0-9]+,\s*v[0-9]+,\s*v[0-9]+} 1 } } */ +/* { dg-final { scan-assembler-times {vsetvli\s+zero,\s*[a-x0-9]+,\s*e16,\s*mf4,\s*t[au],\s*m[au]\s+vnsra\.wv\s+v[0-9]+,\s*v[0-9]+,\s*v[0-9]+} 1 } } */ +/* { dg-final { scan-assembler-times {vsetvli\s+zero,\s*[a-x0-9]+,\s*e16,\s*mf2,\s*t[au],\s*m[au]\s+vnsra\.wv\s+v[0-9]+,\s*v[0-9]+,\s*v[0-9]+} 1 } } */ +/* { dg-final { scan-assembler-times {vsetvli\s+zero,\s*[a-x0-9]+,\s*e16,\s*m1,\s*t[au],\s*m[au]\s+vnsra\.wv\s+v[0-9]+,\s*v[0-9]+,\s*v[0-9]+} 1 } } */ +/* { dg-final { scan-assembler-times {vsetvli\s+zero,\s*[a-x0-9]+,\s*e16,\s*m2,\s*t[au],\s*m[au]\s+vnsra\.wv\s+v[0-9]+,\s*v[0-9]+,\s*v[0-9]+} 1 } } */ +/* { dg-final { scan-assembler-times {vsetvli\s+zero,\s*[a-x0-9]+,\s*e16,\s*m4,\s*t[au],\s*m[au]\s+vnsra\.wv\s+v[0-9]+,\s*v[0-9]+,\s*v[0-9]+} 1 } } */ +/* { dg-final { scan-assembler-times {vsetvli\s+zero,\s*[a-x0-9]+,\s*e32,\s*mf2,\s*t[au],\s*m[au]\s+vnsra\.wv\s+v[0-9]+,\s*v[0-9]+,\s*v[0-9]+} 1 } } */ +/* { dg-final { scan-assembler-times {vsetvli\s+zero,\s*[a-x0-9]+,\s*e32,\s*m1,\s*t[au],\s*m[au]\s+vnsra\.wv\s+v[0-9]+,\s*v[0-9]+,\s*v[0-9]+} 1 } } */ +/* { dg-final { scan-assembler-times {vsetvli\s+zero,\s*[a-x0-9]+,\s*e32,\s*m2,\s*t[au],\s*m[au]\s+vnsra\.wv\s+v[0-9]+,\s*v[0-9]+,\s*v[0-9]+} 1 } } */ +/* { dg-final { scan-assembler-times {vsetvli\s+zero,\s*[a-x0-9]+,\s*e32,\s*m4,\s*t[au],\s*m[au]\s+vnsra\.wv\s+v[0-9]+,\s*v[0-9]+,\s*v[0-9]+} 1 } } */ diff --git a/gcc/testsuite/gcc.target/riscv/rvv/base/vnsra_wv-2.c b/gcc/testsuite/gcc.target/riscv/rvv/base/vnsra_wv-2.c new file mode 100644 index 00000000000..8930860ffbd --- /dev/null +++ b/gcc/testsuite/gcc.target/riscv/rvv/base/vnsra_wv-2.c @@ -0,0 +1,111 @@ +/* { dg-do compile } */ +/* { dg-options "-march=rv64gcv -mabi=lp64d -O3 -fno-schedule-insns -fno-schedule-insns2" } */ + +#include "riscv_vector.h" + +vint8mf8_t test___riscv_vnsra_wv_i8mf8(vint16mf4_t op1,vuint8mf8_t shift,size_t vl) +{ + return __riscv_vnsra_wv_i8mf8(op1,shift,31); +} + + +vint8mf4_t test___riscv_vnsra_wv_i8mf4(vint16mf2_t op1,vuint8mf4_t shift,size_t vl) +{ + return __riscv_vnsra_wv_i8mf4(op1,shift,31); +} + + +vint8mf2_t test___riscv_vnsra_wv_i8mf2(vint16m1_t op1,vuint8mf2_t shift,size_t vl) +{ + return __riscv_vnsra_wv_i8mf2(op1,shift,31); +} + + +vint8m1_t test___riscv_vnsra_wv_i8m1(vint16m2_t op1,vuint8m1_t shift,size_t vl) +{ + return __riscv_vnsra_wv_i8m1(op1,shift,31); +} + + +vint8m2_t test___riscv_vnsra_wv_i8m2(vint16m4_t op1,vuint8m2_t shift,size_t vl) +{ + return __riscv_vnsra_wv_i8m2(op1,shift,31); +} + + +vint8m4_t test___riscv_vnsra_wv_i8m4(vint16m8_t op1,vuint8m4_t shift,size_t vl) +{ + return __riscv_vnsra_wv_i8m4(op1,shift,31); +} + + +vint16mf4_t test___riscv_vnsra_wv_i16mf4(vint32mf2_t op1,vuint16mf4_t shift,size_t vl) +{ + return __riscv_vnsra_wv_i16mf4(op1,shift,31); +} + + +vint16mf2_t test___riscv_vnsra_wv_i16mf2(vint32m1_t op1,vuint16mf2_t shift,size_t vl) +{ + return __riscv_vnsra_wv_i16mf2(op1,shift,31); +} + + +vint16m1_t test___riscv_vnsra_wv_i16m1(vint32m2_t op1,vuint16m1_t shift,size_t vl) +{ + return __riscv_vnsra_wv_i16m1(op1,shift,31); +} + + +vint16m2_t test___riscv_vnsra_wv_i16m2(vint32m4_t op1,vuint16m2_t shift,size_t vl) +{ + return __riscv_vnsra_wv_i16m2(op1,shift,31); +} + + +vint16m4_t test___riscv_vnsra_wv_i16m4(vint32m8_t op1,vuint16m4_t shift,size_t vl) +{ + return __riscv_vnsra_wv_i16m4(op1,shift,31); +} + + +vint32mf2_t test___riscv_vnsra_wv_i32mf2(vint64m1_t op1,vuint32mf2_t shift,size_t vl) +{ + return __riscv_vnsra_wv_i32mf2(op1,shift,31); +} + + +vint32m1_t test___riscv_vnsra_wv_i32m1(vint64m2_t op1,vuint32m1_t shift,size_t vl) +{ + return __riscv_vnsra_wv_i32m1(op1,shift,31); +} + + +vint32m2_t test___riscv_vnsra_wv_i32m2(vint64m4_t op1,vuint32m2_t shift,size_t vl) +{ + return __riscv_vnsra_wv_i32m2(op1,shift,31); +} + + +vint32m4_t test___riscv_vnsra_wv_i32m4(vint64m8_t op1,vuint32m4_t shift,size_t vl) +{ + return __riscv_vnsra_wv_i32m4(op1,shift,31); +} + + + +/* { dg-final { scan-assembler-times {vsetivli\s+zero,\s*31,\s*e8,\s*mf8,\s*t[au],\s*m[au]\s+vnsra\.wv\s+v[0-9]+,\s*v[0-9]+,\s*v[0-9]+} 1 } } */ +/* { dg-final { scan-assembler-times {vsetivli\s+zero,\s*31,\s*e8,\s*mf4,\s*t[au],\s*m[au]\s+vnsra\.wv\s+v[0-9]+,\s*v[0-9]+,\s*v[0-9]+} 1 } } */ +/* { dg-final { scan-assembler-times {vsetivli\s+zero,\s*31,\s*e8,\s*mf2,\s*t[au],\s*m[au]\s+vnsra\.wv\s+v[0-9]+,\s*v[0-9]+,\s*v[0-9]+} 1 } } */ +/* { dg-final { scan-assembler-times {vsetivli\s+zero,\s*31,\s*e8,\s*m1,\s*t[au],\s*m[au]\s+vnsra\.wv\s+v[0-9]+,\s*v[0-9]+,\s*v[0-9]+} 1 } } */ +/* { dg-final { scan-assembler-times {vsetivli\s+zero,\s*31,\s*e8,\s*m2,\s*t[au],\s*m[au]\s+vnsra\.wv\s+v[0-9]+,\s*v[0-9]+,\s*v[0-9]+} 1 } } */ +/* { dg-final { scan-assembler-times {vsetivli\s+zero,\s*31,\s*e8,\s*m4,\s*t[au],\s*m[au]\s+vnsra\.wv\s+v[0-9]+,\s*v[0-9]+,\s*v[0-9]+} 1 } } */ +/* { dg-final { scan-assembler-times {vsetivli\s+zero,\s*31,\s*e16,\s*mf4,\s*t[au],\s*m[au]\s+vnsra\.wv\s+v[0-9]+,\s*v[0-9]+,\s*v[0-9]+} 1 } } */ +/* { dg-final { scan-assembler-times {vsetivli\s+zero,\s*31,\s*e16,\s*mf2,\s*t[au],\s*m[au]\s+vnsra\.wv\s+v[0-9]+,\s*v[0-9]+,\s*v[0-9]+} 1 } } */ +/* { dg-final { scan-assembler-times {vsetivli\s+zero,\s*31,\s*e16,\s*m1,\s*t[au],\s*m[au]\s+vnsra\.wv\s+v[0-9]+,\s*v[0-9]+,\s*v[0-9]+} 1 } } */ +/* { dg-final { scan-assembler-times {vsetivli\s+zero,\s*31,\s*e16,\s*m2,\s*t[au],\s*m[au]\s+vnsra\.wv\s+v[0-9]+,\s*v[0-9]+,\s*v[0-9]+} 1 } } */ +/* { dg-final { scan-assembler-times {vsetivli\s+zero,\s*31,\s*e16,\s*m4,\s*t[au],\s*m[au]\s+vnsra\.wv\s+v[0-9]+,\s*v[0-9]+,\s*v[0-9]+} 1 } } */ +/* { dg-final { scan-assembler-times {vsetivli\s+zero,\s*31,\s*e32,\s*mf2,\s*t[au],\s*m[au]\s+vnsra\.wv\s+v[0-9]+,\s*v[0-9]+,\s*v[0-9]+} 1 } } */ +/* { dg-final { scan-assembler-times {vsetivli\s+zero,\s*31,\s*e32,\s*m1,\s*t[au],\s*m[au]\s+vnsra\.wv\s+v[0-9]+,\s*v[0-9]+,\s*v[0-9]+} 1 } } */ +/* { dg-final { scan-assembler-times {vsetivli\s+zero,\s*31,\s*e32,\s*m2,\s*t[au],\s*m[au]\s+vnsra\.wv\s+v[0-9]+,\s*v[0-9]+,\s*v[0-9]+} 1 } } */ +/* { dg-final { scan-assembler-times {vsetivli\s+zero,\s*31,\s*e32,\s*m4,\s*t[au],\s*m[au]\s+vnsra\.wv\s+v[0-9]+,\s*v[0-9]+,\s*v[0-9]+} 1 } } */ diff --git a/gcc/testsuite/gcc.target/riscv/rvv/base/vnsra_wv-3.c b/gcc/testsuite/gcc.target/riscv/rvv/base/vnsra_wv-3.c new file mode 100644 index 00000000000..1163624298f --- /dev/null +++ b/gcc/testsuite/gcc.target/riscv/rvv/base/vnsra_wv-3.c @@ -0,0 +1,111 @@ +/* { dg-do compile } */ +/* { dg-options "-march=rv64gcv -mabi=lp64d -O3 -fno-schedule-insns -fno-schedule-insns2" } */ + +#include "riscv_vector.h" + +vint8mf8_t test___riscv_vnsra_wv_i8mf8(vint16mf4_t op1,vuint8mf8_t shift,size_t vl) +{ + return __riscv_vnsra_wv_i8mf8(op1,shift,32); +} + + +vint8mf4_t test___riscv_vnsra_wv_i8mf4(vint16mf2_t op1,vuint8mf4_t shift,size_t vl) +{ + return __riscv_vnsra_wv_i8mf4(op1,shift,32); +} + + +vint8mf2_t test___riscv_vnsra_wv_i8mf2(vint16m1_t op1,vuint8mf2_t shift,size_t vl) +{ + return __riscv_vnsra_wv_i8mf2(op1,shift,32); +} + + +vint8m1_t test___riscv_vnsra_wv_i8m1(vint16m2_t op1,vuint8m1_t shift,size_t vl) +{ + return __riscv_vnsra_wv_i8m1(op1,shift,32); +} + + +vint8m2_t test___riscv_vnsra_wv_i8m2(vint16m4_t op1,vuint8m2_t shift,size_t vl) +{ + return __riscv_vnsra_wv_i8m2(op1,shift,32); +} + + +vint8m4_t test___riscv_vnsra_wv_i8m4(vint16m8_t op1,vuint8m4_t shift,size_t vl) +{ + return __riscv_vnsra_wv_i8m4(op1,shift,32); +} + + +vint16mf4_t test___riscv_vnsra_wv_i16mf4(vint32mf2_t op1,vuint16mf4_t shift,size_t vl) +{ + return __riscv_vnsra_wv_i16mf4(op1,shift,32); +} + + +vint16mf2_t test___riscv_vnsra_wv_i16mf2(vint32m1_t op1,vuint16mf2_t shift,size_t vl) +{ + return __riscv_vnsra_wv_i16mf2(op1,shift,32); +} + + +vint16m1_t test___riscv_vnsra_wv_i16m1(vint32m2_t op1,vuint16m1_t shift,size_t vl) +{ + return __riscv_vnsra_wv_i16m1(op1,shift,32); +} + + +vint16m2_t test___riscv_vnsra_wv_i16m2(vint32m4_t op1,vuint16m2_t shift,size_t vl) +{ + return __riscv_vnsra_wv_i16m2(op1,shift,32); +} + + +vint16m4_t test___riscv_vnsra_wv_i16m4(vint32m8_t op1,vuint16m4_t shift,size_t vl) +{ + return __riscv_vnsra_wv_i16m4(op1,shift,32); +} + + +vint32mf2_t test___riscv_vnsra_wv_i32mf2(vint64m1_t op1,vuint32mf2_t shift,size_t vl) +{ + return __riscv_vnsra_wv_i32mf2(op1,shift,32); +} + + +vint32m1_t test___riscv_vnsra_wv_i32m1(vint64m2_t op1,vuint32m1_t shift,size_t vl) +{ + return __riscv_vnsra_wv_i32m1(op1,shift,32); +} + + +vint32m2_t test___riscv_vnsra_wv_i32m2(vint64m4_t op1,vuint32m2_t shift,size_t vl) +{ + return __riscv_vnsra_wv_i32m2(op1,shift,32); +} + + +vint32m4_t test___riscv_vnsra_wv_i32m4(vint64m8_t op1,vuint32m4_t shift,size_t vl) +{ + return __riscv_vnsra_wv_i32m4(op1,shift,32); +} + + + +/* { dg-final { scan-assembler-times {vsetvli\s+zero,\s*[a-x0-9]+,\s*e8,\s*mf8,\s*t[au],\s*m[au]\s+vnsra\.wv\s+v[0-9]+,\s*v[0-9]+,\s*v[0-9]+} 1 } } */ +/* { dg-final { scan-assembler-times {vsetvli\s+zero,\s*[a-x0-9]+,\s*e8,\s*mf4,\s*t[au],\s*m[au]\s+vnsra\.wv\s+v[0-9]+,\s*v[0-9]+,\s*v[0-9]+} 1 } } */ +/* { dg-final { scan-assembler-times {vsetvli\s+zero,\s*[a-x0-9]+,\s*e8,\s*mf2,\s*t[au],\s*m[au]\s+vnsra\.wv\s+v[0-9]+,\s*v[0-9]+,\s*v[0-9]+} 1 } } */ +/* { dg-final { scan-assembler-times {vsetvli\s+zero,\s*[a-x0-9]+,\s*e8,\s*m1,\s*t[au],\s*m[au]\s+vnsra\.wv\s+v[0-9]+,\s*v[0-9]+,\s*v[0-9]+} 1 } } */ +/* { dg-final { scan-assembler-times {vsetvli\s+zero,\s*[a-x0-9]+,\s*e8,\s*m2,\s*t[au],\s*m[au]\s+vnsra\.wv\s+v[0-9]+,\s*v[0-9]+,\s*v[0-9]+} 1 } } */ +/* { dg-final { scan-assembler-times {vsetvli\s+zero,\s*[a-x0-9]+,\s*e8,\s*m4,\s*t[au],\s*m[au]\s+vnsra\.wv\s+v[0-9]+,\s*v[0-9]+,\s*v[0-9]+} 1 } } */ +/* { dg-final { scan-assembler-times {vsetvli\s+zero,\s*[a-x0-9]+,\s*e16,\s*mf4,\s*t[au],\s*m[au]\s+vnsra\.wv\s+v[0-9]+,\s*v[0-9]+,\s*v[0-9]+} 1 } } */ +/* { dg-final { scan-assembler-times {vsetvli\s+zero,\s*[a-x0-9]+,\s*e16,\s*mf2,\s*t[au],\s*m[au]\s+vnsra\.wv\s+v[0-9]+,\s*v[0-9]+,\s*v[0-9]+} 1 } } */ +/* { dg-final { scan-assembler-times {vsetvli\s+zero,\s*[a-x0-9]+,\s*e16,\s*m1,\s*t[au],\s*m[au]\s+vnsra\.wv\s+v[0-9]+,\s*v[0-9]+,\s*v[0-9]+} 1 } } */ +/* { dg-final { scan-assembler-times {vsetvli\s+zero,\s*[a-x0-9]+,\s*e16,\s*m2,\s*t[au],\s*m[au]\s+vnsra\.wv\s+v[0-9]+,\s*v[0-9]+,\s*v[0-9]+} 1 } } */ +/* { dg-final { scan-assembler-times {vsetvli\s+zero,\s*[a-x0-9]+,\s*e16,\s*m4,\s*t[au],\s*m[au]\s+vnsra\.wv\s+v[0-9]+,\s*v[0-9]+,\s*v[0-9]+} 1 } } */ +/* { dg-final { scan-assembler-times {vsetvli\s+zero,\s*[a-x0-9]+,\s*e32,\s*mf2,\s*t[au],\s*m[au]\s+vnsra\.wv\s+v[0-9]+,\s*v[0-9]+,\s*v[0-9]+} 1 } } */ +/* { dg-final { scan-assembler-times {vsetvli\s+zero,\s*[a-x0-9]+,\s*e32,\s*m1,\s*t[au],\s*m[au]\s+vnsra\.wv\s+v[0-9]+,\s*v[0-9]+,\s*v[0-9]+} 1 } } */ +/* { dg-final { scan-assembler-times {vsetvli\s+zero,\s*[a-x0-9]+,\s*e32,\s*m2,\s*t[au],\s*m[au]\s+vnsra\.wv\s+v[0-9]+,\s*v[0-9]+,\s*v[0-9]+} 1 } } */ +/* { dg-final { scan-assembler-times {vsetvli\s+zero,\s*[a-x0-9]+,\s*e32,\s*m4,\s*t[au],\s*m[au]\s+vnsra\.wv\s+v[0-9]+,\s*v[0-9]+,\s*v[0-9]+} 1 } } */ diff --git a/gcc/testsuite/gcc.target/riscv/rvv/base/vnsra_wv_m-1.c b/gcc/testsuite/gcc.target/riscv/rvv/base/vnsra_wv_m-1.c new file mode 100644 index 00000000000..3200a4301da --- /dev/null +++ b/gcc/testsuite/gcc.target/riscv/rvv/base/vnsra_wv_m-1.c @@ -0,0 +1,111 @@ +/* { dg-do compile } */ +/* { dg-options "-march=rv64gcv -mabi=lp64d -O3 -fno-schedule-insns -fno-schedule-insns2" } */ + +#include "riscv_vector.h" + +vint8mf8_t test___riscv_vnsra_wv_i8mf8_m(vbool64_t mask,vint16mf4_t op1,vuint8mf8_t shift,size_t vl) +{ + return __riscv_vnsra_wv_i8mf8_m(mask,op1,shift,vl); +} + + +vint8mf4_t test___riscv_vnsra_wv_i8mf4_m(vbool32_t mask,vint16mf2_t op1,vuint8mf4_t shift,size_t vl) +{ + return __riscv_vnsra_wv_i8mf4_m(mask,op1,shift,vl); +} + + +vint8mf2_t test___riscv_vnsra_wv_i8mf2_m(vbool16_t mask,vint16m1_t op1,vuint8mf2_t shift,size_t vl) +{ + return __riscv_vnsra_wv_i8mf2_m(mask,op1,shift,vl); +} + + +vint8m1_t test___riscv_vnsra_wv_i8m1_m(vbool8_t mask,vint16m2_t op1,vuint8m1_t shift,size_t vl) +{ + return __riscv_vnsra_wv_i8m1_m(mask,op1,shift,vl); +} + + +vint8m2_t test___riscv_vnsra_wv_i8m2_m(vbool4_t mask,vint16m4_t op1,vuint8m2_t shift,size_t vl) +{ + return __riscv_vnsra_wv_i8m2_m(mask,op1,shift,vl); +} + + +vint8m4_t test___riscv_vnsra_wv_i8m4_m(vbool2_t mask,vint16m8_t op1,vuint8m4_t shift,size_t vl) +{ + return __riscv_vnsra_wv_i8m4_m(mask,op1,shift,vl); +} + + +vint16mf4_t test___riscv_vnsra_wv_i16mf4_m(vbool64_t mask,vint32mf2_t op1,vuint16mf4_t shift,size_t vl) +{ + return __riscv_vnsra_wv_i16mf4_m(mask,op1,shift,vl); +} + + +vint16mf2_t test___riscv_vnsra_wv_i16mf2_m(vbool32_t mask,vint32m1_t op1,vuint16mf2_t shift,size_t vl) +{ + return __riscv_vnsra_wv_i16mf2_m(mask,op1,shift,vl); +} + + +vint16m1_t test___riscv_vnsra_wv_i16m1_m(vbool16_t mask,vint32m2_t op1,vuint16m1_t shift,size_t vl) +{ + return __riscv_vnsra_wv_i16m1_m(mask,op1,shift,vl); +} + + +vint16m2_t test___riscv_vnsra_wv_i16m2_m(vbool8_t mask,vint32m4_t op1,vuint16m2_t shift,size_t vl) +{ + return __riscv_vnsra_wv_i16m2_m(mask,op1,shift,vl); +} + + +vint16m4_t test___riscv_vnsra_wv_i16m4_m(vbool4_t mask,vint32m8_t op1,vuint16m4_t shift,size_t vl) +{ + return __riscv_vnsra_wv_i16m4_m(mask,op1,shift,vl); +} + + +vint32mf2_t test___riscv_vnsra_wv_i32mf2_m(vbool64_t mask,vint64m1_t op1,vuint32mf2_t shift,size_t vl) +{ + return __riscv_vnsra_wv_i32mf2_m(mask,op1,shift,vl); +} + + +vint32m1_t test___riscv_vnsra_wv_i32m1_m(vbool32_t mask,vint64m2_t op1,vuint32m1_t shift,size_t vl) +{ + return __riscv_vnsra_wv_i32m1_m(mask,op1,shift,vl); +} + + +vint32m2_t test___riscv_vnsra_wv_i32m2_m(vbool16_t mask,vint64m4_t op1,vuint32m2_t shift,size_t vl) +{ + return __riscv_vnsra_wv_i32m2_m(mask,op1,shift,vl); +} + + +vint32m4_t test___riscv_vnsra_wv_i32m4_m(vbool8_t mask,vint64m8_t op1,vuint32m4_t shift,size_t vl) +{ + return __riscv_vnsra_wv_i32m4_m(mask,op1,shift,vl); +} + + + +/* { dg-final { scan-assembler-times {vsetvli\s+zero,\s*[a-x0-9]+,\s*e8,\s*mf8,\s*t[au],\s*m[au]\s+vnsra\.wv\s+v[0-9]+,\s*v[0-9]+,\s*v[0-9]+,\s*v0.t} 1 } } */ +/* { dg-final { scan-assembler-times {vsetvli\s+zero,\s*[a-x0-9]+,\s*e8,\s*mf4,\s*t[au],\s*m[au]\s+vnsra\.wv\s+v[0-9]+,\s*v[0-9]+,\s*v[0-9]+,\s*v0.t} 1 } } */ +/* { dg-final { scan-assembler-times {vsetvli\s+zero,\s*[a-x0-9]+,\s*e8,\s*mf2,\s*t[au],\s*m[au]\s+vnsra\.wv\s+v[0-9]+,\s*v[0-9]+,\s*v[0-9]+,\s*v0.t} 1 } } */ +/* { dg-final { scan-assembler-times {vsetvli\s+zero,\s*[a-x0-9]+,\s*e8,\s*m1,\s*t[au],\s*m[au]\s+vnsra\.wv\s+v[0-9]+,\s*v[0-9]+,\s*v[0-9]+,\s*v0.t} 1 } } */ +/* { dg-final { scan-assembler-times {vsetvli\s+zero,\s*[a-x0-9]+,\s*e8,\s*m2,\s*t[au],\s*m[au]\s+vnsra\.wv\s+v[0-9]+,\s*v[0-9]+,\s*v[0-9]+,\s*v0.t} 1 } } */ +/* { dg-final { scan-assembler-times {vsetvli\s+zero,\s*[a-x0-9]+,\s*e8,\s*m4,\s*t[au],\s*m[au]\s+vnsra\.wv\s+v[0-9]+,\s*v[0-9]+,\s*v[0-9]+,\s*v0.t} 1 } } */ +/* { dg-final { scan-assembler-times {vsetvli\s+zero,\s*[a-x0-9]+,\s*e16,\s*mf4,\s*t[au],\s*m[au]\s+vnsra\.wv\s+v[0-9]+,\s*v[0-9]+,\s*v[0-9]+,\s*v0.t} 1 } } */ +/* { dg-final { scan-assembler-times {vsetvli\s+zero,\s*[a-x0-9]+,\s*e16,\s*mf2,\s*t[au],\s*m[au]\s+vnsra\.wv\s+v[0-9]+,\s*v[0-9]+,\s*v[0-9]+,\s*v0.t} 1 } } */ +/* { dg-final { scan-assembler-times {vsetvli\s+zero,\s*[a-x0-9]+,\s*e16,\s*m1,\s*t[au],\s*m[au]\s+vnsra\.wv\s+v[0-9]+,\s*v[0-9]+,\s*v[0-9]+,\s*v0.t} 1 } } */ +/* { dg-final { scan-assembler-times {vsetvli\s+zero,\s*[a-x0-9]+,\s*e16,\s*m2,\s*t[au],\s*m[au]\s+vnsra\.wv\s+v[0-9]+,\s*v[0-9]+,\s*v[0-9]+,\s*v0.t} 1 } } */ +/* { dg-final { scan-assembler-times {vsetvli\s+zero,\s*[a-x0-9]+,\s*e16,\s*m4,\s*t[au],\s*m[au]\s+vnsra\.wv\s+v[0-9]+,\s*v[0-9]+,\s*v[0-9]+,\s*v0.t} 1 } } */ +/* { dg-final { scan-assembler-times {vsetvli\s+zero,\s*[a-x0-9]+,\s*e32,\s*mf2,\s*t[au],\s*m[au]\s+vnsra\.wv\s+v[0-9]+,\s*v[0-9]+,\s*v[0-9]+,\s*v0.t} 1 } } */ +/* { dg-final { scan-assembler-times {vsetvli\s+zero,\s*[a-x0-9]+,\s*e32,\s*m1,\s*t[au],\s*m[au]\s+vnsra\.wv\s+v[0-9]+,\s*v[0-9]+,\s*v[0-9]+,\s*v0.t} 1 } } */ +/* { dg-final { scan-assembler-times {vsetvli\s+zero,\s*[a-x0-9]+,\s*e32,\s*m2,\s*t[au],\s*m[au]\s+vnsra\.wv\s+v[0-9]+,\s*v[0-9]+,\s*v[0-9]+,\s*v0.t} 1 } } */ +/* { dg-final { scan-assembler-times {vsetvli\s+zero,\s*[a-x0-9]+,\s*e32,\s*m4,\s*t[au],\s*m[au]\s+vnsra\.wv\s+v[0-9]+,\s*v[0-9]+,\s*v[0-9]+,\s*v0.t} 1 } } */ diff --git a/gcc/testsuite/gcc.target/riscv/rvv/base/vnsra_wv_m-2.c b/gcc/testsuite/gcc.target/riscv/rvv/base/vnsra_wv_m-2.c new file mode 100644 index 00000000000..7458f3bfedb --- /dev/null +++ b/gcc/testsuite/gcc.target/riscv/rvv/base/vnsra_wv_m-2.c @@ -0,0 +1,111 @@ +/* { dg-do compile } */ +/* { dg-options "-march=rv64gcv -mabi=lp64d -O3 -fno-schedule-insns -fno-schedule-insns2" } */ + +#include "riscv_vector.h" + +vint8mf8_t test___riscv_vnsra_wv_i8mf8_m(vbool64_t mask,vint16mf4_t op1,vuint8mf8_t shift,size_t vl) +{ + return __riscv_vnsra_wv_i8mf8_m(mask,op1,shift,31); +} + + +vint8mf4_t test___riscv_vnsra_wv_i8mf4_m(vbool32_t mask,vint16mf2_t op1,vuint8mf4_t shift,size_t vl) +{ + return __riscv_vnsra_wv_i8mf4_m(mask,op1,shift,31); +} + + +vint8mf2_t test___riscv_vnsra_wv_i8mf2_m(vbool16_t mask,vint16m1_t op1,vuint8mf2_t shift,size_t vl) +{ + return __riscv_vnsra_wv_i8mf2_m(mask,op1,shift,31); +} + + +vint8m1_t test___riscv_vnsra_wv_i8m1_m(vbool8_t mask,vint16m2_t op1,vuint8m1_t shift,size_t vl) +{ + return __riscv_vnsra_wv_i8m1_m(mask,op1,shift,31); +} + + +vint8m2_t test___riscv_vnsra_wv_i8m2_m(vbool4_t mask,vint16m4_t op1,vuint8m2_t shift,size_t vl) +{ + return __riscv_vnsra_wv_i8m2_m(mask,op1,shift,31); +} + + +vint8m4_t test___riscv_vnsra_wv_i8m4_m(vbool2_t mask,vint16m8_t op1,vuint8m4_t shift,size_t vl) +{ + return __riscv_vnsra_wv_i8m4_m(mask,op1,shift,31); +} + + +vint16mf4_t test___riscv_vnsra_wv_i16mf4_m(vbool64_t mask,vint32mf2_t op1,vuint16mf4_t shift,size_t vl) +{ + return __riscv_vnsra_wv_i16mf4_m(mask,op1,shift,31); +} + + +vint16mf2_t test___riscv_vnsra_wv_i16mf2_m(vbool32_t mask,vint32m1_t op1,vuint16mf2_t shift,size_t vl) +{ + return __riscv_vnsra_wv_i16mf2_m(mask,op1,shift,31); +} + + +vint16m1_t test___riscv_vnsra_wv_i16m1_m(vbool16_t mask,vint32m2_t op1,vuint16m1_t shift,size_t vl) +{ + return __riscv_vnsra_wv_i16m1_m(mask,op1,shift,31); +} + + +vint16m2_t test___riscv_vnsra_wv_i16m2_m(vbool8_t mask,vint32m4_t op1,vuint16m2_t shift,size_t vl) +{ + return __riscv_vnsra_wv_i16m2_m(mask,op1,shift,31); +} + + +vint16m4_t test___riscv_vnsra_wv_i16m4_m(vbool4_t mask,vint32m8_t op1,vuint16m4_t shift,size_t vl) +{ + return __riscv_vnsra_wv_i16m4_m(mask,op1,shift,31); +} + + +vint32mf2_t test___riscv_vnsra_wv_i32mf2_m(vbool64_t mask,vint64m1_t op1,vuint32mf2_t shift,size_t vl) +{ + return __riscv_vnsra_wv_i32mf2_m(mask,op1,shift,31); +} + + +vint32m1_t test___riscv_vnsra_wv_i32m1_m(vbool32_t mask,vint64m2_t op1,vuint32m1_t shift,size_t vl) +{ + return __riscv_vnsra_wv_i32m1_m(mask,op1,shift,31); +} + + +vint32m2_t test___riscv_vnsra_wv_i32m2_m(vbool16_t mask,vint64m4_t op1,vuint32m2_t shift,size_t vl) +{ + return __riscv_vnsra_wv_i32m2_m(mask,op1,shift,31); +} + + +vint32m4_t test___riscv_vnsra_wv_i32m4_m(vbool8_t mask,vint64m8_t op1,vuint32m4_t shift,size_t vl) +{ + return __riscv_vnsra_wv_i32m4_m(mask,op1,shift,31); +} + + + +/* { dg-final { scan-assembler-times {vsetivli\s+zero,\s*31,\s*e8,\s*mf8,\s*t[au],\s*m[au]\s+vnsra\.wv\s+v[0-9]+,\s*v[0-9]+,\s*v[0-9]+,\s*v0.t} 1 } } */ +/* { dg-final { scan-assembler-times {vsetivli\s+zero,\s*31,\s*e8,\s*mf4,\s*t[au],\s*m[au]\s+vnsra\.wv\s+v[0-9]+,\s*v[0-9]+,\s*v[0-9]+,\s*v0.t} 1 } } */ +/* { dg-final { scan-assembler-times {vsetivli\s+zero,\s*31,\s*e8,\s*mf2,\s*t[au],\s*m[au]\s+vnsra\.wv\s+v[0-9]+,\s*v[0-9]+,\s*v[0-9]+,\s*v0.t} 1 } } */ +/* { dg-final { scan-assembler-times {vsetivli\s+zero,\s*31,\s*e8,\s*m1,\s*t[au],\s*m[au]\s+vnsra\.wv\s+v[0-9]+,\s*v[0-9]+,\s*v[0-9]+,\s*v0.t} 1 } } */ +/* { dg-final { scan-assembler-times {vsetivli\s+zero,\s*31,\s*e8,\s*m2,\s*t[au],\s*m[au]\s+vnsra\.wv\s+v[0-9]+,\s*v[0-9]+,\s*v[0-9]+,\s*v0.t} 1 } } */ +/* { dg-final { scan-assembler-times {vsetivli\s+zero,\s*31,\s*e8,\s*m4,\s*t[au],\s*m[au]\s+vnsra\.wv\s+v[0-9]+,\s*v[0-9]+,\s*v[0-9]+,\s*v0.t} 1 } } */ +/* { dg-final { scan-assembler-times {vsetivli\s+zero,\s*31,\s*e16,\s*mf4,\s*t[au],\s*m[au]\s+vnsra\.wv\s+v[0-9]+,\s*v[0-9]+,\s*v[0-9]+,\s*v0.t} 1 } } */ +/* { dg-final { scan-assembler-times {vsetivli\s+zero,\s*31,\s*e16,\s*mf2,\s*t[au],\s*m[au]\s+vnsra\.wv\s+v[0-9]+,\s*v[0-9]+,\s*v[0-9]+,\s*v0.t} 1 } } */ +/* { dg-final { scan-assembler-times {vsetivli\s+zero,\s*31,\s*e16,\s*m1,\s*t[au],\s*m[au]\s+vnsra\.wv\s+v[0-9]+,\s*v[0-9]+,\s*v[0-9]+,\s*v0.t} 1 } } */ +/* { dg-final { scan-assembler-times {vsetivli\s+zero,\s*31,\s*e16,\s*m2,\s*t[au],\s*m[au]\s+vnsra\.wv\s+v[0-9]+,\s*v[0-9]+,\s*v[0-9]+,\s*v0.t} 1 } } */ +/* { dg-final { scan-assembler-times {vsetivli\s+zero,\s*31,\s*e16,\s*m4,\s*t[au],\s*m[au]\s+vnsra\.wv\s+v[0-9]+,\s*v[0-9]+,\s*v[0-9]+,\s*v0.t} 1 } } */ +/* { dg-final { scan-assembler-times {vsetivli\s+zero,\s*31,\s*e32,\s*mf2,\s*t[au],\s*m[au]\s+vnsra\.wv\s+v[0-9]+,\s*v[0-9]+,\s*v[0-9]+,\s*v0.t} 1 } } */ +/* { dg-final { scan-assembler-times {vsetivli\s+zero,\s*31,\s*e32,\s*m1,\s*t[au],\s*m[au]\s+vnsra\.wv\s+v[0-9]+,\s*v[0-9]+,\s*v[0-9]+,\s*v0.t} 1 } } */ +/* { dg-final { scan-assembler-times {vsetivli\s+zero,\s*31,\s*e32,\s*m2,\s*t[au],\s*m[au]\s+vnsra\.wv\s+v[0-9]+,\s*v[0-9]+,\s*v[0-9]+,\s*v0.t} 1 } } */ +/* { dg-final { scan-assembler-times {vsetivli\s+zero,\s*31,\s*e32,\s*m4,\s*t[au],\s*m[au]\s+vnsra\.wv\s+v[0-9]+,\s*v[0-9]+,\s*v[0-9]+,\s*v0.t} 1 } } */ diff --git a/gcc/testsuite/gcc.target/riscv/rvv/base/vnsra_wv_m-3.c b/gcc/testsuite/gcc.target/riscv/rvv/base/vnsra_wv_m-3.c new file mode 100644 index 00000000000..68e8343454f --- /dev/null +++ b/gcc/testsuite/gcc.target/riscv/rvv/base/vnsra_wv_m-3.c @@ -0,0 +1,111 @@ +/* { dg-do compile } */ +/* { dg-options "-march=rv64gcv -mabi=lp64d -O3 -fno-schedule-insns -fno-schedule-insns2" } */ + +#include "riscv_vector.h" + +vint8mf8_t test___riscv_vnsra_wv_i8mf8_m(vbool64_t mask,vint16mf4_t op1,vuint8mf8_t shift,size_t vl) +{ + return __riscv_vnsra_wv_i8mf8_m(mask,op1,shift,32); +} + + +vint8mf4_t test___riscv_vnsra_wv_i8mf4_m(vbool32_t mask,vint16mf2_t op1,vuint8mf4_t shift,size_t vl) +{ + return __riscv_vnsra_wv_i8mf4_m(mask,op1,shift,32); +} + + +vint8mf2_t test___riscv_vnsra_wv_i8mf2_m(vbool16_t mask,vint16m1_t op1,vuint8mf2_t shift,size_t vl) +{ + return __riscv_vnsra_wv_i8mf2_m(mask,op1,shift,32); +} + + +vint8m1_t test___riscv_vnsra_wv_i8m1_m(vbool8_t mask,vint16m2_t op1,vuint8m1_t shift,size_t vl) +{ + return __riscv_vnsra_wv_i8m1_m(mask,op1,shift,32); +} + + +vint8m2_t test___riscv_vnsra_wv_i8m2_m(vbool4_t mask,vint16m4_t op1,vuint8m2_t shift,size_t vl) +{ + return __riscv_vnsra_wv_i8m2_m(mask,op1,shift,32); +} + + +vint8m4_t test___riscv_vnsra_wv_i8m4_m(vbool2_t mask,vint16m8_t op1,vuint8m4_t shift,size_t vl) +{ + return __riscv_vnsra_wv_i8m4_m(mask,op1,shift,32); +} + + +vint16mf4_t test___riscv_vnsra_wv_i16mf4_m(vbool64_t mask,vint32mf2_t op1,vuint16mf4_t shift,size_t vl) +{ + return __riscv_vnsra_wv_i16mf4_m(mask,op1,shift,32); +} + + +vint16mf2_t test___riscv_vnsra_wv_i16mf2_m(vbool32_t mask,vint32m1_t op1,vuint16mf2_t shift,size_t vl) +{ + return __riscv_vnsra_wv_i16mf2_m(mask,op1,shift,32); +} + + +vint16m1_t test___riscv_vnsra_wv_i16m1_m(vbool16_t mask,vint32m2_t op1,vuint16m1_t shift,size_t vl) +{ + return __riscv_vnsra_wv_i16m1_m(mask,op1,shift,32); +} + + +vint16m2_t test___riscv_vnsra_wv_i16m2_m(vbool8_t mask,vint32m4_t op1,vuint16m2_t shift,size_t vl) +{ + return __riscv_vnsra_wv_i16m2_m(mask,op1,shift,32); +} + + +vint16m4_t test___riscv_vnsra_wv_i16m4_m(vbool4_t mask,vint32m8_t op1,vuint16m4_t shift,size_t vl) +{ + return __riscv_vnsra_wv_i16m4_m(mask,op1,shift,32); +} + + +vint32mf2_t test___riscv_vnsra_wv_i32mf2_m(vbool64_t mask,vint64m1_t op1,vuint32mf2_t shift,size_t vl) +{ + return __riscv_vnsra_wv_i32mf2_m(mask,op1,shift,32); +} + + +vint32m1_t test___riscv_vnsra_wv_i32m1_m(vbool32_t mask,vint64m2_t op1,vuint32m1_t shift,size_t vl) +{ + return __riscv_vnsra_wv_i32m1_m(mask,op1,shift,32); +} + + +vint32m2_t test___riscv_vnsra_wv_i32m2_m(vbool16_t mask,vint64m4_t op1,vuint32m2_t shift,size_t vl) +{ + return __riscv_vnsra_wv_i32m2_m(mask,op1,shift,32); +} + + +vint32m4_t test___riscv_vnsra_wv_i32m4_m(vbool8_t mask,vint64m8_t op1,vuint32m4_t shift,size_t vl) +{ + return __riscv_vnsra_wv_i32m4_m(mask,op1,shift,32); +} + + + +/* { dg-final { scan-assembler-times {vsetvli\s+zero,\s*[a-x0-9]+,\s*e8,\s*mf8,\s*t[au],\s*m[au]\s+vnsra\.wv\s+v[0-9]+,\s*v[0-9]+,\s*v[0-9]+,\s*v0.t} 1 } } */ +/* { dg-final { scan-assembler-times {vsetvli\s+zero,\s*[a-x0-9]+,\s*e8,\s*mf4,\s*t[au],\s*m[au]\s+vnsra\.wv\s+v[0-9]+,\s*v[0-9]+,\s*v[0-9]+,\s*v0.t} 1 } } */ +/* { dg-final { scan-assembler-times {vsetvli\s+zero,\s*[a-x0-9]+,\s*e8,\s*mf2,\s*t[au],\s*m[au]\s+vnsra\.wv\s+v[0-9]+,\s*v[0-9]+,\s*v[0-9]+,\s*v0.t} 1 } } */ +/* { dg-final { scan-assembler-times {vsetvli\s+zero,\s*[a-x0-9]+,\s*e8,\s*m1,\s*t[au],\s*m[au]\s+vnsra\.wv\s+v[0-9]+,\s*v[0-9]+,\s*v[0-9]+,\s*v0.t} 1 } } */ +/* { dg-final { scan-assembler-times {vsetvli\s+zero,\s*[a-x0-9]+,\s*e8,\s*m2,\s*t[au],\s*m[au]\s+vnsra\.wv\s+v[0-9]+,\s*v[0-9]+,\s*v[0-9]+,\s*v0.t} 1 } } */ +/* { dg-final { scan-assembler-times {vsetvli\s+zero,\s*[a-x0-9]+,\s*e8,\s*m4,\s*t[au],\s*m[au]\s+vnsra\.wv\s+v[0-9]+,\s*v[0-9]+,\s*v[0-9]+,\s*v0.t} 1 } } */ +/* { dg-final { scan-assembler-times {vsetvli\s+zero,\s*[a-x0-9]+,\s*e16,\s*mf4,\s*t[au],\s*m[au]\s+vnsra\.wv\s+v[0-9]+,\s*v[0-9]+,\s*v[0-9]+,\s*v0.t} 1 } } */ +/* { dg-final { scan-assembler-times {vsetvli\s+zero,\s*[a-x0-9]+,\s*e16,\s*mf2,\s*t[au],\s*m[au]\s+vnsra\.wv\s+v[0-9]+,\s*v[0-9]+,\s*v[0-9]+,\s*v0.t} 1 } } */ +/* { dg-final { scan-assembler-times {vsetvli\s+zero,\s*[a-x0-9]+,\s*e16,\s*m1,\s*t[au],\s*m[au]\s+vnsra\.wv\s+v[0-9]+,\s*v[0-9]+,\s*v[0-9]+,\s*v0.t} 1 } } */ +/* { dg-final { scan-assembler-times {vsetvli\s+zero,\s*[a-x0-9]+,\s*e16,\s*m2,\s*t[au],\s*m[au]\s+vnsra\.wv\s+v[0-9]+,\s*v[0-9]+,\s*v[0-9]+,\s*v0.t} 1 } } */ +/* { dg-final { scan-assembler-times {vsetvli\s+zero,\s*[a-x0-9]+,\s*e16,\s*m4,\s*t[au],\s*m[au]\s+vnsra\.wv\s+v[0-9]+,\s*v[0-9]+,\s*v[0-9]+,\s*v0.t} 1 } } */ +/* { dg-final { scan-assembler-times {vsetvli\s+zero,\s*[a-x0-9]+,\s*e32,\s*mf2,\s*t[au],\s*m[au]\s+vnsra\.wv\s+v[0-9]+,\s*v[0-9]+,\s*v[0-9]+,\s*v0.t} 1 } } */ +/* { dg-final { scan-assembler-times {vsetvli\s+zero,\s*[a-x0-9]+,\s*e32,\s*m1,\s*t[au],\s*m[au]\s+vnsra\.wv\s+v[0-9]+,\s*v[0-9]+,\s*v[0-9]+,\s*v0.t} 1 } } */ +/* { dg-final { scan-assembler-times {vsetvli\s+zero,\s*[a-x0-9]+,\s*e32,\s*m2,\s*t[au],\s*m[au]\s+vnsra\.wv\s+v[0-9]+,\s*v[0-9]+,\s*v[0-9]+,\s*v0.t} 1 } } */ +/* { dg-final { scan-assembler-times {vsetvli\s+zero,\s*[a-x0-9]+,\s*e32,\s*m4,\s*t[au],\s*m[au]\s+vnsra\.wv\s+v[0-9]+,\s*v[0-9]+,\s*v[0-9]+,\s*v0.t} 1 } } */ diff --git a/gcc/testsuite/gcc.target/riscv/rvv/base/vnsra_wv_mu-1.c b/gcc/testsuite/gcc.target/riscv/rvv/base/vnsra_wv_mu-1.c new file mode 100644 index 00000000000..df60811e0f9 --- /dev/null +++ b/gcc/testsuite/gcc.target/riscv/rvv/base/vnsra_wv_mu-1.c @@ -0,0 +1,111 @@ +/* { dg-do compile } */ +/* { dg-options "-march=rv64gcv -mabi=lp64d -O3 -fno-schedule-insns -fno-schedule-insns2" } */ + +#include "riscv_vector.h" + +vint8mf8_t test___riscv_vnsra_wv_i8mf8_mu(vbool64_t mask,vint8mf8_t merge,vint16mf4_t op1,vuint8mf8_t shift,size_t vl) +{ + return __riscv_vnsra_wv_i8mf8_mu(mask,merge,op1,shift,vl); +} + + +vint8mf4_t test___riscv_vnsra_wv_i8mf4_mu(vbool32_t mask,vint8mf4_t merge,vint16mf2_t op1,vuint8mf4_t shift,size_t vl) +{ + return __riscv_vnsra_wv_i8mf4_mu(mask,merge,op1,shift,vl); +} + + +vint8mf2_t test___riscv_vnsra_wv_i8mf2_mu(vbool16_t mask,vint8mf2_t merge,vint16m1_t op1,vuint8mf2_t shift,size_t vl) +{ + return __riscv_vnsra_wv_i8mf2_mu(mask,merge,op1,shift,vl); +} + + +vint8m1_t test___riscv_vnsra_wv_i8m1_mu(vbool8_t mask,vint8m1_t merge,vint16m2_t op1,vuint8m1_t shift,size_t vl) +{ + return __riscv_vnsra_wv_i8m1_mu(mask,merge,op1,shift,vl); +} + + +vint8m2_t test___riscv_vnsra_wv_i8m2_mu(vbool4_t mask,vint8m2_t merge,vint16m4_t op1,vuint8m2_t shift,size_t vl) +{ + return __riscv_vnsra_wv_i8m2_mu(mask,merge,op1,shift,vl); +} + + +vint8m4_t test___riscv_vnsra_wv_i8m4_mu(vbool2_t mask,vint8m4_t merge,vint16m8_t op1,vuint8m4_t shift,size_t vl) +{ + return __riscv_vnsra_wv_i8m4_mu(mask,merge,op1,shift,vl); +} + + +vint16mf4_t test___riscv_vnsra_wv_i16mf4_mu(vbool64_t mask,vint16mf4_t merge,vint32mf2_t op1,vuint16mf4_t shift,size_t vl) +{ + return __riscv_vnsra_wv_i16mf4_mu(mask,merge,op1,shift,vl); +} + + +vint16mf2_t test___riscv_vnsra_wv_i16mf2_mu(vbool32_t mask,vint16mf2_t merge,vint32m1_t op1,vuint16mf2_t shift,size_t vl) +{ + return __riscv_vnsra_wv_i16mf2_mu(mask,merge,op1,shift,vl); +} + + +vint16m1_t test___riscv_vnsra_wv_i16m1_mu(vbool16_t mask,vint16m1_t merge,vint32m2_t op1,vuint16m1_t shift,size_t vl) +{ + return __riscv_vnsra_wv_i16m1_mu(mask,merge,op1,shift,vl); +} + + +vint16m2_t test___riscv_vnsra_wv_i16m2_mu(vbool8_t mask,vint16m2_t merge,vint32m4_t op1,vuint16m2_t shift,size_t vl) +{ + return __riscv_vnsra_wv_i16m2_mu(mask,merge,op1,shift,vl); +} + + +vint16m4_t test___riscv_vnsra_wv_i16m4_mu(vbool4_t mask,vint16m4_t merge,vint32m8_t op1,vuint16m4_t shift,size_t vl) +{ + return __riscv_vnsra_wv_i16m4_mu(mask,merge,op1,shift,vl); +} + + +vint32mf2_t test___riscv_vnsra_wv_i32mf2_mu(vbool64_t mask,vint32mf2_t merge,vint64m1_t op1,vuint32mf2_t shift,size_t vl) +{ + return __riscv_vnsra_wv_i32mf2_mu(mask,merge,op1,shift,vl); +} + + +vint32m1_t test___riscv_vnsra_wv_i32m1_mu(vbool32_t mask,vint32m1_t merge,vint64m2_t op1,vuint32m1_t shift,size_t vl) +{ + return __riscv_vnsra_wv_i32m1_mu(mask,merge,op1,shift,vl); +} + + +vint32m2_t test___riscv_vnsra_wv_i32m2_mu(vbool16_t mask,vint32m2_t merge,vint64m4_t op1,vuint32m2_t shift,size_t vl) +{ + return __riscv_vnsra_wv_i32m2_mu(mask,merge,op1,shift,vl); +} + + +vint32m4_t test___riscv_vnsra_wv_i32m4_mu(vbool8_t mask,vint32m4_t merge,vint64m8_t op1,vuint32m4_t shift,size_t vl) +{ + return __riscv_vnsra_wv_i32m4_mu(mask,merge,op1,shift,vl); +} + + + +/* { dg-final { scan-assembler-times {vsetvli\s+zero,\s*[a-x0-9]+,\s*e8,\s*mf8,\s*t[au],\s*mu\s+vnsra\.wv\s+v[0-9]+,\s*v[0-9]+,\s*v[0-9]+,\s*v0.t} 1 } } */ +/* { dg-final { scan-assembler-times {vsetvli\s+zero,\s*[a-x0-9]+,\s*e8,\s*mf4,\s*t[au],\s*mu\s+vnsra\.wv\s+v[0-9]+,\s*v[0-9]+,\s*v[0-9]+,\s*v0.t} 1 } } */ +/* { dg-final { scan-assembler-times {vsetvli\s+zero,\s*[a-x0-9]+,\s*e8,\s*mf2,\s*t[au],\s*mu\s+vnsra\.wv\s+v[0-9]+,\s*v[0-9]+,\s*v[0-9]+,\s*v0.t} 1 } } */ +/* { dg-final { scan-assembler-times {vsetvli\s+zero,\s*[a-x0-9]+,\s*e8,\s*m1,\s*t[au],\s*mu\s+vnsra\.wv\s+v[0-9]+,\s*v[0-9]+,\s*v[0-9]+,\s*v0.t} 1 } } */ +/* { dg-final { scan-assembler-times {vsetvli\s+zero,\s*[a-x0-9]+,\s*e8,\s*m2,\s*t[au],\s*mu\s+vnsra\.wv\s+v[0-9]+,\s*v[0-9]+,\s*v[0-9]+,\s*v0.t} 1 } } */ +/* { dg-final { scan-assembler-times {vsetvli\s+zero,\s*[a-x0-9]+,\s*e8,\s*m4,\s*t[au],\s*mu\s+vnsra\.wv\s+v[0-9]+,\s*v[0-9]+,\s*v[0-9]+,\s*v0.t} 1 } } */ +/* { dg-final { scan-assembler-times {vsetvli\s+zero,\s*[a-x0-9]+,\s*e16,\s*mf4,\s*t[au],\s*mu\s+vnsra\.wv\s+v[0-9]+,\s*v[0-9]+,\s*v[0-9]+,\s*v0.t} 1 } } */ +/* { dg-final { scan-assembler-times {vsetvli\s+zero,\s*[a-x0-9]+,\s*e16,\s*mf2,\s*t[au],\s*mu\s+vnsra\.wv\s+v[0-9]+,\s*v[0-9]+,\s*v[0-9]+,\s*v0.t} 1 } } */ +/* { dg-final { scan-assembler-times {vsetvli\s+zero,\s*[a-x0-9]+,\s*e16,\s*m1,\s*t[au],\s*mu\s+vnsra\.wv\s+v[0-9]+,\s*v[0-9]+,\s*v[0-9]+,\s*v0.t} 1 } } */ +/* { dg-final { scan-assembler-times {vsetvli\s+zero,\s*[a-x0-9]+,\s*e16,\s*m2,\s*t[au],\s*mu\s+vnsra\.wv\s+v[0-9]+,\s*v[0-9]+,\s*v[0-9]+,\s*v0.t} 1 } } */ +/* { dg-final { scan-assembler-times {vsetvli\s+zero,\s*[a-x0-9]+,\s*e16,\s*m4,\s*t[au],\s*mu\s+vnsra\.wv\s+v[0-9]+,\s*v[0-9]+,\s*v[0-9]+,\s*v0.t} 1 } } */ +/* { dg-final { scan-assembler-times {vsetvli\s+zero,\s*[a-x0-9]+,\s*e32,\s*mf2,\s*t[au],\s*mu\s+vnsra\.wv\s+v[0-9]+,\s*v[0-9]+,\s*v[0-9]+,\s*v0.t} 1 } } */ +/* { dg-final { scan-assembler-times {vsetvli\s+zero,\s*[a-x0-9]+,\s*e32,\s*m1,\s*t[au],\s*mu\s+vnsra\.wv\s+v[0-9]+,\s*v[0-9]+,\s*v[0-9]+,\s*v0.t} 1 } } */ +/* { dg-final { scan-assembler-times {vsetvli\s+zero,\s*[a-x0-9]+,\s*e32,\s*m2,\s*t[au],\s*mu\s+vnsra\.wv\s+v[0-9]+,\s*v[0-9]+,\s*v[0-9]+,\s*v0.t} 1 } } */ +/* { dg-final { scan-assembler-times {vsetvli\s+zero,\s*[a-x0-9]+,\s*e32,\s*m4,\s*t[au],\s*mu\s+vnsra\.wv\s+v[0-9]+,\s*v[0-9]+,\s*v[0-9]+,\s*v0.t} 1 } } */ diff --git a/gcc/testsuite/gcc.target/riscv/rvv/base/vnsra_wv_mu-2.c b/gcc/testsuite/gcc.target/riscv/rvv/base/vnsra_wv_mu-2.c new file mode 100644 index 00000000000..ff6e2e3fdac --- /dev/null +++ b/gcc/testsuite/gcc.target/riscv/rvv/base/vnsra_wv_mu-2.c @@ -0,0 +1,111 @@ +/* { dg-do compile } */ +/* { dg-options "-march=rv64gcv -mabi=lp64d -O3 -fno-schedule-insns -fno-schedule-insns2" } */ + +#include "riscv_vector.h" + +vint8mf8_t test___riscv_vnsra_wv_i8mf8_mu(vbool64_t mask,vint8mf8_t merge,vint16mf4_t op1,vuint8mf8_t shift,size_t vl) +{ + return __riscv_vnsra_wv_i8mf8_mu(mask,merge,op1,shift,31); +} + + +vint8mf4_t test___riscv_vnsra_wv_i8mf4_mu(vbool32_t mask,vint8mf4_t merge,vint16mf2_t op1,vuint8mf4_t shift,size_t vl) +{ + return __riscv_vnsra_wv_i8mf4_mu(mask,merge,op1,shift,31); +} + + +vint8mf2_t test___riscv_vnsra_wv_i8mf2_mu(vbool16_t mask,vint8mf2_t merge,vint16m1_t op1,vuint8mf2_t shift,size_t vl) +{ + return __riscv_vnsra_wv_i8mf2_mu(mask,merge,op1,shift,31); +} + + +vint8m1_t test___riscv_vnsra_wv_i8m1_mu(vbool8_t mask,vint8m1_t merge,vint16m2_t op1,vuint8m1_t shift,size_t vl) +{ + return __riscv_vnsra_wv_i8m1_mu(mask,merge,op1,shift,31); +} + + +vint8m2_t test___riscv_vnsra_wv_i8m2_mu(vbool4_t mask,vint8m2_t merge,vint16m4_t op1,vuint8m2_t shift,size_t vl) +{ + return __riscv_vnsra_wv_i8m2_mu(mask,merge,op1,shift,31); +} + + +vint8m4_t test___riscv_vnsra_wv_i8m4_mu(vbool2_t mask,vint8m4_t merge,vint16m8_t op1,vuint8m4_t shift,size_t vl) +{ + return __riscv_vnsra_wv_i8m4_mu(mask,merge,op1,shift,31); +} + + +vint16mf4_t test___riscv_vnsra_wv_i16mf4_mu(vbool64_t mask,vint16mf4_t merge,vint32mf2_t op1,vuint16mf4_t shift,size_t vl) +{ + return __riscv_vnsra_wv_i16mf4_mu(mask,merge,op1,shift,31); +} + + +vint16mf2_t test___riscv_vnsra_wv_i16mf2_mu(vbool32_t mask,vint16mf2_t merge,vint32m1_t op1,vuint16mf2_t shift,size_t vl) +{ + return __riscv_vnsra_wv_i16mf2_mu(mask,merge,op1,shift,31); +} + + +vint16m1_t test___riscv_vnsra_wv_i16m1_mu(vbool16_t mask,vint16m1_t merge,vint32m2_t op1,vuint16m1_t shift,size_t vl) +{ + return __riscv_vnsra_wv_i16m1_mu(mask,merge,op1,shift,31); +} + + +vint16m2_t test___riscv_vnsra_wv_i16m2_mu(vbool8_t mask,vint16m2_t merge,vint32m4_t op1,vuint16m2_t shift,size_t vl) +{ + return __riscv_vnsra_wv_i16m2_mu(mask,merge,op1,shift,31); +} + + +vint16m4_t test___riscv_vnsra_wv_i16m4_mu(vbool4_t mask,vint16m4_t merge,vint32m8_t op1,vuint16m4_t shift,size_t vl) +{ + return __riscv_vnsra_wv_i16m4_mu(mask,merge,op1,shift,31); +} + + +vint32mf2_t test___riscv_vnsra_wv_i32mf2_mu(vbool64_t mask,vint32mf2_t merge,vint64m1_t op1,vuint32mf2_t shift,size_t vl) +{ + return __riscv_vnsra_wv_i32mf2_mu(mask,merge,op1,shift,31); +} + + +vint32m1_t test___riscv_vnsra_wv_i32m1_mu(vbool32_t mask,vint32m1_t merge,vint64m2_t op1,vuint32m1_t shift,size_t vl) +{ + return __riscv_vnsra_wv_i32m1_mu(mask,merge,op1,shift,31); +} + + +vint32m2_t test___riscv_vnsra_wv_i32m2_mu(vbool16_t mask,vint32m2_t merge,vint64m4_t op1,vuint32m2_t shift,size_t vl) +{ + return __riscv_vnsra_wv_i32m2_mu(mask,merge,op1,shift,31); +} + + +vint32m4_t test___riscv_vnsra_wv_i32m4_mu(vbool8_t mask,vint32m4_t merge,vint64m8_t op1,vuint32m4_t shift,size_t vl) +{ + return __riscv_vnsra_wv_i32m4_mu(mask,merge,op1,shift,31); +} + + + +/* { dg-final { scan-assembler-times {vsetivli\s+zero,\s*31,\s*e8,\s*mf8,\s*t[au],\s*mu\s+vnsra\.wv\s+v[0-9]+,\s*v[0-9]+,\s*v[0-9]+,\s*v0.t} 1 } } */ +/* { dg-final { scan-assembler-times {vsetivli\s+zero,\s*31,\s*e8,\s*mf4,\s*t[au],\s*mu\s+vnsra\.wv\s+v[0-9]+,\s*v[0-9]+,\s*v[0-9]+,\s*v0.t} 1 } } */ +/* { dg-final { scan-assembler-times {vsetivli\s+zero,\s*31,\s*e8,\s*mf2,\s*t[au],\s*mu\s+vnsra\.wv\s+v[0-9]+,\s*v[0-9]+,\s*v[0-9]+,\s*v0.t} 1 } } */ +/* { dg-final { scan-assembler-times {vsetivli\s+zero,\s*31,\s*e8,\s*m1,\s*t[au],\s*mu\s+vnsra\.wv\s+v[0-9]+,\s*v[0-9]+,\s*v[0-9]+,\s*v0.t} 1 } } */ +/* { dg-final { scan-assembler-times {vsetivli\s+zero,\s*31,\s*e8,\s*m2,\s*t[au],\s*mu\s+vnsra\.wv\s+v[0-9]+,\s*v[0-9]+,\s*v[0-9]+,\s*v0.t} 1 } } */ +/* { dg-final { scan-assembler-times {vsetivli\s+zero,\s*31,\s*e8,\s*m4,\s*t[au],\s*mu\s+vnsra\.wv\s+v[0-9]+,\s*v[0-9]+,\s*v[0-9]+,\s*v0.t} 1 } } */ +/* { dg-final { scan-assembler-times {vsetivli\s+zero,\s*31,\s*e16,\s*mf4,\s*t[au],\s*mu\s+vnsra\.wv\s+v[0-9]+,\s*v[0-9]+,\s*v[0-9]+,\s*v0.t} 1 } } */ +/* { dg-final { scan-assembler-times {vsetivli\s+zero,\s*31,\s*e16,\s*mf2,\s*t[au],\s*mu\s+vnsra\.wv\s+v[0-9]+,\s*v[0-9]+,\s*v[0-9]+,\s*v0.t} 1 } } */ +/* { dg-final { scan-assembler-times {vsetivli\s+zero,\s*31,\s*e16,\s*m1,\s*t[au],\s*mu\s+vnsra\.wv\s+v[0-9]+,\s*v[0-9]+,\s*v[0-9]+,\s*v0.t} 1 } } */ +/* { dg-final { scan-assembler-times {vsetivli\s+zero,\s*31,\s*e16,\s*m2,\s*t[au],\s*mu\s+vnsra\.wv\s+v[0-9]+,\s*v[0-9]+,\s*v[0-9]+,\s*v0.t} 1 } } */ +/* { dg-final { scan-assembler-times {vsetivli\s+zero,\s*31,\s*e16,\s*m4,\s*t[au],\s*mu\s+vnsra\.wv\s+v[0-9]+,\s*v[0-9]+,\s*v[0-9]+,\s*v0.t} 1 } } */ +/* { dg-final { scan-assembler-times {vsetivli\s+zero,\s*31,\s*e32,\s*mf2,\s*t[au],\s*mu\s+vnsra\.wv\s+v[0-9]+,\s*v[0-9]+,\s*v[0-9]+,\s*v0.t} 1 } } */ +/* { dg-final { scan-assembler-times {vsetivli\s+zero,\s*31,\s*e32,\s*m1,\s*t[au],\s*mu\s+vnsra\.wv\s+v[0-9]+,\s*v[0-9]+,\s*v[0-9]+,\s*v0.t} 1 } } */ +/* { dg-final { scan-assembler-times {vsetivli\s+zero,\s*31,\s*e32,\s*m2,\s*t[au],\s*mu\s+vnsra\.wv\s+v[0-9]+,\s*v[0-9]+,\s*v[0-9]+,\s*v0.t} 1 } } */ +/* { dg-final { scan-assembler-times {vsetivli\s+zero,\s*31,\s*e32,\s*m4,\s*t[au],\s*mu\s+vnsra\.wv\s+v[0-9]+,\s*v[0-9]+,\s*v[0-9]+,\s*v0.t} 1 } } */ diff --git a/gcc/testsuite/gcc.target/riscv/rvv/base/vnsra_wv_mu-3.c b/gcc/testsuite/gcc.target/riscv/rvv/base/vnsra_wv_mu-3.c new file mode 100644 index 00000000000..8d749b57f2d --- /dev/null +++ b/gcc/testsuite/gcc.target/riscv/rvv/base/vnsra_wv_mu-3.c @@ -0,0 +1,111 @@ +/* { dg-do compile } */ +/* { dg-options "-march=rv64gcv -mabi=lp64d -O3 -fno-schedule-insns -fno-schedule-insns2" } */ + +#include "riscv_vector.h" + +vint8mf8_t test___riscv_vnsra_wv_i8mf8_mu(vbool64_t mask,vint8mf8_t merge,vint16mf4_t op1,vuint8mf8_t shift,size_t vl) +{ + return __riscv_vnsra_wv_i8mf8_mu(mask,merge,op1,shift,32); +} + + +vint8mf4_t test___riscv_vnsra_wv_i8mf4_mu(vbool32_t mask,vint8mf4_t merge,vint16mf2_t op1,vuint8mf4_t shift,size_t vl) +{ + return __riscv_vnsra_wv_i8mf4_mu(mask,merge,op1,shift,32); +} + + +vint8mf2_t test___riscv_vnsra_wv_i8mf2_mu(vbool16_t mask,vint8mf2_t merge,vint16m1_t op1,vuint8mf2_t shift,size_t vl) +{ + return __riscv_vnsra_wv_i8mf2_mu(mask,merge,op1,shift,32); +} + + +vint8m1_t test___riscv_vnsra_wv_i8m1_mu(vbool8_t mask,vint8m1_t merge,vint16m2_t op1,vuint8m1_t shift,size_t vl) +{ + return __riscv_vnsra_wv_i8m1_mu(mask,merge,op1,shift,32); +} + + +vint8m2_t test___riscv_vnsra_wv_i8m2_mu(vbool4_t mask,vint8m2_t merge,vint16m4_t op1,vuint8m2_t shift,size_t vl) +{ + return __riscv_vnsra_wv_i8m2_mu(mask,merge,op1,shift,32); +} + + +vint8m4_t test___riscv_vnsra_wv_i8m4_mu(vbool2_t mask,vint8m4_t merge,vint16m8_t op1,vuint8m4_t shift,size_t vl) +{ + return __riscv_vnsra_wv_i8m4_mu(mask,merge,op1,shift,32); +} + + +vint16mf4_t test___riscv_vnsra_wv_i16mf4_mu(vbool64_t mask,vint16mf4_t merge,vint32mf2_t op1,vuint16mf4_t shift,size_t vl) +{ + return __riscv_vnsra_wv_i16mf4_mu(mask,merge,op1,shift,32); +} + + +vint16mf2_t test___riscv_vnsra_wv_i16mf2_mu(vbool32_t mask,vint16mf2_t merge,vint32m1_t op1,vuint16mf2_t shift,size_t vl) +{ + return __riscv_vnsra_wv_i16mf2_mu(mask,merge,op1,shift,32); +} + + +vint16m1_t test___riscv_vnsra_wv_i16m1_mu(vbool16_t mask,vint16m1_t merge,vint32m2_t op1,vuint16m1_t shift,size_t vl) +{ + return __riscv_vnsra_wv_i16m1_mu(mask,merge,op1,shift,32); +} + + +vint16m2_t test___riscv_vnsra_wv_i16m2_mu(vbool8_t mask,vint16m2_t merge,vint32m4_t op1,vuint16m2_t shift,size_t vl) +{ + return __riscv_vnsra_wv_i16m2_mu(mask,merge,op1,shift,32); +} + + +vint16m4_t test___riscv_vnsra_wv_i16m4_mu(vbool4_t mask,vint16m4_t merge,vint32m8_t op1,vuint16m4_t shift,size_t vl) +{ + return __riscv_vnsra_wv_i16m4_mu(mask,merge,op1,shift,32); +} + + +vint32mf2_t test___riscv_vnsra_wv_i32mf2_mu(vbool64_t mask,vint32mf2_t merge,vint64m1_t op1,vuint32mf2_t shift,size_t vl) +{ + return __riscv_vnsra_wv_i32mf2_mu(mask,merge,op1,shift,32); +} + + +vint32m1_t test___riscv_vnsra_wv_i32m1_mu(vbool32_t mask,vint32m1_t merge,vint64m2_t op1,vuint32m1_t shift,size_t vl) +{ + return __riscv_vnsra_wv_i32m1_mu(mask,merge,op1,shift,32); +} + + +vint32m2_t test___riscv_vnsra_wv_i32m2_mu(vbool16_t mask,vint32m2_t merge,vint64m4_t op1,vuint32m2_t shift,size_t vl) +{ + return __riscv_vnsra_wv_i32m2_mu(mask,merge,op1,shift,32); +} + + +vint32m4_t test___riscv_vnsra_wv_i32m4_mu(vbool8_t mask,vint32m4_t merge,vint64m8_t op1,vuint32m4_t shift,size_t vl) +{ + return __riscv_vnsra_wv_i32m4_mu(mask,merge,op1,shift,32); +} + + + +/* { dg-final { scan-assembler-times {vsetvli\s+zero,\s*[a-x0-9]+,\s*e8,\s*mf8,\s*t[au],\s*mu\s+vnsra\.wv\s+v[0-9]+,\s*v[0-9]+,\s*v[0-9]+,\s*v0.t} 1 } } */ +/* { dg-final { scan-assembler-times {vsetvli\s+zero,\s*[a-x0-9]+,\s*e8,\s*mf4,\s*t[au],\s*mu\s+vnsra\.wv\s+v[0-9]+,\s*v[0-9]+,\s*v[0-9]+,\s*v0.t} 1 } } */ +/* { dg-final { scan-assembler-times {vsetvli\s+zero,\s*[a-x0-9]+,\s*e8,\s*mf2,\s*t[au],\s*mu\s+vnsra\.wv\s+v[0-9]+,\s*v[0-9]+,\s*v[0-9]+,\s*v0.t} 1 } } */ +/* { dg-final { scan-assembler-times {vsetvli\s+zero,\s*[a-x0-9]+,\s*e8,\s*m1,\s*t[au],\s*mu\s+vnsra\.wv\s+v[0-9]+,\s*v[0-9]+,\s*v[0-9]+,\s*v0.t} 1 } } */ +/* { dg-final { scan-assembler-times {vsetvli\s+zero,\s*[a-x0-9]+,\s*e8,\s*m2,\s*t[au],\s*mu\s+vnsra\.wv\s+v[0-9]+,\s*v[0-9]+,\s*v[0-9]+,\s*v0.t} 1 } } */ +/* { dg-final { scan-assembler-times {vsetvli\s+zero,\s*[a-x0-9]+,\s*e8,\s*m4,\s*t[au],\s*mu\s+vnsra\.wv\s+v[0-9]+,\s*v[0-9]+,\s*v[0-9]+,\s*v0.t} 1 } } */ +/* { dg-final { scan-assembler-times {vsetvli\s+zero,\s*[a-x0-9]+,\s*e16,\s*mf4,\s*t[au],\s*mu\s+vnsra\.wv\s+v[0-9]+,\s*v[0-9]+,\s*v[0-9]+,\s*v0.t} 1 } } */ +/* { dg-final { scan-assembler-times {vsetvli\s+zero,\s*[a-x0-9]+,\s*e16,\s*mf2,\s*t[au],\s*mu\s+vnsra\.wv\s+v[0-9]+,\s*v[0-9]+,\s*v[0-9]+,\s*v0.t} 1 } } */ +/* { dg-final { scan-assembler-times {vsetvli\s+zero,\s*[a-x0-9]+,\s*e16,\s*m1,\s*t[au],\s*mu\s+vnsra\.wv\s+v[0-9]+,\s*v[0-9]+,\s*v[0-9]+,\s*v0.t} 1 } } */ +/* { dg-final { scan-assembler-times {vsetvli\s+zero,\s*[a-x0-9]+,\s*e16,\s*m2,\s*t[au],\s*mu\s+vnsra\.wv\s+v[0-9]+,\s*v[0-9]+,\s*v[0-9]+,\s*v0.t} 1 } } */ +/* { dg-final { scan-assembler-times {vsetvli\s+zero,\s*[a-x0-9]+,\s*e16,\s*m4,\s*t[au],\s*mu\s+vnsra\.wv\s+v[0-9]+,\s*v[0-9]+,\s*v[0-9]+,\s*v0.t} 1 } } */ +/* { dg-final { scan-assembler-times {vsetvli\s+zero,\s*[a-x0-9]+,\s*e32,\s*mf2,\s*t[au],\s*mu\s+vnsra\.wv\s+v[0-9]+,\s*v[0-9]+,\s*v[0-9]+,\s*v0.t} 1 } } */ +/* { dg-final { scan-assembler-times {vsetvli\s+zero,\s*[a-x0-9]+,\s*e32,\s*m1,\s*t[au],\s*mu\s+vnsra\.wv\s+v[0-9]+,\s*v[0-9]+,\s*v[0-9]+,\s*v0.t} 1 } } */ +/* { dg-final { scan-assembler-times {vsetvli\s+zero,\s*[a-x0-9]+,\s*e32,\s*m2,\s*t[au],\s*mu\s+vnsra\.wv\s+v[0-9]+,\s*v[0-9]+,\s*v[0-9]+,\s*v0.t} 1 } } */ +/* { dg-final { scan-assembler-times {vsetvli\s+zero,\s*[a-x0-9]+,\s*e32,\s*m4,\s*t[au],\s*mu\s+vnsra\.wv\s+v[0-9]+,\s*v[0-9]+,\s*v[0-9]+,\s*v0.t} 1 } } */ diff --git a/gcc/testsuite/gcc.target/riscv/rvv/base/vnsra_wv_tu-1.c b/gcc/testsuite/gcc.target/riscv/rvv/base/vnsra_wv_tu-1.c new file mode 100644 index 00000000000..ca3e963647d --- /dev/null +++ b/gcc/testsuite/gcc.target/riscv/rvv/base/vnsra_wv_tu-1.c @@ -0,0 +1,111 @@ +/* { dg-do compile } */ +/* { dg-options "-march=rv64gcv -mabi=lp64d -O3 -fno-schedule-insns -fno-schedule-insns2" } */ + +#include "riscv_vector.h" + +vint8mf8_t test___riscv_vnsra_wv_i8mf8_tu(vint8mf8_t merge,vint16mf4_t op1,vuint8mf8_t shift,size_t vl) +{ + return __riscv_vnsra_wv_i8mf8_tu(merge,op1,shift,vl); +} + + +vint8mf4_t test___riscv_vnsra_wv_i8mf4_tu(vint8mf4_t merge,vint16mf2_t op1,vuint8mf4_t shift,size_t vl) +{ + return __riscv_vnsra_wv_i8mf4_tu(merge,op1,shift,vl); +} + + +vint8mf2_t test___riscv_vnsra_wv_i8mf2_tu(vint8mf2_t merge,vint16m1_t op1,vuint8mf2_t shift,size_t vl) +{ + return __riscv_vnsra_wv_i8mf2_tu(merge,op1,shift,vl); +} + + +vint8m1_t test___riscv_vnsra_wv_i8m1_tu(vint8m1_t merge,vint16m2_t op1,vuint8m1_t shift,size_t vl) +{ + return __riscv_vnsra_wv_i8m1_tu(merge,op1,shift,vl); +} + + +vint8m2_t test___riscv_vnsra_wv_i8m2_tu(vint8m2_t merge,vint16m4_t op1,vuint8m2_t shift,size_t vl) +{ + return __riscv_vnsra_wv_i8m2_tu(merge,op1,shift,vl); +} + + +vint8m4_t test___riscv_vnsra_wv_i8m4_tu(vint8m4_t merge,vint16m8_t op1,vuint8m4_t shift,size_t vl) +{ + return __riscv_vnsra_wv_i8m4_tu(merge,op1,shift,vl); +} + + +vint16mf4_t test___riscv_vnsra_wv_i16mf4_tu(vint16mf4_t merge,vint32mf2_t op1,vuint16mf4_t shift,size_t vl) +{ + return __riscv_vnsra_wv_i16mf4_tu(merge,op1,shift,vl); +} + + +vint16mf2_t test___riscv_vnsra_wv_i16mf2_tu(vint16mf2_t merge,vint32m1_t op1,vuint16mf2_t shift,size_t vl) +{ + return __riscv_vnsra_wv_i16mf2_tu(merge,op1,shift,vl); +} + + +vint16m1_t test___riscv_vnsra_wv_i16m1_tu(vint16m1_t merge,vint32m2_t op1,vuint16m1_t shift,size_t vl) +{ + return __riscv_vnsra_wv_i16m1_tu(merge,op1,shift,vl); +} + + +vint16m2_t test___riscv_vnsra_wv_i16m2_tu(vint16m2_t merge,vint32m4_t op1,vuint16m2_t shift,size_t vl) +{ + return __riscv_vnsra_wv_i16m2_tu(merge,op1,shift,vl); +} + + +vint16m4_t test___riscv_vnsra_wv_i16m4_tu(vint16m4_t merge,vint32m8_t op1,vuint16m4_t shift,size_t vl) +{ + return __riscv_vnsra_wv_i16m4_tu(merge,op1,shift,vl); +} + + +vint32mf2_t test___riscv_vnsra_wv_i32mf2_tu(vint32mf2_t merge,vint64m1_t op1,vuint32mf2_t shift,size_t vl) +{ + return __riscv_vnsra_wv_i32mf2_tu(merge,op1,shift,vl); +} + + +vint32m1_t test___riscv_vnsra_wv_i32m1_tu(vint32m1_t merge,vint64m2_t op1,vuint32m1_t shift,size_t vl) +{ + return __riscv_vnsra_wv_i32m1_tu(merge,op1,shift,vl); +} + + +vint32m2_t test___riscv_vnsra_wv_i32m2_tu(vint32m2_t merge,vint64m4_t op1,vuint32m2_t shift,size_t vl) +{ + return __riscv_vnsra_wv_i32m2_tu(merge,op1,shift,vl); +} + + +vint32m4_t test___riscv_vnsra_wv_i32m4_tu(vint32m4_t merge,vint64m8_t op1,vuint32m4_t shift,size_t vl) +{ + return __riscv_vnsra_wv_i32m4_tu(merge,op1,shift,vl); +} + + + +/* { dg-final { scan-assembler-times {vsetvli\s+zero,\s*[a-x0-9]+,\s*e8,\s*mf8,\s*tu,\s*m[au]\s+vnsra\.wv\s+v[0-9]+,\s*v[0-9]+,\s*v[0-9]+} 1 } } */ +/* { dg-final { scan-assembler-times {vsetvli\s+zero,\s*[a-x0-9]+,\s*e8,\s*mf4,\s*tu,\s*m[au]\s+vnsra\.wv\s+v[0-9]+,\s*v[0-9]+,\s*v[0-9]+} 1 } } */ +/* { dg-final { scan-assembler-times {vsetvli\s+zero,\s*[a-x0-9]+,\s*e8,\s*mf2,\s*tu,\s*m[au]\s+vnsra\.wv\s+v[0-9]+,\s*v[0-9]+,\s*v[0-9]+} 1 } } */ +/* { dg-final { scan-assembler-times {vsetvli\s+zero,\s*[a-x0-9]+,\s*e8,\s*m1,\s*tu,\s*m[au]\s+vnsra\.wv\s+v[0-9]+,\s*v[0-9]+,\s*v[0-9]+} 1 } } */ +/* { dg-final { scan-assembler-times {vsetvli\s+zero,\s*[a-x0-9]+,\s*e8,\s*m2,\s*tu,\s*m[au]\s+vnsra\.wv\s+v[0-9]+,\s*v[0-9]+,\s*v[0-9]+} 1 } } */ +/* { dg-final { scan-assembler-times {vsetvli\s+zero,\s*[a-x0-9]+,\s*e8,\s*m4,\s*tu,\s*m[au]\s+vnsra\.wv\s+v[0-9]+,\s*v[0-9]+,\s*v[0-9]+} 1 } } */ +/* { dg-final { scan-assembler-times {vsetvli\s+zero,\s*[a-x0-9]+,\s*e16,\s*mf4,\s*tu,\s*m[au]\s+vnsra\.wv\s+v[0-9]+,\s*v[0-9]+,\s*v[0-9]+} 1 } } */ +/* { dg-final { scan-assembler-times {vsetvli\s+zero,\s*[a-x0-9]+,\s*e16,\s*mf2,\s*tu,\s*m[au]\s+vnsra\.wv\s+v[0-9]+,\s*v[0-9]+,\s*v[0-9]+} 1 } } */ +/* { dg-final { scan-assembler-times {vsetvli\s+zero,\s*[a-x0-9]+,\s*e16,\s*m1,\s*tu,\s*m[au]\s+vnsra\.wv\s+v[0-9]+,\s*v[0-9]+,\s*v[0-9]+} 1 } } */ +/* { dg-final { scan-assembler-times {vsetvli\s+zero,\s*[a-x0-9]+,\s*e16,\s*m2,\s*tu,\s*m[au]\s+vnsra\.wv\s+v[0-9]+,\s*v[0-9]+,\s*v[0-9]+} 1 } } */ +/* { dg-final { scan-assembler-times {vsetvli\s+zero,\s*[a-x0-9]+,\s*e16,\s*m4,\s*tu,\s*m[au]\s+vnsra\.wv\s+v[0-9]+,\s*v[0-9]+,\s*v[0-9]+} 1 } } */ +/* { dg-final { scan-assembler-times {vsetvli\s+zero,\s*[a-x0-9]+,\s*e32,\s*mf2,\s*tu,\s*m[au]\s+vnsra\.wv\s+v[0-9]+,\s*v[0-9]+,\s*v[0-9]+} 1 } } */ +/* { dg-final { scan-assembler-times {vsetvli\s+zero,\s*[a-x0-9]+,\s*e32,\s*m1,\s*tu,\s*m[au]\s+vnsra\.wv\s+v[0-9]+,\s*v[0-9]+,\s*v[0-9]+} 1 } } */ +/* { dg-final { scan-assembler-times {vsetvli\s+zero,\s*[a-x0-9]+,\s*e32,\s*m2,\s*tu,\s*m[au]\s+vnsra\.wv\s+v[0-9]+,\s*v[0-9]+,\s*v[0-9]+} 1 } } */ +/* { dg-final { scan-assembler-times {vsetvli\s+zero,\s*[a-x0-9]+,\s*e32,\s*m4,\s*tu,\s*m[au]\s+vnsra\.wv\s+v[0-9]+,\s*v[0-9]+,\s*v[0-9]+} 1 } } */ diff --git a/gcc/testsuite/gcc.target/riscv/rvv/base/vnsra_wv_tu-2.c b/gcc/testsuite/gcc.target/riscv/rvv/base/vnsra_wv_tu-2.c new file mode 100644 index 00000000000..319e0c580fc --- /dev/null +++ b/gcc/testsuite/gcc.target/riscv/rvv/base/vnsra_wv_tu-2.c @@ -0,0 +1,111 @@ +/* { dg-do compile } */ +/* { dg-options "-march=rv64gcv -mabi=lp64d -O3 -fno-schedule-insns -fno-schedule-insns2" } */ + +#include "riscv_vector.h" + +vint8mf8_t test___riscv_vnsra_wv_i8mf8_tu(vint8mf8_t merge,vint16mf4_t op1,vuint8mf8_t shift,size_t vl) +{ + return __riscv_vnsra_wv_i8mf8_tu(merge,op1,shift,31); +} + + +vint8mf4_t test___riscv_vnsra_wv_i8mf4_tu(vint8mf4_t merge,vint16mf2_t op1,vuint8mf4_t shift,size_t vl) +{ + return __riscv_vnsra_wv_i8mf4_tu(merge,op1,shift,31); +} + + +vint8mf2_t test___riscv_vnsra_wv_i8mf2_tu(vint8mf2_t merge,vint16m1_t op1,vuint8mf2_t shift,size_t vl) +{ + return __riscv_vnsra_wv_i8mf2_tu(merge,op1,shift,31); +} + + +vint8m1_t test___riscv_vnsra_wv_i8m1_tu(vint8m1_t merge,vint16m2_t op1,vuint8m1_t shift,size_t vl) +{ + return __riscv_vnsra_wv_i8m1_tu(merge,op1,shift,31); +} + + +vint8m2_t test___riscv_vnsra_wv_i8m2_tu(vint8m2_t merge,vint16m4_t op1,vuint8m2_t shift,size_t vl) +{ + return __riscv_vnsra_wv_i8m2_tu(merge,op1,shift,31); +} + + +vint8m4_t test___riscv_vnsra_wv_i8m4_tu(vint8m4_t merge,vint16m8_t op1,vuint8m4_t shift,size_t vl) +{ + return __riscv_vnsra_wv_i8m4_tu(merge,op1,shift,31); +} + + +vint16mf4_t test___riscv_vnsra_wv_i16mf4_tu(vint16mf4_t merge,vint32mf2_t op1,vuint16mf4_t shift,size_t vl) +{ + return __riscv_vnsra_wv_i16mf4_tu(merge,op1,shift,31); +} + + +vint16mf2_t test___riscv_vnsra_wv_i16mf2_tu(vint16mf2_t merge,vint32m1_t op1,vuint16mf2_t shift,size_t vl) +{ + return __riscv_vnsra_wv_i16mf2_tu(merge,op1,shift,31); +} + + +vint16m1_t test___riscv_vnsra_wv_i16m1_tu(vint16m1_t merge,vint32m2_t op1,vuint16m1_t shift,size_t vl) +{ + return __riscv_vnsra_wv_i16m1_tu(merge,op1,shift,31); +} + + +vint16m2_t test___riscv_vnsra_wv_i16m2_tu(vint16m2_t merge,vint32m4_t op1,vuint16m2_t shift,size_t vl) +{ + return __riscv_vnsra_wv_i16m2_tu(merge,op1,shift,31); +} + + +vint16m4_t test___riscv_vnsra_wv_i16m4_tu(vint16m4_t merge,vint32m8_t op1,vuint16m4_t shift,size_t vl) +{ + return __riscv_vnsra_wv_i16m4_tu(merge,op1,shift,31); +} + + +vint32mf2_t test___riscv_vnsra_wv_i32mf2_tu(vint32mf2_t merge,vint64m1_t op1,vuint32mf2_t shift,size_t vl) +{ + return __riscv_vnsra_wv_i32mf2_tu(merge,op1,shift,31); +} + + +vint32m1_t test___riscv_vnsra_wv_i32m1_tu(vint32m1_t merge,vint64m2_t op1,vuint32m1_t shift,size_t vl) +{ + return __riscv_vnsra_wv_i32m1_tu(merge,op1,shift,31); +} + + +vint32m2_t test___riscv_vnsra_wv_i32m2_tu(vint32m2_t merge,vint64m4_t op1,vuint32m2_t shift,size_t vl) +{ + return __riscv_vnsra_wv_i32m2_tu(merge,op1,shift,31); +} + + +vint32m4_t test___riscv_vnsra_wv_i32m4_tu(vint32m4_t merge,vint64m8_t op1,vuint32m4_t shift,size_t vl) +{ + return __riscv_vnsra_wv_i32m4_tu(merge,op1,shift,31); +} + + + +/* { dg-final { scan-assembler-times {vsetivli\s+zero,\s*31,\s*e8,\s*mf8,\s*tu,\s*m[au]\s+vnsra\.wv\s+v[0-9]+,\s*v[0-9]+,\s*v[0-9]+} 1 } } */ +/* { dg-final { scan-assembler-times {vsetivli\s+zero,\s*31,\s*e8,\s*mf4,\s*tu,\s*m[au]\s+vnsra\.wv\s+v[0-9]+,\s*v[0-9]+,\s*v[0-9]+} 1 } } */ +/* { dg-final { scan-assembler-times {vsetivli\s+zero,\s*31,\s*e8,\s*mf2,\s*tu,\s*m[au]\s+vnsra\.wv\s+v[0-9]+,\s*v[0-9]+,\s*v[0-9]+} 1 } } */ +/* { dg-final { scan-assembler-times {vsetivli\s+zero,\s*31,\s*e8,\s*m1,\s*tu,\s*m[au]\s+vnsra\.wv\s+v[0-9]+,\s*v[0-9]+,\s*v[0-9]+} 1 } } */ +/* { dg-final { scan-assembler-times {vsetivli\s+zero,\s*31,\s*e8,\s*m2,\s*tu,\s*m[au]\s+vnsra\.wv\s+v[0-9]+,\s*v[0-9]+,\s*v[0-9]+} 1 } } */ +/* { dg-final { scan-assembler-times {vsetivli\s+zero,\s*31,\s*e8,\s*m4,\s*tu,\s*m[au]\s+vnsra\.wv\s+v[0-9]+,\s*v[0-9]+,\s*v[0-9]+} 1 } } */ +/* { dg-final { scan-assembler-times {vsetivli\s+zero,\s*31,\s*e16,\s*mf4,\s*tu,\s*m[au]\s+vnsra\.wv\s+v[0-9]+,\s*v[0-9]+,\s*v[0-9]+} 1 } } */ +/* { dg-final { scan-assembler-times {vsetivli\s+zero,\s*31,\s*e16,\s*mf2,\s*tu,\s*m[au]\s+vnsra\.wv\s+v[0-9]+,\s*v[0-9]+,\s*v[0-9]+} 1 } } */ +/* { dg-final { scan-assembler-times {vsetivli\s+zero,\s*31,\s*e16,\s*m1,\s*tu,\s*m[au]\s+vnsra\.wv\s+v[0-9]+,\s*v[0-9]+,\s*v[0-9]+} 1 } } */ +/* { dg-final { scan-assembler-times {vsetivli\s+zero,\s*31,\s*e16,\s*m2,\s*tu,\s*m[au]\s+vnsra\.wv\s+v[0-9]+,\s*v[0-9]+,\s*v[0-9]+} 1 } } */ +/* { dg-final { scan-assembler-times {vsetivli\s+zero,\s*31,\s*e16,\s*m4,\s*tu,\s*m[au]\s+vnsra\.wv\s+v[0-9]+,\s*v[0-9]+,\s*v[0-9]+} 1 } } */ +/* { dg-final { scan-assembler-times {vsetivli\s+zero,\s*31,\s*e32,\s*mf2,\s*tu,\s*m[au]\s+vnsra\.wv\s+v[0-9]+,\s*v[0-9]+,\s*v[0-9]+} 1 } } */ +/* { dg-final { scan-assembler-times {vsetivli\s+zero,\s*31,\s*e32,\s*m1,\s*tu,\s*m[au]\s+vnsra\.wv\s+v[0-9]+,\s*v[0-9]+,\s*v[0-9]+} 1 } } */ +/* { dg-final { scan-assembler-times {vsetivli\s+zero,\s*31,\s*e32,\s*m2,\s*tu,\s*m[au]\s+vnsra\.wv\s+v[0-9]+,\s*v[0-9]+,\s*v[0-9]+} 1 } } */ +/* { dg-final { scan-assembler-times {vsetivli\s+zero,\s*31,\s*e32,\s*m4,\s*tu,\s*m[au]\s+vnsra\.wv\s+v[0-9]+,\s*v[0-9]+,\s*v[0-9]+} 1 } } */ diff --git a/gcc/testsuite/gcc.target/riscv/rvv/base/vnsra_wv_tu-3.c b/gcc/testsuite/gcc.target/riscv/rvv/base/vnsra_wv_tu-3.c new file mode 100644 index 00000000000..b17eec2b8d5 --- /dev/null +++ b/gcc/testsuite/gcc.target/riscv/rvv/base/vnsra_wv_tu-3.c @@ -0,0 +1,111 @@ +/* { dg-do compile } */ +/* { dg-options "-march=rv64gcv -mabi=lp64d -O3 -fno-schedule-insns -fno-schedule-insns2" } */ + +#include "riscv_vector.h" + +vint8mf8_t test___riscv_vnsra_wv_i8mf8_tu(vint8mf8_t merge,vint16mf4_t op1,vuint8mf8_t shift,size_t vl) +{ + return __riscv_vnsra_wv_i8mf8_tu(merge,op1,shift,32); +} + + +vint8mf4_t test___riscv_vnsra_wv_i8mf4_tu(vint8mf4_t merge,vint16mf2_t op1,vuint8mf4_t shift,size_t vl) +{ + return __riscv_vnsra_wv_i8mf4_tu(merge,op1,shift,32); +} + + +vint8mf2_t test___riscv_vnsra_wv_i8mf2_tu(vint8mf2_t merge,vint16m1_t op1,vuint8mf2_t shift,size_t vl) +{ + return __riscv_vnsra_wv_i8mf2_tu(merge,op1,shift,32); +} + + +vint8m1_t test___riscv_vnsra_wv_i8m1_tu(vint8m1_t merge,vint16m2_t op1,vuint8m1_t shift,size_t vl) +{ + return __riscv_vnsra_wv_i8m1_tu(merge,op1,shift,32); +} + + +vint8m2_t test___riscv_vnsra_wv_i8m2_tu(vint8m2_t merge,vint16m4_t op1,vuint8m2_t shift,size_t vl) +{ + return __riscv_vnsra_wv_i8m2_tu(merge,op1,shift,32); +} + + +vint8m4_t test___riscv_vnsra_wv_i8m4_tu(vint8m4_t merge,vint16m8_t op1,vuint8m4_t shift,size_t vl) +{ + return __riscv_vnsra_wv_i8m4_tu(merge,op1,shift,32); +} + + +vint16mf4_t test___riscv_vnsra_wv_i16mf4_tu(vint16mf4_t merge,vint32mf2_t op1,vuint16mf4_t shift,size_t vl) +{ + return __riscv_vnsra_wv_i16mf4_tu(merge,op1,shift,32); +} + + +vint16mf2_t test___riscv_vnsra_wv_i16mf2_tu(vint16mf2_t merge,vint32m1_t op1,vuint16mf2_t shift,size_t vl) +{ + return __riscv_vnsra_wv_i16mf2_tu(merge,op1,shift,32); +} + + +vint16m1_t test___riscv_vnsra_wv_i16m1_tu(vint16m1_t merge,vint32m2_t op1,vuint16m1_t shift,size_t vl) +{ + return __riscv_vnsra_wv_i16m1_tu(merge,op1,shift,32); +} + + +vint16m2_t test___riscv_vnsra_wv_i16m2_tu(vint16m2_t merge,vint32m4_t op1,vuint16m2_t shift,size_t vl) +{ + return __riscv_vnsra_wv_i16m2_tu(merge,op1,shift,32); +} + + +vint16m4_t test___riscv_vnsra_wv_i16m4_tu(vint16m4_t merge,vint32m8_t op1,vuint16m4_t shift,size_t vl) +{ + return __riscv_vnsra_wv_i16m4_tu(merge,op1,shift,32); +} + + +vint32mf2_t test___riscv_vnsra_wv_i32mf2_tu(vint32mf2_t merge,vint64m1_t op1,vuint32mf2_t shift,size_t vl) +{ + return __riscv_vnsra_wv_i32mf2_tu(merge,op1,shift,32); +} + + +vint32m1_t test___riscv_vnsra_wv_i32m1_tu(vint32m1_t merge,vint64m2_t op1,vuint32m1_t shift,size_t vl) +{ + return __riscv_vnsra_wv_i32m1_tu(merge,op1,shift,32); +} + + +vint32m2_t test___riscv_vnsra_wv_i32m2_tu(vint32m2_t merge,vint64m4_t op1,vuint32m2_t shift,size_t vl) +{ + return __riscv_vnsra_wv_i32m2_tu(merge,op1,shift,32); +} + + +vint32m4_t test___riscv_vnsra_wv_i32m4_tu(vint32m4_t merge,vint64m8_t op1,vuint32m4_t shift,size_t vl) +{ + return __riscv_vnsra_wv_i32m4_tu(merge,op1,shift,32); +} + + + +/* { dg-final { scan-assembler-times {vsetvli\s+zero,\s*[a-x0-9]+,\s*e8,\s*mf8,\s*tu,\s*m[au]\s+vnsra\.wv\s+v[0-9]+,\s*v[0-9]+,\s*v[0-9]+} 1 } } */ +/* { dg-final { scan-assembler-times {vsetvli\s+zero,\s*[a-x0-9]+,\s*e8,\s*mf4,\s*tu,\s*m[au]\s+vnsra\.wv\s+v[0-9]+,\s*v[0-9]+,\s*v[0-9]+} 1 } } */ +/* { dg-final { scan-assembler-times {vsetvli\s+zero,\s*[a-x0-9]+,\s*e8,\s*mf2,\s*tu,\s*m[au]\s+vnsra\.wv\s+v[0-9]+,\s*v[0-9]+,\s*v[0-9]+} 1 } } */ +/* { dg-final { scan-assembler-times {vsetvli\s+zero,\s*[a-x0-9]+,\s*e8,\s*m1,\s*tu,\s*m[au]\s+vnsra\.wv\s+v[0-9]+,\s*v[0-9]+,\s*v[0-9]+} 1 } } */ +/* { dg-final { scan-assembler-times {vsetvli\s+zero,\s*[a-x0-9]+,\s*e8,\s*m2,\s*tu,\s*m[au]\s+vnsra\.wv\s+v[0-9]+,\s*v[0-9]+,\s*v[0-9]+} 1 } } */ +/* { dg-final { scan-assembler-times {vsetvli\s+zero,\s*[a-x0-9]+,\s*e8,\s*m4,\s*tu,\s*m[au]\s+vnsra\.wv\s+v[0-9]+,\s*v[0-9]+,\s*v[0-9]+} 1 } } */ +/* { dg-final { scan-assembler-times {vsetvli\s+zero,\s*[a-x0-9]+,\s*e16,\s*mf4,\s*tu,\s*m[au]\s+vnsra\.wv\s+v[0-9]+,\s*v[0-9]+,\s*v[0-9]+} 1 } } */ +/* { dg-final { scan-assembler-times {vsetvli\s+zero,\s*[a-x0-9]+,\s*e16,\s*mf2,\s*tu,\s*m[au]\s+vnsra\.wv\s+v[0-9]+,\s*v[0-9]+,\s*v[0-9]+} 1 } } */ +/* { dg-final { scan-assembler-times {vsetvli\s+zero,\s*[a-x0-9]+,\s*e16,\s*m1,\s*tu,\s*m[au]\s+vnsra\.wv\s+v[0-9]+,\s*v[0-9]+,\s*v[0-9]+} 1 } } */ +/* { dg-final { scan-assembler-times {vsetvli\s+zero,\s*[a-x0-9]+,\s*e16,\s*m2,\s*tu,\s*m[au]\s+vnsra\.wv\s+v[0-9]+,\s*v[0-9]+,\s*v[0-9]+} 1 } } */ +/* { dg-final { scan-assembler-times {vsetvli\s+zero,\s*[a-x0-9]+,\s*e16,\s*m4,\s*tu,\s*m[au]\s+vnsra\.wv\s+v[0-9]+,\s*v[0-9]+,\s*v[0-9]+} 1 } } */ +/* { dg-final { scan-assembler-times {vsetvli\s+zero,\s*[a-x0-9]+,\s*e32,\s*mf2,\s*tu,\s*m[au]\s+vnsra\.wv\s+v[0-9]+,\s*v[0-9]+,\s*v[0-9]+} 1 } } */ +/* { dg-final { scan-assembler-times {vsetvli\s+zero,\s*[a-x0-9]+,\s*e32,\s*m1,\s*tu,\s*m[au]\s+vnsra\.wv\s+v[0-9]+,\s*v[0-9]+,\s*v[0-9]+} 1 } } */ +/* { dg-final { scan-assembler-times {vsetvli\s+zero,\s*[a-x0-9]+,\s*e32,\s*m2,\s*tu,\s*m[au]\s+vnsra\.wv\s+v[0-9]+,\s*v[0-9]+,\s*v[0-9]+} 1 } } */ +/* { dg-final { scan-assembler-times {vsetvli\s+zero,\s*[a-x0-9]+,\s*e32,\s*m4,\s*tu,\s*m[au]\s+vnsra\.wv\s+v[0-9]+,\s*v[0-9]+,\s*v[0-9]+} 1 } } */ diff --git a/gcc/testsuite/gcc.target/riscv/rvv/base/vnsra_wv_tum-1.c b/gcc/testsuite/gcc.target/riscv/rvv/base/vnsra_wv_tum-1.c new file mode 100644 index 00000000000..d41f41f9361 --- /dev/null +++ b/gcc/testsuite/gcc.target/riscv/rvv/base/vnsra_wv_tum-1.c @@ -0,0 +1,111 @@ +/* { dg-do compile } */ +/* { dg-options "-march=rv64gcv -mabi=lp64d -O3 -fno-schedule-insns -fno-schedule-insns2" } */ + +#include "riscv_vector.h" + +vint8mf8_t test___riscv_vnsra_wv_i8mf8_tum(vbool64_t mask,vint8mf8_t merge,vint16mf4_t op1,vuint8mf8_t shift,size_t vl) +{ + return __riscv_vnsra_wv_i8mf8_tum(mask,merge,op1,shift,vl); +} + + +vint8mf4_t test___riscv_vnsra_wv_i8mf4_tum(vbool32_t mask,vint8mf4_t merge,vint16mf2_t op1,vuint8mf4_t shift,size_t vl) +{ + return __riscv_vnsra_wv_i8mf4_tum(mask,merge,op1,shift,vl); +} + + +vint8mf2_t test___riscv_vnsra_wv_i8mf2_tum(vbool16_t mask,vint8mf2_t merge,vint16m1_t op1,vuint8mf2_t shift,size_t vl) +{ + return __riscv_vnsra_wv_i8mf2_tum(mask,merge,op1,shift,vl); +} + + +vint8m1_t test___riscv_vnsra_wv_i8m1_tum(vbool8_t mask,vint8m1_t merge,vint16m2_t op1,vuint8m1_t shift,size_t vl) +{ + return __riscv_vnsra_wv_i8m1_tum(mask,merge,op1,shift,vl); +} + + +vint8m2_t test___riscv_vnsra_wv_i8m2_tum(vbool4_t mask,vint8m2_t merge,vint16m4_t op1,vuint8m2_t shift,size_t vl) +{ + return __riscv_vnsra_wv_i8m2_tum(mask,merge,op1,shift,vl); +} + + +vint8m4_t test___riscv_vnsra_wv_i8m4_tum(vbool2_t mask,vint8m4_t merge,vint16m8_t op1,vuint8m4_t shift,size_t vl) +{ + return __riscv_vnsra_wv_i8m4_tum(mask,merge,op1,shift,vl); +} + + +vint16mf4_t test___riscv_vnsra_wv_i16mf4_tum(vbool64_t mask,vint16mf4_t merge,vint32mf2_t op1,vuint16mf4_t shift,size_t vl) +{ + return __riscv_vnsra_wv_i16mf4_tum(mask,merge,op1,shift,vl); +} + + +vint16mf2_t test___riscv_vnsra_wv_i16mf2_tum(vbool32_t mask,vint16mf2_t merge,vint32m1_t op1,vuint16mf2_t shift,size_t vl) +{ + return __riscv_vnsra_wv_i16mf2_tum(mask,merge,op1,shift,vl); +} + + +vint16m1_t test___riscv_vnsra_wv_i16m1_tum(vbool16_t mask,vint16m1_t merge,vint32m2_t op1,vuint16m1_t shift,size_t vl) +{ + return __riscv_vnsra_wv_i16m1_tum(mask,merge,op1,shift,vl); +} + + +vint16m2_t test___riscv_vnsra_wv_i16m2_tum(vbool8_t mask,vint16m2_t merge,vint32m4_t op1,vuint16m2_t shift,size_t vl) +{ + return __riscv_vnsra_wv_i16m2_tum(mask,merge,op1,shift,vl); +} + + +vint16m4_t test___riscv_vnsra_wv_i16m4_tum(vbool4_t mask,vint16m4_t merge,vint32m8_t op1,vuint16m4_t shift,size_t vl) +{ + return __riscv_vnsra_wv_i16m4_tum(mask,merge,op1,shift,vl); +} + + +vint32mf2_t test___riscv_vnsra_wv_i32mf2_tum(vbool64_t mask,vint32mf2_t merge,vint64m1_t op1,vuint32mf2_t shift,size_t vl) +{ + return __riscv_vnsra_wv_i32mf2_tum(mask,merge,op1,shift,vl); +} + + +vint32m1_t test___riscv_vnsra_wv_i32m1_tum(vbool32_t mask,vint32m1_t merge,vint64m2_t op1,vuint32m1_t shift,size_t vl) +{ + return __riscv_vnsra_wv_i32m1_tum(mask,merge,op1,shift,vl); +} + + +vint32m2_t test___riscv_vnsra_wv_i32m2_tum(vbool16_t mask,vint32m2_t merge,vint64m4_t op1,vuint32m2_t shift,size_t vl) +{ + return __riscv_vnsra_wv_i32m2_tum(mask,merge,op1,shift,vl); +} + + +vint32m4_t test___riscv_vnsra_wv_i32m4_tum(vbool8_t mask,vint32m4_t merge,vint64m8_t op1,vuint32m4_t shift,size_t vl) +{ + return __riscv_vnsra_wv_i32m4_tum(mask,merge,op1,shift,vl); +} + + + +/* { dg-final { scan-assembler-times {vsetvli\s+zero,\s*[a-x0-9]+,\s*e8,\s*mf8,\s*tu,\s*m[au]\s+vnsra\.wv\s+v[0-9]+,\s*v[0-9]+,\s*v[0-9]+,\s*v0.t} 1 } } */ +/* { dg-final { scan-assembler-times {vsetvli\s+zero,\s*[a-x0-9]+,\s*e8,\s*mf4,\s*tu,\s*m[au]\s+vnsra\.wv\s+v[0-9]+,\s*v[0-9]+,\s*v[0-9]+,\s*v0.t} 1 } } */ +/* { dg-final { scan-assembler-times {vsetvli\s+zero,\s*[a-x0-9]+,\s*e8,\s*mf2,\s*tu,\s*m[au]\s+vnsra\.wv\s+v[0-9]+,\s*v[0-9]+,\s*v[0-9]+,\s*v0.t} 1 } } */ +/* { dg-final { scan-assembler-times {vsetvli\s+zero,\s*[a-x0-9]+,\s*e8,\s*m1,\s*tu,\s*m[au]\s+vnsra\.wv\s+v[0-9]+,\s*v[0-9]+,\s*v[0-9]+,\s*v0.t} 1 } } */ +/* { dg-final { scan-assembler-times {vsetvli\s+zero,\s*[a-x0-9]+,\s*e8,\s*m2,\s*tu,\s*m[au]\s+vnsra\.wv\s+v[0-9]+,\s*v[0-9]+,\s*v[0-9]+,\s*v0.t} 1 } } */ +/* { dg-final { scan-assembler-times {vsetvli\s+zero,\s*[a-x0-9]+,\s*e8,\s*m4,\s*tu,\s*m[au]\s+vnsra\.wv\s+v[0-9]+,\s*v[0-9]+,\s*v[0-9]+,\s*v0.t} 1 } } */ +/* { dg-final { scan-assembler-times {vsetvli\s+zero,\s*[a-x0-9]+,\s*e16,\s*mf4,\s*tu,\s*m[au]\s+vnsra\.wv\s+v[0-9]+,\s*v[0-9]+,\s*v[0-9]+,\s*v0.t} 1 } } */ +/* { dg-final { scan-assembler-times {vsetvli\s+zero,\s*[a-x0-9]+,\s*e16,\s*mf2,\s*tu,\s*m[au]\s+vnsra\.wv\s+v[0-9]+,\s*v[0-9]+,\s*v[0-9]+,\s*v0.t} 1 } } */ +/* { dg-final { scan-assembler-times {vsetvli\s+zero,\s*[a-x0-9]+,\s*e16,\s*m1,\s*tu,\s*m[au]\s+vnsra\.wv\s+v[0-9]+,\s*v[0-9]+,\s*v[0-9]+,\s*v0.t} 1 } } */ +/* { dg-final { scan-assembler-times {vsetvli\s+zero,\s*[a-x0-9]+,\s*e16,\s*m2,\s*tu,\s*m[au]\s+vnsra\.wv\s+v[0-9]+,\s*v[0-9]+,\s*v[0-9]+,\s*v0.t} 1 } } */ +/* { dg-final { scan-assembler-times {vsetvli\s+zero,\s*[a-x0-9]+,\s*e16,\s*m4,\s*tu,\s*m[au]\s+vnsra\.wv\s+v[0-9]+,\s*v[0-9]+,\s*v[0-9]+,\s*v0.t} 1 } } */ +/* { dg-final { scan-assembler-times {vsetvli\s+zero,\s*[a-x0-9]+,\s*e32,\s*mf2,\s*tu,\s*m[au]\s+vnsra\.wv\s+v[0-9]+,\s*v[0-9]+,\s*v[0-9]+,\s*v0.t} 1 } } */ +/* { dg-final { scan-assembler-times {vsetvli\s+zero,\s*[a-x0-9]+,\s*e32,\s*m1,\s*tu,\s*m[au]\s+vnsra\.wv\s+v[0-9]+,\s*v[0-9]+,\s*v[0-9]+,\s*v0.t} 1 } } */ +/* { dg-final { scan-assembler-times {vsetvli\s+zero,\s*[a-x0-9]+,\s*e32,\s*m2,\s*tu,\s*m[au]\s+vnsra\.wv\s+v[0-9]+,\s*v[0-9]+,\s*v[0-9]+,\s*v0.t} 1 } } */ +/* { dg-final { scan-assembler-times {vsetvli\s+zero,\s*[a-x0-9]+,\s*e32,\s*m4,\s*tu,\s*m[au]\s+vnsra\.wv\s+v[0-9]+,\s*v[0-9]+,\s*v[0-9]+,\s*v0.t} 1 } } */ diff --git a/gcc/testsuite/gcc.target/riscv/rvv/base/vnsra_wv_tum-2.c b/gcc/testsuite/gcc.target/riscv/rvv/base/vnsra_wv_tum-2.c new file mode 100644 index 00000000000..ad396d664b9 --- /dev/null +++ b/gcc/testsuite/gcc.target/riscv/rvv/base/vnsra_wv_tum-2.c @@ -0,0 +1,111 @@ +/* { dg-do compile } */ +/* { dg-options "-march=rv64gcv -mabi=lp64d -O3 -fno-schedule-insns -fno-schedule-insns2" } */ + +#include "riscv_vector.h" + +vint8mf8_t test___riscv_vnsra_wv_i8mf8_tum(vbool64_t mask,vint8mf8_t merge,vint16mf4_t op1,vuint8mf8_t shift,size_t vl) +{ + return __riscv_vnsra_wv_i8mf8_tum(mask,merge,op1,shift,31); +} + + +vint8mf4_t test___riscv_vnsra_wv_i8mf4_tum(vbool32_t mask,vint8mf4_t merge,vint16mf2_t op1,vuint8mf4_t shift,size_t vl) +{ + return __riscv_vnsra_wv_i8mf4_tum(mask,merge,op1,shift,31); +} + + +vint8mf2_t test___riscv_vnsra_wv_i8mf2_tum(vbool16_t mask,vint8mf2_t merge,vint16m1_t op1,vuint8mf2_t shift,size_t vl) +{ + return __riscv_vnsra_wv_i8mf2_tum(mask,merge,op1,shift,31); +} + + +vint8m1_t test___riscv_vnsra_wv_i8m1_tum(vbool8_t mask,vint8m1_t merge,vint16m2_t op1,vuint8m1_t shift,size_t vl) +{ + return __riscv_vnsra_wv_i8m1_tum(mask,merge,op1,shift,31); +} + + +vint8m2_t test___riscv_vnsra_wv_i8m2_tum(vbool4_t mask,vint8m2_t merge,vint16m4_t op1,vuint8m2_t shift,size_t vl) +{ + return __riscv_vnsra_wv_i8m2_tum(mask,merge,op1,shift,31); +} + + +vint8m4_t test___riscv_vnsra_wv_i8m4_tum(vbool2_t mask,vint8m4_t merge,vint16m8_t op1,vuint8m4_t shift,size_t vl) +{ + return __riscv_vnsra_wv_i8m4_tum(mask,merge,op1,shift,31); +} + + +vint16mf4_t test___riscv_vnsra_wv_i16mf4_tum(vbool64_t mask,vint16mf4_t merge,vint32mf2_t op1,vuint16mf4_t shift,size_t vl) +{ + return __riscv_vnsra_wv_i16mf4_tum(mask,merge,op1,shift,31); +} + + +vint16mf2_t test___riscv_vnsra_wv_i16mf2_tum(vbool32_t mask,vint16mf2_t merge,vint32m1_t op1,vuint16mf2_t shift,size_t vl) +{ + return __riscv_vnsra_wv_i16mf2_tum(mask,merge,op1,shift,31); +} + + +vint16m1_t test___riscv_vnsra_wv_i16m1_tum(vbool16_t mask,vint16m1_t merge,vint32m2_t op1,vuint16m1_t shift,size_t vl) +{ + return __riscv_vnsra_wv_i16m1_tum(mask,merge,op1,shift,31); +} + + +vint16m2_t test___riscv_vnsra_wv_i16m2_tum(vbool8_t mask,vint16m2_t merge,vint32m4_t op1,vuint16m2_t shift,size_t vl) +{ + return __riscv_vnsra_wv_i16m2_tum(mask,merge,op1,shift,31); +} + + +vint16m4_t test___riscv_vnsra_wv_i16m4_tum(vbool4_t mask,vint16m4_t merge,vint32m8_t op1,vuint16m4_t shift,size_t vl) +{ + return __riscv_vnsra_wv_i16m4_tum(mask,merge,op1,shift,31); +} + + +vint32mf2_t test___riscv_vnsra_wv_i32mf2_tum(vbool64_t mask,vint32mf2_t merge,vint64m1_t op1,vuint32mf2_t shift,size_t vl) +{ + return __riscv_vnsra_wv_i32mf2_tum(mask,merge,op1,shift,31); +} + + +vint32m1_t test___riscv_vnsra_wv_i32m1_tum(vbool32_t mask,vint32m1_t merge,vint64m2_t op1,vuint32m1_t shift,size_t vl) +{ + return __riscv_vnsra_wv_i32m1_tum(mask,merge,op1,shift,31); +} + + +vint32m2_t test___riscv_vnsra_wv_i32m2_tum(vbool16_t mask,vint32m2_t merge,vint64m4_t op1,vuint32m2_t shift,size_t vl) +{ + return __riscv_vnsra_wv_i32m2_tum(mask,merge,op1,shift,31); +} + + +vint32m4_t test___riscv_vnsra_wv_i32m4_tum(vbool8_t mask,vint32m4_t merge,vint64m8_t op1,vuint32m4_t shift,size_t vl) +{ + return __riscv_vnsra_wv_i32m4_tum(mask,merge,op1,shift,31); +} + + + +/* { dg-final { scan-assembler-times {vsetivli\s+zero,\s*31,\s*e8,\s*mf8,\s*tu,\s*m[au]\s+vnsra\.wv\s+v[0-9]+,\s*v[0-9]+,\s*v[0-9]+,\s*v0.t} 1 } } */ +/* { dg-final { scan-assembler-times {vsetivli\s+zero,\s*31,\s*e8,\s*mf4,\s*tu,\s*m[au]\s+vnsra\.wv\s+v[0-9]+,\s*v[0-9]+,\s*v[0-9]+,\s*v0.t} 1 } } */ +/* { dg-final { scan-assembler-times {vsetivli\s+zero,\s*31,\s*e8,\s*mf2,\s*tu,\s*m[au]\s+vnsra\.wv\s+v[0-9]+,\s*v[0-9]+,\s*v[0-9]+,\s*v0.t} 1 } } */ +/* { dg-final { scan-assembler-times {vsetivli\s+zero,\s*31,\s*e8,\s*m1,\s*tu,\s*m[au]\s+vnsra\.wv\s+v[0-9]+,\s*v[0-9]+,\s*v[0-9]+,\s*v0.t} 1 } } */ +/* { dg-final { scan-assembler-times {vsetivli\s+zero,\s*31,\s*e8,\s*m2,\s*tu,\s*m[au]\s+vnsra\.wv\s+v[0-9]+,\s*v[0-9]+,\s*v[0-9]+,\s*v0.t} 1 } } */ +/* { dg-final { scan-assembler-times {vsetivli\s+zero,\s*31,\s*e8,\s*m4,\s*tu,\s*m[au]\s+vnsra\.wv\s+v[0-9]+,\s*v[0-9]+,\s*v[0-9]+,\s*v0.t} 1 } } */ +/* { dg-final { scan-assembler-times {vsetivli\s+zero,\s*31,\s*e16,\s*mf4,\s*tu,\s*m[au]\s+vnsra\.wv\s+v[0-9]+,\s*v[0-9]+,\s*v[0-9]+,\s*v0.t} 1 } } */ +/* { dg-final { scan-assembler-times {vsetivli\s+zero,\s*31,\s*e16,\s*mf2,\s*tu,\s*m[au]\s+vnsra\.wv\s+v[0-9]+,\s*v[0-9]+,\s*v[0-9]+,\s*v0.t} 1 } } */ +/* { dg-final { scan-assembler-times {vsetivli\s+zero,\s*31,\s*e16,\s*m1,\s*tu,\s*m[au]\s+vnsra\.wv\s+v[0-9]+,\s*v[0-9]+,\s*v[0-9]+,\s*v0.t} 1 } } */ +/* { dg-final { scan-assembler-times {vsetivli\s+zero,\s*31,\s*e16,\s*m2,\s*tu,\s*m[au]\s+vnsra\.wv\s+v[0-9]+,\s*v[0-9]+,\s*v[0-9]+,\s*v0.t} 1 } } */ +/* { dg-final { scan-assembler-times {vsetivli\s+zero,\s*31,\s*e16,\s*m4,\s*tu,\s*m[au]\s+vnsra\.wv\s+v[0-9]+,\s*v[0-9]+,\s*v[0-9]+,\s*v0.t} 1 } } */ +/* { dg-final { scan-assembler-times {vsetivli\s+zero,\s*31,\s*e32,\s*mf2,\s*tu,\s*m[au]\s+vnsra\.wv\s+v[0-9]+,\s*v[0-9]+,\s*v[0-9]+,\s*v0.t} 1 } } */ +/* { dg-final { scan-assembler-times {vsetivli\s+zero,\s*31,\s*e32,\s*m1,\s*tu,\s*m[au]\s+vnsra\.wv\s+v[0-9]+,\s*v[0-9]+,\s*v[0-9]+,\s*v0.t} 1 } } */ +/* { dg-final { scan-assembler-times {vsetivli\s+zero,\s*31,\s*e32,\s*m2,\s*tu,\s*m[au]\s+vnsra\.wv\s+v[0-9]+,\s*v[0-9]+,\s*v[0-9]+,\s*v0.t} 1 } } */ +/* { dg-final { scan-assembler-times {vsetivli\s+zero,\s*31,\s*e32,\s*m4,\s*tu,\s*m[au]\s+vnsra\.wv\s+v[0-9]+,\s*v[0-9]+,\s*v[0-9]+,\s*v0.t} 1 } } */ diff --git a/gcc/testsuite/gcc.target/riscv/rvv/base/vnsra_wv_tum-3.c b/gcc/testsuite/gcc.target/riscv/rvv/base/vnsra_wv_tum-3.c new file mode 100644 index 00000000000..c7078da01b4 --- /dev/null +++ b/gcc/testsuite/gcc.target/riscv/rvv/base/vnsra_wv_tum-3.c @@ -0,0 +1,111 @@ +/* { dg-do compile } */ +/* { dg-options "-march=rv64gcv -mabi=lp64d -O3 -fno-schedule-insns -fno-schedule-insns2" } */ + +#include "riscv_vector.h" + +vint8mf8_t test___riscv_vnsra_wv_i8mf8_tum(vbool64_t mask,vint8mf8_t merge,vint16mf4_t op1,vuint8mf8_t shift,size_t vl) +{ + return __riscv_vnsra_wv_i8mf8_tum(mask,merge,op1,shift,32); +} + + +vint8mf4_t test___riscv_vnsra_wv_i8mf4_tum(vbool32_t mask,vint8mf4_t merge,vint16mf2_t op1,vuint8mf4_t shift,size_t vl) +{ + return __riscv_vnsra_wv_i8mf4_tum(mask,merge,op1,shift,32); +} + + +vint8mf2_t test___riscv_vnsra_wv_i8mf2_tum(vbool16_t mask,vint8mf2_t merge,vint16m1_t op1,vuint8mf2_t shift,size_t vl) +{ + return __riscv_vnsra_wv_i8mf2_tum(mask,merge,op1,shift,32); +} + + +vint8m1_t test___riscv_vnsra_wv_i8m1_tum(vbool8_t mask,vint8m1_t merge,vint16m2_t op1,vuint8m1_t shift,size_t vl) +{ + return __riscv_vnsra_wv_i8m1_tum(mask,merge,op1,shift,32); +} + + +vint8m2_t test___riscv_vnsra_wv_i8m2_tum(vbool4_t mask,vint8m2_t merge,vint16m4_t op1,vuint8m2_t shift,size_t vl) +{ + return __riscv_vnsra_wv_i8m2_tum(mask,merge,op1,shift,32); +} + + +vint8m4_t test___riscv_vnsra_wv_i8m4_tum(vbool2_t mask,vint8m4_t merge,vint16m8_t op1,vuint8m4_t shift,size_t vl) +{ + return __riscv_vnsra_wv_i8m4_tum(mask,merge,op1,shift,32); +} + + +vint16mf4_t test___riscv_vnsra_wv_i16mf4_tum(vbool64_t mask,vint16mf4_t merge,vint32mf2_t op1,vuint16mf4_t shift,size_t vl) +{ + return __riscv_vnsra_wv_i16mf4_tum(mask,merge,op1,shift,32); +} + + +vint16mf2_t test___riscv_vnsra_wv_i16mf2_tum(vbool32_t mask,vint16mf2_t merge,vint32m1_t op1,vuint16mf2_t shift,size_t vl) +{ + return __riscv_vnsra_wv_i16mf2_tum(mask,merge,op1,shift,32); +} + + +vint16m1_t test___riscv_vnsra_wv_i16m1_tum(vbool16_t mask,vint16m1_t merge,vint32m2_t op1,vuint16m1_t shift,size_t vl) +{ + return __riscv_vnsra_wv_i16m1_tum(mask,merge,op1,shift,32); +} + + +vint16m2_t test___riscv_vnsra_wv_i16m2_tum(vbool8_t mask,vint16m2_t merge,vint32m4_t op1,vuint16m2_t shift,size_t vl) +{ + return __riscv_vnsra_wv_i16m2_tum(mask,merge,op1,shift,32); +} + + +vint16m4_t test___riscv_vnsra_wv_i16m4_tum(vbool4_t mask,vint16m4_t merge,vint32m8_t op1,vuint16m4_t shift,size_t vl) +{ + return __riscv_vnsra_wv_i16m4_tum(mask,merge,op1,shift,32); +} + + +vint32mf2_t test___riscv_vnsra_wv_i32mf2_tum(vbool64_t mask,vint32mf2_t merge,vint64m1_t op1,vuint32mf2_t shift,size_t vl) +{ + return __riscv_vnsra_wv_i32mf2_tum(mask,merge,op1,shift,32); +} + + +vint32m1_t test___riscv_vnsra_wv_i32m1_tum(vbool32_t mask,vint32m1_t merge,vint64m2_t op1,vuint32m1_t shift,size_t vl) +{ + return __riscv_vnsra_wv_i32m1_tum(mask,merge,op1,shift,32); +} + + +vint32m2_t test___riscv_vnsra_wv_i32m2_tum(vbool16_t mask,vint32m2_t merge,vint64m4_t op1,vuint32m2_t shift,size_t vl) +{ + return __riscv_vnsra_wv_i32m2_tum(mask,merge,op1,shift,32); +} + + +vint32m4_t test___riscv_vnsra_wv_i32m4_tum(vbool8_t mask,vint32m4_t merge,vint64m8_t op1,vuint32m4_t shift,size_t vl) +{ + return __riscv_vnsra_wv_i32m4_tum(mask,merge,op1,shift,32); +} + + + +/* { dg-final { scan-assembler-times {vsetvli\s+zero,\s*[a-x0-9]+,\s*e8,\s*mf8,\s*tu,\s*m[au]\s+vnsra\.wv\s+v[0-9]+,\s*v[0-9]+,\s*v[0-9]+,\s*v0.t} 1 } } */ +/* { dg-final { scan-assembler-times {vsetvli\s+zero,\s*[a-x0-9]+,\s*e8,\s*mf4,\s*tu,\s*m[au]\s+vnsra\.wv\s+v[0-9]+,\s*v[0-9]+,\s*v[0-9]+,\s*v0.t} 1 } } */ +/* { dg-final { scan-assembler-times {vsetvli\s+zero,\s*[a-x0-9]+,\s*e8,\s*mf2,\s*tu,\s*m[au]\s+vnsra\.wv\s+v[0-9]+,\s*v[0-9]+,\s*v[0-9]+,\s*v0.t} 1 } } */ +/* { dg-final { scan-assembler-times {vsetvli\s+zero,\s*[a-x0-9]+,\s*e8,\s*m1,\s*tu,\s*m[au]\s+vnsra\.wv\s+v[0-9]+,\s*v[0-9]+,\s*v[0-9]+,\s*v0.t} 1 } } */ +/* { dg-final { scan-assembler-times {vsetvli\s+zero,\s*[a-x0-9]+,\s*e8,\s*m2,\s*tu,\s*m[au]\s+vnsra\.wv\s+v[0-9]+,\s*v[0-9]+,\s*v[0-9]+,\s*v0.t} 1 } } */ +/* { dg-final { scan-assembler-times {vsetvli\s+zero,\s*[a-x0-9]+,\s*e8,\s*m4,\s*tu,\s*m[au]\s+vnsra\.wv\s+v[0-9]+,\s*v[0-9]+,\s*v[0-9]+,\s*v0.t} 1 } } */ +/* { dg-final { scan-assembler-times {vsetvli\s+zero,\s*[a-x0-9]+,\s*e16,\s*mf4,\s*tu,\s*m[au]\s+vnsra\.wv\s+v[0-9]+,\s*v[0-9]+,\s*v[0-9]+,\s*v0.t} 1 } } */ +/* { dg-final { scan-assembler-times {vsetvli\s+zero,\s*[a-x0-9]+,\s*e16,\s*mf2,\s*tu,\s*m[au]\s+vnsra\.wv\s+v[0-9]+,\s*v[0-9]+,\s*v[0-9]+,\s*v0.t} 1 } } */ +/* { dg-final { scan-assembler-times {vsetvli\s+zero,\s*[a-x0-9]+,\s*e16,\s*m1,\s*tu,\s*m[au]\s+vnsra\.wv\s+v[0-9]+,\s*v[0-9]+,\s*v[0-9]+,\s*v0.t} 1 } } */ +/* { dg-final { scan-assembler-times {vsetvli\s+zero,\s*[a-x0-9]+,\s*e16,\s*m2,\s*tu,\s*m[au]\s+vnsra\.wv\s+v[0-9]+,\s*v[0-9]+,\s*v[0-9]+,\s*v0.t} 1 } } */ +/* { dg-final { scan-assembler-times {vsetvli\s+zero,\s*[a-x0-9]+,\s*e16,\s*m4,\s*tu,\s*m[au]\s+vnsra\.wv\s+v[0-9]+,\s*v[0-9]+,\s*v[0-9]+,\s*v0.t} 1 } } */ +/* { dg-final { scan-assembler-times {vsetvli\s+zero,\s*[a-x0-9]+,\s*e32,\s*mf2,\s*tu,\s*m[au]\s+vnsra\.wv\s+v[0-9]+,\s*v[0-9]+,\s*v[0-9]+,\s*v0.t} 1 } } */ +/* { dg-final { scan-assembler-times {vsetvli\s+zero,\s*[a-x0-9]+,\s*e32,\s*m1,\s*tu,\s*m[au]\s+vnsra\.wv\s+v[0-9]+,\s*v[0-9]+,\s*v[0-9]+,\s*v0.t} 1 } } */ +/* { dg-final { scan-assembler-times {vsetvli\s+zero,\s*[a-x0-9]+,\s*e32,\s*m2,\s*tu,\s*m[au]\s+vnsra\.wv\s+v[0-9]+,\s*v[0-9]+,\s*v[0-9]+,\s*v0.t} 1 } } */ +/* { dg-final { scan-assembler-times {vsetvli\s+zero,\s*[a-x0-9]+,\s*e32,\s*m4,\s*tu,\s*m[au]\s+vnsra\.wv\s+v[0-9]+,\s*v[0-9]+,\s*v[0-9]+,\s*v0.t} 1 } } */ diff --git a/gcc/testsuite/gcc.target/riscv/rvv/base/vnsra_wv_tumu-1.c b/gcc/testsuite/gcc.target/riscv/rvv/base/vnsra_wv_tumu-1.c new file mode 100644 index 00000000000..e82fa2f576b --- /dev/null +++ b/gcc/testsuite/gcc.target/riscv/rvv/base/vnsra_wv_tumu-1.c @@ -0,0 +1,111 @@ +/* { dg-do compile } */ +/* { dg-options "-march=rv64gcv -mabi=lp64d -O3 -fno-schedule-insns -fno-schedule-insns2" } */ + +#include "riscv_vector.h" + +vint8mf8_t test___riscv_vnsra_wv_i8mf8_tumu(vbool64_t mask,vint8mf8_t merge,vint16mf4_t op1,vuint8mf8_t shift,size_t vl) +{ + return __riscv_vnsra_wv_i8mf8_tumu(mask,merge,op1,shift,vl); +} + + +vint8mf4_t test___riscv_vnsra_wv_i8mf4_tumu(vbool32_t mask,vint8mf4_t merge,vint16mf2_t op1,vuint8mf4_t shift,size_t vl) +{ + return __riscv_vnsra_wv_i8mf4_tumu(mask,merge,op1,shift,vl); +} + + +vint8mf2_t test___riscv_vnsra_wv_i8mf2_tumu(vbool16_t mask,vint8mf2_t merge,vint16m1_t op1,vuint8mf2_t shift,size_t vl) +{ + return __riscv_vnsra_wv_i8mf2_tumu(mask,merge,op1,shift,vl); +} + + +vint8m1_t test___riscv_vnsra_wv_i8m1_tumu(vbool8_t mask,vint8m1_t merge,vint16m2_t op1,vuint8m1_t shift,size_t vl) +{ + return __riscv_vnsra_wv_i8m1_tumu(mask,merge,op1,shift,vl); +} + + +vint8m2_t test___riscv_vnsra_wv_i8m2_tumu(vbool4_t mask,vint8m2_t merge,vint16m4_t op1,vuint8m2_t shift,size_t vl) +{ + return __riscv_vnsra_wv_i8m2_tumu(mask,merge,op1,shift,vl); +} + + +vint8m4_t test___riscv_vnsra_wv_i8m4_tumu(vbool2_t mask,vint8m4_t merge,vint16m8_t op1,vuint8m4_t shift,size_t vl) +{ + return __riscv_vnsra_wv_i8m4_tumu(mask,merge,op1,shift,vl); +} + + +vint16mf4_t test___riscv_vnsra_wv_i16mf4_tumu(vbool64_t mask,vint16mf4_t merge,vint32mf2_t op1,vuint16mf4_t shift,size_t vl) +{ + return __riscv_vnsra_wv_i16mf4_tumu(mask,merge,op1,shift,vl); +} + + +vint16mf2_t test___riscv_vnsra_wv_i16mf2_tumu(vbool32_t mask,vint16mf2_t merge,vint32m1_t op1,vuint16mf2_t shift,size_t vl) +{ + return __riscv_vnsra_wv_i16mf2_tumu(mask,merge,op1,shift,vl); +} + + +vint16m1_t test___riscv_vnsra_wv_i16m1_tumu(vbool16_t mask,vint16m1_t merge,vint32m2_t op1,vuint16m1_t shift,size_t vl) +{ + return __riscv_vnsra_wv_i16m1_tumu(mask,merge,op1,shift,vl); +} + + +vint16m2_t test___riscv_vnsra_wv_i16m2_tumu(vbool8_t mask,vint16m2_t merge,vint32m4_t op1,vuint16m2_t shift,size_t vl) +{ + return __riscv_vnsra_wv_i16m2_tumu(mask,merge,op1,shift,vl); +} + + +vint16m4_t test___riscv_vnsra_wv_i16m4_tumu(vbool4_t mask,vint16m4_t merge,vint32m8_t op1,vuint16m4_t shift,size_t vl) +{ + return __riscv_vnsra_wv_i16m4_tumu(mask,merge,op1,shift,vl); +} + + +vint32mf2_t test___riscv_vnsra_wv_i32mf2_tumu(vbool64_t mask,vint32mf2_t merge,vint64m1_t op1,vuint32mf2_t shift,size_t vl) +{ + return __riscv_vnsra_wv_i32mf2_tumu(mask,merge,op1,shift,vl); +} + + +vint32m1_t test___riscv_vnsra_wv_i32m1_tumu(vbool32_t mask,vint32m1_t merge,vint64m2_t op1,vuint32m1_t shift,size_t vl) +{ + return __riscv_vnsra_wv_i32m1_tumu(mask,merge,op1,shift,vl); +} + + +vint32m2_t test___riscv_vnsra_wv_i32m2_tumu(vbool16_t mask,vint32m2_t merge,vint64m4_t op1,vuint32m2_t shift,size_t vl) +{ + return __riscv_vnsra_wv_i32m2_tumu(mask,merge,op1,shift,vl); +} + + +vint32m4_t test___riscv_vnsra_wv_i32m4_tumu(vbool8_t mask,vint32m4_t merge,vint64m8_t op1,vuint32m4_t shift,size_t vl) +{ + return __riscv_vnsra_wv_i32m4_tumu(mask,merge,op1,shift,vl); +} + + + +/* { dg-final { scan-assembler-times {vsetvli\s+zero,\s*[a-x0-9]+,\s*e8,\s*mf8,\s*tu,\s*mu\s+vnsra\.wv\s+v[0-9]+,\s*v[0-9]+,\s*v[0-9]+,\s*v0.t} 1 } } */ +/* { dg-final { scan-assembler-times {vsetvli\s+zero,\s*[a-x0-9]+,\s*e8,\s*mf4,\s*tu,\s*mu\s+vnsra\.wv\s+v[0-9]+,\s*v[0-9]+,\s*v[0-9]+,\s*v0.t} 1 } } */ +/* { dg-final { scan-assembler-times {vsetvli\s+zero,\s*[a-x0-9]+,\s*e8,\s*mf2,\s*tu,\s*mu\s+vnsra\.wv\s+v[0-9]+,\s*v[0-9]+,\s*v[0-9]+,\s*v0.t} 1 } } */ +/* { dg-final { scan-assembler-times {vsetvli\s+zero,\s*[a-x0-9]+,\s*e8,\s*m1,\s*tu,\s*mu\s+vnsra\.wv\s+v[0-9]+,\s*v[0-9]+,\s*v[0-9]+,\s*v0.t} 1 } } */ +/* { dg-final { scan-assembler-times {vsetvli\s+zero,\s*[a-x0-9]+,\s*e8,\s*m2,\s*tu,\s*mu\s+vnsra\.wv\s+v[0-9]+,\s*v[0-9]+,\s*v[0-9]+,\s*v0.t} 1 } } */ +/* { dg-final { scan-assembler-times {vsetvli\s+zero,\s*[a-x0-9]+,\s*e8,\s*m4,\s*tu,\s*mu\s+vnsra\.wv\s+v[0-9]+,\s*v[0-9]+,\s*v[0-9]+,\s*v0.t} 1 } } */ +/* { dg-final { scan-assembler-times {vsetvli\s+zero,\s*[a-x0-9]+,\s*e16,\s*mf4,\s*tu,\s*mu\s+vnsra\.wv\s+v[0-9]+,\s*v[0-9]+,\s*v[0-9]+,\s*v0.t} 1 } } */ +/* { dg-final { scan-assembler-times {vsetvli\s+zero,\s*[a-x0-9]+,\s*e16,\s*mf2,\s*tu,\s*mu\s+vnsra\.wv\s+v[0-9]+,\s*v[0-9]+,\s*v[0-9]+,\s*v0.t} 1 } } */ +/* { dg-final { scan-assembler-times {vsetvli\s+zero,\s*[a-x0-9]+,\s*e16,\s*m1,\s*tu,\s*mu\s+vnsra\.wv\s+v[0-9]+,\s*v[0-9]+,\s*v[0-9]+,\s*v0.t} 1 } } */ +/* { dg-final { scan-assembler-times {vsetvli\s+zero,\s*[a-x0-9]+,\s*e16,\s*m2,\s*tu,\s*mu\s+vnsra\.wv\s+v[0-9]+,\s*v[0-9]+,\s*v[0-9]+,\s*v0.t} 1 } } */ +/* { dg-final { scan-assembler-times {vsetvli\s+zero,\s*[a-x0-9]+,\s*e16,\s*m4,\s*tu,\s*mu\s+vnsra\.wv\s+v[0-9]+,\s*v[0-9]+,\s*v[0-9]+,\s*v0.t} 1 } } */ +/* { dg-final { scan-assembler-times {vsetvli\s+zero,\s*[a-x0-9]+,\s*e32,\s*mf2,\s*tu,\s*mu\s+vnsra\.wv\s+v[0-9]+,\s*v[0-9]+,\s*v[0-9]+,\s*v0.t} 1 } } */ +/* { dg-final { scan-assembler-times {vsetvli\s+zero,\s*[a-x0-9]+,\s*e32,\s*m1,\s*tu,\s*mu\s+vnsra\.wv\s+v[0-9]+,\s*v[0-9]+,\s*v[0-9]+,\s*v0.t} 1 } } */ +/* { dg-final { scan-assembler-times {vsetvli\s+zero,\s*[a-x0-9]+,\s*e32,\s*m2,\s*tu,\s*mu\s+vnsra\.wv\s+v[0-9]+,\s*v[0-9]+,\s*v[0-9]+,\s*v0.t} 1 } } */ +/* { dg-final { scan-assembler-times {vsetvli\s+zero,\s*[a-x0-9]+,\s*e32,\s*m4,\s*tu,\s*mu\s+vnsra\.wv\s+v[0-9]+,\s*v[0-9]+,\s*v[0-9]+,\s*v0.t} 1 } } */ diff --git a/gcc/testsuite/gcc.target/riscv/rvv/base/vnsra_wv_tumu-2.c b/gcc/testsuite/gcc.target/riscv/rvv/base/vnsra_wv_tumu-2.c new file mode 100644 index 00000000000..89a8361be94 --- /dev/null +++ b/gcc/testsuite/gcc.target/riscv/rvv/base/vnsra_wv_tumu-2.c @@ -0,0 +1,111 @@ +/* { dg-do compile } */ +/* { dg-options "-march=rv64gcv -mabi=lp64d -O3 -fno-schedule-insns -fno-schedule-insns2" } */ + +#include "riscv_vector.h" + +vint8mf8_t test___riscv_vnsra_wv_i8mf8_tumu(vbool64_t mask,vint8mf8_t merge,vint16mf4_t op1,vuint8mf8_t shift,size_t vl) +{ + return __riscv_vnsra_wv_i8mf8_tumu(mask,merge,op1,shift,31); +} + + +vint8mf4_t test___riscv_vnsra_wv_i8mf4_tumu(vbool32_t mask,vint8mf4_t merge,vint16mf2_t op1,vuint8mf4_t shift,size_t vl) +{ + return __riscv_vnsra_wv_i8mf4_tumu(mask,merge,op1,shift,31); +} + + +vint8mf2_t test___riscv_vnsra_wv_i8mf2_tumu(vbool16_t mask,vint8mf2_t merge,vint16m1_t op1,vuint8mf2_t shift,size_t vl) +{ + return __riscv_vnsra_wv_i8mf2_tumu(mask,merge,op1,shift,31); +} + + +vint8m1_t test___riscv_vnsra_wv_i8m1_tumu(vbool8_t mask,vint8m1_t merge,vint16m2_t op1,vuint8m1_t shift,size_t vl) +{ + return __riscv_vnsra_wv_i8m1_tumu(mask,merge,op1,shift,31); +} + + +vint8m2_t test___riscv_vnsra_wv_i8m2_tumu(vbool4_t mask,vint8m2_t merge,vint16m4_t op1,vuint8m2_t shift,size_t vl) +{ + return __riscv_vnsra_wv_i8m2_tumu(mask,merge,op1,shift,31); +} + + +vint8m4_t test___riscv_vnsra_wv_i8m4_tumu(vbool2_t mask,vint8m4_t merge,vint16m8_t op1,vuint8m4_t shift,size_t vl) +{ + return __riscv_vnsra_wv_i8m4_tumu(mask,merge,op1,shift,31); +} + + +vint16mf4_t test___riscv_vnsra_wv_i16mf4_tumu(vbool64_t mask,vint16mf4_t merge,vint32mf2_t op1,vuint16mf4_t shift,size_t vl) +{ + return __riscv_vnsra_wv_i16mf4_tumu(mask,merge,op1,shift,31); +} + + +vint16mf2_t test___riscv_vnsra_wv_i16mf2_tumu(vbool32_t mask,vint16mf2_t merge,vint32m1_t op1,vuint16mf2_t shift,size_t vl) +{ + return __riscv_vnsra_wv_i16mf2_tumu(mask,merge,op1,shift,31); +} + + +vint16m1_t test___riscv_vnsra_wv_i16m1_tumu(vbool16_t mask,vint16m1_t merge,vint32m2_t op1,vuint16m1_t shift,size_t vl) +{ + return __riscv_vnsra_wv_i16m1_tumu(mask,merge,op1,shift,31); +} + + +vint16m2_t test___riscv_vnsra_wv_i16m2_tumu(vbool8_t mask,vint16m2_t merge,vint32m4_t op1,vuint16m2_t shift,size_t vl) +{ + return __riscv_vnsra_wv_i16m2_tumu(mask,merge,op1,shift,31); +} + + +vint16m4_t test___riscv_vnsra_wv_i16m4_tumu(vbool4_t mask,vint16m4_t merge,vint32m8_t op1,vuint16m4_t shift,size_t vl) +{ + return __riscv_vnsra_wv_i16m4_tumu(mask,merge,op1,shift,31); +} + + +vint32mf2_t test___riscv_vnsra_wv_i32mf2_tumu(vbool64_t mask,vint32mf2_t merge,vint64m1_t op1,vuint32mf2_t shift,size_t vl) +{ + return __riscv_vnsra_wv_i32mf2_tumu(mask,merge,op1,shift,31); +} + + +vint32m1_t test___riscv_vnsra_wv_i32m1_tumu(vbool32_t mask,vint32m1_t merge,vint64m2_t op1,vuint32m1_t shift,size_t vl) +{ + return __riscv_vnsra_wv_i32m1_tumu(mask,merge,op1,shift,31); +} + + +vint32m2_t test___riscv_vnsra_wv_i32m2_tumu(vbool16_t mask,vint32m2_t merge,vint64m4_t op1,vuint32m2_t shift,size_t vl) +{ + return __riscv_vnsra_wv_i32m2_tumu(mask,merge,op1,shift,31); +} + + +vint32m4_t test___riscv_vnsra_wv_i32m4_tumu(vbool8_t mask,vint32m4_t merge,vint64m8_t op1,vuint32m4_t shift,size_t vl) +{ + return __riscv_vnsra_wv_i32m4_tumu(mask,merge,op1,shift,31); +} + + + +/* { dg-final { scan-assembler-times {vsetivli\s+zero,\s*31,\s*e8,\s*mf8,\s*tu,\s*mu\s+vnsra\.wv\s+v[0-9]+,\s*v[0-9]+,\s*v[0-9]+,\s*v0.t} 1 } } */ +/* { dg-final { scan-assembler-times {vsetivli\s+zero,\s*31,\s*e8,\s*mf4,\s*tu,\s*mu\s+vnsra\.wv\s+v[0-9]+,\s*v[0-9]+,\s*v[0-9]+,\s*v0.t} 1 } } */ +/* { dg-final { scan-assembler-times {vsetivli\s+zero,\s*31,\s*e8,\s*mf2,\s*tu,\s*mu\s+vnsra\.wv\s+v[0-9]+,\s*v[0-9]+,\s*v[0-9]+,\s*v0.t} 1 } } */ +/* { dg-final { scan-assembler-times {vsetivli\s+zero,\s*31,\s*e8,\s*m1,\s*tu,\s*mu\s+vnsra\.wv\s+v[0-9]+,\s*v[0-9]+,\s*v[0-9]+,\s*v0.t} 1 } } */ +/* { dg-final { scan-assembler-times {vsetivli\s+zero,\s*31,\s*e8,\s*m2,\s*tu,\s*mu\s+vnsra\.wv\s+v[0-9]+,\s*v[0-9]+,\s*v[0-9]+,\s*v0.t} 1 } } */ +/* { dg-final { scan-assembler-times {vsetivli\s+zero,\s*31,\s*e8,\s*m4,\s*tu,\s*mu\s+vnsra\.wv\s+v[0-9]+,\s*v[0-9]+,\s*v[0-9]+,\s*v0.t} 1 } } */ +/* { dg-final { scan-assembler-times {vsetivli\s+zero,\s*31,\s*e16,\s*mf4,\s*tu,\s*mu\s+vnsra\.wv\s+v[0-9]+,\s*v[0-9]+,\s*v[0-9]+,\s*v0.t} 1 } } */ +/* { dg-final { scan-assembler-times {vsetivli\s+zero,\s*31,\s*e16,\s*mf2,\s*tu,\s*mu\s+vnsra\.wv\s+v[0-9]+,\s*v[0-9]+,\s*v[0-9]+,\s*v0.t} 1 } } */ +/* { dg-final { scan-assembler-times {vsetivli\s+zero,\s*31,\s*e16,\s*m1,\s*tu,\s*mu\s+vnsra\.wv\s+v[0-9]+,\s*v[0-9]+,\s*v[0-9]+,\s*v0.t} 1 } } */ +/* { dg-final { scan-assembler-times {vsetivli\s+zero,\s*31,\s*e16,\s*m2,\s*tu,\s*mu\s+vnsra\.wv\s+v[0-9]+,\s*v[0-9]+,\s*v[0-9]+,\s*v0.t} 1 } } */ +/* { dg-final { scan-assembler-times {vsetivli\s+zero,\s*31,\s*e16,\s*m4,\s*tu,\s*mu\s+vnsra\.wv\s+v[0-9]+,\s*v[0-9]+,\s*v[0-9]+,\s*v0.t} 1 } } */ +/* { dg-final { scan-assembler-times {vsetivli\s+zero,\s*31,\s*e32,\s*mf2,\s*tu,\s*mu\s+vnsra\.wv\s+v[0-9]+,\s*v[0-9]+,\s*v[0-9]+,\s*v0.t} 1 } } */ +/* { dg-final { scan-assembler-times {vsetivli\s+zero,\s*31,\s*e32,\s*m1,\s*tu,\s*mu\s+vnsra\.wv\s+v[0-9]+,\s*v[0-9]+,\s*v[0-9]+,\s*v0.t} 1 } } */ +/* { dg-final { scan-assembler-times {vsetivli\s+zero,\s*31,\s*e32,\s*m2,\s*tu,\s*mu\s+vnsra\.wv\s+v[0-9]+,\s*v[0-9]+,\s*v[0-9]+,\s*v0.t} 1 } } */ +/* { dg-final { scan-assembler-times {vsetivli\s+zero,\s*31,\s*e32,\s*m4,\s*tu,\s*mu\s+vnsra\.wv\s+v[0-9]+,\s*v[0-9]+,\s*v[0-9]+,\s*v0.t} 1 } } */ diff --git a/gcc/testsuite/gcc.target/riscv/rvv/base/vnsra_wv_tumu-3.c b/gcc/testsuite/gcc.target/riscv/rvv/base/vnsra_wv_tumu-3.c new file mode 100644 index 00000000000..2805fa3edab --- /dev/null +++ b/gcc/testsuite/gcc.target/riscv/rvv/base/vnsra_wv_tumu-3.c @@ -0,0 +1,111 @@ +/* { dg-do compile } */ +/* { dg-options "-march=rv64gcv -mabi=lp64d -O3 -fno-schedule-insns -fno-schedule-insns2" } */ + +#include "riscv_vector.h" + +vint8mf8_t test___riscv_vnsra_wv_i8mf8_tumu(vbool64_t mask,vint8mf8_t merge,vint16mf4_t op1,vuint8mf8_t shift,size_t vl) +{ + return __riscv_vnsra_wv_i8mf8_tumu(mask,merge,op1,shift,32); +} + + +vint8mf4_t test___riscv_vnsra_wv_i8mf4_tumu(vbool32_t mask,vint8mf4_t merge,vint16mf2_t op1,vuint8mf4_t shift,size_t vl) +{ + return __riscv_vnsra_wv_i8mf4_tumu(mask,merge,op1,shift,32); +} + + +vint8mf2_t test___riscv_vnsra_wv_i8mf2_tumu(vbool16_t mask,vint8mf2_t merge,vint16m1_t op1,vuint8mf2_t shift,size_t vl) +{ + return __riscv_vnsra_wv_i8mf2_tumu(mask,merge,op1,shift,32); +} + + +vint8m1_t test___riscv_vnsra_wv_i8m1_tumu(vbool8_t mask,vint8m1_t merge,vint16m2_t op1,vuint8m1_t shift,size_t vl) +{ + return __riscv_vnsra_wv_i8m1_tumu(mask,merge,op1,shift,32); +} + + +vint8m2_t test___riscv_vnsra_wv_i8m2_tumu(vbool4_t mask,vint8m2_t merge,vint16m4_t op1,vuint8m2_t shift,size_t vl) +{ + return __riscv_vnsra_wv_i8m2_tumu(mask,merge,op1,shift,32); +} + + +vint8m4_t test___riscv_vnsra_wv_i8m4_tumu(vbool2_t mask,vint8m4_t merge,vint16m8_t op1,vuint8m4_t shift,size_t vl) +{ + return __riscv_vnsra_wv_i8m4_tumu(mask,merge,op1,shift,32); +} + + +vint16mf4_t test___riscv_vnsra_wv_i16mf4_tumu(vbool64_t mask,vint16mf4_t merge,vint32mf2_t op1,vuint16mf4_t shift,size_t vl) +{ + return __riscv_vnsra_wv_i16mf4_tumu(mask,merge,op1,shift,32); +} + + +vint16mf2_t test___riscv_vnsra_wv_i16mf2_tumu(vbool32_t mask,vint16mf2_t merge,vint32m1_t op1,vuint16mf2_t shift,size_t vl) +{ + return __riscv_vnsra_wv_i16mf2_tumu(mask,merge,op1,shift,32); +} + + +vint16m1_t test___riscv_vnsra_wv_i16m1_tumu(vbool16_t mask,vint16m1_t merge,vint32m2_t op1,vuint16m1_t shift,size_t vl) +{ + return __riscv_vnsra_wv_i16m1_tumu(mask,merge,op1,shift,32); +} + + +vint16m2_t test___riscv_vnsra_wv_i16m2_tumu(vbool8_t mask,vint16m2_t merge,vint32m4_t op1,vuint16m2_t shift,size_t vl) +{ + return __riscv_vnsra_wv_i16m2_tumu(mask,merge,op1,shift,32); +} + + +vint16m4_t test___riscv_vnsra_wv_i16m4_tumu(vbool4_t mask,vint16m4_t merge,vint32m8_t op1,vuint16m4_t shift,size_t vl) +{ + return __riscv_vnsra_wv_i16m4_tumu(mask,merge,op1,shift,32); +} + + +vint32mf2_t test___riscv_vnsra_wv_i32mf2_tumu(vbool64_t mask,vint32mf2_t merge,vint64m1_t op1,vuint32mf2_t shift,size_t vl) +{ + return __riscv_vnsra_wv_i32mf2_tumu(mask,merge,op1,shift,32); +} + + +vint32m1_t test___riscv_vnsra_wv_i32m1_tumu(vbool32_t mask,vint32m1_t merge,vint64m2_t op1,vuint32m1_t shift,size_t vl) +{ + return __riscv_vnsra_wv_i32m1_tumu(mask,merge,op1,shift,32); +} + + +vint32m2_t test___riscv_vnsra_wv_i32m2_tumu(vbool16_t mask,vint32m2_t merge,vint64m4_t op1,vuint32m2_t shift,size_t vl) +{ + return __riscv_vnsra_wv_i32m2_tumu(mask,merge,op1,shift,32); +} + + +vint32m4_t test___riscv_vnsra_wv_i32m4_tumu(vbool8_t mask,vint32m4_t merge,vint64m8_t op1,vuint32m4_t shift,size_t vl) +{ + return __riscv_vnsra_wv_i32m4_tumu(mask,merge,op1,shift,32); +} + + + +/* { dg-final { scan-assembler-times {vsetvli\s+zero,\s*[a-x0-9]+,\s*e8,\s*mf8,\s*tu,\s*mu\s+vnsra\.wv\s+v[0-9]+,\s*v[0-9]+,\s*v[0-9]+,\s*v0.t} 1 } } */ +/* { dg-final { scan-assembler-times {vsetvli\s+zero,\s*[a-x0-9]+,\s*e8,\s*mf4,\s*tu,\s*mu\s+vnsra\.wv\s+v[0-9]+,\s*v[0-9]+,\s*v[0-9]+,\s*v0.t} 1 } } */ +/* { dg-final { scan-assembler-times {vsetvli\s+zero,\s*[a-x0-9]+,\s*e8,\s*mf2,\s*tu,\s*mu\s+vnsra\.wv\s+v[0-9]+,\s*v[0-9]+,\s*v[0-9]+,\s*v0.t} 1 } } */ +/* { dg-final { scan-assembler-times {vsetvli\s+zero,\s*[a-x0-9]+,\s*e8,\s*m1,\s*tu,\s*mu\s+vnsra\.wv\s+v[0-9]+,\s*v[0-9]+,\s*v[0-9]+,\s*v0.t} 1 } } */ +/* { dg-final { scan-assembler-times {vsetvli\s+zero,\s*[a-x0-9]+,\s*e8,\s*m2,\s*tu,\s*mu\s+vnsra\.wv\s+v[0-9]+,\s*v[0-9]+,\s*v[0-9]+,\s*v0.t} 1 } } */ +/* { dg-final { scan-assembler-times {vsetvli\s+zero,\s*[a-x0-9]+,\s*e8,\s*m4,\s*tu,\s*mu\s+vnsra\.wv\s+v[0-9]+,\s*v[0-9]+,\s*v[0-9]+,\s*v0.t} 1 } } */ +/* { dg-final { scan-assembler-times {vsetvli\s+zero,\s*[a-x0-9]+,\s*e16,\s*mf4,\s*tu,\s*mu\s+vnsra\.wv\s+v[0-9]+,\s*v[0-9]+,\s*v[0-9]+,\s*v0.t} 1 } } */ +/* { dg-final { scan-assembler-times {vsetvli\s+zero,\s*[a-x0-9]+,\s*e16,\s*mf2,\s*tu,\s*mu\s+vnsra\.wv\s+v[0-9]+,\s*v[0-9]+,\s*v[0-9]+,\s*v0.t} 1 } } */ +/* { dg-final { scan-assembler-times {vsetvli\s+zero,\s*[a-x0-9]+,\s*e16,\s*m1,\s*tu,\s*mu\s+vnsra\.wv\s+v[0-9]+,\s*v[0-9]+,\s*v[0-9]+,\s*v0.t} 1 } } */ +/* { dg-final { scan-assembler-times {vsetvli\s+zero,\s*[a-x0-9]+,\s*e16,\s*m2,\s*tu,\s*mu\s+vnsra\.wv\s+v[0-9]+,\s*v[0-9]+,\s*v[0-9]+,\s*v0.t} 1 } } */ +/* { dg-final { scan-assembler-times {vsetvli\s+zero,\s*[a-x0-9]+,\s*e16,\s*m4,\s*tu,\s*mu\s+vnsra\.wv\s+v[0-9]+,\s*v[0-9]+,\s*v[0-9]+,\s*v0.t} 1 } } */ +/* { dg-final { scan-assembler-times {vsetvli\s+zero,\s*[a-x0-9]+,\s*e32,\s*mf2,\s*tu,\s*mu\s+vnsra\.wv\s+v[0-9]+,\s*v[0-9]+,\s*v[0-9]+,\s*v0.t} 1 } } */ +/* { dg-final { scan-assembler-times {vsetvli\s+zero,\s*[a-x0-9]+,\s*e32,\s*m1,\s*tu,\s*mu\s+vnsra\.wv\s+v[0-9]+,\s*v[0-9]+,\s*v[0-9]+,\s*v0.t} 1 } } */ +/* { dg-final { scan-assembler-times {vsetvli\s+zero,\s*[a-x0-9]+,\s*e32,\s*m2,\s*tu,\s*mu\s+vnsra\.wv\s+v[0-9]+,\s*v[0-9]+,\s*v[0-9]+,\s*v0.t} 1 } } */ +/* { dg-final { scan-assembler-times {vsetvli\s+zero,\s*[a-x0-9]+,\s*e32,\s*m4,\s*tu,\s*mu\s+vnsra\.wv\s+v[0-9]+,\s*v[0-9]+,\s*v[0-9]+,\s*v0.t} 1 } } */ diff --git a/gcc/testsuite/gcc.target/riscv/rvv/base/vnsra_wx-1.c b/gcc/testsuite/gcc.target/riscv/rvv/base/vnsra_wx-1.c new file mode 100644 index 00000000000..9d73d3ca177 --- /dev/null +++ b/gcc/testsuite/gcc.target/riscv/rvv/base/vnsra_wx-1.c @@ -0,0 +1,111 @@ +/* { dg-do compile } */ +/* { dg-options "-march=rv64gcv -mabi=lp64d -O3 -fno-schedule-insns -fno-schedule-insns2" } */ + +#include "riscv_vector.h" + +vint8mf8_t test___riscv_vnsra_wx_i8mf8(vint16mf4_t op1,size_t shift,size_t vl) +{ + return __riscv_vnsra_wx_i8mf8(op1,shift,vl); +} + + +vint8mf4_t test___riscv_vnsra_wx_i8mf4(vint16mf2_t op1,size_t shift,size_t vl) +{ + return __riscv_vnsra_wx_i8mf4(op1,shift,vl); +} + + +vint8mf2_t test___riscv_vnsra_wx_i8mf2(vint16m1_t op1,size_t shift,size_t vl) +{ + return __riscv_vnsra_wx_i8mf2(op1,shift,vl); +} + + +vint8m1_t test___riscv_vnsra_wx_i8m1(vint16m2_t op1,size_t shift,size_t vl) +{ + return __riscv_vnsra_wx_i8m1(op1,shift,vl); +} + + +vint8m2_t test___riscv_vnsra_wx_i8m2(vint16m4_t op1,size_t shift,size_t vl) +{ + return __riscv_vnsra_wx_i8m2(op1,shift,vl); +} + + +vint8m4_t test___riscv_vnsra_wx_i8m4(vint16m8_t op1,size_t shift,size_t vl) +{ + return __riscv_vnsra_wx_i8m4(op1,shift,vl); +} + + +vint16mf4_t test___riscv_vnsra_wx_i16mf4(vint32mf2_t op1,size_t shift,size_t vl) +{ + return __riscv_vnsra_wx_i16mf4(op1,shift,vl); +} + + +vint16mf2_t test___riscv_vnsra_wx_i16mf2(vint32m1_t op1,size_t shift,size_t vl) +{ + return __riscv_vnsra_wx_i16mf2(op1,shift,vl); +} + + +vint16m1_t test___riscv_vnsra_wx_i16m1(vint32m2_t op1,size_t shift,size_t vl) +{ + return __riscv_vnsra_wx_i16m1(op1,shift,vl); +} + + +vint16m2_t test___riscv_vnsra_wx_i16m2(vint32m4_t op1,size_t shift,size_t vl) +{ + return __riscv_vnsra_wx_i16m2(op1,shift,vl); +} + + +vint16m4_t test___riscv_vnsra_wx_i16m4(vint32m8_t op1,size_t shift,size_t vl) +{ + return __riscv_vnsra_wx_i16m4(op1,shift,vl); +} + + +vint32mf2_t test___riscv_vnsra_wx_i32mf2(vint64m1_t op1,size_t shift,size_t vl) +{ + return __riscv_vnsra_wx_i32mf2(op1,shift,vl); +} + + +vint32m1_t test___riscv_vnsra_wx_i32m1(vint64m2_t op1,size_t shift,size_t vl) +{ + return __riscv_vnsra_wx_i32m1(op1,shift,vl); +} + + +vint32m2_t test___riscv_vnsra_wx_i32m2(vint64m4_t op1,size_t shift,size_t vl) +{ + return __riscv_vnsra_wx_i32m2(op1,shift,vl); +} + + +vint32m4_t test___riscv_vnsra_wx_i32m4(vint64m8_t op1,size_t shift,size_t vl) +{ + return __riscv_vnsra_wx_i32m4(op1,shift,vl); +} + + + +/* { dg-final { scan-assembler-times {vsetvli\s+zero,\s*[a-x0-9]+,\s*e8,\s*mf8,\s*t[au],\s*m[au]\s+vnsra\.wx\s+v[0-9]+,\s*v[0-9]+,\s*[a-x0-9]+} 1 } } */ +/* { dg-final { scan-assembler-times {vsetvli\s+zero,\s*[a-x0-9]+,\s*e8,\s*mf4,\s*t[au],\s*m[au]\s+vnsra\.wx\s+v[0-9]+,\s*v[0-9]+,\s*[a-x0-9]+} 1 } } */ +/* { dg-final { scan-assembler-times {vsetvli\s+zero,\s*[a-x0-9]+,\s*e8,\s*mf2,\s*t[au],\s*m[au]\s+vnsra\.wx\s+v[0-9]+,\s*v[0-9]+,\s*[a-x0-9]+} 1 } } */ +/* { dg-final { scan-assembler-times {vsetvli\s+zero,\s*[a-x0-9]+,\s*e8,\s*m1,\s*t[au],\s*m[au]\s+vnsra\.wx\s+v[0-9]+,\s*v[0-9]+,\s*[a-x0-9]+} 1 } } */ +/* { dg-final { scan-assembler-times {vsetvli\s+zero,\s*[a-x0-9]+,\s*e8,\s*m2,\s*t[au],\s*m[au]\s+vnsra\.wx\s+v[0-9]+,\s*v[0-9]+,\s*[a-x0-9]+} 1 } } */ +/* { dg-final { scan-assembler-times {vsetvli\s+zero,\s*[a-x0-9]+,\s*e8,\s*m4,\s*t[au],\s*m[au]\s+vnsra\.wx\s+v[0-9]+,\s*v[0-9]+,\s*[a-x0-9]+} 1 } } */ +/* { dg-final { scan-assembler-times {vsetvli\s+zero,\s*[a-x0-9]+,\s*e16,\s*mf4,\s*t[au],\s*m[au]\s+vnsra\.wx\s+v[0-9]+,\s*v[0-9]+,\s*[a-x0-9]+} 1 } } */ +/* { dg-final { scan-assembler-times {vsetvli\s+zero,\s*[a-x0-9]+,\s*e16,\s*mf2,\s*t[au],\s*m[au]\s+vnsra\.wx\s+v[0-9]+,\s*v[0-9]+,\s*[a-x0-9]+} 1 } } */ +/* { dg-final { scan-assembler-times {vsetvli\s+zero,\s*[a-x0-9]+,\s*e16,\s*m1,\s*t[au],\s*m[au]\s+vnsra\.wx\s+v[0-9]+,\s*v[0-9]+,\s*[a-x0-9]+} 1 } } */ +/* { dg-final { scan-assembler-times {vsetvli\s+zero,\s*[a-x0-9]+,\s*e16,\s*m2,\s*t[au],\s*m[au]\s+vnsra\.wx\s+v[0-9]+,\s*v[0-9]+,\s*[a-x0-9]+} 1 } } */ +/* { dg-final { scan-assembler-times {vsetvli\s+zero,\s*[a-x0-9]+,\s*e16,\s*m4,\s*t[au],\s*m[au]\s+vnsra\.wx\s+v[0-9]+,\s*v[0-9]+,\s*[a-x0-9]+} 1 } } */ +/* { dg-final { scan-assembler-times {vsetvli\s+zero,\s*[a-x0-9]+,\s*e32,\s*mf2,\s*t[au],\s*m[au]\s+vnsra\.wx\s+v[0-9]+,\s*v[0-9]+,\s*[a-x0-9]+} 1 } } */ +/* { dg-final { scan-assembler-times {vsetvli\s+zero,\s*[a-x0-9]+,\s*e32,\s*m1,\s*t[au],\s*m[au]\s+vnsra\.wx\s+v[0-9]+,\s*v[0-9]+,\s*[a-x0-9]+} 1 } } */ +/* { dg-final { scan-assembler-times {vsetvli\s+zero,\s*[a-x0-9]+,\s*e32,\s*m2,\s*t[au],\s*m[au]\s+vnsra\.wx\s+v[0-9]+,\s*v[0-9]+,\s*[a-x0-9]+} 1 } } */ +/* { dg-final { scan-assembler-times {vsetvli\s+zero,\s*[a-x0-9]+,\s*e32,\s*m4,\s*t[au],\s*m[au]\s+vnsra\.wx\s+v[0-9]+,\s*v[0-9]+,\s*[a-x0-9]+} 1 } } */ diff --git a/gcc/testsuite/gcc.target/riscv/rvv/base/vnsra_wx-2.c b/gcc/testsuite/gcc.target/riscv/rvv/base/vnsra_wx-2.c new file mode 100644 index 00000000000..a6427748146 --- /dev/null +++ b/gcc/testsuite/gcc.target/riscv/rvv/base/vnsra_wx-2.c @@ -0,0 +1,111 @@ +/* { dg-do compile } */ +/* { dg-options "-march=rv64gcv -mabi=lp64d -O3 -fno-schedule-insns -fno-schedule-insns2" } */ + +#include "riscv_vector.h" + +vint8mf8_t test___riscv_vnsra_wx_i8mf8(vint16mf4_t op1,size_t shift,size_t vl) +{ + return __riscv_vnsra_wx_i8mf8(op1,shift,31); +} + + +vint8mf4_t test___riscv_vnsra_wx_i8mf4(vint16mf2_t op1,size_t shift,size_t vl) +{ + return __riscv_vnsra_wx_i8mf4(op1,shift,31); +} + + +vint8mf2_t test___riscv_vnsra_wx_i8mf2(vint16m1_t op1,size_t shift,size_t vl) +{ + return __riscv_vnsra_wx_i8mf2(op1,shift,31); +} + + +vint8m1_t test___riscv_vnsra_wx_i8m1(vint16m2_t op1,size_t shift,size_t vl) +{ + return __riscv_vnsra_wx_i8m1(op1,shift,31); +} + + +vint8m2_t test___riscv_vnsra_wx_i8m2(vint16m4_t op1,size_t shift,size_t vl) +{ + return __riscv_vnsra_wx_i8m2(op1,shift,31); +} + + +vint8m4_t test___riscv_vnsra_wx_i8m4(vint16m8_t op1,size_t shift,size_t vl) +{ + return __riscv_vnsra_wx_i8m4(op1,shift,31); +} + + +vint16mf4_t test___riscv_vnsra_wx_i16mf4(vint32mf2_t op1,size_t shift,size_t vl) +{ + return __riscv_vnsra_wx_i16mf4(op1,shift,31); +} + + +vint16mf2_t test___riscv_vnsra_wx_i16mf2(vint32m1_t op1,size_t shift,size_t vl) +{ + return __riscv_vnsra_wx_i16mf2(op1,shift,31); +} + + +vint16m1_t test___riscv_vnsra_wx_i16m1(vint32m2_t op1,size_t shift,size_t vl) +{ + return __riscv_vnsra_wx_i16m1(op1,shift,31); +} + + +vint16m2_t test___riscv_vnsra_wx_i16m2(vint32m4_t op1,size_t shift,size_t vl) +{ + return __riscv_vnsra_wx_i16m2(op1,shift,31); +} + + +vint16m4_t test___riscv_vnsra_wx_i16m4(vint32m8_t op1,size_t shift,size_t vl) +{ + return __riscv_vnsra_wx_i16m4(op1,shift,31); +} + + +vint32mf2_t test___riscv_vnsra_wx_i32mf2(vint64m1_t op1,size_t shift,size_t vl) +{ + return __riscv_vnsra_wx_i32mf2(op1,shift,31); +} + + +vint32m1_t test___riscv_vnsra_wx_i32m1(vint64m2_t op1,size_t shift,size_t vl) +{ + return __riscv_vnsra_wx_i32m1(op1,shift,31); +} + + +vint32m2_t test___riscv_vnsra_wx_i32m2(vint64m4_t op1,size_t shift,size_t vl) +{ + return __riscv_vnsra_wx_i32m2(op1,shift,31); +} + + +vint32m4_t test___riscv_vnsra_wx_i32m4(vint64m8_t op1,size_t shift,size_t vl) +{ + return __riscv_vnsra_wx_i32m4(op1,shift,31); +} + + + +/* { dg-final { scan-assembler-times {vsetivli\s+zero,\s*31,\s*e8,\s*mf8,\s*t[au],\s*m[au]\s+vnsra\.wx\s+v[0-9]+,\s*v[0-9]+,\s*[a-x0-9]+} 1 } } */ +/* { dg-final { scan-assembler-times {vsetivli\s+zero,\s*31,\s*e8,\s*mf4,\s*t[au],\s*m[au]\s+vnsra\.wx\s+v[0-9]+,\s*v[0-9]+,\s*[a-x0-9]+} 1 } } */ +/* { dg-final { scan-assembler-times {vsetivli\s+zero,\s*31,\s*e8,\s*mf2,\s*t[au],\s*m[au]\s+vnsra\.wx\s+v[0-9]+,\s*v[0-9]+,\s*[a-x0-9]+} 1 } } */ +/* { dg-final { scan-assembler-times {vsetivli\s+zero,\s*31,\s*e8,\s*m1,\s*t[au],\s*m[au]\s+vnsra\.wx\s+v[0-9]+,\s*v[0-9]+,\s*[a-x0-9]+} 1 } } */ +/* { dg-final { scan-assembler-times {vsetivli\s+zero,\s*31,\s*e8,\s*m2,\s*t[au],\s*m[au]\s+vnsra\.wx\s+v[0-9]+,\s*v[0-9]+,\s*[a-x0-9]+} 1 } } */ +/* { dg-final { scan-assembler-times {vsetivli\s+zero,\s*31,\s*e8,\s*m4,\s*t[au],\s*m[au]\s+vnsra\.wx\s+v[0-9]+,\s*v[0-9]+,\s*[a-x0-9]+} 1 } } */ +/* { dg-final { scan-assembler-times {vsetivli\s+zero,\s*31,\s*e16,\s*mf4,\s*t[au],\s*m[au]\s+vnsra\.wx\s+v[0-9]+,\s*v[0-9]+,\s*[a-x0-9]+} 1 } } */ +/* { dg-final { scan-assembler-times {vsetivli\s+zero,\s*31,\s*e16,\s*mf2,\s*t[au],\s*m[au]\s+vnsra\.wx\s+v[0-9]+,\s*v[0-9]+,\s*[a-x0-9]+} 1 } } */ +/* { dg-final { scan-assembler-times {vsetivli\s+zero,\s*31,\s*e16,\s*m1,\s*t[au],\s*m[au]\s+vnsra\.wx\s+v[0-9]+,\s*v[0-9]+,\s*[a-x0-9]+} 1 } } */ +/* { dg-final { scan-assembler-times {vsetivli\s+zero,\s*31,\s*e16,\s*m2,\s*t[au],\s*m[au]\s+vnsra\.wx\s+v[0-9]+,\s*v[0-9]+,\s*[a-x0-9]+} 1 } } */ +/* { dg-final { scan-assembler-times {vsetivli\s+zero,\s*31,\s*e16,\s*m4,\s*t[au],\s*m[au]\s+vnsra\.wx\s+v[0-9]+,\s*v[0-9]+,\s*[a-x0-9]+} 1 } } */ +/* { dg-final { scan-assembler-times {vsetivli\s+zero,\s*31,\s*e32,\s*mf2,\s*t[au],\s*m[au]\s+vnsra\.wx\s+v[0-9]+,\s*v[0-9]+,\s*[a-x0-9]+} 1 } } */ +/* { dg-final { scan-assembler-times {vsetivli\s+zero,\s*31,\s*e32,\s*m1,\s*t[au],\s*m[au]\s+vnsra\.wx\s+v[0-9]+,\s*v[0-9]+,\s*[a-x0-9]+} 1 } } */ +/* { dg-final { scan-assembler-times {vsetivli\s+zero,\s*31,\s*e32,\s*m2,\s*t[au],\s*m[au]\s+vnsra\.wx\s+v[0-9]+,\s*v[0-9]+,\s*[a-x0-9]+} 1 } } */ +/* { dg-final { scan-assembler-times {vsetivli\s+zero,\s*31,\s*e32,\s*m4,\s*t[au],\s*m[au]\s+vnsra\.wx\s+v[0-9]+,\s*v[0-9]+,\s*[a-x0-9]+} 1 } } */ diff --git a/gcc/testsuite/gcc.target/riscv/rvv/base/vnsra_wx-3.c b/gcc/testsuite/gcc.target/riscv/rvv/base/vnsra_wx-3.c new file mode 100644 index 00000000000..6a136972095 --- /dev/null +++ b/gcc/testsuite/gcc.target/riscv/rvv/base/vnsra_wx-3.c @@ -0,0 +1,111 @@ +/* { dg-do compile } */ +/* { dg-options "-march=rv64gcv -mabi=lp64d -O3 -fno-schedule-insns -fno-schedule-insns2" } */ + +#include "riscv_vector.h" + +vint8mf8_t test___riscv_vnsra_wx_i8mf8(vint16mf4_t op1,size_t shift,size_t vl) +{ + return __riscv_vnsra_wx_i8mf8(op1,shift,32); +} + + +vint8mf4_t test___riscv_vnsra_wx_i8mf4(vint16mf2_t op1,size_t shift,size_t vl) +{ + return __riscv_vnsra_wx_i8mf4(op1,shift,32); +} + + +vint8mf2_t test___riscv_vnsra_wx_i8mf2(vint16m1_t op1,size_t shift,size_t vl) +{ + return __riscv_vnsra_wx_i8mf2(op1,shift,32); +} + + +vint8m1_t test___riscv_vnsra_wx_i8m1(vint16m2_t op1,size_t shift,size_t vl) +{ + return __riscv_vnsra_wx_i8m1(op1,shift,32); +} + + +vint8m2_t test___riscv_vnsra_wx_i8m2(vint16m4_t op1,size_t shift,size_t vl) +{ + return __riscv_vnsra_wx_i8m2(op1,shift,32); +} + + +vint8m4_t test___riscv_vnsra_wx_i8m4(vint16m8_t op1,size_t shift,size_t vl) +{ + return __riscv_vnsra_wx_i8m4(op1,shift,32); +} + + +vint16mf4_t test___riscv_vnsra_wx_i16mf4(vint32mf2_t op1,size_t shift,size_t vl) +{ + return __riscv_vnsra_wx_i16mf4(op1,shift,32); +} + + +vint16mf2_t test___riscv_vnsra_wx_i16mf2(vint32m1_t op1,size_t shift,size_t vl) +{ + return __riscv_vnsra_wx_i16mf2(op1,shift,32); +} + + +vint16m1_t test___riscv_vnsra_wx_i16m1(vint32m2_t op1,size_t shift,size_t vl) +{ + return __riscv_vnsra_wx_i16m1(op1,shift,32); +} + + +vint16m2_t test___riscv_vnsra_wx_i16m2(vint32m4_t op1,size_t shift,size_t vl) +{ + return __riscv_vnsra_wx_i16m2(op1,shift,32); +} + + +vint16m4_t test___riscv_vnsra_wx_i16m4(vint32m8_t op1,size_t shift,size_t vl) +{ + return __riscv_vnsra_wx_i16m4(op1,shift,32); +} + + +vint32mf2_t test___riscv_vnsra_wx_i32mf2(vint64m1_t op1,size_t shift,size_t vl) +{ + return __riscv_vnsra_wx_i32mf2(op1,shift,32); +} + + +vint32m1_t test___riscv_vnsra_wx_i32m1(vint64m2_t op1,size_t shift,size_t vl) +{ + return __riscv_vnsra_wx_i32m1(op1,shift,32); +} + + +vint32m2_t test___riscv_vnsra_wx_i32m2(vint64m4_t op1,size_t shift,size_t vl) +{ + return __riscv_vnsra_wx_i32m2(op1,shift,32); +} + + +vint32m4_t test___riscv_vnsra_wx_i32m4(vint64m8_t op1,size_t shift,size_t vl) +{ + return __riscv_vnsra_wx_i32m4(op1,shift,32); +} + + + +/* { dg-final { scan-assembler-times {vsetvli\s+zero,\s*[a-x0-9]+,\s*e8,\s*mf8,\s*t[au],\s*m[au]\s+vnsra\.wx\s+v[0-9]+,\s*v[0-9]+,\s*[a-x0-9]+} 1 } } */ +/* { dg-final { scan-assembler-times {vsetvli\s+zero,\s*[a-x0-9]+,\s*e8,\s*mf4,\s*t[au],\s*m[au]\s+vnsra\.wx\s+v[0-9]+,\s*v[0-9]+,\s*[a-x0-9]+} 1 } } */ +/* { dg-final { scan-assembler-times {vsetvli\s+zero,\s*[a-x0-9]+,\s*e8,\s*mf2,\s*t[au],\s*m[au]\s+vnsra\.wx\s+v[0-9]+,\s*v[0-9]+,\s*[a-x0-9]+} 1 } } */ +/* { dg-final { scan-assembler-times {vsetvli\s+zero,\s*[a-x0-9]+,\s*e8,\s*m1,\s*t[au],\s*m[au]\s+vnsra\.wx\s+v[0-9]+,\s*v[0-9]+,\s*[a-x0-9]+} 1 } } */ +/* { dg-final { scan-assembler-times {vsetvli\s+zero,\s*[a-x0-9]+,\s*e8,\s*m2,\s*t[au],\s*m[au]\s+vnsra\.wx\s+v[0-9]+,\s*v[0-9]+,\s*[a-x0-9]+} 1 } } */ +/* { dg-final { scan-assembler-times {vsetvli\s+zero,\s*[a-x0-9]+,\s*e8,\s*m4,\s*t[au],\s*m[au]\s+vnsra\.wx\s+v[0-9]+,\s*v[0-9]+,\s*[a-x0-9]+} 1 } } */ +/* { dg-final { scan-assembler-times {vsetvli\s+zero,\s*[a-x0-9]+,\s*e16,\s*mf4,\s*t[au],\s*m[au]\s+vnsra\.wx\s+v[0-9]+,\s*v[0-9]+,\s*[a-x0-9]+} 1 } } */ +/* { dg-final { scan-assembler-times {vsetvli\s+zero,\s*[a-x0-9]+,\s*e16,\s*mf2,\s*t[au],\s*m[au]\s+vnsra\.wx\s+v[0-9]+,\s*v[0-9]+,\s*[a-x0-9]+} 1 } } */ +/* { dg-final { scan-assembler-times {vsetvli\s+zero,\s*[a-x0-9]+,\s*e16,\s*m1,\s*t[au],\s*m[au]\s+vnsra\.wx\s+v[0-9]+,\s*v[0-9]+,\s*[a-x0-9]+} 1 } } */ +/* { dg-final { scan-assembler-times {vsetvli\s+zero,\s*[a-x0-9]+,\s*e16,\s*m2,\s*t[au],\s*m[au]\s+vnsra\.wx\s+v[0-9]+,\s*v[0-9]+,\s*[a-x0-9]+} 1 } } */ +/* { dg-final { scan-assembler-times {vsetvli\s+zero,\s*[a-x0-9]+,\s*e16,\s*m4,\s*t[au],\s*m[au]\s+vnsra\.wx\s+v[0-9]+,\s*v[0-9]+,\s*[a-x0-9]+} 1 } } */ +/* { dg-final { scan-assembler-times {vsetvli\s+zero,\s*[a-x0-9]+,\s*e32,\s*mf2,\s*t[au],\s*m[au]\s+vnsra\.wx\s+v[0-9]+,\s*v[0-9]+,\s*[a-x0-9]+} 1 } } */ +/* { dg-final { scan-assembler-times {vsetvli\s+zero,\s*[a-x0-9]+,\s*e32,\s*m1,\s*t[au],\s*m[au]\s+vnsra\.wx\s+v[0-9]+,\s*v[0-9]+,\s*[a-x0-9]+} 1 } } */ +/* { dg-final { scan-assembler-times {vsetvli\s+zero,\s*[a-x0-9]+,\s*e32,\s*m2,\s*t[au],\s*m[au]\s+vnsra\.wx\s+v[0-9]+,\s*v[0-9]+,\s*[a-x0-9]+} 1 } } */ +/* { dg-final { scan-assembler-times {vsetvli\s+zero,\s*[a-x0-9]+,\s*e32,\s*m4,\s*t[au],\s*m[au]\s+vnsra\.wx\s+v[0-9]+,\s*v[0-9]+,\s*[a-x0-9]+} 1 } } */ diff --git a/gcc/testsuite/gcc.target/riscv/rvv/base/vnsra_wx_m-1.c b/gcc/testsuite/gcc.target/riscv/rvv/base/vnsra_wx_m-1.c new file mode 100644 index 00000000000..a960228bdf7 --- /dev/null +++ b/gcc/testsuite/gcc.target/riscv/rvv/base/vnsra_wx_m-1.c @@ -0,0 +1,111 @@ +/* { dg-do compile } */ +/* { dg-options "-march=rv64gcv -mabi=lp64d -O3 -fno-schedule-insns -fno-schedule-insns2" } */ + +#include "riscv_vector.h" + +vint8mf8_t test___riscv_vnsra_wx_i8mf8_m(vbool64_t mask,vint16mf4_t op1,size_t shift,size_t vl) +{ + return __riscv_vnsra_wx_i8mf8_m(mask,op1,shift,vl); +} + + +vint8mf4_t test___riscv_vnsra_wx_i8mf4_m(vbool32_t mask,vint16mf2_t op1,size_t shift,size_t vl) +{ + return __riscv_vnsra_wx_i8mf4_m(mask,op1,shift,vl); +} + + +vint8mf2_t test___riscv_vnsra_wx_i8mf2_m(vbool16_t mask,vint16m1_t op1,size_t shift,size_t vl) +{ + return __riscv_vnsra_wx_i8mf2_m(mask,op1,shift,vl); +} + + +vint8m1_t test___riscv_vnsra_wx_i8m1_m(vbool8_t mask,vint16m2_t op1,size_t shift,size_t vl) +{ + return __riscv_vnsra_wx_i8m1_m(mask,op1,shift,vl); +} + + +vint8m2_t test___riscv_vnsra_wx_i8m2_m(vbool4_t mask,vint16m4_t op1,size_t shift,size_t vl) +{ + return __riscv_vnsra_wx_i8m2_m(mask,op1,shift,vl); +} + + +vint8m4_t test___riscv_vnsra_wx_i8m4_m(vbool2_t mask,vint16m8_t op1,size_t shift,size_t vl) +{ + return __riscv_vnsra_wx_i8m4_m(mask,op1,shift,vl); +} + + +vint16mf4_t test___riscv_vnsra_wx_i16mf4_m(vbool64_t mask,vint32mf2_t op1,size_t shift,size_t vl) +{ + return __riscv_vnsra_wx_i16mf4_m(mask,op1,shift,vl); +} + + +vint16mf2_t test___riscv_vnsra_wx_i16mf2_m(vbool32_t mask,vint32m1_t op1,size_t shift,size_t vl) +{ + return __riscv_vnsra_wx_i16mf2_m(mask,op1,shift,vl); +} + + +vint16m1_t test___riscv_vnsra_wx_i16m1_m(vbool16_t mask,vint32m2_t op1,size_t shift,size_t vl) +{ + return __riscv_vnsra_wx_i16m1_m(mask,op1,shift,vl); +} + + +vint16m2_t test___riscv_vnsra_wx_i16m2_m(vbool8_t mask,vint32m4_t op1,size_t shift,size_t vl) +{ + return __riscv_vnsra_wx_i16m2_m(mask,op1,shift,vl); +} + + +vint16m4_t test___riscv_vnsra_wx_i16m4_m(vbool4_t mask,vint32m8_t op1,size_t shift,size_t vl) +{ + return __riscv_vnsra_wx_i16m4_m(mask,op1,shift,vl); +} + + +vint32mf2_t test___riscv_vnsra_wx_i32mf2_m(vbool64_t mask,vint64m1_t op1,size_t shift,size_t vl) +{ + return __riscv_vnsra_wx_i32mf2_m(mask,op1,shift,vl); +} + + +vint32m1_t test___riscv_vnsra_wx_i32m1_m(vbool32_t mask,vint64m2_t op1,size_t shift,size_t vl) +{ + return __riscv_vnsra_wx_i32m1_m(mask,op1,shift,vl); +} + + +vint32m2_t test___riscv_vnsra_wx_i32m2_m(vbool16_t mask,vint64m4_t op1,size_t shift,size_t vl) +{ + return __riscv_vnsra_wx_i32m2_m(mask,op1,shift,vl); +} + + +vint32m4_t test___riscv_vnsra_wx_i32m4_m(vbool8_t mask,vint64m8_t op1,size_t shift,size_t vl) +{ + return __riscv_vnsra_wx_i32m4_m(mask,op1,shift,vl); +} + + + +/* { dg-final { scan-assembler-times {vsetvli\s+zero,\s*[a-x0-9]+,\s*e8,\s*mf8,\s*t[au],\s*m[au]\s+vnsra\.wx\s+v[0-9]+,\s*v[0-9]+,\s*[a-x0-9]+,\s*v0.t} 1 } } */ +/* { dg-final { scan-assembler-times {vsetvli\s+zero,\s*[a-x0-9]+,\s*e8,\s*mf4,\s*t[au],\s*m[au]\s+vnsra\.wx\s+v[0-9]+,\s*v[0-9]+,\s*[a-x0-9]+,\s*v0.t} 1 } } */ +/* { dg-final { scan-assembler-times {vsetvli\s+zero,\s*[a-x0-9]+,\s*e8,\s*mf2,\s*t[au],\s*m[au]\s+vnsra\.wx\s+v[0-9]+,\s*v[0-9]+,\s*[a-x0-9]+,\s*v0.t} 1 } } */ +/* { dg-final { scan-assembler-times {vsetvli\s+zero,\s*[a-x0-9]+,\s*e8,\s*m1,\s*t[au],\s*m[au]\s+vnsra\.wx\s+v[0-9]+,\s*v[0-9]+,\s*[a-x0-9]+,\s*v0.t} 1 } } */ +/* { dg-final { scan-assembler-times {vsetvli\s+zero,\s*[a-x0-9]+,\s*e8,\s*m2,\s*t[au],\s*m[au]\s+vnsra\.wx\s+v[0-9]+,\s*v[0-9]+,\s*[a-x0-9]+,\s*v0.t} 1 } } */ +/* { dg-final { scan-assembler-times {vsetvli\s+zero,\s*[a-x0-9]+,\s*e8,\s*m4,\s*t[au],\s*m[au]\s+vnsra\.wx\s+v[0-9]+,\s*v[0-9]+,\s*[a-x0-9]+,\s*v0.t} 1 } } */ +/* { dg-final { scan-assembler-times {vsetvli\s+zero,\s*[a-x0-9]+,\s*e16,\s*mf4,\s*t[au],\s*m[au]\s+vnsra\.wx\s+v[0-9]+,\s*v[0-9]+,\s*[a-x0-9]+,\s*v0.t} 1 } } */ +/* { dg-final { scan-assembler-times {vsetvli\s+zero,\s*[a-x0-9]+,\s*e16,\s*mf2,\s*t[au],\s*m[au]\s+vnsra\.wx\s+v[0-9]+,\s*v[0-9]+,\s*[a-x0-9]+,\s*v0.t} 1 } } */ +/* { dg-final { scan-assembler-times {vsetvli\s+zero,\s*[a-x0-9]+,\s*e16,\s*m1,\s*t[au],\s*m[au]\s+vnsra\.wx\s+v[0-9]+,\s*v[0-9]+,\s*[a-x0-9]+,\s*v0.t} 1 } } */ +/* { dg-final { scan-assembler-times {vsetvli\s+zero,\s*[a-x0-9]+,\s*e16,\s*m2,\s*t[au],\s*m[au]\s+vnsra\.wx\s+v[0-9]+,\s*v[0-9]+,\s*[a-x0-9]+,\s*v0.t} 1 } } */ +/* { dg-final { scan-assembler-times {vsetvli\s+zero,\s*[a-x0-9]+,\s*e16,\s*m4,\s*t[au],\s*m[au]\s+vnsra\.wx\s+v[0-9]+,\s*v[0-9]+,\s*[a-x0-9]+,\s*v0.t} 1 } } */ +/* { dg-final { scan-assembler-times {vsetvli\s+zero,\s*[a-x0-9]+,\s*e32,\s*mf2,\s*t[au],\s*m[au]\s+vnsra\.wx\s+v[0-9]+,\s*v[0-9]+,\s*[a-x0-9]+,\s*v0.t} 1 } } */ +/* { dg-final { scan-assembler-times {vsetvli\s+zero,\s*[a-x0-9]+,\s*e32,\s*m1,\s*t[au],\s*m[au]\s+vnsra\.wx\s+v[0-9]+,\s*v[0-9]+,\s*[a-x0-9]+,\s*v0.t} 1 } } */ +/* { dg-final { scan-assembler-times {vsetvli\s+zero,\s*[a-x0-9]+,\s*e32,\s*m2,\s*t[au],\s*m[au]\s+vnsra\.wx\s+v[0-9]+,\s*v[0-9]+,\s*[a-x0-9]+,\s*v0.t} 1 } } */ +/* { dg-final { scan-assembler-times {vsetvli\s+zero,\s*[a-x0-9]+,\s*e32,\s*m4,\s*t[au],\s*m[au]\s+vnsra\.wx\s+v[0-9]+,\s*v[0-9]+,\s*[a-x0-9]+,\s*v0.t} 1 } } */ diff --git a/gcc/testsuite/gcc.target/riscv/rvv/base/vnsra_wx_m-2.c b/gcc/testsuite/gcc.target/riscv/rvv/base/vnsra_wx_m-2.c new file mode 100644 index 00000000000..64ee422857b --- /dev/null +++ b/gcc/testsuite/gcc.target/riscv/rvv/base/vnsra_wx_m-2.c @@ -0,0 +1,111 @@ +/* { dg-do compile } */ +/* { dg-options "-march=rv64gcv -mabi=lp64d -O3 -fno-schedule-insns -fno-schedule-insns2" } */ + +#include "riscv_vector.h" + +vint8mf8_t test___riscv_vnsra_wx_i8mf8_m(vbool64_t mask,vint16mf4_t op1,size_t shift,size_t vl) +{ + return __riscv_vnsra_wx_i8mf8_m(mask,op1,shift,31); +} + + +vint8mf4_t test___riscv_vnsra_wx_i8mf4_m(vbool32_t mask,vint16mf2_t op1,size_t shift,size_t vl) +{ + return __riscv_vnsra_wx_i8mf4_m(mask,op1,shift,31); +} + + +vint8mf2_t test___riscv_vnsra_wx_i8mf2_m(vbool16_t mask,vint16m1_t op1,size_t shift,size_t vl) +{ + return __riscv_vnsra_wx_i8mf2_m(mask,op1,shift,31); +} + + +vint8m1_t test___riscv_vnsra_wx_i8m1_m(vbool8_t mask,vint16m2_t op1,size_t shift,size_t vl) +{ + return __riscv_vnsra_wx_i8m1_m(mask,op1,shift,31); +} + + +vint8m2_t test___riscv_vnsra_wx_i8m2_m(vbool4_t mask,vint16m4_t op1,size_t shift,size_t vl) +{ + return __riscv_vnsra_wx_i8m2_m(mask,op1,shift,31); +} + + +vint8m4_t test___riscv_vnsra_wx_i8m4_m(vbool2_t mask,vint16m8_t op1,size_t shift,size_t vl) +{ + return __riscv_vnsra_wx_i8m4_m(mask,op1,shift,31); +} + + +vint16mf4_t test___riscv_vnsra_wx_i16mf4_m(vbool64_t mask,vint32mf2_t op1,size_t shift,size_t vl) +{ + return __riscv_vnsra_wx_i16mf4_m(mask,op1,shift,31); +} + + +vint16mf2_t test___riscv_vnsra_wx_i16mf2_m(vbool32_t mask,vint32m1_t op1,size_t shift,size_t vl) +{ + return __riscv_vnsra_wx_i16mf2_m(mask,op1,shift,31); +} + + +vint16m1_t test___riscv_vnsra_wx_i16m1_m(vbool16_t mask,vint32m2_t op1,size_t shift,size_t vl) +{ + return __riscv_vnsra_wx_i16m1_m(mask,op1,shift,31); +} + + +vint16m2_t test___riscv_vnsra_wx_i16m2_m(vbool8_t mask,vint32m4_t op1,size_t shift,size_t vl) +{ + return __riscv_vnsra_wx_i16m2_m(mask,op1,shift,31); +} + + +vint16m4_t test___riscv_vnsra_wx_i16m4_m(vbool4_t mask,vint32m8_t op1,size_t shift,size_t vl) +{ + return __riscv_vnsra_wx_i16m4_m(mask,op1,shift,31); +} + + +vint32mf2_t test___riscv_vnsra_wx_i32mf2_m(vbool64_t mask,vint64m1_t op1,size_t shift,size_t vl) +{ + return __riscv_vnsra_wx_i32mf2_m(mask,op1,shift,31); +} + + +vint32m1_t test___riscv_vnsra_wx_i32m1_m(vbool32_t mask,vint64m2_t op1,size_t shift,size_t vl) +{ + return __riscv_vnsra_wx_i32m1_m(mask,op1,shift,31); +} + + +vint32m2_t test___riscv_vnsra_wx_i32m2_m(vbool16_t mask,vint64m4_t op1,size_t shift,size_t vl) +{ + return __riscv_vnsra_wx_i32m2_m(mask,op1,shift,31); +} + + +vint32m4_t test___riscv_vnsra_wx_i32m4_m(vbool8_t mask,vint64m8_t op1,size_t shift,size_t vl) +{ + return __riscv_vnsra_wx_i32m4_m(mask,op1,shift,31); +} + + + +/* { dg-final { scan-assembler-times {vsetivli\s+zero,\s*31,\s*e8,\s*mf8,\s*t[au],\s*m[au]\s+vnsra\.wx\s+v[0-9]+,\s*v[0-9]+,\s*[a-x0-9]+,\s*v0.t} 1 } } */ +/* { dg-final { scan-assembler-times {vsetivli\s+zero,\s*31,\s*e8,\s*mf4,\s*t[au],\s*m[au]\s+vnsra\.wx\s+v[0-9]+,\s*v[0-9]+,\s*[a-x0-9]+,\s*v0.t} 1 } } */ +/* { dg-final { scan-assembler-times {vsetivli\s+zero,\s*31,\s*e8,\s*mf2,\s*t[au],\s*m[au]\s+vnsra\.wx\s+v[0-9]+,\s*v[0-9]+,\s*[a-x0-9]+,\s*v0.t} 1 } } */ +/* { dg-final { scan-assembler-times {vsetivli\s+zero,\s*31,\s*e8,\s*m1,\s*t[au],\s*m[au]\s+vnsra\.wx\s+v[0-9]+,\s*v[0-9]+,\s*[a-x0-9]+,\s*v0.t} 1 } } */ +/* { dg-final { scan-assembler-times {vsetivli\s+zero,\s*31,\s*e8,\s*m2,\s*t[au],\s*m[au]\s+vnsra\.wx\s+v[0-9]+,\s*v[0-9]+,\s*[a-x0-9]+,\s*v0.t} 1 } } */ +/* { dg-final { scan-assembler-times {vsetivli\s+zero,\s*31,\s*e8,\s*m4,\s*t[au],\s*m[au]\s+vnsra\.wx\s+v[0-9]+,\s*v[0-9]+,\s*[a-x0-9]+,\s*v0.t} 1 } } */ +/* { dg-final { scan-assembler-times {vsetivli\s+zero,\s*31,\s*e16,\s*mf4,\s*t[au],\s*m[au]\s+vnsra\.wx\s+v[0-9]+,\s*v[0-9]+,\s*[a-x0-9]+,\s*v0.t} 1 } } */ +/* { dg-final { scan-assembler-times {vsetivli\s+zero,\s*31,\s*e16,\s*mf2,\s*t[au],\s*m[au]\s+vnsra\.wx\s+v[0-9]+,\s*v[0-9]+,\s*[a-x0-9]+,\s*v0.t} 1 } } */ +/* { dg-final { scan-assembler-times {vsetivli\s+zero,\s*31,\s*e16,\s*m1,\s*t[au],\s*m[au]\s+vnsra\.wx\s+v[0-9]+,\s*v[0-9]+,\s*[a-x0-9]+,\s*v0.t} 1 } } */ +/* { dg-final { scan-assembler-times {vsetivli\s+zero,\s*31,\s*e16,\s*m2,\s*t[au],\s*m[au]\s+vnsra\.wx\s+v[0-9]+,\s*v[0-9]+,\s*[a-x0-9]+,\s*v0.t} 1 } } */ +/* { dg-final { scan-assembler-times {vsetivli\s+zero,\s*31,\s*e16,\s*m4,\s*t[au],\s*m[au]\s+vnsra\.wx\s+v[0-9]+,\s*v[0-9]+,\s*[a-x0-9]+,\s*v0.t} 1 } } */ +/* { dg-final { scan-assembler-times {vsetivli\s+zero,\s*31,\s*e32,\s*mf2,\s*t[au],\s*m[au]\s+vnsra\.wx\s+v[0-9]+,\s*v[0-9]+,\s*[a-x0-9]+,\s*v0.t} 1 } } */ +/* { dg-final { scan-assembler-times {vsetivli\s+zero,\s*31,\s*e32,\s*m1,\s*t[au],\s*m[au]\s+vnsra\.wx\s+v[0-9]+,\s*v[0-9]+,\s*[a-x0-9]+,\s*v0.t} 1 } } */ +/* { dg-final { scan-assembler-times {vsetivli\s+zero,\s*31,\s*e32,\s*m2,\s*t[au],\s*m[au]\s+vnsra\.wx\s+v[0-9]+,\s*v[0-9]+,\s*[a-x0-9]+,\s*v0.t} 1 } } */ +/* { dg-final { scan-assembler-times {vsetivli\s+zero,\s*31,\s*e32,\s*m4,\s*t[au],\s*m[au]\s+vnsra\.wx\s+v[0-9]+,\s*v[0-9]+,\s*[a-x0-9]+,\s*v0.t} 1 } } */ diff --git a/gcc/testsuite/gcc.target/riscv/rvv/base/vnsra_wx_m-3.c b/gcc/testsuite/gcc.target/riscv/rvv/base/vnsra_wx_m-3.c new file mode 100644 index 00000000000..1fb8b431540 --- /dev/null +++ b/gcc/testsuite/gcc.target/riscv/rvv/base/vnsra_wx_m-3.c @@ -0,0 +1,111 @@ +/* { dg-do compile } */ +/* { dg-options "-march=rv64gcv -mabi=lp64d -O3 -fno-schedule-insns -fno-schedule-insns2" } */ + +#include "riscv_vector.h" + +vint8mf8_t test___riscv_vnsra_wx_i8mf8_m(vbool64_t mask,vint16mf4_t op1,size_t shift,size_t vl) +{ + return __riscv_vnsra_wx_i8mf8_m(mask,op1,shift,32); +} + + +vint8mf4_t test___riscv_vnsra_wx_i8mf4_m(vbool32_t mask,vint16mf2_t op1,size_t shift,size_t vl) +{ + return __riscv_vnsra_wx_i8mf4_m(mask,op1,shift,32); +} + + +vint8mf2_t test___riscv_vnsra_wx_i8mf2_m(vbool16_t mask,vint16m1_t op1,size_t shift,size_t vl) +{ + return __riscv_vnsra_wx_i8mf2_m(mask,op1,shift,32); +} + + +vint8m1_t test___riscv_vnsra_wx_i8m1_m(vbool8_t mask,vint16m2_t op1,size_t shift,size_t vl) +{ + return __riscv_vnsra_wx_i8m1_m(mask,op1,shift,32); +} + + +vint8m2_t test___riscv_vnsra_wx_i8m2_m(vbool4_t mask,vint16m4_t op1,size_t shift,size_t vl) +{ + return __riscv_vnsra_wx_i8m2_m(mask,op1,shift,32); +} + + +vint8m4_t test___riscv_vnsra_wx_i8m4_m(vbool2_t mask,vint16m8_t op1,size_t shift,size_t vl) +{ + return __riscv_vnsra_wx_i8m4_m(mask,op1,shift,32); +} + + +vint16mf4_t test___riscv_vnsra_wx_i16mf4_m(vbool64_t mask,vint32mf2_t op1,size_t shift,size_t vl) +{ + return __riscv_vnsra_wx_i16mf4_m(mask,op1,shift,32); +} + + +vint16mf2_t test___riscv_vnsra_wx_i16mf2_m(vbool32_t mask,vint32m1_t op1,size_t shift,size_t vl) +{ + return __riscv_vnsra_wx_i16mf2_m(mask,op1,shift,32); +} + + +vint16m1_t test___riscv_vnsra_wx_i16m1_m(vbool16_t mask,vint32m2_t op1,size_t shift,size_t vl) +{ + return __riscv_vnsra_wx_i16m1_m(mask,op1,shift,32); +} + + +vint16m2_t test___riscv_vnsra_wx_i16m2_m(vbool8_t mask,vint32m4_t op1,size_t shift,size_t vl) +{ + return __riscv_vnsra_wx_i16m2_m(mask,op1,shift,32); +} + + +vint16m4_t test___riscv_vnsra_wx_i16m4_m(vbool4_t mask,vint32m8_t op1,size_t shift,size_t vl) +{ + return __riscv_vnsra_wx_i16m4_m(mask,op1,shift,32); +} + + +vint32mf2_t test___riscv_vnsra_wx_i32mf2_m(vbool64_t mask,vint64m1_t op1,size_t shift,size_t vl) +{ + return __riscv_vnsra_wx_i32mf2_m(mask,op1,shift,32); +} + + +vint32m1_t test___riscv_vnsra_wx_i32m1_m(vbool32_t mask,vint64m2_t op1,size_t shift,size_t vl) +{ + return __riscv_vnsra_wx_i32m1_m(mask,op1,shift,32); +} + + +vint32m2_t test___riscv_vnsra_wx_i32m2_m(vbool16_t mask,vint64m4_t op1,size_t shift,size_t vl) +{ + return __riscv_vnsra_wx_i32m2_m(mask,op1,shift,32); +} + + +vint32m4_t test___riscv_vnsra_wx_i32m4_m(vbool8_t mask,vint64m8_t op1,size_t shift,size_t vl) +{ + return __riscv_vnsra_wx_i32m4_m(mask,op1,shift,32); +} + + + +/* { dg-final { scan-assembler-times {vsetvli\s+zero,\s*[a-x0-9]+,\s*e8,\s*mf8,\s*t[au],\s*m[au]\s+vnsra\.wx\s+v[0-9]+,\s*v[0-9]+,\s*[a-x0-9]+,\s*v0.t} 1 } } */ +/* { dg-final { scan-assembler-times {vsetvli\s+zero,\s*[a-x0-9]+,\s*e8,\s*mf4,\s*t[au],\s*m[au]\s+vnsra\.wx\s+v[0-9]+,\s*v[0-9]+,\s*[a-x0-9]+,\s*v0.t} 1 } } */ +/* { dg-final { scan-assembler-times {vsetvli\s+zero,\s*[a-x0-9]+,\s*e8,\s*mf2,\s*t[au],\s*m[au]\s+vnsra\.wx\s+v[0-9]+,\s*v[0-9]+,\s*[a-x0-9]+,\s*v0.t} 1 } } */ +/* { dg-final { scan-assembler-times {vsetvli\s+zero,\s*[a-x0-9]+,\s*e8,\s*m1,\s*t[au],\s*m[au]\s+vnsra\.wx\s+v[0-9]+,\s*v[0-9]+,\s*[a-x0-9]+,\s*v0.t} 1 } } */ +/* { dg-final { scan-assembler-times {vsetvli\s+zero,\s*[a-x0-9]+,\s*e8,\s*m2,\s*t[au],\s*m[au]\s+vnsra\.wx\s+v[0-9]+,\s*v[0-9]+,\s*[a-x0-9]+,\s*v0.t} 1 } } */ +/* { dg-final { scan-assembler-times {vsetvli\s+zero,\s*[a-x0-9]+,\s*e8,\s*m4,\s*t[au],\s*m[au]\s+vnsra\.wx\s+v[0-9]+,\s*v[0-9]+,\s*[a-x0-9]+,\s*v0.t} 1 } } */ +/* { dg-final { scan-assembler-times {vsetvli\s+zero,\s*[a-x0-9]+,\s*e16,\s*mf4,\s*t[au],\s*m[au]\s+vnsra\.wx\s+v[0-9]+,\s*v[0-9]+,\s*[a-x0-9]+,\s*v0.t} 1 } } */ +/* { dg-final { scan-assembler-times {vsetvli\s+zero,\s*[a-x0-9]+,\s*e16,\s*mf2,\s*t[au],\s*m[au]\s+vnsra\.wx\s+v[0-9]+,\s*v[0-9]+,\s*[a-x0-9]+,\s*v0.t} 1 } } */ +/* { dg-final { scan-assembler-times {vsetvli\s+zero,\s*[a-x0-9]+,\s*e16,\s*m1,\s*t[au],\s*m[au]\s+vnsra\.wx\s+v[0-9]+,\s*v[0-9]+,\s*[a-x0-9]+,\s*v0.t} 1 } } */ +/* { dg-final { scan-assembler-times {vsetvli\s+zero,\s*[a-x0-9]+,\s*e16,\s*m2,\s*t[au],\s*m[au]\s+vnsra\.wx\s+v[0-9]+,\s*v[0-9]+,\s*[a-x0-9]+,\s*v0.t} 1 } } */ +/* { dg-final { scan-assembler-times {vsetvli\s+zero,\s*[a-x0-9]+,\s*e16,\s*m4,\s*t[au],\s*m[au]\s+vnsra\.wx\s+v[0-9]+,\s*v[0-9]+,\s*[a-x0-9]+,\s*v0.t} 1 } } */ +/* { dg-final { scan-assembler-times {vsetvli\s+zero,\s*[a-x0-9]+,\s*e32,\s*mf2,\s*t[au],\s*m[au]\s+vnsra\.wx\s+v[0-9]+,\s*v[0-9]+,\s*[a-x0-9]+,\s*v0.t} 1 } } */ +/* { dg-final { scan-assembler-times {vsetvli\s+zero,\s*[a-x0-9]+,\s*e32,\s*m1,\s*t[au],\s*m[au]\s+vnsra\.wx\s+v[0-9]+,\s*v[0-9]+,\s*[a-x0-9]+,\s*v0.t} 1 } } */ +/* { dg-final { scan-assembler-times {vsetvli\s+zero,\s*[a-x0-9]+,\s*e32,\s*m2,\s*t[au],\s*m[au]\s+vnsra\.wx\s+v[0-9]+,\s*v[0-9]+,\s*[a-x0-9]+,\s*v0.t} 1 } } */ +/* { dg-final { scan-assembler-times {vsetvli\s+zero,\s*[a-x0-9]+,\s*e32,\s*m4,\s*t[au],\s*m[au]\s+vnsra\.wx\s+v[0-9]+,\s*v[0-9]+,\s*[a-x0-9]+,\s*v0.t} 1 } } */ diff --git a/gcc/testsuite/gcc.target/riscv/rvv/base/vnsra_wx_mu-1.c b/gcc/testsuite/gcc.target/riscv/rvv/base/vnsra_wx_mu-1.c new file mode 100644 index 00000000000..4d0a3cb4c1d --- /dev/null +++ b/gcc/testsuite/gcc.target/riscv/rvv/base/vnsra_wx_mu-1.c @@ -0,0 +1,111 @@ +/* { dg-do compile } */ +/* { dg-options "-march=rv64gcv -mabi=lp64d -O3 -fno-schedule-insns -fno-schedule-insns2" } */ + +#include "riscv_vector.h" + +vint8mf8_t test___riscv_vnsra_wx_i8mf8_mu(vbool64_t mask,vint8mf8_t merge,vint16mf4_t op1,size_t shift,size_t vl) +{ + return __riscv_vnsra_wx_i8mf8_mu(mask,merge,op1,shift,vl); +} + + +vint8mf4_t test___riscv_vnsra_wx_i8mf4_mu(vbool32_t mask,vint8mf4_t merge,vint16mf2_t op1,size_t shift,size_t vl) +{ + return __riscv_vnsra_wx_i8mf4_mu(mask,merge,op1,shift,vl); +} + + +vint8mf2_t test___riscv_vnsra_wx_i8mf2_mu(vbool16_t mask,vint8mf2_t merge,vint16m1_t op1,size_t shift,size_t vl) +{ + return __riscv_vnsra_wx_i8mf2_mu(mask,merge,op1,shift,vl); +} + + +vint8m1_t test___riscv_vnsra_wx_i8m1_mu(vbool8_t mask,vint8m1_t merge,vint16m2_t op1,size_t shift,size_t vl) +{ + return __riscv_vnsra_wx_i8m1_mu(mask,merge,op1,shift,vl); +} + + +vint8m2_t test___riscv_vnsra_wx_i8m2_mu(vbool4_t mask,vint8m2_t merge,vint16m4_t op1,size_t shift,size_t vl) +{ + return __riscv_vnsra_wx_i8m2_mu(mask,merge,op1,shift,vl); +} + + +vint8m4_t test___riscv_vnsra_wx_i8m4_mu(vbool2_t mask,vint8m4_t merge,vint16m8_t op1,size_t shift,size_t vl) +{ + return __riscv_vnsra_wx_i8m4_mu(mask,merge,op1,shift,vl); +} + + +vint16mf4_t test___riscv_vnsra_wx_i16mf4_mu(vbool64_t mask,vint16mf4_t merge,vint32mf2_t op1,size_t shift,size_t vl) +{ + return __riscv_vnsra_wx_i16mf4_mu(mask,merge,op1,shift,vl); +} + + +vint16mf2_t test___riscv_vnsra_wx_i16mf2_mu(vbool32_t mask,vint16mf2_t merge,vint32m1_t op1,size_t shift,size_t vl) +{ + return __riscv_vnsra_wx_i16mf2_mu(mask,merge,op1,shift,vl); +} + + +vint16m1_t test___riscv_vnsra_wx_i16m1_mu(vbool16_t mask,vint16m1_t merge,vint32m2_t op1,size_t shift,size_t vl) +{ + return __riscv_vnsra_wx_i16m1_mu(mask,merge,op1,shift,vl); +} + + +vint16m2_t test___riscv_vnsra_wx_i16m2_mu(vbool8_t mask,vint16m2_t merge,vint32m4_t op1,size_t shift,size_t vl) +{ + return __riscv_vnsra_wx_i16m2_mu(mask,merge,op1,shift,vl); +} + + +vint16m4_t test___riscv_vnsra_wx_i16m4_mu(vbool4_t mask,vint16m4_t merge,vint32m8_t op1,size_t shift,size_t vl) +{ + return __riscv_vnsra_wx_i16m4_mu(mask,merge,op1,shift,vl); +} + + +vint32mf2_t test___riscv_vnsra_wx_i32mf2_mu(vbool64_t mask,vint32mf2_t merge,vint64m1_t op1,size_t shift,size_t vl) +{ + return __riscv_vnsra_wx_i32mf2_mu(mask,merge,op1,shift,vl); +} + + +vint32m1_t test___riscv_vnsra_wx_i32m1_mu(vbool32_t mask,vint32m1_t merge,vint64m2_t op1,size_t shift,size_t vl) +{ + return __riscv_vnsra_wx_i32m1_mu(mask,merge,op1,shift,vl); +} + + +vint32m2_t test___riscv_vnsra_wx_i32m2_mu(vbool16_t mask,vint32m2_t merge,vint64m4_t op1,size_t shift,size_t vl) +{ + return __riscv_vnsra_wx_i32m2_mu(mask,merge,op1,shift,vl); +} + + +vint32m4_t test___riscv_vnsra_wx_i32m4_mu(vbool8_t mask,vint32m4_t merge,vint64m8_t op1,size_t shift,size_t vl) +{ + return __riscv_vnsra_wx_i32m4_mu(mask,merge,op1,shift,vl); +} + + + +/* { dg-final { scan-assembler-times {vsetvli\s+zero,\s*[a-x0-9]+,\s*e8,\s*mf8,\s*t[au],\s*mu\s+vnsra\.wx\s+v[0-9]+,\s*v[0-9]+,\s*[a-x0-9]+,\s*v0.t} 1 } } */ +/* { dg-final { scan-assembler-times {vsetvli\s+zero,\s*[a-x0-9]+,\s*e8,\s*mf4,\s*t[au],\s*mu\s+vnsra\.wx\s+v[0-9]+,\s*v[0-9]+,\s*[a-x0-9]+,\s*v0.t} 1 } } */ +/* { dg-final { scan-assembler-times {vsetvli\s+zero,\s*[a-x0-9]+,\s*e8,\s*mf2,\s*t[au],\s*mu\s+vnsra\.wx\s+v[0-9]+,\s*v[0-9]+,\s*[a-x0-9]+,\s*v0.t} 1 } } */ +/* { dg-final { scan-assembler-times {vsetvli\s+zero,\s*[a-x0-9]+,\s*e8,\s*m1,\s*t[au],\s*mu\s+vnsra\.wx\s+v[0-9]+,\s*v[0-9]+,\s*[a-x0-9]+,\s*v0.t} 1 } } */ +/* { dg-final { scan-assembler-times {vsetvli\s+zero,\s*[a-x0-9]+,\s*e8,\s*m2,\s*t[au],\s*mu\s+vnsra\.wx\s+v[0-9]+,\s*v[0-9]+,\s*[a-x0-9]+,\s*v0.t} 1 } } */ +/* { dg-final { scan-assembler-times {vsetvli\s+zero,\s*[a-x0-9]+,\s*e8,\s*m4,\s*t[au],\s*mu\s+vnsra\.wx\s+v[0-9]+,\s*v[0-9]+,\s*[a-x0-9]+,\s*v0.t} 1 } } */ +/* { dg-final { scan-assembler-times {vsetvli\s+zero,\s*[a-x0-9]+,\s*e16,\s*mf4,\s*t[au],\s*mu\s+vnsra\.wx\s+v[0-9]+,\s*v[0-9]+,\s*[a-x0-9]+,\s*v0.t} 1 } } */ +/* { dg-final { scan-assembler-times {vsetvli\s+zero,\s*[a-x0-9]+,\s*e16,\s*mf2,\s*t[au],\s*mu\s+vnsra\.wx\s+v[0-9]+,\s*v[0-9]+,\s*[a-x0-9]+,\s*v0.t} 1 } } */ +/* { dg-final { scan-assembler-times {vsetvli\s+zero,\s*[a-x0-9]+,\s*e16,\s*m1,\s*t[au],\s*mu\s+vnsra\.wx\s+v[0-9]+,\s*v[0-9]+,\s*[a-x0-9]+,\s*v0.t} 1 } } */ +/* { dg-final { scan-assembler-times {vsetvli\s+zero,\s*[a-x0-9]+,\s*e16,\s*m2,\s*t[au],\s*mu\s+vnsra\.wx\s+v[0-9]+,\s*v[0-9]+,\s*[a-x0-9]+,\s*v0.t} 1 } } */ +/* { dg-final { scan-assembler-times {vsetvli\s+zero,\s*[a-x0-9]+,\s*e16,\s*m4,\s*t[au],\s*mu\s+vnsra\.wx\s+v[0-9]+,\s*v[0-9]+,\s*[a-x0-9]+,\s*v0.t} 1 } } */ +/* { dg-final { scan-assembler-times {vsetvli\s+zero,\s*[a-x0-9]+,\s*e32,\s*mf2,\s*t[au],\s*mu\s+vnsra\.wx\s+v[0-9]+,\s*v[0-9]+,\s*[a-x0-9]+,\s*v0.t} 1 } } */ +/* { dg-final { scan-assembler-times {vsetvli\s+zero,\s*[a-x0-9]+,\s*e32,\s*m1,\s*t[au],\s*mu\s+vnsra\.wx\s+v[0-9]+,\s*v[0-9]+,\s*[a-x0-9]+,\s*v0.t} 1 } } */ +/* { dg-final { scan-assembler-times {vsetvli\s+zero,\s*[a-x0-9]+,\s*e32,\s*m2,\s*t[au],\s*mu\s+vnsra\.wx\s+v[0-9]+,\s*v[0-9]+,\s*[a-x0-9]+,\s*v0.t} 1 } } */ +/* { dg-final { scan-assembler-times {vsetvli\s+zero,\s*[a-x0-9]+,\s*e32,\s*m4,\s*t[au],\s*mu\s+vnsra\.wx\s+v[0-9]+,\s*v[0-9]+,\s*[a-x0-9]+,\s*v0.t} 1 } } */ diff --git a/gcc/testsuite/gcc.target/riscv/rvv/base/vnsra_wx_mu-2.c b/gcc/testsuite/gcc.target/riscv/rvv/base/vnsra_wx_mu-2.c new file mode 100644 index 00000000000..b4ffd402af6 --- /dev/null +++ b/gcc/testsuite/gcc.target/riscv/rvv/base/vnsra_wx_mu-2.c @@ -0,0 +1,111 @@ +/* { dg-do compile } */ +/* { dg-options "-march=rv64gcv -mabi=lp64d -O3 -fno-schedule-insns -fno-schedule-insns2" } */ + +#include "riscv_vector.h" + +vint8mf8_t test___riscv_vnsra_wx_i8mf8_mu(vbool64_t mask,vint8mf8_t merge,vint16mf4_t op1,size_t shift,size_t vl) +{ + return __riscv_vnsra_wx_i8mf8_mu(mask,merge,op1,shift,31); +} + + +vint8mf4_t test___riscv_vnsra_wx_i8mf4_mu(vbool32_t mask,vint8mf4_t merge,vint16mf2_t op1,size_t shift,size_t vl) +{ + return __riscv_vnsra_wx_i8mf4_mu(mask,merge,op1,shift,31); +} + + +vint8mf2_t test___riscv_vnsra_wx_i8mf2_mu(vbool16_t mask,vint8mf2_t merge,vint16m1_t op1,size_t shift,size_t vl) +{ + return __riscv_vnsra_wx_i8mf2_mu(mask,merge,op1,shift,31); +} + + +vint8m1_t test___riscv_vnsra_wx_i8m1_mu(vbool8_t mask,vint8m1_t merge,vint16m2_t op1,size_t shift,size_t vl) +{ + return __riscv_vnsra_wx_i8m1_mu(mask,merge,op1,shift,31); +} + + +vint8m2_t test___riscv_vnsra_wx_i8m2_mu(vbool4_t mask,vint8m2_t merge,vint16m4_t op1,size_t shift,size_t vl) +{ + return __riscv_vnsra_wx_i8m2_mu(mask,merge,op1,shift,31); +} + + +vint8m4_t test___riscv_vnsra_wx_i8m4_mu(vbool2_t mask,vint8m4_t merge,vint16m8_t op1,size_t shift,size_t vl) +{ + return __riscv_vnsra_wx_i8m4_mu(mask,merge,op1,shift,31); +} + + +vint16mf4_t test___riscv_vnsra_wx_i16mf4_mu(vbool64_t mask,vint16mf4_t merge,vint32mf2_t op1,size_t shift,size_t vl) +{ + return __riscv_vnsra_wx_i16mf4_mu(mask,merge,op1,shift,31); +} + + +vint16mf2_t test___riscv_vnsra_wx_i16mf2_mu(vbool32_t mask,vint16mf2_t merge,vint32m1_t op1,size_t shift,size_t vl) +{ + return __riscv_vnsra_wx_i16mf2_mu(mask,merge,op1,shift,31); +} + + +vint16m1_t test___riscv_vnsra_wx_i16m1_mu(vbool16_t mask,vint16m1_t merge,vint32m2_t op1,size_t shift,size_t vl) +{ + return __riscv_vnsra_wx_i16m1_mu(mask,merge,op1,shift,31); +} + + +vint16m2_t test___riscv_vnsra_wx_i16m2_mu(vbool8_t mask,vint16m2_t merge,vint32m4_t op1,size_t shift,size_t vl) +{ + return __riscv_vnsra_wx_i16m2_mu(mask,merge,op1,shift,31); +} + + +vint16m4_t test___riscv_vnsra_wx_i16m4_mu(vbool4_t mask,vint16m4_t merge,vint32m8_t op1,size_t shift,size_t vl) +{ + return __riscv_vnsra_wx_i16m4_mu(mask,merge,op1,shift,31); +} + + +vint32mf2_t test___riscv_vnsra_wx_i32mf2_mu(vbool64_t mask,vint32mf2_t merge,vint64m1_t op1,size_t shift,size_t vl) +{ + return __riscv_vnsra_wx_i32mf2_mu(mask,merge,op1,shift,31); +} + + +vint32m1_t test___riscv_vnsra_wx_i32m1_mu(vbool32_t mask,vint32m1_t merge,vint64m2_t op1,size_t shift,size_t vl) +{ + return __riscv_vnsra_wx_i32m1_mu(mask,merge,op1,shift,31); +} + + +vint32m2_t test___riscv_vnsra_wx_i32m2_mu(vbool16_t mask,vint32m2_t merge,vint64m4_t op1,size_t shift,size_t vl) +{ + return __riscv_vnsra_wx_i32m2_mu(mask,merge,op1,shift,31); +} + + +vint32m4_t test___riscv_vnsra_wx_i32m4_mu(vbool8_t mask,vint32m4_t merge,vint64m8_t op1,size_t shift,size_t vl) +{ + return __riscv_vnsra_wx_i32m4_mu(mask,merge,op1,shift,31); +} + + + +/* { dg-final { scan-assembler-times {vsetivli\s+zero,\s*31,\s*e8,\s*mf8,\s*t[au],\s*mu\s+vnsra\.wx\s+v[0-9]+,\s*v[0-9]+,\s*[a-x0-9]+,\s*v0.t} 1 } } */ +/* { dg-final { scan-assembler-times {vsetivli\s+zero,\s*31,\s*e8,\s*mf4,\s*t[au],\s*mu\s+vnsra\.wx\s+v[0-9]+,\s*v[0-9]+,\s*[a-x0-9]+,\s*v0.t} 1 } } */ +/* { dg-final { scan-assembler-times {vsetivli\s+zero,\s*31,\s*e8,\s*mf2,\s*t[au],\s*mu\s+vnsra\.wx\s+v[0-9]+,\s*v[0-9]+,\s*[a-x0-9]+,\s*v0.t} 1 } } */ +/* { dg-final { scan-assembler-times {vsetivli\s+zero,\s*31,\s*e8,\s*m1,\s*t[au],\s*mu\s+vnsra\.wx\s+v[0-9]+,\s*v[0-9]+,\s*[a-x0-9]+,\s*v0.t} 1 } } */ +/* { dg-final { scan-assembler-times {vsetivli\s+zero,\s*31,\s*e8,\s*m2,\s*t[au],\s*mu\s+vnsra\.wx\s+v[0-9]+,\s*v[0-9]+,\s*[a-x0-9]+,\s*v0.t} 1 } } */ +/* { dg-final { scan-assembler-times {vsetivli\s+zero,\s*31,\s*e8,\s*m4,\s*t[au],\s*mu\s+vnsra\.wx\s+v[0-9]+,\s*v[0-9]+,\s*[a-x0-9]+,\s*v0.t} 1 } } */ +/* { dg-final { scan-assembler-times {vsetivli\s+zero,\s*31,\s*e16,\s*mf4,\s*t[au],\s*mu\s+vnsra\.wx\s+v[0-9]+,\s*v[0-9]+,\s*[a-x0-9]+,\s*v0.t} 1 } } */ +/* { dg-final { scan-assembler-times {vsetivli\s+zero,\s*31,\s*e16,\s*mf2,\s*t[au],\s*mu\s+vnsra\.wx\s+v[0-9]+,\s*v[0-9]+,\s*[a-x0-9]+,\s*v0.t} 1 } } */ +/* { dg-final { scan-assembler-times {vsetivli\s+zero,\s*31,\s*e16,\s*m1,\s*t[au],\s*mu\s+vnsra\.wx\s+v[0-9]+,\s*v[0-9]+,\s*[a-x0-9]+,\s*v0.t} 1 } } */ +/* { dg-final { scan-assembler-times {vsetivli\s+zero,\s*31,\s*e16,\s*m2,\s*t[au],\s*mu\s+vnsra\.wx\s+v[0-9]+,\s*v[0-9]+,\s*[a-x0-9]+,\s*v0.t} 1 } } */ +/* { dg-final { scan-assembler-times {vsetivli\s+zero,\s*31,\s*e16,\s*m4,\s*t[au],\s*mu\s+vnsra\.wx\s+v[0-9]+,\s*v[0-9]+,\s*[a-x0-9]+,\s*v0.t} 1 } } */ +/* { dg-final { scan-assembler-times {vsetivli\s+zero,\s*31,\s*e32,\s*mf2,\s*t[au],\s*mu\s+vnsra\.wx\s+v[0-9]+,\s*v[0-9]+,\s*[a-x0-9]+,\s*v0.t} 1 } } */ +/* { dg-final { scan-assembler-times {vsetivli\s+zero,\s*31,\s*e32,\s*m1,\s*t[au],\s*mu\s+vnsra\.wx\s+v[0-9]+,\s*v[0-9]+,\s*[a-x0-9]+,\s*v0.t} 1 } } */ +/* { dg-final { scan-assembler-times {vsetivli\s+zero,\s*31,\s*e32,\s*m2,\s*t[au],\s*mu\s+vnsra\.wx\s+v[0-9]+,\s*v[0-9]+,\s*[a-x0-9]+,\s*v0.t} 1 } } */ +/* { dg-final { scan-assembler-times {vsetivli\s+zero,\s*31,\s*e32,\s*m4,\s*t[au],\s*mu\s+vnsra\.wx\s+v[0-9]+,\s*v[0-9]+,\s*[a-x0-9]+,\s*v0.t} 1 } } */ diff --git a/gcc/testsuite/gcc.target/riscv/rvv/base/vnsra_wx_mu-3.c b/gcc/testsuite/gcc.target/riscv/rvv/base/vnsra_wx_mu-3.c new file mode 100644 index 00000000000..3e7f8d78ef8 --- /dev/null +++ b/gcc/testsuite/gcc.target/riscv/rvv/base/vnsra_wx_mu-3.c @@ -0,0 +1,111 @@ +/* { dg-do compile } */ +/* { dg-options "-march=rv64gcv -mabi=lp64d -O3 -fno-schedule-insns -fno-schedule-insns2" } */ + +#include "riscv_vector.h" + +vint8mf8_t test___riscv_vnsra_wx_i8mf8_mu(vbool64_t mask,vint8mf8_t merge,vint16mf4_t op1,size_t shift,size_t vl) +{ + return __riscv_vnsra_wx_i8mf8_mu(mask,merge,op1,shift,32); +} + + +vint8mf4_t test___riscv_vnsra_wx_i8mf4_mu(vbool32_t mask,vint8mf4_t merge,vint16mf2_t op1,size_t shift,size_t vl) +{ + return __riscv_vnsra_wx_i8mf4_mu(mask,merge,op1,shift,32); +} + + +vint8mf2_t test___riscv_vnsra_wx_i8mf2_mu(vbool16_t mask,vint8mf2_t merge,vint16m1_t op1,size_t shift,size_t vl) +{ + return __riscv_vnsra_wx_i8mf2_mu(mask,merge,op1,shift,32); +} + + +vint8m1_t test___riscv_vnsra_wx_i8m1_mu(vbool8_t mask,vint8m1_t merge,vint16m2_t op1,size_t shift,size_t vl) +{ + return __riscv_vnsra_wx_i8m1_mu(mask,merge,op1,shift,32); +} + + +vint8m2_t test___riscv_vnsra_wx_i8m2_mu(vbool4_t mask,vint8m2_t merge,vint16m4_t op1,size_t shift,size_t vl) +{ + return __riscv_vnsra_wx_i8m2_mu(mask,merge,op1,shift,32); +} + + +vint8m4_t test___riscv_vnsra_wx_i8m4_mu(vbool2_t mask,vint8m4_t merge,vint16m8_t op1,size_t shift,size_t vl) +{ + return __riscv_vnsra_wx_i8m4_mu(mask,merge,op1,shift,32); +} + + +vint16mf4_t test___riscv_vnsra_wx_i16mf4_mu(vbool64_t mask,vint16mf4_t merge,vint32mf2_t op1,size_t shift,size_t vl) +{ + return __riscv_vnsra_wx_i16mf4_mu(mask,merge,op1,shift,32); +} + + +vint16mf2_t test___riscv_vnsra_wx_i16mf2_mu(vbool32_t mask,vint16mf2_t merge,vint32m1_t op1,size_t shift,size_t vl) +{ + return __riscv_vnsra_wx_i16mf2_mu(mask,merge,op1,shift,32); +} + + +vint16m1_t test___riscv_vnsra_wx_i16m1_mu(vbool16_t mask,vint16m1_t merge,vint32m2_t op1,size_t shift,size_t vl) +{ + return __riscv_vnsra_wx_i16m1_mu(mask,merge,op1,shift,32); +} + + +vint16m2_t test___riscv_vnsra_wx_i16m2_mu(vbool8_t mask,vint16m2_t merge,vint32m4_t op1,size_t shift,size_t vl) +{ + return __riscv_vnsra_wx_i16m2_mu(mask,merge,op1,shift,32); +} + + +vint16m4_t test___riscv_vnsra_wx_i16m4_mu(vbool4_t mask,vint16m4_t merge,vint32m8_t op1,size_t shift,size_t vl) +{ + return __riscv_vnsra_wx_i16m4_mu(mask,merge,op1,shift,32); +} + + +vint32mf2_t test___riscv_vnsra_wx_i32mf2_mu(vbool64_t mask,vint32mf2_t merge,vint64m1_t op1,size_t shift,size_t vl) +{ + return __riscv_vnsra_wx_i32mf2_mu(mask,merge,op1,shift,32); +} + + +vint32m1_t test___riscv_vnsra_wx_i32m1_mu(vbool32_t mask,vint32m1_t merge,vint64m2_t op1,size_t shift,size_t vl) +{ + return __riscv_vnsra_wx_i32m1_mu(mask,merge,op1,shift,32); +} + + +vint32m2_t test___riscv_vnsra_wx_i32m2_mu(vbool16_t mask,vint32m2_t merge,vint64m4_t op1,size_t shift,size_t vl) +{ + return __riscv_vnsra_wx_i32m2_mu(mask,merge,op1,shift,32); +} + + +vint32m4_t test___riscv_vnsra_wx_i32m4_mu(vbool8_t mask,vint32m4_t merge,vint64m8_t op1,size_t shift,size_t vl) +{ + return __riscv_vnsra_wx_i32m4_mu(mask,merge,op1,shift,32); +} + + + +/* { dg-final { scan-assembler-times {vsetvli\s+zero,\s*[a-x0-9]+,\s*e8,\s*mf8,\s*t[au],\s*mu\s+vnsra\.wx\s+v[0-9]+,\s*v[0-9]+,\s*[a-x0-9]+,\s*v0.t} 1 } } */ +/* { dg-final { scan-assembler-times {vsetvli\s+zero,\s*[a-x0-9]+,\s*e8,\s*mf4,\s*t[au],\s*mu\s+vnsra\.wx\s+v[0-9]+,\s*v[0-9]+,\s*[a-x0-9]+,\s*v0.t} 1 } } */ +/* { dg-final { scan-assembler-times {vsetvli\s+zero,\s*[a-x0-9]+,\s*e8,\s*mf2,\s*t[au],\s*mu\s+vnsra\.wx\s+v[0-9]+,\s*v[0-9]+,\s*[a-x0-9]+,\s*v0.t} 1 } } */ +/* { dg-final { scan-assembler-times {vsetvli\s+zero,\s*[a-x0-9]+,\s*e8,\s*m1,\s*t[au],\s*mu\s+vnsra\.wx\s+v[0-9]+,\s*v[0-9]+,\s*[a-x0-9]+,\s*v0.t} 1 } } */ +/* { dg-final { scan-assembler-times {vsetvli\s+zero,\s*[a-x0-9]+,\s*e8,\s*m2,\s*t[au],\s*mu\s+vnsra\.wx\s+v[0-9]+,\s*v[0-9]+,\s*[a-x0-9]+,\s*v0.t} 1 } } */ +/* { dg-final { scan-assembler-times {vsetvli\s+zero,\s*[a-x0-9]+,\s*e8,\s*m4,\s*t[au],\s*mu\s+vnsra\.wx\s+v[0-9]+,\s*v[0-9]+,\s*[a-x0-9]+,\s*v0.t} 1 } } */ +/* { dg-final { scan-assembler-times {vsetvli\s+zero,\s*[a-x0-9]+,\s*e16,\s*mf4,\s*t[au],\s*mu\s+vnsra\.wx\s+v[0-9]+,\s*v[0-9]+,\s*[a-x0-9]+,\s*v0.t} 1 } } */ +/* { dg-final { scan-assembler-times {vsetvli\s+zero,\s*[a-x0-9]+,\s*e16,\s*mf2,\s*t[au],\s*mu\s+vnsra\.wx\s+v[0-9]+,\s*v[0-9]+,\s*[a-x0-9]+,\s*v0.t} 1 } } */ +/* { dg-final { scan-assembler-times {vsetvli\s+zero,\s*[a-x0-9]+,\s*e16,\s*m1,\s*t[au],\s*mu\s+vnsra\.wx\s+v[0-9]+,\s*v[0-9]+,\s*[a-x0-9]+,\s*v0.t} 1 } } */ +/* { dg-final { scan-assembler-times {vsetvli\s+zero,\s*[a-x0-9]+,\s*e16,\s*m2,\s*t[au],\s*mu\s+vnsra\.wx\s+v[0-9]+,\s*v[0-9]+,\s*[a-x0-9]+,\s*v0.t} 1 } } */ +/* { dg-final { scan-assembler-times {vsetvli\s+zero,\s*[a-x0-9]+,\s*e16,\s*m4,\s*t[au],\s*mu\s+vnsra\.wx\s+v[0-9]+,\s*v[0-9]+,\s*[a-x0-9]+,\s*v0.t} 1 } } */ +/* { dg-final { scan-assembler-times {vsetvli\s+zero,\s*[a-x0-9]+,\s*e32,\s*mf2,\s*t[au],\s*mu\s+vnsra\.wx\s+v[0-9]+,\s*v[0-9]+,\s*[a-x0-9]+,\s*v0.t} 1 } } */ +/* { dg-final { scan-assembler-times {vsetvli\s+zero,\s*[a-x0-9]+,\s*e32,\s*m1,\s*t[au],\s*mu\s+vnsra\.wx\s+v[0-9]+,\s*v[0-9]+,\s*[a-x0-9]+,\s*v0.t} 1 } } */ +/* { dg-final { scan-assembler-times {vsetvli\s+zero,\s*[a-x0-9]+,\s*e32,\s*m2,\s*t[au],\s*mu\s+vnsra\.wx\s+v[0-9]+,\s*v[0-9]+,\s*[a-x0-9]+,\s*v0.t} 1 } } */ +/* { dg-final { scan-assembler-times {vsetvli\s+zero,\s*[a-x0-9]+,\s*e32,\s*m4,\s*t[au],\s*mu\s+vnsra\.wx\s+v[0-9]+,\s*v[0-9]+,\s*[a-x0-9]+,\s*v0.t} 1 } } */ diff --git a/gcc/testsuite/gcc.target/riscv/rvv/base/vnsra_wx_tu-1.c b/gcc/testsuite/gcc.target/riscv/rvv/base/vnsra_wx_tu-1.c new file mode 100644 index 00000000000..02380fad466 --- /dev/null +++ b/gcc/testsuite/gcc.target/riscv/rvv/base/vnsra_wx_tu-1.c @@ -0,0 +1,111 @@ +/* { dg-do compile } */ +/* { dg-options "-march=rv64gcv -mabi=lp64d -O3 -fno-schedule-insns -fno-schedule-insns2" } */ + +#include "riscv_vector.h" + +vint8mf8_t test___riscv_vnsra_wx_i8mf8_tu(vint8mf8_t merge,vint16mf4_t op1,size_t shift,size_t vl) +{ + return __riscv_vnsra_wx_i8mf8_tu(merge,op1,shift,vl); +} + + +vint8mf4_t test___riscv_vnsra_wx_i8mf4_tu(vint8mf4_t merge,vint16mf2_t op1,size_t shift,size_t vl) +{ + return __riscv_vnsra_wx_i8mf4_tu(merge,op1,shift,vl); +} + + +vint8mf2_t test___riscv_vnsra_wx_i8mf2_tu(vint8mf2_t merge,vint16m1_t op1,size_t shift,size_t vl) +{ + return __riscv_vnsra_wx_i8mf2_tu(merge,op1,shift,vl); +} + + +vint8m1_t test___riscv_vnsra_wx_i8m1_tu(vint8m1_t merge,vint16m2_t op1,size_t shift,size_t vl) +{ + return __riscv_vnsra_wx_i8m1_tu(merge,op1,shift,vl); +} + + +vint8m2_t test___riscv_vnsra_wx_i8m2_tu(vint8m2_t merge,vint16m4_t op1,size_t shift,size_t vl) +{ + return __riscv_vnsra_wx_i8m2_tu(merge,op1,shift,vl); +} + + +vint8m4_t test___riscv_vnsra_wx_i8m4_tu(vint8m4_t merge,vint16m8_t op1,size_t shift,size_t vl) +{ + return __riscv_vnsra_wx_i8m4_tu(merge,op1,shift,vl); +} + + +vint16mf4_t test___riscv_vnsra_wx_i16mf4_tu(vint16mf4_t merge,vint32mf2_t op1,size_t shift,size_t vl) +{ + return __riscv_vnsra_wx_i16mf4_tu(merge,op1,shift,vl); +} + + +vint16mf2_t test___riscv_vnsra_wx_i16mf2_tu(vint16mf2_t merge,vint32m1_t op1,size_t shift,size_t vl) +{ + return __riscv_vnsra_wx_i16mf2_tu(merge,op1,shift,vl); +} + + +vint16m1_t test___riscv_vnsra_wx_i16m1_tu(vint16m1_t merge,vint32m2_t op1,size_t shift,size_t vl) +{ + return __riscv_vnsra_wx_i16m1_tu(merge,op1,shift,vl); +} + + +vint16m2_t test___riscv_vnsra_wx_i16m2_tu(vint16m2_t merge,vint32m4_t op1,size_t shift,size_t vl) +{ + return __riscv_vnsra_wx_i16m2_tu(merge,op1,shift,vl); +} + + +vint16m4_t test___riscv_vnsra_wx_i16m4_tu(vint16m4_t merge,vint32m8_t op1,size_t shift,size_t vl) +{ + return __riscv_vnsra_wx_i16m4_tu(merge,op1,shift,vl); +} + + +vint32mf2_t test___riscv_vnsra_wx_i32mf2_tu(vint32mf2_t merge,vint64m1_t op1,size_t shift,size_t vl) +{ + return __riscv_vnsra_wx_i32mf2_tu(merge,op1,shift,vl); +} + + +vint32m1_t test___riscv_vnsra_wx_i32m1_tu(vint32m1_t merge,vint64m2_t op1,size_t shift,size_t vl) +{ + return __riscv_vnsra_wx_i32m1_tu(merge,op1,shift,vl); +} + + +vint32m2_t test___riscv_vnsra_wx_i32m2_tu(vint32m2_t merge,vint64m4_t op1,size_t shift,size_t vl) +{ + return __riscv_vnsra_wx_i32m2_tu(merge,op1,shift,vl); +} + + +vint32m4_t test___riscv_vnsra_wx_i32m4_tu(vint32m4_t merge,vint64m8_t op1,size_t shift,size_t vl) +{ + return __riscv_vnsra_wx_i32m4_tu(merge,op1,shift,vl); +} + + + +/* { dg-final { scan-assembler-times {vsetvli\s+zero,\s*[a-x0-9]+,\s*e8,\s*mf8,\s*tu,\s*m[au]\s+vnsra\.wx\s+v[0-9]+,\s*v[0-9]+,\s*[a-x0-9]+} 1 } } */ +/* { dg-final { scan-assembler-times {vsetvli\s+zero,\s*[a-x0-9]+,\s*e8,\s*mf4,\s*tu,\s*m[au]\s+vnsra\.wx\s+v[0-9]+,\s*v[0-9]+,\s*[a-x0-9]+} 1 } } */ +/* { dg-final { scan-assembler-times {vsetvli\s+zero,\s*[a-x0-9]+,\s*e8,\s*mf2,\s*tu,\s*m[au]\s+vnsra\.wx\s+v[0-9]+,\s*v[0-9]+,\s*[a-x0-9]+} 1 } } */ +/* { dg-final { scan-assembler-times {vsetvli\s+zero,\s*[a-x0-9]+,\s*e8,\s*m1,\s*tu,\s*m[au]\s+vnsra\.wx\s+v[0-9]+,\s*v[0-9]+,\s*[a-x0-9]+} 1 } } */ +/* { dg-final { scan-assembler-times {vsetvli\s+zero,\s*[a-x0-9]+,\s*e8,\s*m2,\s*tu,\s*m[au]\s+vnsra\.wx\s+v[0-9]+,\s*v[0-9]+,\s*[a-x0-9]+} 1 } } */ +/* { dg-final { scan-assembler-times {vsetvli\s+zero,\s*[a-x0-9]+,\s*e8,\s*m4,\s*tu,\s*m[au]\s+vnsra\.wx\s+v[0-9]+,\s*v[0-9]+,\s*[a-x0-9]+} 1 } } */ +/* { dg-final { scan-assembler-times {vsetvli\s+zero,\s*[a-x0-9]+,\s*e16,\s*mf4,\s*tu,\s*m[au]\s+vnsra\.wx\s+v[0-9]+,\s*v[0-9]+,\s*[a-x0-9]+} 1 } } */ +/* { dg-final { scan-assembler-times {vsetvli\s+zero,\s*[a-x0-9]+,\s*e16,\s*mf2,\s*tu,\s*m[au]\s+vnsra\.wx\s+v[0-9]+,\s*v[0-9]+,\s*[a-x0-9]+} 1 } } */ +/* { dg-final { scan-assembler-times {vsetvli\s+zero,\s*[a-x0-9]+,\s*e16,\s*m1,\s*tu,\s*m[au]\s+vnsra\.wx\s+v[0-9]+,\s*v[0-9]+,\s*[a-x0-9]+} 1 } } */ +/* { dg-final { scan-assembler-times {vsetvli\s+zero,\s*[a-x0-9]+,\s*e16,\s*m2,\s*tu,\s*m[au]\s+vnsra\.wx\s+v[0-9]+,\s*v[0-9]+,\s*[a-x0-9]+} 1 } } */ +/* { dg-final { scan-assembler-times {vsetvli\s+zero,\s*[a-x0-9]+,\s*e16,\s*m4,\s*tu,\s*m[au]\s+vnsra\.wx\s+v[0-9]+,\s*v[0-9]+,\s*[a-x0-9]+} 1 } } */ +/* { dg-final { scan-assembler-times {vsetvli\s+zero,\s*[a-x0-9]+,\s*e32,\s*mf2,\s*tu,\s*m[au]\s+vnsra\.wx\s+v[0-9]+,\s*v[0-9]+,\s*[a-x0-9]+} 1 } } */ +/* { dg-final { scan-assembler-times {vsetvli\s+zero,\s*[a-x0-9]+,\s*e32,\s*m1,\s*tu,\s*m[au]\s+vnsra\.wx\s+v[0-9]+,\s*v[0-9]+,\s*[a-x0-9]+} 1 } } */ +/* { dg-final { scan-assembler-times {vsetvli\s+zero,\s*[a-x0-9]+,\s*e32,\s*m2,\s*tu,\s*m[au]\s+vnsra\.wx\s+v[0-9]+,\s*v[0-9]+,\s*[a-x0-9]+} 1 } } */ +/* { dg-final { scan-assembler-times {vsetvli\s+zero,\s*[a-x0-9]+,\s*e32,\s*m4,\s*tu,\s*m[au]\s+vnsra\.wx\s+v[0-9]+,\s*v[0-9]+,\s*[a-x0-9]+} 1 } } */ diff --git a/gcc/testsuite/gcc.target/riscv/rvv/base/vnsra_wx_tu-2.c b/gcc/testsuite/gcc.target/riscv/rvv/base/vnsra_wx_tu-2.c new file mode 100644 index 00000000000..873ba05fc33 --- /dev/null +++ b/gcc/testsuite/gcc.target/riscv/rvv/base/vnsra_wx_tu-2.c @@ -0,0 +1,111 @@ +/* { dg-do compile } */ +/* { dg-options "-march=rv64gcv -mabi=lp64d -O3 -fno-schedule-insns -fno-schedule-insns2" } */ + +#include "riscv_vector.h" + +vint8mf8_t test___riscv_vnsra_wx_i8mf8_tu(vint8mf8_t merge,vint16mf4_t op1,size_t shift,size_t vl) +{ + return __riscv_vnsra_wx_i8mf8_tu(merge,op1,shift,31); +} + + +vint8mf4_t test___riscv_vnsra_wx_i8mf4_tu(vint8mf4_t merge,vint16mf2_t op1,size_t shift,size_t vl) +{ + return __riscv_vnsra_wx_i8mf4_tu(merge,op1,shift,31); +} + + +vint8mf2_t test___riscv_vnsra_wx_i8mf2_tu(vint8mf2_t merge,vint16m1_t op1,size_t shift,size_t vl) +{ + return __riscv_vnsra_wx_i8mf2_tu(merge,op1,shift,31); +} + + +vint8m1_t test___riscv_vnsra_wx_i8m1_tu(vint8m1_t merge,vint16m2_t op1,size_t shift,size_t vl) +{ + return __riscv_vnsra_wx_i8m1_tu(merge,op1,shift,31); +} + + +vint8m2_t test___riscv_vnsra_wx_i8m2_tu(vint8m2_t merge,vint16m4_t op1,size_t shift,size_t vl) +{ + return __riscv_vnsra_wx_i8m2_tu(merge,op1,shift,31); +} + + +vint8m4_t test___riscv_vnsra_wx_i8m4_tu(vint8m4_t merge,vint16m8_t op1,size_t shift,size_t vl) +{ + return __riscv_vnsra_wx_i8m4_tu(merge,op1,shift,31); +} + + +vint16mf4_t test___riscv_vnsra_wx_i16mf4_tu(vint16mf4_t merge,vint32mf2_t op1,size_t shift,size_t vl) +{ + return __riscv_vnsra_wx_i16mf4_tu(merge,op1,shift,31); +} + + +vint16mf2_t test___riscv_vnsra_wx_i16mf2_tu(vint16mf2_t merge,vint32m1_t op1,size_t shift,size_t vl) +{ + return __riscv_vnsra_wx_i16mf2_tu(merge,op1,shift,31); +} + + +vint16m1_t test___riscv_vnsra_wx_i16m1_tu(vint16m1_t merge,vint32m2_t op1,size_t shift,size_t vl) +{ + return __riscv_vnsra_wx_i16m1_tu(merge,op1,shift,31); +} + + +vint16m2_t test___riscv_vnsra_wx_i16m2_tu(vint16m2_t merge,vint32m4_t op1,size_t shift,size_t vl) +{ + return __riscv_vnsra_wx_i16m2_tu(merge,op1,shift,31); +} + + +vint16m4_t test___riscv_vnsra_wx_i16m4_tu(vint16m4_t merge,vint32m8_t op1,size_t shift,size_t vl) +{ + return __riscv_vnsra_wx_i16m4_tu(merge,op1,shift,31); +} + + +vint32mf2_t test___riscv_vnsra_wx_i32mf2_tu(vint32mf2_t merge,vint64m1_t op1,size_t shift,size_t vl) +{ + return __riscv_vnsra_wx_i32mf2_tu(merge,op1,shift,31); +} + + +vint32m1_t test___riscv_vnsra_wx_i32m1_tu(vint32m1_t merge,vint64m2_t op1,size_t shift,size_t vl) +{ + return __riscv_vnsra_wx_i32m1_tu(merge,op1,shift,31); +} + + +vint32m2_t test___riscv_vnsra_wx_i32m2_tu(vint32m2_t merge,vint64m4_t op1,size_t shift,size_t vl) +{ + return __riscv_vnsra_wx_i32m2_tu(merge,op1,shift,31); +} + + +vint32m4_t test___riscv_vnsra_wx_i32m4_tu(vint32m4_t merge,vint64m8_t op1,size_t shift,size_t vl) +{ + return __riscv_vnsra_wx_i32m4_tu(merge,op1,shift,31); +} + + + +/* { dg-final { scan-assembler-times {vsetivli\s+zero,\s*31,\s*e8,\s*mf8,\s*tu,\s*m[au]\s+vnsra\.wx\s+v[0-9]+,\s*v[0-9]+,\s*[a-x0-9]+} 1 } } */ +/* { dg-final { scan-assembler-times {vsetivli\s+zero,\s*31,\s*e8,\s*mf4,\s*tu,\s*m[au]\s+vnsra\.wx\s+v[0-9]+,\s*v[0-9]+,\s*[a-x0-9]+} 1 } } */ +/* { dg-final { scan-assembler-times {vsetivli\s+zero,\s*31,\s*e8,\s*mf2,\s*tu,\s*m[au]\s+vnsra\.wx\s+v[0-9]+,\s*v[0-9]+,\s*[a-x0-9]+} 1 } } */ +/* { dg-final { scan-assembler-times {vsetivli\s+zero,\s*31,\s*e8,\s*m1,\s*tu,\s*m[au]\s+vnsra\.wx\s+v[0-9]+,\s*v[0-9]+,\s*[a-x0-9]+} 1 } } */ +/* { dg-final { scan-assembler-times {vsetivli\s+zero,\s*31,\s*e8,\s*m2,\s*tu,\s*m[au]\s+vnsra\.wx\s+v[0-9]+,\s*v[0-9]+,\s*[a-x0-9]+} 1 } } */ +/* { dg-final { scan-assembler-times {vsetivli\s+zero,\s*31,\s*e8,\s*m4,\s*tu,\s*m[au]\s+vnsra\.wx\s+v[0-9]+,\s*v[0-9]+,\s*[a-x0-9]+} 1 } } */ +/* { dg-final { scan-assembler-times {vsetivli\s+zero,\s*31,\s*e16,\s*mf4,\s*tu,\s*m[au]\s+vnsra\.wx\s+v[0-9]+,\s*v[0-9]+,\s*[a-x0-9]+} 1 } } */ +/* { dg-final { scan-assembler-times {vsetivli\s+zero,\s*31,\s*e16,\s*mf2,\s*tu,\s*m[au]\s+vnsra\.wx\s+v[0-9]+,\s*v[0-9]+,\s*[a-x0-9]+} 1 } } */ +/* { dg-final { scan-assembler-times {vsetivli\s+zero,\s*31,\s*e16,\s*m1,\s*tu,\s*m[au]\s+vnsra\.wx\s+v[0-9]+,\s*v[0-9]+,\s*[a-x0-9]+} 1 } } */ +/* { dg-final { scan-assembler-times {vsetivli\s+zero,\s*31,\s*e16,\s*m2,\s*tu,\s*m[au]\s+vnsra\.wx\s+v[0-9]+,\s*v[0-9]+,\s*[a-x0-9]+} 1 } } */ +/* { dg-final { scan-assembler-times {vsetivli\s+zero,\s*31,\s*e16,\s*m4,\s*tu,\s*m[au]\s+vnsra\.wx\s+v[0-9]+,\s*v[0-9]+,\s*[a-x0-9]+} 1 } } */ +/* { dg-final { scan-assembler-times {vsetivli\s+zero,\s*31,\s*e32,\s*mf2,\s*tu,\s*m[au]\s+vnsra\.wx\s+v[0-9]+,\s*v[0-9]+,\s*[a-x0-9]+} 1 } } */ +/* { dg-final { scan-assembler-times {vsetivli\s+zero,\s*31,\s*e32,\s*m1,\s*tu,\s*m[au]\s+vnsra\.wx\s+v[0-9]+,\s*v[0-9]+,\s*[a-x0-9]+} 1 } } */ +/* { dg-final { scan-assembler-times {vsetivli\s+zero,\s*31,\s*e32,\s*m2,\s*tu,\s*m[au]\s+vnsra\.wx\s+v[0-9]+,\s*v[0-9]+,\s*[a-x0-9]+} 1 } } */ +/* { dg-final { scan-assembler-times {vsetivli\s+zero,\s*31,\s*e32,\s*m4,\s*tu,\s*m[au]\s+vnsra\.wx\s+v[0-9]+,\s*v[0-9]+,\s*[a-x0-9]+} 1 } } */ diff --git a/gcc/testsuite/gcc.target/riscv/rvv/base/vnsra_wx_tu-3.c b/gcc/testsuite/gcc.target/riscv/rvv/base/vnsra_wx_tu-3.c new file mode 100644 index 00000000000..8c3abbdd606 --- /dev/null +++ b/gcc/testsuite/gcc.target/riscv/rvv/base/vnsra_wx_tu-3.c @@ -0,0 +1,111 @@ +/* { dg-do compile } */ +/* { dg-options "-march=rv64gcv -mabi=lp64d -O3 -fno-schedule-insns -fno-schedule-insns2" } */ + +#include "riscv_vector.h" + +vint8mf8_t test___riscv_vnsra_wx_i8mf8_tu(vint8mf8_t merge,vint16mf4_t op1,size_t shift,size_t vl) +{ + return __riscv_vnsra_wx_i8mf8_tu(merge,op1,shift,32); +} + + +vint8mf4_t test___riscv_vnsra_wx_i8mf4_tu(vint8mf4_t merge,vint16mf2_t op1,size_t shift,size_t vl) +{ + return __riscv_vnsra_wx_i8mf4_tu(merge,op1,shift,32); +} + + +vint8mf2_t test___riscv_vnsra_wx_i8mf2_tu(vint8mf2_t merge,vint16m1_t op1,size_t shift,size_t vl) +{ + return __riscv_vnsra_wx_i8mf2_tu(merge,op1,shift,32); +} + + +vint8m1_t test___riscv_vnsra_wx_i8m1_tu(vint8m1_t merge,vint16m2_t op1,size_t shift,size_t vl) +{ + return __riscv_vnsra_wx_i8m1_tu(merge,op1,shift,32); +} + + +vint8m2_t test___riscv_vnsra_wx_i8m2_tu(vint8m2_t merge,vint16m4_t op1,size_t shift,size_t vl) +{ + return __riscv_vnsra_wx_i8m2_tu(merge,op1,shift,32); +} + + +vint8m4_t test___riscv_vnsra_wx_i8m4_tu(vint8m4_t merge,vint16m8_t op1,size_t shift,size_t vl) +{ + return __riscv_vnsra_wx_i8m4_tu(merge,op1,shift,32); +} + + +vint16mf4_t test___riscv_vnsra_wx_i16mf4_tu(vint16mf4_t merge,vint32mf2_t op1,size_t shift,size_t vl) +{ + return __riscv_vnsra_wx_i16mf4_tu(merge,op1,shift,32); +} + + +vint16mf2_t test___riscv_vnsra_wx_i16mf2_tu(vint16mf2_t merge,vint32m1_t op1,size_t shift,size_t vl) +{ + return __riscv_vnsra_wx_i16mf2_tu(merge,op1,shift,32); +} + + +vint16m1_t test___riscv_vnsra_wx_i16m1_tu(vint16m1_t merge,vint32m2_t op1,size_t shift,size_t vl) +{ + return __riscv_vnsra_wx_i16m1_tu(merge,op1,shift,32); +} + + +vint16m2_t test___riscv_vnsra_wx_i16m2_tu(vint16m2_t merge,vint32m4_t op1,size_t shift,size_t vl) +{ + return __riscv_vnsra_wx_i16m2_tu(merge,op1,shift,32); +} + + +vint16m4_t test___riscv_vnsra_wx_i16m4_tu(vint16m4_t merge,vint32m8_t op1,size_t shift,size_t vl) +{ + return __riscv_vnsra_wx_i16m4_tu(merge,op1,shift,32); +} + + +vint32mf2_t test___riscv_vnsra_wx_i32mf2_tu(vint32mf2_t merge,vint64m1_t op1,size_t shift,size_t vl) +{ + return __riscv_vnsra_wx_i32mf2_tu(merge,op1,shift,32); +} + + +vint32m1_t test___riscv_vnsra_wx_i32m1_tu(vint32m1_t merge,vint64m2_t op1,size_t shift,size_t vl) +{ + return __riscv_vnsra_wx_i32m1_tu(merge,op1,shift,32); +} + + +vint32m2_t test___riscv_vnsra_wx_i32m2_tu(vint32m2_t merge,vint64m4_t op1,size_t shift,size_t vl) +{ + return __riscv_vnsra_wx_i32m2_tu(merge,op1,shift,32); +} + + +vint32m4_t test___riscv_vnsra_wx_i32m4_tu(vint32m4_t merge,vint64m8_t op1,size_t shift,size_t vl) +{ + return __riscv_vnsra_wx_i32m4_tu(merge,op1,shift,32); +} + + + +/* { dg-final { scan-assembler-times {vsetvli\s+zero,\s*[a-x0-9]+,\s*e8,\s*mf8,\s*tu,\s*m[au]\s+vnsra\.wx\s+v[0-9]+,\s*v[0-9]+,\s*[a-x0-9]+} 1 } } */ +/* { dg-final { scan-assembler-times {vsetvli\s+zero,\s*[a-x0-9]+,\s*e8,\s*mf4,\s*tu,\s*m[au]\s+vnsra\.wx\s+v[0-9]+,\s*v[0-9]+,\s*[a-x0-9]+} 1 } } */ +/* { dg-final { scan-assembler-times {vsetvli\s+zero,\s*[a-x0-9]+,\s*e8,\s*mf2,\s*tu,\s*m[au]\s+vnsra\.wx\s+v[0-9]+,\s*v[0-9]+,\s*[a-x0-9]+} 1 } } */ +/* { dg-final { scan-assembler-times {vsetvli\s+zero,\s*[a-x0-9]+,\s*e8,\s*m1,\s*tu,\s*m[au]\s+vnsra\.wx\s+v[0-9]+,\s*v[0-9]+,\s*[a-x0-9]+} 1 } } */ +/* { dg-final { scan-assembler-times {vsetvli\s+zero,\s*[a-x0-9]+,\s*e8,\s*m2,\s*tu,\s*m[au]\s+vnsra\.wx\s+v[0-9]+,\s*v[0-9]+,\s*[a-x0-9]+} 1 } } */ +/* { dg-final { scan-assembler-times {vsetvli\s+zero,\s*[a-x0-9]+,\s*e8,\s*m4,\s*tu,\s*m[au]\s+vnsra\.wx\s+v[0-9]+,\s*v[0-9]+,\s*[a-x0-9]+} 1 } } */ +/* { dg-final { scan-assembler-times {vsetvli\s+zero,\s*[a-x0-9]+,\s*e16,\s*mf4,\s*tu,\s*m[au]\s+vnsra\.wx\s+v[0-9]+,\s*v[0-9]+,\s*[a-x0-9]+} 1 } } */ +/* { dg-final { scan-assembler-times {vsetvli\s+zero,\s*[a-x0-9]+,\s*e16,\s*mf2,\s*tu,\s*m[au]\s+vnsra\.wx\s+v[0-9]+,\s*v[0-9]+,\s*[a-x0-9]+} 1 } } */ +/* { dg-final { scan-assembler-times {vsetvli\s+zero,\s*[a-x0-9]+,\s*e16,\s*m1,\s*tu,\s*m[au]\s+vnsra\.wx\s+v[0-9]+,\s*v[0-9]+,\s*[a-x0-9]+} 1 } } */ +/* { dg-final { scan-assembler-times {vsetvli\s+zero,\s*[a-x0-9]+,\s*e16,\s*m2,\s*tu,\s*m[au]\s+vnsra\.wx\s+v[0-9]+,\s*v[0-9]+,\s*[a-x0-9]+} 1 } } */ +/* { dg-final { scan-assembler-times {vsetvli\s+zero,\s*[a-x0-9]+,\s*e16,\s*m4,\s*tu,\s*m[au]\s+vnsra\.wx\s+v[0-9]+,\s*v[0-9]+,\s*[a-x0-9]+} 1 } } */ +/* { dg-final { scan-assembler-times {vsetvli\s+zero,\s*[a-x0-9]+,\s*e32,\s*mf2,\s*tu,\s*m[au]\s+vnsra\.wx\s+v[0-9]+,\s*v[0-9]+,\s*[a-x0-9]+} 1 } } */ +/* { dg-final { scan-assembler-times {vsetvli\s+zero,\s*[a-x0-9]+,\s*e32,\s*m1,\s*tu,\s*m[au]\s+vnsra\.wx\s+v[0-9]+,\s*v[0-9]+,\s*[a-x0-9]+} 1 } } */ +/* { dg-final { scan-assembler-times {vsetvli\s+zero,\s*[a-x0-9]+,\s*e32,\s*m2,\s*tu,\s*m[au]\s+vnsra\.wx\s+v[0-9]+,\s*v[0-9]+,\s*[a-x0-9]+} 1 } } */ +/* { dg-final { scan-assembler-times {vsetvli\s+zero,\s*[a-x0-9]+,\s*e32,\s*m4,\s*tu,\s*m[au]\s+vnsra\.wx\s+v[0-9]+,\s*v[0-9]+,\s*[a-x0-9]+} 1 } } */ diff --git a/gcc/testsuite/gcc.target/riscv/rvv/base/vnsra_wx_tum-1.c b/gcc/testsuite/gcc.target/riscv/rvv/base/vnsra_wx_tum-1.c new file mode 100644 index 00000000000..49996e05102 --- /dev/null +++ b/gcc/testsuite/gcc.target/riscv/rvv/base/vnsra_wx_tum-1.c @@ -0,0 +1,111 @@ +/* { dg-do compile } */ +/* { dg-options "-march=rv64gcv -mabi=lp64d -O3 -fno-schedule-insns -fno-schedule-insns2" } */ + +#include "riscv_vector.h" + +vint8mf8_t test___riscv_vnsra_wx_i8mf8_tum(vbool64_t mask,vint8mf8_t merge,vint16mf4_t op1,size_t shift,size_t vl) +{ + return __riscv_vnsra_wx_i8mf8_tum(mask,merge,op1,shift,vl); +} + + +vint8mf4_t test___riscv_vnsra_wx_i8mf4_tum(vbool32_t mask,vint8mf4_t merge,vint16mf2_t op1,size_t shift,size_t vl) +{ + return __riscv_vnsra_wx_i8mf4_tum(mask,merge,op1,shift,vl); +} + + +vint8mf2_t test___riscv_vnsra_wx_i8mf2_tum(vbool16_t mask,vint8mf2_t merge,vint16m1_t op1,size_t shift,size_t vl) +{ + return __riscv_vnsra_wx_i8mf2_tum(mask,merge,op1,shift,vl); +} + + +vint8m1_t test___riscv_vnsra_wx_i8m1_tum(vbool8_t mask,vint8m1_t merge,vint16m2_t op1,size_t shift,size_t vl) +{ + return __riscv_vnsra_wx_i8m1_tum(mask,merge,op1,shift,vl); +} + + +vint8m2_t test___riscv_vnsra_wx_i8m2_tum(vbool4_t mask,vint8m2_t merge,vint16m4_t op1,size_t shift,size_t vl) +{ + return __riscv_vnsra_wx_i8m2_tum(mask,merge,op1,shift,vl); +} + + +vint8m4_t test___riscv_vnsra_wx_i8m4_tum(vbool2_t mask,vint8m4_t merge,vint16m8_t op1,size_t shift,size_t vl) +{ + return __riscv_vnsra_wx_i8m4_tum(mask,merge,op1,shift,vl); +} + + +vint16mf4_t test___riscv_vnsra_wx_i16mf4_tum(vbool64_t mask,vint16mf4_t merge,vint32mf2_t op1,size_t shift,size_t vl) +{ + return __riscv_vnsra_wx_i16mf4_tum(mask,merge,op1,shift,vl); +} + + +vint16mf2_t test___riscv_vnsra_wx_i16mf2_tum(vbool32_t mask,vint16mf2_t merge,vint32m1_t op1,size_t shift,size_t vl) +{ + return __riscv_vnsra_wx_i16mf2_tum(mask,merge,op1,shift,vl); +} + + +vint16m1_t test___riscv_vnsra_wx_i16m1_tum(vbool16_t mask,vint16m1_t merge,vint32m2_t op1,size_t shift,size_t vl) +{ + return __riscv_vnsra_wx_i16m1_tum(mask,merge,op1,shift,vl); +} + + +vint16m2_t test___riscv_vnsra_wx_i16m2_tum(vbool8_t mask,vint16m2_t merge,vint32m4_t op1,size_t shift,size_t vl) +{ + return __riscv_vnsra_wx_i16m2_tum(mask,merge,op1,shift,vl); +} + + +vint16m4_t test___riscv_vnsra_wx_i16m4_tum(vbool4_t mask,vint16m4_t merge,vint32m8_t op1,size_t shift,size_t vl) +{ + return __riscv_vnsra_wx_i16m4_tum(mask,merge,op1,shift,vl); +} + + +vint32mf2_t test___riscv_vnsra_wx_i32mf2_tum(vbool64_t mask,vint32mf2_t merge,vint64m1_t op1,size_t shift,size_t vl) +{ + return __riscv_vnsra_wx_i32mf2_tum(mask,merge,op1,shift,vl); +} + + +vint32m1_t test___riscv_vnsra_wx_i32m1_tum(vbool32_t mask,vint32m1_t merge,vint64m2_t op1,size_t shift,size_t vl) +{ + return __riscv_vnsra_wx_i32m1_tum(mask,merge,op1,shift,vl); +} + + +vint32m2_t test___riscv_vnsra_wx_i32m2_tum(vbool16_t mask,vint32m2_t merge,vint64m4_t op1,size_t shift,size_t vl) +{ + return __riscv_vnsra_wx_i32m2_tum(mask,merge,op1,shift,vl); +} + + +vint32m4_t test___riscv_vnsra_wx_i32m4_tum(vbool8_t mask,vint32m4_t merge,vint64m8_t op1,size_t shift,size_t vl) +{ + return __riscv_vnsra_wx_i32m4_tum(mask,merge,op1,shift,vl); +} + + + +/* { dg-final { scan-assembler-times {vsetvli\s+zero,\s*[a-x0-9]+,\s*e8,\s*mf8,\s*tu,\s*m[au]\s+vnsra\.wx\s+v[0-9]+,\s*v[0-9]+,\s*[a-x0-9]+,\s*v0.t} 1 } } */ +/* { dg-final { scan-assembler-times {vsetvli\s+zero,\s*[a-x0-9]+,\s*e8,\s*mf4,\s*tu,\s*m[au]\s+vnsra\.wx\s+v[0-9]+,\s*v[0-9]+,\s*[a-x0-9]+,\s*v0.t} 1 } } */ +/* { dg-final { scan-assembler-times {vsetvli\s+zero,\s*[a-x0-9]+,\s*e8,\s*mf2,\s*tu,\s*m[au]\s+vnsra\.wx\s+v[0-9]+,\s*v[0-9]+,\s*[a-x0-9]+,\s*v0.t} 1 } } */ +/* { dg-final { scan-assembler-times {vsetvli\s+zero,\s*[a-x0-9]+,\s*e8,\s*m1,\s*tu,\s*m[au]\s+vnsra\.wx\s+v[0-9]+,\s*v[0-9]+,\s*[a-x0-9]+,\s*v0.t} 1 } } */ +/* { dg-final { scan-assembler-times {vsetvli\s+zero,\s*[a-x0-9]+,\s*e8,\s*m2,\s*tu,\s*m[au]\s+vnsra\.wx\s+v[0-9]+,\s*v[0-9]+,\s*[a-x0-9]+,\s*v0.t} 1 } } */ +/* { dg-final { scan-assembler-times {vsetvli\s+zero,\s*[a-x0-9]+,\s*e8,\s*m4,\s*tu,\s*m[au]\s+vnsra\.wx\s+v[0-9]+,\s*v[0-9]+,\s*[a-x0-9]+,\s*v0.t} 1 } } */ +/* { dg-final { scan-assembler-times {vsetvli\s+zero,\s*[a-x0-9]+,\s*e16,\s*mf4,\s*tu,\s*m[au]\s+vnsra\.wx\s+v[0-9]+,\s*v[0-9]+,\s*[a-x0-9]+,\s*v0.t} 1 } } */ +/* { dg-final { scan-assembler-times {vsetvli\s+zero,\s*[a-x0-9]+,\s*e16,\s*mf2,\s*tu,\s*m[au]\s+vnsra\.wx\s+v[0-9]+,\s*v[0-9]+,\s*[a-x0-9]+,\s*v0.t} 1 } } */ +/* { dg-final { scan-assembler-times {vsetvli\s+zero,\s*[a-x0-9]+,\s*e16,\s*m1,\s*tu,\s*m[au]\s+vnsra\.wx\s+v[0-9]+,\s*v[0-9]+,\s*[a-x0-9]+,\s*v0.t} 1 } } */ +/* { dg-final { scan-assembler-times {vsetvli\s+zero,\s*[a-x0-9]+,\s*e16,\s*m2,\s*tu,\s*m[au]\s+vnsra\.wx\s+v[0-9]+,\s*v[0-9]+,\s*[a-x0-9]+,\s*v0.t} 1 } } */ +/* { dg-final { scan-assembler-times {vsetvli\s+zero,\s*[a-x0-9]+,\s*e16,\s*m4,\s*tu,\s*m[au]\s+vnsra\.wx\s+v[0-9]+,\s*v[0-9]+,\s*[a-x0-9]+,\s*v0.t} 1 } } */ +/* { dg-final { scan-assembler-times {vsetvli\s+zero,\s*[a-x0-9]+,\s*e32,\s*mf2,\s*tu,\s*m[au]\s+vnsra\.wx\s+v[0-9]+,\s*v[0-9]+,\s*[a-x0-9]+,\s*v0.t} 1 } } */ +/* { dg-final { scan-assembler-times {vsetvli\s+zero,\s*[a-x0-9]+,\s*e32,\s*m1,\s*tu,\s*m[au]\s+vnsra\.wx\s+v[0-9]+,\s*v[0-9]+,\s*[a-x0-9]+,\s*v0.t} 1 } } */ +/* { dg-final { scan-assembler-times {vsetvli\s+zero,\s*[a-x0-9]+,\s*e32,\s*m2,\s*tu,\s*m[au]\s+vnsra\.wx\s+v[0-9]+,\s*v[0-9]+,\s*[a-x0-9]+,\s*v0.t} 1 } } */ +/* { dg-final { scan-assembler-times {vsetvli\s+zero,\s*[a-x0-9]+,\s*e32,\s*m4,\s*tu,\s*m[au]\s+vnsra\.wx\s+v[0-9]+,\s*v[0-9]+,\s*[a-x0-9]+,\s*v0.t} 1 } } */ diff --git a/gcc/testsuite/gcc.target/riscv/rvv/base/vnsra_wx_tum-2.c b/gcc/testsuite/gcc.target/riscv/rvv/base/vnsra_wx_tum-2.c new file mode 100644 index 00000000000..dff3b3ea728 --- /dev/null +++ b/gcc/testsuite/gcc.target/riscv/rvv/base/vnsra_wx_tum-2.c @@ -0,0 +1,111 @@ +/* { dg-do compile } */ +/* { dg-options "-march=rv64gcv -mabi=lp64d -O3 -fno-schedule-insns -fno-schedule-insns2" } */ + +#include "riscv_vector.h" + +vint8mf8_t test___riscv_vnsra_wx_i8mf8_tum(vbool64_t mask,vint8mf8_t merge,vint16mf4_t op1,size_t shift,size_t vl) +{ + return __riscv_vnsra_wx_i8mf8_tum(mask,merge,op1,shift,31); +} + + +vint8mf4_t test___riscv_vnsra_wx_i8mf4_tum(vbool32_t mask,vint8mf4_t merge,vint16mf2_t op1,size_t shift,size_t vl) +{ + return __riscv_vnsra_wx_i8mf4_tum(mask,merge,op1,shift,31); +} + + +vint8mf2_t test___riscv_vnsra_wx_i8mf2_tum(vbool16_t mask,vint8mf2_t merge,vint16m1_t op1,size_t shift,size_t vl) +{ + return __riscv_vnsra_wx_i8mf2_tum(mask,merge,op1,shift,31); +} + + +vint8m1_t test___riscv_vnsra_wx_i8m1_tum(vbool8_t mask,vint8m1_t merge,vint16m2_t op1,size_t shift,size_t vl) +{ + return __riscv_vnsra_wx_i8m1_tum(mask,merge,op1,shift,31); +} + + +vint8m2_t test___riscv_vnsra_wx_i8m2_tum(vbool4_t mask,vint8m2_t merge,vint16m4_t op1,size_t shift,size_t vl) +{ + return __riscv_vnsra_wx_i8m2_tum(mask,merge,op1,shift,31); +} + + +vint8m4_t test___riscv_vnsra_wx_i8m4_tum(vbool2_t mask,vint8m4_t merge,vint16m8_t op1,size_t shift,size_t vl) +{ + return __riscv_vnsra_wx_i8m4_tum(mask,merge,op1,shift,31); +} + + +vint16mf4_t test___riscv_vnsra_wx_i16mf4_tum(vbool64_t mask,vint16mf4_t merge,vint32mf2_t op1,size_t shift,size_t vl) +{ + return __riscv_vnsra_wx_i16mf4_tum(mask,merge,op1,shift,31); +} + + +vint16mf2_t test___riscv_vnsra_wx_i16mf2_tum(vbool32_t mask,vint16mf2_t merge,vint32m1_t op1,size_t shift,size_t vl) +{ + return __riscv_vnsra_wx_i16mf2_tum(mask,merge,op1,shift,31); +} + + +vint16m1_t test___riscv_vnsra_wx_i16m1_tum(vbool16_t mask,vint16m1_t merge,vint32m2_t op1,size_t shift,size_t vl) +{ + return __riscv_vnsra_wx_i16m1_tum(mask,merge,op1,shift,31); +} + + +vint16m2_t test___riscv_vnsra_wx_i16m2_tum(vbool8_t mask,vint16m2_t merge,vint32m4_t op1,size_t shift,size_t vl) +{ + return __riscv_vnsra_wx_i16m2_tum(mask,merge,op1,shift,31); +} + + +vint16m4_t test___riscv_vnsra_wx_i16m4_tum(vbool4_t mask,vint16m4_t merge,vint32m8_t op1,size_t shift,size_t vl) +{ + return __riscv_vnsra_wx_i16m4_tum(mask,merge,op1,shift,31); +} + + +vint32mf2_t test___riscv_vnsra_wx_i32mf2_tum(vbool64_t mask,vint32mf2_t merge,vint64m1_t op1,size_t shift,size_t vl) +{ + return __riscv_vnsra_wx_i32mf2_tum(mask,merge,op1,shift,31); +} + + +vint32m1_t test___riscv_vnsra_wx_i32m1_tum(vbool32_t mask,vint32m1_t merge,vint64m2_t op1,size_t shift,size_t vl) +{ + return __riscv_vnsra_wx_i32m1_tum(mask,merge,op1,shift,31); +} + + +vint32m2_t test___riscv_vnsra_wx_i32m2_tum(vbool16_t mask,vint32m2_t merge,vint64m4_t op1,size_t shift,size_t vl) +{ + return __riscv_vnsra_wx_i32m2_tum(mask,merge,op1,shift,31); +} + + +vint32m4_t test___riscv_vnsra_wx_i32m4_tum(vbool8_t mask,vint32m4_t merge,vint64m8_t op1,size_t shift,size_t vl) +{ + return __riscv_vnsra_wx_i32m4_tum(mask,merge,op1,shift,31); +} + + + +/* { dg-final { scan-assembler-times {vsetivli\s+zero,\s*31,\s*e8,\s*mf8,\s*tu,\s*m[au]\s+vnsra\.wx\s+v[0-9]+,\s*v[0-9]+,\s*[a-x0-9]+,\s*v0.t} 1 } } */ +/* { dg-final { scan-assembler-times {vsetivli\s+zero,\s*31,\s*e8,\s*mf4,\s*tu,\s*m[au]\s+vnsra\.wx\s+v[0-9]+,\s*v[0-9]+,\s*[a-x0-9]+,\s*v0.t} 1 } } */ +/* { dg-final { scan-assembler-times {vsetivli\s+zero,\s*31,\s*e8,\s*mf2,\s*tu,\s*m[au]\s+vnsra\.wx\s+v[0-9]+,\s*v[0-9]+,\s*[a-x0-9]+,\s*v0.t} 1 } } */ +/* { dg-final { scan-assembler-times {vsetivli\s+zero,\s*31,\s*e8,\s*m1,\s*tu,\s*m[au]\s+vnsra\.wx\s+v[0-9]+,\s*v[0-9]+,\s*[a-x0-9]+,\s*v0.t} 1 } } */ +/* { dg-final { scan-assembler-times {vsetivli\s+zero,\s*31,\s*e8,\s*m2,\s*tu,\s*m[au]\s+vnsra\.wx\s+v[0-9]+,\s*v[0-9]+,\s*[a-x0-9]+,\s*v0.t} 1 } } */ +/* { dg-final { scan-assembler-times {vsetivli\s+zero,\s*31,\s*e8,\s*m4,\s*tu,\s*m[au]\s+vnsra\.wx\s+v[0-9]+,\s*v[0-9]+,\s*[a-x0-9]+,\s*v0.t} 1 } } */ +/* { dg-final { scan-assembler-times {vsetivli\s+zero,\s*31,\s*e16,\s*mf4,\s*tu,\s*m[au]\s+vnsra\.wx\s+v[0-9]+,\s*v[0-9]+,\s*[a-x0-9]+,\s*v0.t} 1 } } */ +/* { dg-final { scan-assembler-times {vsetivli\s+zero,\s*31,\s*e16,\s*mf2,\s*tu,\s*m[au]\s+vnsra\.wx\s+v[0-9]+,\s*v[0-9]+,\s*[a-x0-9]+,\s*v0.t} 1 } } */ +/* { dg-final { scan-assembler-times {vsetivli\s+zero,\s*31,\s*e16,\s*m1,\s*tu,\s*m[au]\s+vnsra\.wx\s+v[0-9]+,\s*v[0-9]+,\s*[a-x0-9]+,\s*v0.t} 1 } } */ +/* { dg-final { scan-assembler-times {vsetivli\s+zero,\s*31,\s*e16,\s*m2,\s*tu,\s*m[au]\s+vnsra\.wx\s+v[0-9]+,\s*v[0-9]+,\s*[a-x0-9]+,\s*v0.t} 1 } } */ +/* { dg-final { scan-assembler-times {vsetivli\s+zero,\s*31,\s*e16,\s*m4,\s*tu,\s*m[au]\s+vnsra\.wx\s+v[0-9]+,\s*v[0-9]+,\s*[a-x0-9]+,\s*v0.t} 1 } } */ +/* { dg-final { scan-assembler-times {vsetivli\s+zero,\s*31,\s*e32,\s*mf2,\s*tu,\s*m[au]\s+vnsra\.wx\s+v[0-9]+,\s*v[0-9]+,\s*[a-x0-9]+,\s*v0.t} 1 } } */ +/* { dg-final { scan-assembler-times {vsetivli\s+zero,\s*31,\s*e32,\s*m1,\s*tu,\s*m[au]\s+vnsra\.wx\s+v[0-9]+,\s*v[0-9]+,\s*[a-x0-9]+,\s*v0.t} 1 } } */ +/* { dg-final { scan-assembler-times {vsetivli\s+zero,\s*31,\s*e32,\s*m2,\s*tu,\s*m[au]\s+vnsra\.wx\s+v[0-9]+,\s*v[0-9]+,\s*[a-x0-9]+,\s*v0.t} 1 } } */ +/* { dg-final { scan-assembler-times {vsetivli\s+zero,\s*31,\s*e32,\s*m4,\s*tu,\s*m[au]\s+vnsra\.wx\s+v[0-9]+,\s*v[0-9]+,\s*[a-x0-9]+,\s*v0.t} 1 } } */ diff --git a/gcc/testsuite/gcc.target/riscv/rvv/base/vnsra_wx_tum-3.c b/gcc/testsuite/gcc.target/riscv/rvv/base/vnsra_wx_tum-3.c new file mode 100644 index 00000000000..ebbc13decdc --- /dev/null +++ b/gcc/testsuite/gcc.target/riscv/rvv/base/vnsra_wx_tum-3.c @@ -0,0 +1,111 @@ +/* { dg-do compile } */ +/* { dg-options "-march=rv64gcv -mabi=lp64d -O3 -fno-schedule-insns -fno-schedule-insns2" } */ + +#include "riscv_vector.h" + +vint8mf8_t test___riscv_vnsra_wx_i8mf8_tum(vbool64_t mask,vint8mf8_t merge,vint16mf4_t op1,size_t shift,size_t vl) +{ + return __riscv_vnsra_wx_i8mf8_tum(mask,merge,op1,shift,32); +} + + +vint8mf4_t test___riscv_vnsra_wx_i8mf4_tum(vbool32_t mask,vint8mf4_t merge,vint16mf2_t op1,size_t shift,size_t vl) +{ + return __riscv_vnsra_wx_i8mf4_tum(mask,merge,op1,shift,32); +} + + +vint8mf2_t test___riscv_vnsra_wx_i8mf2_tum(vbool16_t mask,vint8mf2_t merge,vint16m1_t op1,size_t shift,size_t vl) +{ + return __riscv_vnsra_wx_i8mf2_tum(mask,merge,op1,shift,32); +} + + +vint8m1_t test___riscv_vnsra_wx_i8m1_tum(vbool8_t mask,vint8m1_t merge,vint16m2_t op1,size_t shift,size_t vl) +{ + return __riscv_vnsra_wx_i8m1_tum(mask,merge,op1,shift,32); +} + + +vint8m2_t test___riscv_vnsra_wx_i8m2_tum(vbool4_t mask,vint8m2_t merge,vint16m4_t op1,size_t shift,size_t vl) +{ + return __riscv_vnsra_wx_i8m2_tum(mask,merge,op1,shift,32); +} + + +vint8m4_t test___riscv_vnsra_wx_i8m4_tum(vbool2_t mask,vint8m4_t merge,vint16m8_t op1,size_t shift,size_t vl) +{ + return __riscv_vnsra_wx_i8m4_tum(mask,merge,op1,shift,32); +} + + +vint16mf4_t test___riscv_vnsra_wx_i16mf4_tum(vbool64_t mask,vint16mf4_t merge,vint32mf2_t op1,size_t shift,size_t vl) +{ + return __riscv_vnsra_wx_i16mf4_tum(mask,merge,op1,shift,32); +} + + +vint16mf2_t test___riscv_vnsra_wx_i16mf2_tum(vbool32_t mask,vint16mf2_t merge,vint32m1_t op1,size_t shift,size_t vl) +{ + return __riscv_vnsra_wx_i16mf2_tum(mask,merge,op1,shift,32); +} + + +vint16m1_t test___riscv_vnsra_wx_i16m1_tum(vbool16_t mask,vint16m1_t merge,vint32m2_t op1,size_t shift,size_t vl) +{ + return __riscv_vnsra_wx_i16m1_tum(mask,merge,op1,shift,32); +} + + +vint16m2_t test___riscv_vnsra_wx_i16m2_tum(vbool8_t mask,vint16m2_t merge,vint32m4_t op1,size_t shift,size_t vl) +{ + return __riscv_vnsra_wx_i16m2_tum(mask,merge,op1,shift,32); +} + + +vint16m4_t test___riscv_vnsra_wx_i16m4_tum(vbool4_t mask,vint16m4_t merge,vint32m8_t op1,size_t shift,size_t vl) +{ + return __riscv_vnsra_wx_i16m4_tum(mask,merge,op1,shift,32); +} + + +vint32mf2_t test___riscv_vnsra_wx_i32mf2_tum(vbool64_t mask,vint32mf2_t merge,vint64m1_t op1,size_t shift,size_t vl) +{ + return __riscv_vnsra_wx_i32mf2_tum(mask,merge,op1,shift,32); +} + + +vint32m1_t test___riscv_vnsra_wx_i32m1_tum(vbool32_t mask,vint32m1_t merge,vint64m2_t op1,size_t shift,size_t vl) +{ + return __riscv_vnsra_wx_i32m1_tum(mask,merge,op1,shift,32); +} + + +vint32m2_t test___riscv_vnsra_wx_i32m2_tum(vbool16_t mask,vint32m2_t merge,vint64m4_t op1,size_t shift,size_t vl) +{ + return __riscv_vnsra_wx_i32m2_tum(mask,merge,op1,shift,32); +} + + +vint32m4_t test___riscv_vnsra_wx_i32m4_tum(vbool8_t mask,vint32m4_t merge,vint64m8_t op1,size_t shift,size_t vl) +{ + return __riscv_vnsra_wx_i32m4_tum(mask,merge,op1,shift,32); +} + + + +/* { dg-final { scan-assembler-times {vsetvli\s+zero,\s*[a-x0-9]+,\s*e8,\s*mf8,\s*tu,\s*m[au]\s+vnsra\.wx\s+v[0-9]+,\s*v[0-9]+,\s*[a-x0-9]+,\s*v0.t} 1 } } */ +/* { dg-final { scan-assembler-times {vsetvli\s+zero,\s*[a-x0-9]+,\s*e8,\s*mf4,\s*tu,\s*m[au]\s+vnsra\.wx\s+v[0-9]+,\s*v[0-9]+,\s*[a-x0-9]+,\s*v0.t} 1 } } */ +/* { dg-final { scan-assembler-times {vsetvli\s+zero,\s*[a-x0-9]+,\s*e8,\s*mf2,\s*tu,\s*m[au]\s+vnsra\.wx\s+v[0-9]+,\s*v[0-9]+,\s*[a-x0-9]+,\s*v0.t} 1 } } */ +/* { dg-final { scan-assembler-times {vsetvli\s+zero,\s*[a-x0-9]+,\s*e8,\s*m1,\s*tu,\s*m[au]\s+vnsra\.wx\s+v[0-9]+,\s*v[0-9]+,\s*[a-x0-9]+,\s*v0.t} 1 } } */ +/* { dg-final { scan-assembler-times {vsetvli\s+zero,\s*[a-x0-9]+,\s*e8,\s*m2,\s*tu,\s*m[au]\s+vnsra\.wx\s+v[0-9]+,\s*v[0-9]+,\s*[a-x0-9]+,\s*v0.t} 1 } } */ +/* { dg-final { scan-assembler-times {vsetvli\s+zero,\s*[a-x0-9]+,\s*e8,\s*m4,\s*tu,\s*m[au]\s+vnsra\.wx\s+v[0-9]+,\s*v[0-9]+,\s*[a-x0-9]+,\s*v0.t} 1 } } */ +/* { dg-final { scan-assembler-times {vsetvli\s+zero,\s*[a-x0-9]+,\s*e16,\s*mf4,\s*tu,\s*m[au]\s+vnsra\.wx\s+v[0-9]+,\s*v[0-9]+,\s*[a-x0-9]+,\s*v0.t} 1 } } */ +/* { dg-final { scan-assembler-times {vsetvli\s+zero,\s*[a-x0-9]+,\s*e16,\s*mf2,\s*tu,\s*m[au]\s+vnsra\.wx\s+v[0-9]+,\s*v[0-9]+,\s*[a-x0-9]+,\s*v0.t} 1 } } */ +/* { dg-final { scan-assembler-times {vsetvli\s+zero,\s*[a-x0-9]+,\s*e16,\s*m1,\s*tu,\s*m[au]\s+vnsra\.wx\s+v[0-9]+,\s*v[0-9]+,\s*[a-x0-9]+,\s*v0.t} 1 } } */ +/* { dg-final { scan-assembler-times {vsetvli\s+zero,\s*[a-x0-9]+,\s*e16,\s*m2,\s*tu,\s*m[au]\s+vnsra\.wx\s+v[0-9]+,\s*v[0-9]+,\s*[a-x0-9]+,\s*v0.t} 1 } } */ +/* { dg-final { scan-assembler-times {vsetvli\s+zero,\s*[a-x0-9]+,\s*e16,\s*m4,\s*tu,\s*m[au]\s+vnsra\.wx\s+v[0-9]+,\s*v[0-9]+,\s*[a-x0-9]+,\s*v0.t} 1 } } */ +/* { dg-final { scan-assembler-times {vsetvli\s+zero,\s*[a-x0-9]+,\s*e32,\s*mf2,\s*tu,\s*m[au]\s+vnsra\.wx\s+v[0-9]+,\s*v[0-9]+,\s*[a-x0-9]+,\s*v0.t} 1 } } */ +/* { dg-final { scan-assembler-times {vsetvli\s+zero,\s*[a-x0-9]+,\s*e32,\s*m1,\s*tu,\s*m[au]\s+vnsra\.wx\s+v[0-9]+,\s*v[0-9]+,\s*[a-x0-9]+,\s*v0.t} 1 } } */ +/* { dg-final { scan-assembler-times {vsetvli\s+zero,\s*[a-x0-9]+,\s*e32,\s*m2,\s*tu,\s*m[au]\s+vnsra\.wx\s+v[0-9]+,\s*v[0-9]+,\s*[a-x0-9]+,\s*v0.t} 1 } } */ +/* { dg-final { scan-assembler-times {vsetvli\s+zero,\s*[a-x0-9]+,\s*e32,\s*m4,\s*tu,\s*m[au]\s+vnsra\.wx\s+v[0-9]+,\s*v[0-9]+,\s*[a-x0-9]+,\s*v0.t} 1 } } */ diff --git a/gcc/testsuite/gcc.target/riscv/rvv/base/vnsra_wx_tumu-1.c b/gcc/testsuite/gcc.target/riscv/rvv/base/vnsra_wx_tumu-1.c new file mode 100644 index 00000000000..1471ddf2d77 --- /dev/null +++ b/gcc/testsuite/gcc.target/riscv/rvv/base/vnsra_wx_tumu-1.c @@ -0,0 +1,111 @@ +/* { dg-do compile } */ +/* { dg-options "-march=rv64gcv -mabi=lp64d -O3 -fno-schedule-insns -fno-schedule-insns2" } */ + +#include "riscv_vector.h" + +vint8mf8_t test___riscv_vnsra_wx_i8mf8_tumu(vbool64_t mask,vint8mf8_t merge,vint16mf4_t op1,size_t shift,size_t vl) +{ + return __riscv_vnsra_wx_i8mf8_tumu(mask,merge,op1,shift,vl); +} + + +vint8mf4_t test___riscv_vnsra_wx_i8mf4_tumu(vbool32_t mask,vint8mf4_t merge,vint16mf2_t op1,size_t shift,size_t vl) +{ + return __riscv_vnsra_wx_i8mf4_tumu(mask,merge,op1,shift,vl); +} + + +vint8mf2_t test___riscv_vnsra_wx_i8mf2_tumu(vbool16_t mask,vint8mf2_t merge,vint16m1_t op1,size_t shift,size_t vl) +{ + return __riscv_vnsra_wx_i8mf2_tumu(mask,merge,op1,shift,vl); +} + + +vint8m1_t test___riscv_vnsra_wx_i8m1_tumu(vbool8_t mask,vint8m1_t merge,vint16m2_t op1,size_t shift,size_t vl) +{ + return __riscv_vnsra_wx_i8m1_tumu(mask,merge,op1,shift,vl); +} + + +vint8m2_t test___riscv_vnsra_wx_i8m2_tumu(vbool4_t mask,vint8m2_t merge,vint16m4_t op1,size_t shift,size_t vl) +{ + return __riscv_vnsra_wx_i8m2_tumu(mask,merge,op1,shift,vl); +} + + +vint8m4_t test___riscv_vnsra_wx_i8m4_tumu(vbool2_t mask,vint8m4_t merge,vint16m8_t op1,size_t shift,size_t vl) +{ + return __riscv_vnsra_wx_i8m4_tumu(mask,merge,op1,shift,vl); +} + + +vint16mf4_t test___riscv_vnsra_wx_i16mf4_tumu(vbool64_t mask,vint16mf4_t merge,vint32mf2_t op1,size_t shift,size_t vl) +{ + return __riscv_vnsra_wx_i16mf4_tumu(mask,merge,op1,shift,vl); +} + + +vint16mf2_t test___riscv_vnsra_wx_i16mf2_tumu(vbool32_t mask,vint16mf2_t merge,vint32m1_t op1,size_t shift,size_t vl) +{ + return __riscv_vnsra_wx_i16mf2_tumu(mask,merge,op1,shift,vl); +} + + +vint16m1_t test___riscv_vnsra_wx_i16m1_tumu(vbool16_t mask,vint16m1_t merge,vint32m2_t op1,size_t shift,size_t vl) +{ + return __riscv_vnsra_wx_i16m1_tumu(mask,merge,op1,shift,vl); +} + + +vint16m2_t test___riscv_vnsra_wx_i16m2_tumu(vbool8_t mask,vint16m2_t merge,vint32m4_t op1,size_t shift,size_t vl) +{ + return __riscv_vnsra_wx_i16m2_tumu(mask,merge,op1,shift,vl); +} + + +vint16m4_t test___riscv_vnsra_wx_i16m4_tumu(vbool4_t mask,vint16m4_t merge,vint32m8_t op1,size_t shift,size_t vl) +{ + return __riscv_vnsra_wx_i16m4_tumu(mask,merge,op1,shift,vl); +} + + +vint32mf2_t test___riscv_vnsra_wx_i32mf2_tumu(vbool64_t mask,vint32mf2_t merge,vint64m1_t op1,size_t shift,size_t vl) +{ + return __riscv_vnsra_wx_i32mf2_tumu(mask,merge,op1,shift,vl); +} + + +vint32m1_t test___riscv_vnsra_wx_i32m1_tumu(vbool32_t mask,vint32m1_t merge,vint64m2_t op1,size_t shift,size_t vl) +{ + return __riscv_vnsra_wx_i32m1_tumu(mask,merge,op1,shift,vl); +} + + +vint32m2_t test___riscv_vnsra_wx_i32m2_tumu(vbool16_t mask,vint32m2_t merge,vint64m4_t op1,size_t shift,size_t vl) +{ + return __riscv_vnsra_wx_i32m2_tumu(mask,merge,op1,shift,vl); +} + + +vint32m4_t test___riscv_vnsra_wx_i32m4_tumu(vbool8_t mask,vint32m4_t merge,vint64m8_t op1,size_t shift,size_t vl) +{ + return __riscv_vnsra_wx_i32m4_tumu(mask,merge,op1,shift,vl); +} + + + +/* { dg-final { scan-assembler-times {vsetvli\s+zero,\s*[a-x0-9]+,\s*e8,\s*mf8,\s*tu,\s*mu\s+vnsra\.wx\s+v[0-9]+,\s*v[0-9]+,\s*[a-x0-9]+,\s*v0.t} 1 } } */ +/* { dg-final { scan-assembler-times {vsetvli\s+zero,\s*[a-x0-9]+,\s*e8,\s*mf4,\s*tu,\s*mu\s+vnsra\.wx\s+v[0-9]+,\s*v[0-9]+,\s*[a-x0-9]+,\s*v0.t} 1 } } */ +/* { dg-final { scan-assembler-times {vsetvli\s+zero,\s*[a-x0-9]+,\s*e8,\s*mf2,\s*tu,\s*mu\s+vnsra\.wx\s+v[0-9]+,\s*v[0-9]+,\s*[a-x0-9]+,\s*v0.t} 1 } } */ +/* { dg-final { scan-assembler-times {vsetvli\s+zero,\s*[a-x0-9]+,\s*e8,\s*m1,\s*tu,\s*mu\s+vnsra\.wx\s+v[0-9]+,\s*v[0-9]+,\s*[a-x0-9]+,\s*v0.t} 1 } } */ +/* { dg-final { scan-assembler-times {vsetvli\s+zero,\s*[a-x0-9]+,\s*e8,\s*m2,\s*tu,\s*mu\s+vnsra\.wx\s+v[0-9]+,\s*v[0-9]+,\s*[a-x0-9]+,\s*v0.t} 1 } } */ +/* { dg-final { scan-assembler-times {vsetvli\s+zero,\s*[a-x0-9]+,\s*e8,\s*m4,\s*tu,\s*mu\s+vnsra\.wx\s+v[0-9]+,\s*v[0-9]+,\s*[a-x0-9]+,\s*v0.t} 1 } } */ +/* { dg-final { scan-assembler-times {vsetvli\s+zero,\s*[a-x0-9]+,\s*e16,\s*mf4,\s*tu,\s*mu\s+vnsra\.wx\s+v[0-9]+,\s*v[0-9]+,\s*[a-x0-9]+,\s*v0.t} 1 } } */ +/* { dg-final { scan-assembler-times {vsetvli\s+zero,\s*[a-x0-9]+,\s*e16,\s*mf2,\s*tu,\s*mu\s+vnsra\.wx\s+v[0-9]+,\s*v[0-9]+,\s*[a-x0-9]+,\s*v0.t} 1 } } */ +/* { dg-final { scan-assembler-times {vsetvli\s+zero,\s*[a-x0-9]+,\s*e16,\s*m1,\s*tu,\s*mu\s+vnsra\.wx\s+v[0-9]+,\s*v[0-9]+,\s*[a-x0-9]+,\s*v0.t} 1 } } */ +/* { dg-final { scan-assembler-times {vsetvli\s+zero,\s*[a-x0-9]+,\s*e16,\s*m2,\s*tu,\s*mu\s+vnsra\.wx\s+v[0-9]+,\s*v[0-9]+,\s*[a-x0-9]+,\s*v0.t} 1 } } */ +/* { dg-final { scan-assembler-times {vsetvli\s+zero,\s*[a-x0-9]+,\s*e16,\s*m4,\s*tu,\s*mu\s+vnsra\.wx\s+v[0-9]+,\s*v[0-9]+,\s*[a-x0-9]+,\s*v0.t} 1 } } */ +/* { dg-final { scan-assembler-times {vsetvli\s+zero,\s*[a-x0-9]+,\s*e32,\s*mf2,\s*tu,\s*mu\s+vnsra\.wx\s+v[0-9]+,\s*v[0-9]+,\s*[a-x0-9]+,\s*v0.t} 1 } } */ +/* { dg-final { scan-assembler-times {vsetvli\s+zero,\s*[a-x0-9]+,\s*e32,\s*m1,\s*tu,\s*mu\s+vnsra\.wx\s+v[0-9]+,\s*v[0-9]+,\s*[a-x0-9]+,\s*v0.t} 1 } } */ +/* { dg-final { scan-assembler-times {vsetvli\s+zero,\s*[a-x0-9]+,\s*e32,\s*m2,\s*tu,\s*mu\s+vnsra\.wx\s+v[0-9]+,\s*v[0-9]+,\s*[a-x0-9]+,\s*v0.t} 1 } } */ +/* { dg-final { scan-assembler-times {vsetvli\s+zero,\s*[a-x0-9]+,\s*e32,\s*m4,\s*tu,\s*mu\s+vnsra\.wx\s+v[0-9]+,\s*v[0-9]+,\s*[a-x0-9]+,\s*v0.t} 1 } } */ diff --git a/gcc/testsuite/gcc.target/riscv/rvv/base/vnsra_wx_tumu-2.c b/gcc/testsuite/gcc.target/riscv/rvv/base/vnsra_wx_tumu-2.c new file mode 100644 index 00000000000..d594e43c151 --- /dev/null +++ b/gcc/testsuite/gcc.target/riscv/rvv/base/vnsra_wx_tumu-2.c @@ -0,0 +1,111 @@ +/* { dg-do compile } */ +/* { dg-options "-march=rv64gcv -mabi=lp64d -O3 -fno-schedule-insns -fno-schedule-insns2" } */ + +#include "riscv_vector.h" + +vint8mf8_t test___riscv_vnsra_wx_i8mf8_tumu(vbool64_t mask,vint8mf8_t merge,vint16mf4_t op1,size_t shift,size_t vl) +{ + return __riscv_vnsra_wx_i8mf8_tumu(mask,merge,op1,shift,31); +} + + +vint8mf4_t test___riscv_vnsra_wx_i8mf4_tumu(vbool32_t mask,vint8mf4_t merge,vint16mf2_t op1,size_t shift,size_t vl) +{ + return __riscv_vnsra_wx_i8mf4_tumu(mask,merge,op1,shift,31); +} + + +vint8mf2_t test___riscv_vnsra_wx_i8mf2_tumu(vbool16_t mask,vint8mf2_t merge,vint16m1_t op1,size_t shift,size_t vl) +{ + return __riscv_vnsra_wx_i8mf2_tumu(mask,merge,op1,shift,31); +} + + +vint8m1_t test___riscv_vnsra_wx_i8m1_tumu(vbool8_t mask,vint8m1_t merge,vint16m2_t op1,size_t shift,size_t vl) +{ + return __riscv_vnsra_wx_i8m1_tumu(mask,merge,op1,shift,31); +} + + +vint8m2_t test___riscv_vnsra_wx_i8m2_tumu(vbool4_t mask,vint8m2_t merge,vint16m4_t op1,size_t shift,size_t vl) +{ + return __riscv_vnsra_wx_i8m2_tumu(mask,merge,op1,shift,31); +} + + +vint8m4_t test___riscv_vnsra_wx_i8m4_tumu(vbool2_t mask,vint8m4_t merge,vint16m8_t op1,size_t shift,size_t vl) +{ + return __riscv_vnsra_wx_i8m4_tumu(mask,merge,op1,shift,31); +} + + +vint16mf4_t test___riscv_vnsra_wx_i16mf4_tumu(vbool64_t mask,vint16mf4_t merge,vint32mf2_t op1,size_t shift,size_t vl) +{ + return __riscv_vnsra_wx_i16mf4_tumu(mask,merge,op1,shift,31); +} + + +vint16mf2_t test___riscv_vnsra_wx_i16mf2_tumu(vbool32_t mask,vint16mf2_t merge,vint32m1_t op1,size_t shift,size_t vl) +{ + return __riscv_vnsra_wx_i16mf2_tumu(mask,merge,op1,shift,31); +} + + +vint16m1_t test___riscv_vnsra_wx_i16m1_tumu(vbool16_t mask,vint16m1_t merge,vint32m2_t op1,size_t shift,size_t vl) +{ + return __riscv_vnsra_wx_i16m1_tumu(mask,merge,op1,shift,31); +} + + +vint16m2_t test___riscv_vnsra_wx_i16m2_tumu(vbool8_t mask,vint16m2_t merge,vint32m4_t op1,size_t shift,size_t vl) +{ + return __riscv_vnsra_wx_i16m2_tumu(mask,merge,op1,shift,31); +} + + +vint16m4_t test___riscv_vnsra_wx_i16m4_tumu(vbool4_t mask,vint16m4_t merge,vint32m8_t op1,size_t shift,size_t vl) +{ + return __riscv_vnsra_wx_i16m4_tumu(mask,merge,op1,shift,31); +} + + +vint32mf2_t test___riscv_vnsra_wx_i32mf2_tumu(vbool64_t mask,vint32mf2_t merge,vint64m1_t op1,size_t shift,size_t vl) +{ + return __riscv_vnsra_wx_i32mf2_tumu(mask,merge,op1,shift,31); +} + + +vint32m1_t test___riscv_vnsra_wx_i32m1_tumu(vbool32_t mask,vint32m1_t merge,vint64m2_t op1,size_t shift,size_t vl) +{ + return __riscv_vnsra_wx_i32m1_tumu(mask,merge,op1,shift,31); +} + + +vint32m2_t test___riscv_vnsra_wx_i32m2_tumu(vbool16_t mask,vint32m2_t merge,vint64m4_t op1,size_t shift,size_t vl) +{ + return __riscv_vnsra_wx_i32m2_tumu(mask,merge,op1,shift,31); +} + + +vint32m4_t test___riscv_vnsra_wx_i32m4_tumu(vbool8_t mask,vint32m4_t merge,vint64m8_t op1,size_t shift,size_t vl) +{ + return __riscv_vnsra_wx_i32m4_tumu(mask,merge,op1,shift,31); +} + + + +/* { dg-final { scan-assembler-times {vsetivli\s+zero,\s*31,\s*e8,\s*mf8,\s*tu,\s*mu\s+vnsra\.wx\s+v[0-9]+,\s*v[0-9]+,\s*[a-x0-9]+,\s*v0.t} 1 } } */ +/* { dg-final { scan-assembler-times {vsetivli\s+zero,\s*31,\s*e8,\s*mf4,\s*tu,\s*mu\s+vnsra\.wx\s+v[0-9]+,\s*v[0-9]+,\s*[a-x0-9]+,\s*v0.t} 1 } } */ +/* { dg-final { scan-assembler-times {vsetivli\s+zero,\s*31,\s*e8,\s*mf2,\s*tu,\s*mu\s+vnsra\.wx\s+v[0-9]+,\s*v[0-9]+,\s*[a-x0-9]+,\s*v0.t} 1 } } */ +/* { dg-final { scan-assembler-times {vsetivli\s+zero,\s*31,\s*e8,\s*m1,\s*tu,\s*mu\s+vnsra\.wx\s+v[0-9]+,\s*v[0-9]+,\s*[a-x0-9]+,\s*v0.t} 1 } } */ +/* { dg-final { scan-assembler-times {vsetivli\s+zero,\s*31,\s*e8,\s*m2,\s*tu,\s*mu\s+vnsra\.wx\s+v[0-9]+,\s*v[0-9]+,\s*[a-x0-9]+,\s*v0.t} 1 } } */ +/* { dg-final { scan-assembler-times {vsetivli\s+zero,\s*31,\s*e8,\s*m4,\s*tu,\s*mu\s+vnsra\.wx\s+v[0-9]+,\s*v[0-9]+,\s*[a-x0-9]+,\s*v0.t} 1 } } */ +/* { dg-final { scan-assembler-times {vsetivli\s+zero,\s*31,\s*e16,\s*mf4,\s*tu,\s*mu\s+vnsra\.wx\s+v[0-9]+,\s*v[0-9]+,\s*[a-x0-9]+,\s*v0.t} 1 } } */ +/* { dg-final { scan-assembler-times {vsetivli\s+zero,\s*31,\s*e16,\s*mf2,\s*tu,\s*mu\s+vnsra\.wx\s+v[0-9]+,\s*v[0-9]+,\s*[a-x0-9]+,\s*v0.t} 1 } } */ +/* { dg-final { scan-assembler-times {vsetivli\s+zero,\s*31,\s*e16,\s*m1,\s*tu,\s*mu\s+vnsra\.wx\s+v[0-9]+,\s*v[0-9]+,\s*[a-x0-9]+,\s*v0.t} 1 } } */ +/* { dg-final { scan-assembler-times {vsetivli\s+zero,\s*31,\s*e16,\s*m2,\s*tu,\s*mu\s+vnsra\.wx\s+v[0-9]+,\s*v[0-9]+,\s*[a-x0-9]+,\s*v0.t} 1 } } */ +/* { dg-final { scan-assembler-times {vsetivli\s+zero,\s*31,\s*e16,\s*m4,\s*tu,\s*mu\s+vnsra\.wx\s+v[0-9]+,\s*v[0-9]+,\s*[a-x0-9]+,\s*v0.t} 1 } } */ +/* { dg-final { scan-assembler-times {vsetivli\s+zero,\s*31,\s*e32,\s*mf2,\s*tu,\s*mu\s+vnsra\.wx\s+v[0-9]+,\s*v[0-9]+,\s*[a-x0-9]+,\s*v0.t} 1 } } */ +/* { dg-final { scan-assembler-times {vsetivli\s+zero,\s*31,\s*e32,\s*m1,\s*tu,\s*mu\s+vnsra\.wx\s+v[0-9]+,\s*v[0-9]+,\s*[a-x0-9]+,\s*v0.t} 1 } } */ +/* { dg-final { scan-assembler-times {vsetivli\s+zero,\s*31,\s*e32,\s*m2,\s*tu,\s*mu\s+vnsra\.wx\s+v[0-9]+,\s*v[0-9]+,\s*[a-x0-9]+,\s*v0.t} 1 } } */ +/* { dg-final { scan-assembler-times {vsetivli\s+zero,\s*31,\s*e32,\s*m4,\s*tu,\s*mu\s+vnsra\.wx\s+v[0-9]+,\s*v[0-9]+,\s*[a-x0-9]+,\s*v0.t} 1 } } */ diff --git a/gcc/testsuite/gcc.target/riscv/rvv/base/vnsra_wx_tumu-3.c b/gcc/testsuite/gcc.target/riscv/rvv/base/vnsra_wx_tumu-3.c new file mode 100644 index 00000000000..85b3935f886 --- /dev/null +++ b/gcc/testsuite/gcc.target/riscv/rvv/base/vnsra_wx_tumu-3.c @@ -0,0 +1,111 @@ +/* { dg-do compile } */ +/* { dg-options "-march=rv64gcv -mabi=lp64d -O3 -fno-schedule-insns -fno-schedule-insns2" } */ + +#include "riscv_vector.h" + +vint8mf8_t test___riscv_vnsra_wx_i8mf8_tumu(vbool64_t mask,vint8mf8_t merge,vint16mf4_t op1,size_t shift,size_t vl) +{ + return __riscv_vnsra_wx_i8mf8_tumu(mask,merge,op1,shift,32); +} + + +vint8mf4_t test___riscv_vnsra_wx_i8mf4_tumu(vbool32_t mask,vint8mf4_t merge,vint16mf2_t op1,size_t shift,size_t vl) +{ + return __riscv_vnsra_wx_i8mf4_tumu(mask,merge,op1,shift,32); +} + + +vint8mf2_t test___riscv_vnsra_wx_i8mf2_tumu(vbool16_t mask,vint8mf2_t merge,vint16m1_t op1,size_t shift,size_t vl) +{ + return __riscv_vnsra_wx_i8mf2_tumu(mask,merge,op1,shift,32); +} + + +vint8m1_t test___riscv_vnsra_wx_i8m1_tumu(vbool8_t mask,vint8m1_t merge,vint16m2_t op1,size_t shift,size_t vl) +{ + return __riscv_vnsra_wx_i8m1_tumu(mask,merge,op1,shift,32); +} + + +vint8m2_t test___riscv_vnsra_wx_i8m2_tumu(vbool4_t mask,vint8m2_t merge,vint16m4_t op1,size_t shift,size_t vl) +{ + return __riscv_vnsra_wx_i8m2_tumu(mask,merge,op1,shift,32); +} + + +vint8m4_t test___riscv_vnsra_wx_i8m4_tumu(vbool2_t mask,vint8m4_t merge,vint16m8_t op1,size_t shift,size_t vl) +{ + return __riscv_vnsra_wx_i8m4_tumu(mask,merge,op1,shift,32); +} + + +vint16mf4_t test___riscv_vnsra_wx_i16mf4_tumu(vbool64_t mask,vint16mf4_t merge,vint32mf2_t op1,size_t shift,size_t vl) +{ + return __riscv_vnsra_wx_i16mf4_tumu(mask,merge,op1,shift,32); +} + + +vint16mf2_t test___riscv_vnsra_wx_i16mf2_tumu(vbool32_t mask,vint16mf2_t merge,vint32m1_t op1,size_t shift,size_t vl) +{ + return __riscv_vnsra_wx_i16mf2_tumu(mask,merge,op1,shift,32); +} + + +vint16m1_t test___riscv_vnsra_wx_i16m1_tumu(vbool16_t mask,vint16m1_t merge,vint32m2_t op1,size_t shift,size_t vl) +{ + return __riscv_vnsra_wx_i16m1_tumu(mask,merge,op1,shift,32); +} + + +vint16m2_t test___riscv_vnsra_wx_i16m2_tumu(vbool8_t mask,vint16m2_t merge,vint32m4_t op1,size_t shift,size_t vl) +{ + return __riscv_vnsra_wx_i16m2_tumu(mask,merge,op1,shift,32); +} + + +vint16m4_t test___riscv_vnsra_wx_i16m4_tumu(vbool4_t mask,vint16m4_t merge,vint32m8_t op1,size_t shift,size_t vl) +{ + return __riscv_vnsra_wx_i16m4_tumu(mask,merge,op1,shift,32); +} + + +vint32mf2_t test___riscv_vnsra_wx_i32mf2_tumu(vbool64_t mask,vint32mf2_t merge,vint64m1_t op1,size_t shift,size_t vl) +{ + return __riscv_vnsra_wx_i32mf2_tumu(mask,merge,op1,shift,32); +} + + +vint32m1_t test___riscv_vnsra_wx_i32m1_tumu(vbool32_t mask,vint32m1_t merge,vint64m2_t op1,size_t shift,size_t vl) +{ + return __riscv_vnsra_wx_i32m1_tumu(mask,merge,op1,shift,32); +} + + +vint32m2_t test___riscv_vnsra_wx_i32m2_tumu(vbool16_t mask,vint32m2_t merge,vint64m4_t op1,size_t shift,size_t vl) +{ + return __riscv_vnsra_wx_i32m2_tumu(mask,merge,op1,shift,32); +} + + +vint32m4_t test___riscv_vnsra_wx_i32m4_tumu(vbool8_t mask,vint32m4_t merge,vint64m8_t op1,size_t shift,size_t vl) +{ + return __riscv_vnsra_wx_i32m4_tumu(mask,merge,op1,shift,32); +} + + + +/* { dg-final { scan-assembler-times {vsetvli\s+zero,\s*[a-x0-9]+,\s*e8,\s*mf8,\s*tu,\s*mu\s+vnsra\.wx\s+v[0-9]+,\s*v[0-9]+,\s*[a-x0-9]+,\s*v0.t} 1 } } */ +/* { dg-final { scan-assembler-times {vsetvli\s+zero,\s*[a-x0-9]+,\s*e8,\s*mf4,\s*tu,\s*mu\s+vnsra\.wx\s+v[0-9]+,\s*v[0-9]+,\s*[a-x0-9]+,\s*v0.t} 1 } } */ +/* { dg-final { scan-assembler-times {vsetvli\s+zero,\s*[a-x0-9]+,\s*e8,\s*mf2,\s*tu,\s*mu\s+vnsra\.wx\s+v[0-9]+,\s*v[0-9]+,\s*[a-x0-9]+,\s*v0.t} 1 } } */ +/* { dg-final { scan-assembler-times {vsetvli\s+zero,\s*[a-x0-9]+,\s*e8,\s*m1,\s*tu,\s*mu\s+vnsra\.wx\s+v[0-9]+,\s*v[0-9]+,\s*[a-x0-9]+,\s*v0.t} 1 } } */ +/* { dg-final { scan-assembler-times {vsetvli\s+zero,\s*[a-x0-9]+,\s*e8,\s*m2,\s*tu,\s*mu\s+vnsra\.wx\s+v[0-9]+,\s*v[0-9]+,\s*[a-x0-9]+,\s*v0.t} 1 } } */ +/* { dg-final { scan-assembler-times {vsetvli\s+zero,\s*[a-x0-9]+,\s*e8,\s*m4,\s*tu,\s*mu\s+vnsra\.wx\s+v[0-9]+,\s*v[0-9]+,\s*[a-x0-9]+,\s*v0.t} 1 } } */ +/* { dg-final { scan-assembler-times {vsetvli\s+zero,\s*[a-x0-9]+,\s*e16,\s*mf4,\s*tu,\s*mu\s+vnsra\.wx\s+v[0-9]+,\s*v[0-9]+,\s*[a-x0-9]+,\s*v0.t} 1 } } */ +/* { dg-final { scan-assembler-times {vsetvli\s+zero,\s*[a-x0-9]+,\s*e16,\s*mf2,\s*tu,\s*mu\s+vnsra\.wx\s+v[0-9]+,\s*v[0-9]+,\s*[a-x0-9]+,\s*v0.t} 1 } } */ +/* { dg-final { scan-assembler-times {vsetvli\s+zero,\s*[a-x0-9]+,\s*e16,\s*m1,\s*tu,\s*mu\s+vnsra\.wx\s+v[0-9]+,\s*v[0-9]+,\s*[a-x0-9]+,\s*v0.t} 1 } } */ +/* { dg-final { scan-assembler-times {vsetvli\s+zero,\s*[a-x0-9]+,\s*e16,\s*m2,\s*tu,\s*mu\s+vnsra\.wx\s+v[0-9]+,\s*v[0-9]+,\s*[a-x0-9]+,\s*v0.t} 1 } } */ +/* { dg-final { scan-assembler-times {vsetvli\s+zero,\s*[a-x0-9]+,\s*e16,\s*m4,\s*tu,\s*mu\s+vnsra\.wx\s+v[0-9]+,\s*v[0-9]+,\s*[a-x0-9]+,\s*v0.t} 1 } } */ +/* { dg-final { scan-assembler-times {vsetvli\s+zero,\s*[a-x0-9]+,\s*e32,\s*mf2,\s*tu,\s*mu\s+vnsra\.wx\s+v[0-9]+,\s*v[0-9]+,\s*[a-x0-9]+,\s*v0.t} 1 } } */ +/* { dg-final { scan-assembler-times {vsetvli\s+zero,\s*[a-x0-9]+,\s*e32,\s*m1,\s*tu,\s*mu\s+vnsra\.wx\s+v[0-9]+,\s*v[0-9]+,\s*[a-x0-9]+,\s*v0.t} 1 } } */ +/* { dg-final { scan-assembler-times {vsetvli\s+zero,\s*[a-x0-9]+,\s*e32,\s*m2,\s*tu,\s*mu\s+vnsra\.wx\s+v[0-9]+,\s*v[0-9]+,\s*[a-x0-9]+,\s*v0.t} 1 } } */ +/* { dg-final { scan-assembler-times {vsetvli\s+zero,\s*[a-x0-9]+,\s*e32,\s*m4,\s*tu,\s*mu\s+vnsra\.wx\s+v[0-9]+,\s*v[0-9]+,\s*[a-x0-9]+,\s*v0.t} 1 } } */