From patchwork Mon Dec 12 08:32:02 2011 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Uros Bizjak X-Patchwork-Id: 130671 Return-Path: X-Original-To: incoming@patchwork.ozlabs.org Delivered-To: patchwork-incoming@bilbo.ozlabs.org Received: from sourceware.org (server1.sourceware.org [209.132.180.131]) by ozlabs.org (Postfix) with SMTP id C7968B6F9A for ; Mon, 12 Dec 2011 19:32:20 +1100 (EST) Received: (qmail 4829 invoked by alias); 12 Dec 2011 08:32:19 -0000 Received: (qmail 4814 invoked by uid 22791); 12 Dec 2011 08:32:16 -0000 X-SWARE-Spam-Status: No, hits=-2.3 required=5.0 tests=AWL, BAYES_00, DKIM_SIGNED, DKIM_VALID, DKIM_VALID_AU, FREEMAIL_FROM, RCVD_IN_DNSWL_LOW, TW_AV X-Spam-Check-By: sourceware.org Received: from mail-gy0-f175.google.com (HELO mail-gy0-f175.google.com) (209.85.160.175) by sourceware.org (qpsmtpd/0.43rc1) with ESMTP; Mon, 12 Dec 2011 08:32:03 +0000 Received: by ghrr13 with SMTP id r13so4145539ghr.20 for ; Mon, 12 Dec 2011 00:32:02 -0800 (PST) MIME-Version: 1.0 Received: by 10.236.187.97 with SMTP id x61mr4110565yhm.97.1323678722789; Mon, 12 Dec 2011 00:32:02 -0800 (PST) Received: by 10.147.133.6 with HTTP; Mon, 12 Dec 2011 00:32:02 -0800 (PST) Date: Mon, 12 Dec 2011 09:32:02 +0100 Message-ID: Subject: Re: [Patch] Adjust diag-scans in vect-tests to fix fails on AVX/AVX2 From: Uros Bizjak To: gcc-patches@gcc.gnu.org Cc: Michael Zolotukhin , Igor Zamyatin , Kirill Yukhin Mailing-List: contact gcc-patches-help@gcc.gnu.org; run by ezmlm Precedence: bulk List-Id: List-Unsubscribe: List-Archive: List-Post: List-Help: Sender: gcc-patches-owner@gcc.gnu.org Delivered-To: mailing list gcc-patches@gcc.gnu.org Hello! > This patch fixes dg-final scans in tests from vect.exp suite, which > currently fail when avx2 is used. using peeling" 2 "vect" { target {! vect_multiple_sizes} } } } */ +/* { dg-final { scan-tree-dump-times "Alignment of access forced using peeling" 2 "vect" { xfail vect_multiple_sizes} } } */ /* { dg-final { cleanup-tree-dump "vect" } } */ Please do not add xfails through the patch, xfail means that a problem was identified and will someday be fixed. In the above case, just add target condition, no need for xfailed scan. If I'm not missing simething, you can probably remove all introduced xfails, just add new target conditions. # Return 1 if avx instructions can be compiled. +proc check_effective_explicit_target_avx { } { + return [check_no_messages_and_pattern e_avx "!__builtin_ia32_vzeroall" assembly { + void _mm256_zeroall (void) + { + __builtin_ia32_vzeroall (); + } + } "-O2" ] +} Please use # Return true if we are compiling for AVX target. proc check_avx_available { } { return [check_no_compiler_messages avx_available assembly { #ifndef __AVX__ #error unsupported #endif } ""] } Uros. --- a/gcc/testsuite/gcc.dg/vect/no-section-anchors-vect-31.c +++ b/gcc/testsuite/gcc.dg/vect/no-section-anchors-vect-31.c @@ -88,5 +88,6 @@ 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" } } */ +/* { dg-final { scan-tree-dump-times "Alignment of access forced