Hello,

The attached patch adds the test case from comment #3 of PR 38621 to the
test suite.

Tested with
make check-gcc RUNTESTFLAGS="compile.exp=pr38621.c --target_board=sh-sim
\{-m2/-ml,-m2/-mb,-m2a/-mb,-m2a-single/-mb,-m4/-ml,-m4/-mb,-m4-single/-ml,
-m4-single/-mb,-m4a-single/-ml,-m4a-single/-mb}"

OK?

Cheers,
Oleg

testsuite/ChangeLog:

        target PR/38621
        * gcc.c-torture/compile/pr38621.c: New.
Index: gcc/testsuite/gcc.c-torture/compile/pr38621.c
===================================================================
--- gcc/testsuite/gcc.c-torture/compile/pr38621.c	(revision 0)
+++ gcc/testsuite/gcc.c-torture/compile/pr38621.c	(revision 0)
@@ -0,0 +1,17 @@
+/* PR target/38621  */
+struct s
+{
+  char a[512];
+  int b;
+  int c;
+};
+
+long long
+foo (struct s *p, int m, int r)
+{
+  if (r == m)
+    p->b = 3;
+  p->c = 1;
+  return m;
+}
+

Reply via email to