From 7ba2d2344c508c825db800f0218f8121887c6852 Mon Sep 17 00:00:00 2001 From: Juzhe-Zhong Date: Tue, 7 Nov 2023 11:36:44 +0800 Subject: test: Fix FAIL of SAD tests for RVV RVV didn't explicitly enable SAD optab but we can vectorize it since loop vectorizer is able to recognize SAD pattern for RVV during analysis. Current scan check of explicit SAD pattern looks odd, it should be more reasonable to check recognition of SAD pattern during Loop vectorize analysis. Other SAD tests like slp-reduc-sad-2.c are checking pattern recognition instead of explicit pattern enable. Fix SAD dump check to fix the FAILS for RVV. gcc/testsuite/ChangeLog: * gcc.dg/vect/slp-reduc-sad.c: Fix check. * gcc.dg/vect/vect-reduc-sad.c: Ditto. --- gcc/testsuite/gcc.dg/vect/slp-reduc-sad.c | 2 +- gcc/testsuite/gcc.dg/vect/vect-reduc-sad.c | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) (limited to 'gcc') diff --git a/gcc/testsuite/gcc.dg/vect/slp-reduc-sad.c b/gcc/testsuite/gcc.dg/vect/slp-reduc-sad.c index faa1c16..977cfab 100644 --- a/gcc/testsuite/gcc.dg/vect/slp-reduc-sad.c +++ b/gcc/testsuite/gcc.dg/vect/slp-reduc-sad.c @@ -57,6 +57,6 @@ main () return 0; } -/* { dg-final { scan-tree-dump "sad pattern recognized" "vect" } } */ +/* { dg-final { scan-tree-dump "vect_recog_sad_pattern: detected" "vect" } } */ /* { dg-final { scan-tree-dump "vectorizing stmts using SLP" "vect" } } */ /* { dg-final { scan-tree-dump-times "vectorized 1 loops" 1 "vect" } } */ diff --git a/gcc/testsuite/gcc.dg/vect/vect-reduc-sad.c b/gcc/testsuite/gcc.dg/vect/vect-reduc-sad.c index 2f0bb69..08f7987 100644 --- a/gcc/testsuite/gcc.dg/vect/vect-reduc-sad.c +++ b/gcc/testsuite/gcc.dg/vect/vect-reduc-sad.c @@ -51,6 +51,6 @@ main (void) return 0; } -/* { dg-final { scan-tree-dump-times "sad pattern recognized" 1 "vect" } } */ +/* { dg-final { scan-tree-dump "vect_recog_sad_pattern: detected" "vect" } } */ /* { dg-final { scan-tree-dump-times "vectorized 1 loops" 1 "vect" } } */ -- cgit v1.1