From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 13609 invoked by alias); 28 Mar 2014 13:14:59 -0000 Mailing-List: contact gdb-patches-help@sourceware.org; run by ezmlm Precedence: bulk List-Id: List-Subscribe: List-Archive: List-Post: List-Help: , Sender: gdb-patches-owner@sourceware.org Received: (qmail 13540 invoked by uid 89); 28 Mar 2014 13:14:59 -0000 Authentication-Results: sourceware.org; auth=none X-Virus-Found: No X-Spam-SWARE-Status: No, score=-1.6 required=5.0 tests=AWL,BAYES_00 autolearn=ham version=3.3.2 X-HELO: rock.gnat.com Received: from rock.gnat.com (HELO rock.gnat.com) (205.232.38.15) by sourceware.org (qpsmtpd/0.93/v0.84-503-g423c35a) with (AES256-SHA encrypted) ESMTPS; Fri, 28 Mar 2014 13:14:58 +0000 Received: from localhost (localhost.localdomain [127.0.0.1]) by filtered-rock.gnat.com (Postfix) with ESMTP id 6E3F11164F1; Fri, 28 Mar 2014 09:14:56 -0400 (EDT) Received: from rock.gnat.com ([127.0.0.1]) by localhost (rock.gnat.com [127.0.0.1]) (amavisd-new, port 10024) with LMTP id UJMyHwGVUJfR; Fri, 28 Mar 2014 09:14:56 -0400 (EDT) Received: from joel.gnat.com (localhost.localdomain [127.0.0.1]) by rock.gnat.com (Postfix) with ESMTP id 3BA0B11646B; Fri, 28 Mar 2014 09:14:56 -0400 (EDT) Received: by joel.gnat.com (Postfix, from userid 1000) id A4C06E079B; Fri, 28 Mar 2014 06:14:55 -0700 (PDT) Date: Fri, 28 Mar 2014 13:14:00 -0000 From: Joel Brobecker To: Anton Blanchard Cc: gdb-patches@sourceware.org, emachado@linux.vnet.ibm.com, luis_gustavo@mentor.com, ulrich.weigand@de.ibm.com Subject: Re: [PATCH 3/4] Add multiple branches to ppc64 single step through atomic sequence testcase Message-ID: <20140328131455.GF4030@adacore.com> References: <1395978111-30706-1-git-send-email-anton@samba.org> <1395978111-30706-3-git-send-email-anton@samba.org> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <1395978111-30706-3-git-send-email-anton@samba.org> User-Agent: Mutt/1.5.21 (2010-09-15) X-SW-Source: 2014-03/txt/msg00657.txt.bz2 > Test 3 conditional branches in an atomic sequence, 2 to the same > destination. > > gdb/testsuite/ > 2014-03-28 Anton Blanchard > > * gdb.arch/ppc64-atomic-inst.s: Add second and third branch > inside atomic sequence. Just a thought - is there no value in keeping the old assembly code and creating an additional testcase? It would be very similar to the one you already have, but then you'd be covering most cases... Otherwise, the patch seems fine. > --- > gdb/testsuite/gdb.arch/ppc64-atomic-inst.s | 18 +++++++++++++++--- > 1 file changed, 15 insertions(+), 3 deletions(-) > > diff --git a/gdb/testsuite/gdb.arch/ppc64-atomic-inst.s b/gdb/testsuite/gdb.arch/ppc64-atomic-inst.s > index 15ccfd9..0521170 100644 > --- a/gdb/testsuite/gdb.arch/ppc64-atomic-inst.s > +++ b/gdb/testsuite/gdb.arch/ppc64-atomic-inst.s > @@ -39,18 +39,30 @@ main: > 1: lwarx 5,0,4 > cmpwi 5,0 > bne 2f > + cmpwi 5,1 > + beq 3f > + cmpwi 5,2 > + beq 3f /* branch to same destination */ > addi 5,5,1 > stwcx. 5,0,4 > bne 1b > > - std 0,0(4) > -2: ldarx 5,0,4 > +2: nop > + > +3: std 0,0(4) > +1: ldarx 5,0,4 > cmpdi 5,0 > - bne 3f > + bne 2f > + cmpdi 5,1 > + beq 3f > + cmpwi 5,2 > + beq 3f /* branch to same destination */ > addi 5,5,1 > stdcx. 5,0,4 > bne 1b > > +2: nop > + > 3: li 3,0 > blr > > -- > 1.8.3.2 -- Joel