From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 53330 invoked by alias); 21 Feb 2019 12:13:20 -0000 Mailing-List: contact gdb-help@sourceware.org; run by ezmlm Precedence: bulk List-Id: List-Subscribe: List-Archive: List-Post: List-Help: , Sender: gdb-owner@sourceware.org Received: (qmail 52275 invoked by uid 89); 21 Feb 2019 12:13:20 -0000 Authentication-Results: sourceware.org; auth=none X-Spam-SWARE-Status: No, score=-6.9 required=5.0 tests=BAYES_00,GIT_PATCH_2,HTML_MESSAGE,KAM_SHORT,RCVD_IN_DNSWL_NONE,SPF_PASS autolearn=ham version=3.3.2 spammy=resumed, supplier, H*c:alternative, customer X-HELO: mail-it1-f174.google.com Received: from mail-it1-f174.google.com (HELO mail-it1-f174.google.com) (209.85.166.174) by sourceware.org (qpsmtpd/0.93/v0.84-503-g423c35a) with ESMTP; Thu, 21 Feb 2019 12:13:18 +0000 Received: by mail-it1-f174.google.com with SMTP id l66so22415817itg.3 for ; Thu, 21 Feb 2019 04:13:18 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=undo-io.20150623.gappssmtp.com; s=20150623; h=mime-version:references:in-reply-to:from:date:message-id:subject:to :cc; bh=jKa+FQRYUzG93BiSsfIhVf94vUlrTa1ktoqiWCfsqnw=; b=Q1h6JHLGQQLf/S2Lg1vWdUImuseUoeE9c+2cM840u+G8y6+On670wAJqBc3+CHm+Rc HEdJcLte85inHL3lU1ggiqvDHtURkpOT+04DqFnrlJg9L/BNrZdw2xYs9oGN2W7y2pED yflLLMLhQTzsyVE3wTcQRKJZzrYV4CkkgOtL4OpjTfp812BS8AdsYYOI+8KPe7h/PAIR IGBAUgtuBAz5QTJtuTWxXYzGgR4Ztya1bxqo5M9lBBgYs1h9aNMIRHMfhmhdS33WArFl Bd0YF0M+Nuk5TO0qBe9r7is18d3xW3nbxL4BEwILPDgxQk7i0Kem1mFCv4kdi/Mrrz+H aQBw== MIME-Version: 1.0 References: In-Reply-To: From: David Griffiths Date: Thu, 21 Feb 2019 12:13:00 -0000 Message-ID: Subject: Re: "finish" command leads to SIGTRAP To: Pedro Alves Cc: gdb@sourceware.org Content-Type: text/plain; charset="UTF-8" X-IsSubscribed: yes X-SW-Source: 2019-02/txt/msg00039.txt.bz2 Ok thanks, did that. If I compare the output for the bad case with the good case, this seems to be the main difference: < infrun: proceed: resuming Thread 0x7ffff7fd8700 (LWP 12901) < infrun: resume (step=0, signal=GDB_SIGNAL_0), trap_expected=0, current thread [Thread 0x7ffff7fd8700 (LWP 12901)] at 0x7ffff6d33b00 < LLR: Preparing to resume Thread 0x7ffff7fd8700 (LWP 12901), 0, inferior_ptid Thread 0x7ffff7fd8700 (LWP 12901) < LLR: PTRACE_CONT Thread 0x7ffff7fd8700 (LWP 12901), 0 (resume event thread) --- > infrun: step-over queue now empty > infrun: resuming [Thread 0x7ffff7fd8700 (LWP 12901)] for step-over > infrun: resume (step=1, signal=GDB_SIGNAL_0), trap_expected=1, current thread [Thread 0x7ffff7fd8700 (LWP 12901)] at 0x7ffff6d33b00 > LLR: Preparing to step Thread 0x7ffff7fd8700 (LWP 12901), 0, inferior_ptid Thread 0x7ffff7fd8700 (LWP 12901) > LLR: PTRACE_SINGLESTEP Thread 0x7ffff7fd8700 (LWP 12901), 0 (resume event thread) 10a11 > infrun: proceed: [Thread 0x7ffff7fd8700 (LWP 12901)] resumed 27c28,60 < infrun: random signal (GDB_SIGNAL_TRAP) --- > infrun: no stepping, continue > infrun: resume (step=0, signal=GDB_SIGNAL_0), trap_expected=0, current thread [Thread 0x7ffff7fd8700 (LWP 12901)] at 0x7ffff6d33b01 Cheers, David On Thu, 21 Feb 2019 at 11:24, Pedro Alves wrote: > On 02/21/2019 11:21 AM, David Griffiths wrote: > > > > I need it to work because I'm trying to automate something via gdb/MI. > Any > > suggestions as to how to debug this would be very welcome. > > Start with "set debug infrun 1". > > And then "set debug lin-lwp 1" if debugging natively, or > "set debug remote 1" if using the remote serial protocol. > > Thanks, > Pedro Alves > -- David Griffiths, Senior Software Engineer Undo | Resolve even the most challenging software defects with software flight recorder technology Software reliability report: optimizing the software supplier and customer relationship