From patchwork Tue Apr 14 11:45:17 2015 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Luis Machado X-Patchwork-Id: 6212 Received: (qmail 80940 invoked by alias); 14 Apr 2015 11:45:29 -0000 Mailing-List: contact gdb-patches-help@sourceware.org; run by ezmlm Precedence: bulk List-Id: List-Unsubscribe: List-Subscribe: List-Archive: List-Post: List-Help: , Sender: gdb-patches-owner@sourceware.org Delivered-To: mailing list gdb-patches@sourceware.org Received: (qmail 80909 invoked by uid 89); 14 Apr 2015 11:45:26 -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 X-HELO: relay1.mentorg.com Received: from relay1.mentorg.com (HELO relay1.mentorg.com) (192.94.38.131) by sourceware.org (qpsmtpd/0.93/v0.84-503-g423c35a) with ESMTP; Tue, 14 Apr 2015 11:45:25 +0000 Received: from svr-orw-fem-02x.mgc.mentorg.com ([147.34.96.206] helo=SVR-ORW-FEM-02.mgc.mentorg.com) by relay1.mentorg.com with esmtp id 1YhzHN-00077s-Ew from Luis_Gustavo@mentor.com ; Tue, 14 Apr 2015 04:45:21 -0700 Received: from [172.30.1.77] (147.34.91.1) by svr-orw-fem-02.mgc.mentorg.com (147.34.96.168) with Microsoft SMTP Server id 14.3.224.2; Tue, 14 Apr 2015 04:45:20 -0700 Message-ID: <552CFDCD.4030706@codesourcery.com> Date: Tue, 14 Apr 2015 08:45:17 -0300 From: Luis Machado Reply-To: Luis Machado User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:31.0) Gecko/20100101 Thunderbird/31.6.0 MIME-Version: 1.0 To: Pedro Alves , "'gdb-patches@sourceware.org'" Subject: Re: [PATCH] Harden gdb.base/bp-permanent.exp References: <5526B296.8040000@codesourcery.com> <5527A047.1030201@redhat.com> <5527D804.10709@codesourcery.com> <552C0212.5080102@codesourcery.com> <552CFA96.6070707@redhat.com> In-Reply-To: <552CFA96.6070707@redhat.com> X-IsSubscribed: yes On 04/14/2015 08:31 AM, Pedro Alves wrote: > Hi Luis, > > On 04/13/2015 06:51 PM, Luis Machado wrote: > >> I've pushed this now. > > I've just noticed this: > > -PASS: gdb.base/bp-permanent.exp: always_inserted=off, sw_watchpoint=0: setup: p /x addr_bp[0] = buffer[0] > -PASS: gdb.base/bp-permanent.exp: always_inserted=off, sw_watchpoint=0: setup: p /x addr_bp[1] = buffer[1] > -PASS: gdb.base/bp-permanent.exp: always_inserted=off, sw_watchpoint=0: setup: p /x addr_bp[2] = buffer[2] > -PASS: gdb.base/bp-permanent.exp: always_inserted=off, sw_watchpoint=0: setup: p /x addr_bp[3] = buffer[3] > +PASS: gdb.base/bp-permanent.exp: always_inserted=off, sw_watchpoint=0: setup: get size of instruction > +PASS: gdb.base/bp-permanent.exp: always_inserted=off, sw_watchpoint=0: setup: get size of instruction > +PASS: gdb.base/bp-permanent.exp: always_inserted=off, sw_watchpoint=0: setup: get size of instruction > +PASS: gdb.base/bp-permanent.exp: always_inserted=off, sw_watchpoint=0: setup: get size of instruction > > Obviously, "get size of instruction" is the wrong test message to > use here. Could you restore the old messages please? Oops, sorry. How about the attached? 2015-04-14 Luis Machado gdb/testsuite/ * gdb.base/bp-permanent.exp: Reinstate correct test message. diff --git a/gdb/testsuite/gdb.base/bp-permanent.exp b/gdb/testsuite/gdb.base/bp-permanent.exp index e802eee..4d7e519 100644 --- a/gdb/testsuite/gdb.base/bp-permanent.exp +++ b/gdb/testsuite/gdb.base/bp-permanent.exp @@ -104,6 +104,7 @@ proc test {always_inserted sw_watchpoint} { # to memory manually. set count [expr $address_after_bp - $address_bp] for {set i 0} {$i < $count} {incr i} { + set test "p /x addr_bp\[$i\] = buffer\[$i\]" gdb_test_multiple "p /x addr_bp\[$i\] = buffer\[$i\]" $test { -re "Cannot access memory at address $hex.*$gdb_prompt $" { # Some targets (QEMU for one) will disallow writes to the