From 533277ba752b9f89c3938571b21a1e70f050e94d Mon Sep 17 00:00:00 2001 From: Michael Meissner Date: Thu, 25 Jan 2018 01:09:19 +0000 Subject: [PATCH] re PR target/81550 (gcc.target/powerpc/loop_align.c fails starting with r250482) [gcc/testsuite] 2018-01-24 Michael Meissner PR target/81550 * gcc.target/powerpc/loop_align.c: Use unsigned long for the loop index instead of int, which allows IVOPTs to properly optimize the loop. From-SVN: r257038 --- gcc/testsuite/ChangeLog | 7 +++++++ gcc/testsuite/gcc.target/powerpc/loop_align.c | 4 ++-- 2 files changed, 9 insertions(+), 2 deletions(-) diff --git a/gcc/testsuite/ChangeLog b/gcc/testsuite/ChangeLog index 72efc3fbbbf..ba13b88f70a 100644 --- a/gcc/testsuite/ChangeLog +++ b/gcc/testsuite/ChangeLog @@ -1,3 +1,10 @@ +2018-01-24 Michael Meissner + + PR target/81550 + * gcc.target/powerpc/loop_align.c: Use unsigned long for the loop + index instead of int, which allows IVOPTs to properly optimize the + loop. + 2018-01-24 David Malcolm PR jit/82846 diff --git a/gcc/testsuite/gcc.target/powerpc/loop_align.c b/gcc/testsuite/gcc.target/powerpc/loop_align.c index 670fdc0d8b9..7eabc118217 100644 --- a/gcc/testsuite/gcc.target/powerpc/loop_align.c +++ b/gcc/testsuite/gcc.target/powerpc/loop_align.c @@ -4,8 +4,8 @@ /* { dg-options "-O2 -mcpu=power7 -falign-functions=16" } */ /* { dg-final { scan-assembler ".p2align 5,,31" } } */ -void f(double *a, double *b, double *c, int n) { - int i; +void f(double *a, double *b, double *c, unsigned long n) { + unsigned long i; for (i=0; i < n; i++) a[i] = b[i] + c[i]; } -- 2.30.2