public inbox for gcc-patches@gcc.gnu.org
 help / color / mirror / Atom feed
* [PATCH] RISC-V: Add testcase for PR114749.
@ 2024-04-25 11:23 Robin Dapp
  2024-04-25 12:04 ` juzhe.zhong
  0 siblings, 1 reply; 2+ messages in thread
From: Robin Dapp @ 2024-04-25 11:23 UTC (permalink / raw)
  To: gcc-patches
  Cc: rdapp.gcc, palmer, Kito Cheng, juzhe.zhong, jeffreyalaw,
	Patrick O'Neill

Hi,

this adds a test case for PR114749.
Going to commit as obvious unless somebody complains.

Regards
 Robin

gcc/testsuite/ChangeLog:

	PR tree-optimization/114749

	* gcc.target/riscv/rvv/autovec/pr114749.c: New test.
---
 .../gcc.target/riscv/rvv/autovec/pr114749.c       | 15 +++++++++++++++
 1 file changed, 15 insertions(+)
 create mode 100644 gcc/testsuite/gcc.target/riscv/rvv/autovec/pr114749.c

diff --git a/gcc/testsuite/gcc.target/riscv/rvv/autovec/pr114749.c b/gcc/testsuite/gcc.target/riscv/rvv/autovec/pr114749.c
new file mode 100644
index 00000000000..6733b0481a6
--- /dev/null
+++ b/gcc/testsuite/gcc.target/riscv/rvv/autovec/pr114749.c
@@ -0,0 +1,15 @@
+/* { dg-do compile } */
+/* { dg-options "-march=rv64gcv_zvl128b -mabi=lp64d -fwhole-program -O3 -mrvv-vector-bits=zvl" } */
+
+extern int a[];
+extern char b[];
+int c = 24;
+_Bool d[24][24][24];
+_Bool (*e)[24][24] = d;
+int main() {
+  for (short f = 0; f < 24; f += 3)
+    for (unsigned g = 0; g < (char)c; g += 2) {
+      a[f] = 0;
+      b[g] |= ({ e[f][f][f]; });
+    }
+}
-- 
2.44.0

^ permalink raw reply	[flat|nested] 2+ messages in thread

* Re: [PATCH] RISC-V: Add testcase for PR114749.
  2024-04-25 11:23 [PATCH] RISC-V: Add testcase for PR114749 Robin Dapp
@ 2024-04-25 12:04 ` juzhe.zhong
  0 siblings, 0 replies; 2+ messages in thread
From: juzhe.zhong @ 2024-04-25 12:04 UTC (permalink / raw)
  To: Robin Dapp, gcc-patches
  Cc: Robin Dapp, palmer, kito.cheng, jeffreyalaw, Patrick O'Neill

[-- Attachment #1: Type: text/plain, Size: 1348 bytes --]

LGTM



juzhe.zhong@rivai.ai
 
From: Robin Dapp
Date: 2024-04-25 19:23
To: gcc-patches
CC: rdapp.gcc; palmer; Kito Cheng; juzhe.zhong@rivai.ai; jeffreyalaw; Patrick O'Neill
Subject: [PATCH] RISC-V: Add testcase for PR114749.
Hi,
 
this adds a test case for PR114749.
Going to commit as obvious unless somebody complains.
 
Regards
Robin
 
gcc/testsuite/ChangeLog:
 
PR tree-optimization/114749
 
* gcc.target/riscv/rvv/autovec/pr114749.c: New test.
---
.../gcc.target/riscv/rvv/autovec/pr114749.c       | 15 +++++++++++++++
1 file changed, 15 insertions(+)
create mode 100644 gcc/testsuite/gcc.target/riscv/rvv/autovec/pr114749.c
 
diff --git a/gcc/testsuite/gcc.target/riscv/rvv/autovec/pr114749.c b/gcc/testsuite/gcc.target/riscv/rvv/autovec/pr114749.c
new file mode 100644
index 00000000000..6733b0481a6
--- /dev/null
+++ b/gcc/testsuite/gcc.target/riscv/rvv/autovec/pr114749.c
@@ -0,0 +1,15 @@
+/* { dg-do compile } */
+/* { dg-options "-march=rv64gcv_zvl128b -mabi=lp64d -fwhole-program -O3 -mrvv-vector-bits=zvl" } */
+
+extern int a[];
+extern char b[];
+int c = 24;
+_Bool d[24][24][24];
+_Bool (*e)[24][24] = d;
+int main() {
+  for (short f = 0; f < 24; f += 3)
+    for (unsigned g = 0; g < (char)c; g += 2) {
+      a[f] = 0;
+      b[g] |= ({ e[f][f][f]; });
+    }
+}
-- 
2.44.0
 

^ permalink raw reply	[flat|nested] 2+ messages in thread

end of thread, other threads:[~2024-04-25 12:04 UTC | newest]

Thread overview: 2+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2024-04-25 11:23 [PATCH] RISC-V: Add testcase for PR114749 Robin Dapp
2024-04-25 12:04 ` juzhe.zhong

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).