From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 21060 invoked by alias); 15 Sep 2011 15:53:21 -0000 Received: (qmail 21043 invoked by uid 22791); 15 Sep 2011 15:53:19 -0000 X-SWARE-Spam-Status: No, hits=-1.8 required=5.0 tests=AWL,BAYES_00 X-Spam-Check-By: sourceware.org Received: from relay1.mentorg.com (HELO relay1.mentorg.com) (192.94.38.131) by sourceware.org (qpsmtpd/0.43rc1) with ESMTP; Thu, 15 Sep 2011 15:53:01 +0000 Received: from nat-ies.mentorg.com ([192.94.31.2] helo=EU1-MAIL.mgc.mentorg.com) by relay1.mentorg.com with esmtp id 1R4EFI-0000Ua-Kg from pedro_alves@mentor.com for gdb-patches@sourceware.org; Thu, 15 Sep 2011 08:53:00 -0700 Received: from scottsdale.localnet ([172.16.63.104]) by EU1-MAIL.mgc.mentorg.com with Microsoft SMTPSVC(6.0.3790.1830); Thu, 15 Sep 2011 16:52:58 +0100 From: Pedro Alves To: Yao Qi Subject: Re: [patch 2/2] Displaced stepping across fork/vfork : test case Date: Thu, 15 Sep 2011 16:13:00 -0000 User-Agent: KMail/1.13.6 (Linux/2.6.38-11-generic; KDE/4.7.0; x86_64; ; ) Cc: gdb-patches@sourceware.org References: <4E6C06E4.7010302@codesourcery.com> <201109141255.02766.pedro@codesourcery.com> <4E721948.5080407@codesourcery.com> In-Reply-To: <4E721948.5080407@codesourcery.com> MIME-Version: 1.0 Content-Type: Text/Plain; charset="iso-8859-15" Content-Transfer-Encoding: 7bit Message-Id: <201109151652.57149.pedro@codesourcery.com> X-IsSubscribed: yes 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 X-SW-Source: 2011-09/txt/msg00276.txt.bz2 On Thursday 15 September 2011 16:27:04, Yao Qi wrote: > This is improved by adding another matching in inserting breakpoint on > syscall insns like this, ... > + set syscall_insn_bp 0 > + gdb_test_multiple "break \*$syscall_insn_addr" "break on syscall insn" { > + -re "Breakpoint (\[0-9\]*) at .*$gdb_prompt $" { > + set syscall_insn_bp $expect_out(1,string) > + pass "break on syscall insns" > + } > + -re "Cannot insert breakpoint .*${gdb_prompt} $" { > + # This syscall insn may be in vsyscall page, and we can't set a breakpoint > + # there on some systems. > + fail "break on syscall insns" Please don't make this is a fail. It is not GDB's fault. "unsupported" or "xfail" would be better. > + set pf_prefix $old_pf_prefix > + return -1 > + } > + } But this won't work as is. Breakpoints will only be inserted on the next resume, not immediately. Unless you enable always-inserted mode, that is. -- Pedro Alves