diff options
Diffstat (limited to 'gcc/testsuite/gcc.dg/vect/vect-reduc-2.c')
-rw-r--r-- | gcc/testsuite/gcc.dg/vect/vect-reduc-2.c | 16 |
1 files changed, 7 insertions, 9 deletions
diff --git a/gcc/testsuite/gcc.dg/vect/vect-reduc-2.c b/gcc/testsuite/gcc.dg/vect/vect-reduc-2.c index ca1a3da07e3..ef4499f761d 100644 --- a/gcc/testsuite/gcc.dg/vect/vect-reduc-2.c +++ b/gcc/testsuite/gcc.dg/vect/vect-reduc-2.c @@ -8,14 +8,14 @@ /* Test vectorization of reduction of signed-int. */ -int main1 (int x, int max_result) +void main1 (int x, int max_result, int min_result) { int i; - int b[N] = {0,3,6,9,12,15,18,21,24,27,30,33,36,39,42,45}; - int c[N] = {0,1,2,3,4,5,6,7,8,9,10,11,12,13,14,15}; + int b[N] = {1,3,6,9,12,15,18,21,24,27,30,33,36,39,42,45}; + int c[N] = {1,1,2,3,4,5,6,7,8,9,10,11,12,13,14,15}; int diff = 0; int max = x; - int min = 10; + int min = x; for (i = 0; i < N; i++) { diff += (b[i] - c[i]); @@ -34,18 +34,16 @@ int main1 (int x, int max_result) abort (); if (max != max_result) abort (); - if (min != 0) + if (min != min_result) abort (); - - return 0; } int main (void) { check_vect (); - main1 (100, 100); - main1 (0, 15); + main1 (100, 100, 1); + main1 (0, 15, 0); return 0; } |