From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 128432 invoked by alias); 18 Jul 2017 17:46:39 -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 128421 invoked by uid 89); 18 Jul 2017 17:46:38 -0000 Authentication-Results: sourceware.org; auth=none X-Virus-Found: No X-Spam-SWARE-Status: No, score=-1.9 required=5.0 tests=BAYES_00,RP_MATCHES_RCVD,SPF_HELO_PASS autolearn=ham version=3.3.2 spammy=offer X-HELO: mx1.redhat.com Received: from mx1.redhat.com (HELO mx1.redhat.com) (209.132.183.28) by sourceware.org (qpsmtpd/0.93/v0.84-503-g423c35a) with ESMTP; Tue, 18 Jul 2017 17:46:37 +0000 Received: from smtp.corp.redhat.com (int-mx01.intmail.prod.int.phx2.redhat.com [10.5.11.11]) (using TLSv1.2 with cipher AECDH-AES256-SHA (256/256 bits)) (No client certificate requested) by mx1.redhat.com (Postfix) with ESMTPS id E942861BBB for ; Tue, 18 Jul 2017 17:46:35 +0000 (UTC) DMARC-Filter: OpenDMARC Filter v1.3.2 mx1.redhat.com E942861BBB Authentication-Results: ext-mx10.extmail.prod.ext.phx2.redhat.com; dmarc=none (p=none dis=none) header.from=redhat.com Authentication-Results: ext-mx10.extmail.prod.ext.phx2.redhat.com; spf=pass smtp.mailfrom=palves@redhat.com DKIM-Filter: OpenDKIM Filter v2.11.0 mx1.redhat.com E942861BBB Received: from [127.0.0.1] (ovpn04.gateway.prod.ext.ams2.redhat.com [10.39.146.4]) by smtp.corp.redhat.com (Postfix) with ESMTP id 2690F7EE7B; Tue, 18 Jul 2017 17:46:34 +0000 (UTC) Subject: Re: [PATCH 2/2] Report stop locations in inlined functions. To: Keith Seitz , gdb-patches@sourceware.org References: <1499740601-15957-1-git-send-email-keiths@redhat.com> <1499740601-15957-2-git-send-email-keiths@redhat.com> <4bfba041-22f5-1650-1f83-0f8860f202fb@redhat.com> From: Pedro Alves Message-ID: <17ac2bdc-cd7b-d8f1-bf75-056fe87ca916@redhat.com> Date: Tue, 18 Jul 2017 17:46:00 -0000 User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:45.0) Gecko/20100101 Thunderbird/45.4.0 MIME-Version: 1.0 In-Reply-To: <4bfba041-22f5-1650-1f83-0f8860f202fb@redhat.com> Content-Type: text/plain; charset=windows-1252 Content-Transfer-Encoding: 7bit X-SW-Source: 2017-07/txt/msg00262.txt.bz2 On 07/18/2017 06:16 PM, Pedro Alves wrote: > On 07/11/2017 03:36 AM, Keith Seitz wrote: >> I don't quite like this, though. This solution involves calling >> decode_line_full, and that is really expensive, so I would be grateful if >> maintaienrs could offer advice on how to better tackle this. > > I'm still trying to grok these patches fully, but, shouldn't comparing > the breakpoint's bp_location's addresses work the same? I.e., with this, > gdb.opt/inline-break.exp still passes cleanly here: > Hmm, and with this direction, we may not even need the breakpoint_for_stop function. The location(s) that caused the stop is/are in the bpstat chain: stop_chain->bp_location_at->address etc. Using those also implicitly makes sure that you're only consulting locations that were inserted/enabled, as other not-enabled/inserted locations won't appear in the bpstat chain. Maybe we need to move this bit in infrun.c: /* See if there is a breakpoint/watchpoint/catchpoint/etc. that handles this event. */ ecs->event_thread->control.stop_bpstat = bpstat_stop_status (get_regcache_aspace (get_current_regcache ()), stop_pc, ecs->ptid, &ecs->ws, stop_chain); a bit above, before the skip_inline_frames call, and then you don't even need to pass down the bpstat to skip_inline_frames, as you can then access it from the thread directly? Thanks, Pedro Alves