From: Lehua Ding <lehua.ding@rivai.ai>
To: gcc-patches@gcc.gnu.org, mliska@suse.cz
Subject: [PATCH] testsuite: fix the condition bug in tsvc s176
Date: Thu, 8 Jun 2023 19:23:51 +0800 [thread overview]
Message-ID: <20230608112351.207461-1-lehua.ding@rivai.ai> (raw)
Hi,
This patch fixes the problem that the loop in the tsvc s176 function is
optimized and removed because `iterations/LEN_1D` is 0 (where iterations
is set to 10000, LEN_1D is set to 32000 in tsvc.h).
This testcase passed on x86 and AArch64 system.
Best,
Lehua
gcc/testsuite/ChangeLog:
* gcc.dg/vect/tsvc/vect-tsvc-s176.c: adjust iterations
---
gcc/testsuite/gcc.dg/vect/tsvc/vect-tsvc-s176.c | 4 ++--
1 file changed, 2 insertions(+), 2 deletions(-)
diff --git a/gcc/testsuite/gcc.dg/vect/tsvc/vect-tsvc-s176.c b/gcc/testsuite/gcc.dg/vect/tsvc/vect-tsvc-s176.c
index 79faf7fdb9e4..365e5205982b 100644
--- a/gcc/testsuite/gcc.dg/vect/tsvc/vect-tsvc-s176.c
+++ b/gcc/testsuite/gcc.dg/vect/tsvc/vect-tsvc-s176.c
@@ -14,7 +14,7 @@ real_t s176(struct args_t * func_args)
initialise_arrays(__func__);
int m = LEN_1D/2;
- for (int nl = 0; nl < 4*(iterations/LEN_1D); nl++) {
+ for (int nl = 0; nl < 4*(10*iterations/LEN_1D); nl++) {
for (int j = 0; j < (LEN_1D/2); j++) {
for (int i = 0; i < m; i++) {
a[i] += b[i+m-j-1] * c[j];
@@ -39,4 +39,4 @@ int main (int argc, char **argv)
return 0;
}
-/* { dg-final { scan-tree-dump "vectorized 1 loops" "vect" { xfail *-*-* } } } */
+/* { dg-final { scan-tree-dump "vectorized 1 loops" "vect" } } */
--
2.36.1
next reply other threads:[~2023-06-08 11:23 UTC|newest]
Thread overview: 6+ messages / expand[flat|nested] mbox.gz Atom feed top
2023-06-08 11:23 Lehua Ding [this message]
2023-06-09 8:58 ` Richard Biener
2023-06-09 9:57 Lehua Ding
2023-06-09 11:56 ` Richard Biener
2023-06-09 13:29 ` Jeff Law
2023-06-09 13:49 ` Lehua Ding
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=20230608112351.207461-1-lehua.ding@rivai.ai \
--to=lehua.ding@rivai.ai \
--cc=gcc-patches@gcc.gnu.org \
--cc=mliska@suse.cz \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).