From patchwork Wed May 4 09:55:42 2016 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Christophe Lyon X-Patchwork-Id: 618344 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]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by ozlabs.org (Postfix) with ESMTPS id 3r0D2R4CZGz9t3v for ; Wed, 4 May 2016 19:56:14 +1000 (AEST) Authentication-Results: ozlabs.org; dkim=pass (1024-bit key; unprotected) header.d=gcc.gnu.org header.i=@gcc.gnu.org header.b=Mj7S9ZlV; dkim-atps=neutral DomainKey-Signature: a=rsa-sha1; c=nofws; d=gcc.gnu.org; h=list-id :list-unsubscribe:list-archive:list-post:list-help:sender :mime-version:in-reply-to:references:date:message-id:subject :from:to:cc:content-type; q=dns; s=default; b=aGLhinNBossEZ6ezT2 3RT2gLBd1CFWnACjLqp8HpTmh5+ppJIvWFPpbiA7oPU6D9+LeqJ6S1ueS9x2b9SU VjeZErwEEnH/wcTd0Jx4kuneWvU1J3CwCYRcvodBamxEEyDZXvizIyrk48g8RZcd 8SREQ/u0rZj3MYjIQmSLkNI8Q= DKIM-Signature: v=1; a=rsa-sha1; c=relaxed; d=gcc.gnu.org; h=list-id :list-unsubscribe:list-archive:list-post:list-help:sender :mime-version:in-reply-to:references:date:message-id:subject :from:to:cc:content-type; s=default; bh=xgPnDaaRq9ufqYJZOkbSZ3rC VBA=; b=Mj7S9ZlVn/oVraZWGUGa0qNj+jgnKS7p2jCME/rMVcmnqcGwOYVqwIIl lY/uPBUiAFsuy0xAe1ahkEMeALSvDeh/oO1Vqi0VdLwcYnJUY3miHdPjRmUgHpsj Vj4QoPBMJk9BUOHnl0dCu3HUTylham8a9n706ziXj7M8BF6H/N4= Received: (qmail 20122 invoked by alias); 4 May 2016 09:55:56 -0000 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 Received: (qmail 20103 invoked by uid 89); 4 May 2016 09:55:54 -0000 Authentication-Results: sourceware.org; auth=none X-Virus-Found: No X-Spam-SWARE-Status: No, score=-2.4 required=5.0 tests=AWL, BAYES_00, RCVD_IN_DNSWL_LOW, SPF_PASS autolearn=ham version=3.3.2 spammy=D*foss.arm.com, kyrylo.tkachov@foss.arm.com, kyrylotkachovfossarmcom, H*f:sk:5729B62 X-HELO: mail-qg0-f43.google.com Received: from mail-qg0-f43.google.com (HELO mail-qg0-f43.google.com) (209.85.192.43) by sourceware.org (qpsmtpd/0.93/v0.84-503-g423c35a) with (AES128-GCM-SHA256 encrypted) ESMTPS; Wed, 04 May 2016 09:55:44 +0000 Received: by mail-qg0-f43.google.com with SMTP id f74so20227095qge.2 for ; Wed, 04 May 2016 02:55:44 -0700 (PDT) X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20130820; h=x-gm-message-state:mime-version:in-reply-to:references:date :message-id:subject:from:to:cc; bh=+PtTzVekCiQ4Gj5PRbEu4KrwhEJUxQgKb8WudXS9HAg=; b=CSyBV4dotnnuo0pO1iLpLoCL6jSZZSY9m05l8HygQjH6Yn1aFWKoj14p+31936SzyD edewGQONcKyxGkivc/cqtd7PDS7YELdPGkYLD8dCo6z+/Rmr/UEUWtYFfjx3Dxxv4zEw 8k2bpwO7m9Lg9ZwF/SNsBpDrH0QbXAxwRZ/ZpSgFmTV80sMwiqReN/+hBbx2MSSsoDDq 87eC/XgQqyj0IOSGI0hxR1Me6lisNHd4mArO42e2Ak8trrdOMJQSTct1L+mWEZ8mTRf8 2iHe8quYWEEN5EZsqP+ewhLm35X9w2D84bLTTPn5prwhJhQzf1lIcczrar+qq4jA9Rm2 Co1A== X-Gm-Message-State: AOPr4FUvpxZ0woZp2mSzG63vSDVxuMKGtKMwXhN9SF7RLdL9Rn0qCOZL4oSa5tLDWvwrfYjkglbM5OZMM9Pf3L8/ MIME-Version: 1.0 X-Received: by 10.140.235.14 with SMTP id g14mr7274836qhc.86.1462355742666; Wed, 04 May 2016 02:55:42 -0700 (PDT) Received: by 10.140.99.73 with HTTP; Wed, 4 May 2016 02:55:42 -0700 (PDT) In-Reply-To: <5729B622.1060001@foss.arm.com> References: <5729B622.1060001@foss.arm.com> Date: Wed, 4 May 2016 11:55:42 +0200 Message-ID: Subject: Re: [testuite,AArch64] Make scan for 'br' more robust From: Christophe Lyon To: Kyrill Tkachov Cc: "gcc-patches@gcc.gnu.org" X-IsSubscribed: yes On 4 May 2016 at 10:43, Kyrill Tkachov wrote: > > Hi Christophe, > > > On 02/05/16 12:50, Christophe Lyon wrote: >> >> Hi, >> >> I've noticed a "regression" of AArch64's noplt_3.c in the gcc-6-branch >> because my validation script adds the branch name to gcc/REVISION. >> >> As a result scan-assembler-times "br" also matched "gcc-6-branch", >> hence the failure. >> >> The small attached patch replaces "br" by "br\t" to fix the problem. >> >> I've also made a similar change to tail_indirect_call_1 although the >> problem did not happen for this test because it uses scan-assembler >> instead of scan-assembler-times. I think it's better to make it more >> robust too. >> >> OK? >> >> Christophe > > > diff --git a/gcc/testsuite/gcc.target/aarch64/noplt_3.c > b/gcc/testsuite/gcc.target/aarch64/noplt_3.c > index ef6e65d..a382618 100644 > --- a/gcc/testsuite/gcc.target/aarch64/noplt_3.c > +++ b/gcc/testsuite/gcc.target/aarch64/noplt_3.c > @@ -16,5 +16,5 @@ cal_novalue (int a) > dec (a); > } > -/* { dg-final { scan-assembler-times "br" 2 } } */ > +/* { dg-final { scan-assembler-times "br\t" 2 } } */ > /* { dg-final { scan-assembler-not "b\t" } } */ > diff --git a/gcc/testsuite/gcc.target/aarch64/tail_indirect_call_1.c > b/gcc/testsuite/gcc.target/aarch64/tail_indirect_call_1.c > index 4759d20..e863323 100644 > --- a/gcc/testsuite/gcc.target/aarch64/tail_indirect_call_1.c > +++ b/gcc/testsuite/gcc.target/aarch64/tail_indirect_call_1.c > @@ -3,7 +3,7 @@ > typedef void FP (int); > -/* { dg-final { scan-assembler "br" } } */ > +/* { dg-final { scan-assembler "br\t" } } */ > > Did you mean to make this scan-assembler-times as well? > I kept the changes minimal, but you are right, it would be more robust as attached. OK for trunk and gcc-6 branch? Thanks Christophe > Kyrill > > > 2016-05-04 Christophe Lyon * gcc.target/aarch64/noplt_3.c: Scan for "br\t". * gcc.target/aarch64/tail_indirect_call_1.c: Scan for "br\t", "blr\t" and switch to scan-assembler-times. diff --git a/gcc/testsuite/gcc.target/aarch64/noplt_3.c b/gcc/testsuite/gcc.target/aarch64/noplt_3.c index ef6e65d..a382618 100644 --- a/gcc/testsuite/gcc.target/aarch64/noplt_3.c +++ b/gcc/testsuite/gcc.target/aarch64/noplt_3.c @@ -16,5 +16,5 @@ cal_novalue (int a) dec (a); } -/* { dg-final { scan-assembler-times "br" 2 } } */ +/* { dg-final { scan-assembler-times "br\t" 2 } } */ /* { dg-final { scan-assembler-not "b\t" } } */ diff --git a/gcc/testsuite/gcc.target/aarch64/tail_indirect_call_1.c b/gcc/testsuite/gcc.target/aarch64/tail_indirect_call_1.c index 4759d20..de8f12d 100644 --- a/gcc/testsuite/gcc.target/aarch64/tail_indirect_call_1.c +++ b/gcc/testsuite/gcc.target/aarch64/tail_indirect_call_1.c @@ -3,8 +3,8 @@ typedef void FP (int); -/* { dg-final { scan-assembler "br" } } */ -/* { dg-final { scan-assembler-not "blr" } } */ +/* { dg-final { scan-assembler-times "br\t" 2 } } */ +/* { dg-final { scan-assembler-not "blr\t" } } */ void f1 (FP fp, int n) {