This is the mail archive of the
gcc-patches@gcc.gnu.org
mailing list for the GCC project.
Re: [Patch] Testsuite fixes for failures caused by patch for PR 80925 - loop peeling and alignment
- From: Steve Ellcey <sellcey at cavium dot com>
- To: Richard Biener <richard dot guenther at gmail dot com>
- Cc: gcc-patches <gcc-patches at gcc dot gnu dot org>, rdapp at linux dot vnet dot ibm dot com
- Date: Fri, 28 Jul 2017 11:22:07 -0700
- Subject: Re: [Patch] Testsuite fixes for failures caused by patch for PR 80925 - loop peeling and alignment
- Authentication-results: sourceware.org; auth=none
- Authentication-results: spf=none (sender IP is ) smtp.mailfrom=Steve dot Ellcey at cavium dot com;
- References: <1501193805.28549.115.camel@cavium.com> <CAFiYyc0sR1TJUmiZbGkPxYFmK-wtRsoObyvfoJaXhnP9pMw0TQ@mail.gmail.com>
- Reply-to: sellcey at cavium dot com
- Spamdiagnosticmetadata: NSPM
- Spamdiagnosticoutput: 1:99
On Fri, 2017-07-28 at 09:47 +0200, Richard Biener wrote:
> On Fri, Jul 28, 2017 at 12:16 AM, Steve Ellcey <sellcey@cavium.com> wrote:
> >
> > Any comments from the power and/or vectorizer folks?
> On one side I'm inclined to simplify the testsuite by adding
> --param vect-max-peeling-for-alignment=0 in addition to
> -fno-vect-cost-model we already pass and override that in the
> tests that specifically exercise peeling for alignment (do we have
> any?).
> OTOH that would remove quite some testing coverage of prologue
> peeling.
>
> So ideally testresults would be clean with both no such --param
> and that --param added...
>
> I think most of the testcases you needed to adjust have nothing
> to do with peeling for alignment thus adding this --param just for
> those (and simplifying their dump scanning accordingly) is another
> pragmatic option.
>
> Adding yet another target (vect_peel_align) is IMHO not good,
> especially as this one depends on cost tuning and not HW
> features, so it's impossible(?) to dynamically compute it
> with a test compile for example (we _do_ want a clean
> vect.exp with any vector HW / tuning switch you add).
How about something like the following. I only fixed two of the tests,
I can follow up with more if this approach seems reasonable. I tested
this on aarch64 and x86_64.
Steve Ellcey
sellcey@cavium.com
2017-07-28 Steve Ellcey <sellcey@cavium.com>
PR tree-optimization/80925
* gcc.dg/vect/no-section-anchors-vect-69.c: Add
--param vect-max-peeling-for-alignment=0 option.
Remove unaligned access and peeling checks.
* gcc.dg/vect/section-anchors-vect-69.c: Ditto.
diff --git a/gcc/testsuite/gcc.dg/vect/no-section-anchors-vect-69.c b/gcc/testsuite/gcc.dg/vect/no-section-anchors-vect-69.c
index fe968de..1458ba6 100644
--- a/gcc/testsuite/gcc.dg/vect/no-section-anchors-vect-69.c
+++ b/gcc/testsuite/gcc.dg/vect/no-section-anchors-vect-69.c
@@ -1,5 +1,6 @@
/* { dg-require-effective-target vect_int } */
/* { dg-add-options bind_pic_locally } */
+/* { dg-additional-options "--param vect-max-peeling-for-alignment=0" } */
#include <stdarg.h>
#include "tree-vect.h"
@@ -114,7 +115,4 @@ int main (void)
}
/* { dg-final { scan-tree-dump-times "vectorized 4 loops" 1 "vect" } } */
-/* { dg-final { scan-tree-dump-times "Vectorizing an unaligned access" 0 "vect" } } */
-/* { dg-final { scan-tree-dump-times "Alignment of access forced using peeling" 2 "vect" { xfail { {! vector_alignment_reachable} || { vect_sizes_32B_16B} } } } } */
/* { dg-final { scan-tree-dump-times "Alignment of access forced using versioning" 1 "vect" { target { {! vector_alignment_reachable} && {! vect_hw_misalign} } } } } */
-/* { dg-final { scan-tree-dump-times "Alignment of access forced using peeling" 1 "vect" { target { {! vector_alignment_reachable} && {! vect_hw_misalign} } } } } */
diff --git a/gcc/testsuite/gcc.dg/vect/section-anchors-vect-69.c b/gcc/testsuite/gcc.dg/vect/section-anchors-vect-69.c
index 8c88e5f..26bcf4b0 100644
--- a/gcc/testsuite/gcc.dg/vect/section-anchors-vect-69.c
+++ b/gcc/testsuite/gcc.dg/vect/section-anchors-vect-69.c
@@ -1,4 +1,5 @@
/* { dg-require-effective-target section_anchors } */
+/* { dg-additional-options "--param vect-max-peeling-for-alignment=0" } */
#include <stdarg.h>
#include "tree-vect.h"
@@ -112,8 +113,6 @@ int main (void)
}
/* { dg-final { scan-tree-dump-times "vectorized 4 loops" 1 "vect" { target vect_int } } } */
-/* { dg-final { scan-tree-dump-times "Vectorizing an unaligned access" 0 "vect" } } */
/* Alignment forced using versioning until the pass that increases alignment
is extended to handle structs. */
-/* { dg-final { scan-tree-dump-times "Alignment of access forced using peeling" 2 "vect" { target {vect_int && vector_alignment_reachable } } } } */
/* { dg-final { scan-tree-dump-times "Alignment of access forced using versioning" 4 "vect" { target {vect_int && {! vector_alignment_reachable} } } } } */