From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from smtp.polymtl.ca (smtp.polymtl.ca [132.207.4.11]) by sourceware.org (Postfix) with ESMTPS id BEC563858D1E for ; Tue, 3 Jan 2023 19:09:07 +0000 (GMT) Received: from simark.ca (simark.ca [158.69.221.121]) (authenticated bits=0) by smtp.polymtl.ca (8.14.7/8.14.7) with ESMTP id 303J921l011485 (version=TLSv1/SSLv3 cipher=ECDHE-RSA-AES256-GCM-SHA384 bits=256 verify=NOT) for ; Tue, 3 Jan 2023 14:09:07 -0500 DKIM-Filter: OpenDKIM Filter v2.11.0 smtp.polymtl.ca 303J921l011485 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=polymtl.ca; s=default; t=1672772947; bh=xmq+eLocySc1judg7ZbYxCiRlwMBsqqxqoWRNEYQkXs=; h=Date:Subject:To:References:From:In-Reply-To:From; b=CSjnIcN5RvR6RB+Ei54AvQ5VHF4G4BOyIEbPQTolzrkgQdRXwS9VWUmRplWB5Gm9O Vu0xePmr/ks1XXvF3ioUXPh5EqM1CMQlDtLePjSP8ARPjTpVvZeE65jvGQfAjAJmrh jIYDPNX/cxTV250+yj4u/WZ0HPCPCgRVbzoEmcDM= Received: from [10.0.0.11] (unknown [217.28.27.60]) (using TLSv1.3 with cipher TLS_AES_128_GCM_SHA256 (128/128 bits) key-exchange X25519 server-signature RSA-PSS (2048 bits)) (No client certificate requested) by simark.ca (Postfix) with ESMTPSA id 5B8DF1E112 for ; Tue, 3 Jan 2023 14:09:02 -0500 (EST) Message-ID: <988383af-9eba-6d83-e467-bb435c28c51d@polymtl.ca> Date: Tue, 3 Jan 2023 14:09:01 -0500 MIME-Version: 1.0 User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:102.0) Gecko/20100101 Thunderbird/102.6.1 Subject: Re: [PATCH v2 00/13] Make frame_info_ptr automatic Content-Language: en-US To: gdb-patches@sourceware.org References: <20221214033441.499512-1-simon.marchi@polymtl.ca> From: Simon Marchi In-Reply-To: <20221214033441.499512-1-simon.marchi@polymtl.ca> Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 7bit X-Poly-FromMTA: (simark.ca [158.69.221.121]) at Tue, 3 Jan 2023 19:09:02 +0000 X-Spam-Status: No, score=-3033.6 required=5.0 tests=BAYES_00,DKIM_SIGNED,DKIM_VALID,DKIM_VALID_AU,DKIM_VALID_EF,NICE_REPLY_A,RCVD_IN_MSPIKE_H3,RCVD_IN_MSPIKE_WL,SPF_HELO_PASS,SPF_PASS,TXREP autolearn=ham autolearn_force=no version=3.4.6 X-Spam-Checker-Version: SpamAssassin 3.4.6 (2021-04-09) on server2.sourceware.org List-Id: On 12/13/22 22:34, Simon Marchi wrote: > This is v2 of: > > https://inbox.sourceware.org/gdb-patches/20221202180052.212745-1-simon.marchi@polymtl.ca/ > > The first main change is that I dropped the patch removing the user of > frame_info_ptr at many places, following Tom's comment. If we end up > trying to reinflate a frame at a moment where it's not possible (because > the frame's id is being computed), we'll hit an assert in > frame_info_ptr. This is fine, because it indicates some logic problem > in GDB. > > The second main change, found after doing the first one, is to fix a bug > with the user-created frame reinflation. In v1, if we had two > frame_info_ptr wrapping the same user-created frame_info object, they > would each create their own frame_info instance on reinflation. And > that confused GDB down the line. There are a few new patches to deal > with that, by adding user-created frames to the frame stash, so they can > be found by frame_info_ptr when reinflating. > > At the end of the series, frame_info_ptr::frame_info_ptr (at the end of > the series) accesses some frame_info internals (the frame's id, without > calling get_frame_id), so I decided to move frame_info_ptr to > frame.{c,h} (patch 6). I think that makes sense anyway, as the logic in > the implementation of frame_info_ptr is tightly coupled to the rest of > the frame stuff. However, to do so, we need to break some inclusion > cycles. This is done in the few patches before. Patches 1 and 2 are > not strictly necessary, but fix oddities I found along the way. > > Regression-tested on Ubuntu 22.04 x86-64. FYI, I intend to merge this series by the end of the week. It was reviewed by Bruno and acknowledged by Tom Tromey. Simon