public inbox for gcc-patches@gcc.gnu.org
 help / color / mirror / Atom feed
* [PATCH] testsuite/96147 - align vector access
@ 2021-01-15 13:05 Richard Biener
  0 siblings, 0 replies; only message in thread
From: Richard Biener @ 2021-01-15 13:05 UTC (permalink / raw)
  To: gcc-patches

This aligns p so that the testcase is meaningful for targets
without a hw misaligned access.

Pushed.

2021-01-15  Richard Biener  <rguenther@suse.de>

	PR testsuite/96147
	* gcc.dg/vect/bb-slp-32.c: Align p.
---
 gcc/testsuite/gcc.dg/vect/bb-slp-32.c | 1 +
 1 file changed, 1 insertion(+)

diff --git a/gcc/testsuite/gcc.dg/vect/bb-slp-32.c b/gcc/testsuite/gcc.dg/vect/bb-slp-32.c
index 020b6365e02..84cc4370f09 100644
--- a/gcc/testsuite/gcc.dg/vect/bb-slp-32.c
+++ b/gcc/testsuite/gcc.dg/vect/bb-slp-32.c
@@ -8,6 +8,7 @@ int foo (int *p, int a, int b)
   int x[4];
   int tem0, tem1, tem2, tem3;
   int sum = 0;
+  p = __builtin_assume_aligned (p, __BIGGEST_ALIGNMENT__);
   tem0 = p[0] + 1 + a;
   sum += tem0;
   x[0] = tem0;
-- 
2.26.2

^ permalink raw reply	[flat|nested] only message in thread

only message in thread, other threads:[~2021-01-15 13:05 UTC | newest]

Thread overview: (only message) (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2021-01-15 13:05 [PATCH] testsuite/96147 - align vector access Richard Biener

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