From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 94782 invoked by alias); 10 Jan 2020 14:41:11 -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 94754 invoked by uid 89); 10 Jan 2020 14:41:10 -0000 Authentication-Results: sourceware.org; auth=none X-Spam-SWARE-Status: No, score=-8.7 required=5.0 tests=AWL,BAYES_00,RCVD_IN_DNSWL_NONE,SPF_HELO_PASS autolearn=ham version=3.3.1 spammy=resetting, Longer X-HELO: gateway23.websitewelcome.com Received: from gateway23.websitewelcome.com (HELO gateway23.websitewelcome.com) (192.185.50.120) by sourceware.org (qpsmtpd/0.93/v0.84-503-g423c35a) with ESMTP; Fri, 10 Jan 2020 14:41:09 +0000 Received: from cm12.websitewelcome.com (cm12.websitewelcome.com [100.42.49.8]) by gateway23.websitewelcome.com (Postfix) with ESMTP id 84A6527818 for ; Fri, 10 Jan 2020 08:34:03 -0600 (CST) Received: from box5379.bluehost.com ([162.241.216.53]) by cmsmtp with SMTP id pvMRij0SHW4frpvMRiyWQf; Fri, 10 Jan 2020 08:34:03 -0600 DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=tromey.com; s=default; h=Content-Type:MIME-Version:Message-ID:In-Reply-To:Date: References:Subject:Cc:To:From:Sender:Reply-To:Content-Transfer-Encoding: Content-ID:Content-Description:Resent-Date:Resent-From:Resent-Sender: Resent-To:Resent-Cc:Resent-Message-ID:List-Id:List-Help:List-Unsubscribe: List-Subscribe:List-Post:List-Owner:List-Archive; bh=eoRjfg37dTnMrJlyVlFjY92XDYLbw65Lhyecy0vlhUw=; b=NJFHjPbFMiQXR43UARWrHd4438 vcAV4yNMKOrnzgAeqsLAGSfU8d3IindBtnhp0HCXnhnu+DZYeGkiV+UXor87/h6fIpmRjcHkcbU+9 fLf0bqzVB/UM2CIAxINniXWxU; Received: from 75-166-123-50.hlrn.qwest.net ([75.166.123.50]:36090 helo=murgatroyd) by box5379.bluehost.com with esmtpsa (TLSv1.2:ECDHE-RSA-AES256-GCM-SHA384:256) (Exim 4.92) (envelope-from ) id 1ipvMR-0026vh-8Z; Fri, 10 Jan 2020 07:34:03 -0700 From: Tom Tromey To: Pedro Alves Cc: "Aktemur\, Tankut Baris" , "gdb-patches\@sourceware.org" , "Paunovic\, Aleksandar" Subject: Re: [PATCH] Switch the inferior too in switch_to_program_space_and_thread (Re: [PATCH v2 08/24] Introduce switch_to_inferior_no_thread) References: <20191017225026.30496-1-palves@redhat.com> <20191017225026.30496-9-palves@redhat.com> <489c25ee-b0ae-6a17-65cc-32c5d7c652d2@redhat.com> <9039e000-1d8c-ffcc-60bd-659b3a983a43@redhat.com> Date: Fri, 10 Jan 2020 14:41:00 -0000 In-Reply-To: <9039e000-1d8c-ffcc-60bd-659b3a983a43@redhat.com> (Pedro Alves's message of "Fri, 10 Jan 2020 02:02:58 +0000") Message-ID: <87lfqfwfc5.fsf@tromey.com> User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/26.3 (gnu/linux) MIME-Version: 1.0 Content-Type: text/plain X-SW-Source: 2020-01/txt/msg00251.txt.bz2 >>>>> "Pedro" == Pedro Alves writes: Pedro> The crash happens while doing a breakpoint re-set, called by Pedro> clear_symtab_users at the tail end of (3). That is, while recreating Pedro> breakpoints for the current program space, which is the program space Pedro> we're tearing down. During breakpoint re-set, we try to switch to the Pedro> new location's pspace (the current pspace set in (1), so the pspace Pedro> we're tearing down) with switch_to_program_space_and_thread, and that Pedro> hits the failed assertion. Whatever happened to fine-grained breakpoint resetting? Among other things maybe that would help with this sort of problem. Pedro> I'm not hard set on this approach though; I can go with adding the Pedro> symfile_add_flags parameter to program_space::free_all_objfiles if Pedro> people prefer that. This approach seems fine. Longer term I would like to get rid of clear_symtab_users. Maybe it could be replaced with more precisely targeted observers instead. thanks, Tom