From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from simark.ca by simark.ca with LMTP id 16IuIpFfImk+6yEAWB0awg (envelope-from ) for ; Sat, 22 Nov 2025 20:12:49 -0500 Authentication-Results: simark.ca; dkim=pass (1024-bit key; unprotected) header.d=redhat.com header.i=@redhat.com header.a=rsa-sha256 header.s=mimecast20190719 header.b=bq2jSRIO; dkim-atps=neutral Received: by simark.ca (Postfix, from userid 112) id 6B0A41E0B6; Sat, 22 Nov 2025 20:12:49 -0500 (EST) X-Spam-Checker-Version: SpamAssassin 4.0.1 (2024-03-25) on simark.ca X-Spam-Level: X-Spam-Status: No, score=-3.4 required=5.0 tests=ARC_SIGNED,ARC_VALID,BAYES_00, DKIMWL_WL_HIGH,DKIM_SIGNED,DKIM_VALID,DKIM_VALID_AU,MAILING_LIST_MULTI, RCVD_IN_DNSWL_MED,RCVD_IN_VALIDITY_CERTIFIED_BLOCKED, RCVD_IN_VALIDITY_RPBL_BLOCKED,RCVD_IN_VALIDITY_SAFE_BLOCKED autolearn=ham autolearn_force=no version=4.0.1 Received: from server2.sourceware.org (server2.sourceware.org [8.43.85.97]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange x25519 server-signature ECDSA (prime256v1) server-digest SHA256) (No client certificate requested) by simark.ca (Postfix) with ESMTPS id 5EB4B1E048 for ; Sat, 22 Nov 2025 20:12:48 -0500 (EST) Received: from server2.sourceware.org (localhost [IPv6:::1]) by sourceware.org (Postfix) with ESMTP id A6BBD3858D38 for ; Sun, 23 Nov 2025 01:12:47 +0000 (GMT) DKIM-Filter: OpenDKIM Filter v2.11.0 sourceware.org A6BBD3858D38 Authentication-Results: sourceware.org; dkim=pass (1024-bit key, unprotected) header.d=redhat.com header.i=@redhat.com header.a=rsa-sha256 header.s=mimecast20190719 header.b=bq2jSRIO Received: from us-smtp-delivery-124.mimecast.com (us-smtp-delivery-124.mimecast.com [170.10.133.124]) by sourceware.org (Postfix) with ESMTP id 32DDB3858D20 for ; Sun, 23 Nov 2025 01:10:37 +0000 (GMT) DMARC-Filter: OpenDMARC Filter v1.4.2 sourceware.org 32DDB3858D20 Authentication-Results: sourceware.org; dmarc=pass (p=quarantine dis=none) header.from=redhat.com Authentication-Results: sourceware.org; spf=pass smtp.mailfrom=redhat.com ARC-Filter: OpenARC Filter v1.0.0 sourceware.org 32DDB3858D20 Authentication-Results: server2.sourceware.org; arc=none smtp.remote-ip=170.10.133.124 ARC-Seal: i=1; a=rsa-sha256; d=sourceware.org; s=key; t=1763860237; cv=none; b=uvawP0ijoVXYBAk66uoaYMswrMCNgB4LUJIGwoz/fGaFzFciJalY3yjFmpV5mUZt/541kl6UhJpeNDK/n97+VkGKcdlLCbWYWrUq5JV/peX+Y4l9+EUDO/7bYJQ8cKAq2wfhmA3xc1WT6DmBa+e9Wv9JPhcWKJhLgmk9Jf7vnHQ= ARC-Message-Signature: i=1; a=rsa-sha256; d=sourceware.org; s=key; t=1763860237; c=relaxed/simple; bh=DlnkfSwv4gF0h1OW7Jq8D9nzhSHE6k+YlMP2VQmf1W8=; h=DKIM-Signature:Date:From:To:Subject:Message-ID:MIME-Version; b=LRapgEEuCyngwteyNoGmTvFTXFk8uL+JJbVhxueSL/znFszdrnEGjfalQPU3xhEt2YDj94yuiYS3oBZzzW6FbReZ2G1Ax294Zk7bikMNbx+SVOLaqOIL8PXYkjIIvcAyI2j0F1nXOBiZdJIiVJGpDgGqOmsH/CkiqFGQVco0i8o= ARC-Authentication-Results: i=1; server2.sourceware.org DKIM-Filter: OpenDKIM Filter v2.11.0 sourceware.org 32DDB3858D20 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=redhat.com; s=mimecast20190719; t=1763860236; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding: in-reply-to:in-reply-to:references:references; bh=hjmFmlvZLotH0yQ4o71E0BggvWU5cZtb/DBbni7Vers=; b=bq2jSRIOapKnnsSkTU6qnw4RQUz1mUb0yuXj1V7whRFeFcdto8RK6tG5i+V478pIQQ5bRd kuPEEABjnjwwkf+St0WFIHjftKUwbiptGUXmWxI90yHzqET2RLhnRoG7TqhH/VigUlt3W9 sFHGE8MPIJiALdykVs5t5mDcloCSLyY= Received: from mx-prod-mc-03.mail-002.prod.us-west-2.aws.redhat.com (ec2-54-186-198-63.us-west-2.compute.amazonaws.com [54.186.198.63]) by relay.mimecast.com with ESMTP with STARTTLS (version=TLSv1.3, cipher=TLS_AES_256_GCM_SHA384) id us-mta-546-iTyg2KtMP5KIieRWjgVltw-1; Sat, 22 Nov 2025 20:10:33 -0500 X-MC-Unique: iTyg2KtMP5KIieRWjgVltw-1 X-Mimecast-MFC-AGG-ID: iTyg2KtMP5KIieRWjgVltw_1763860232 Received: from mx-prod-int-06.mail-002.prod.us-west-2.aws.redhat.com (mx-prod-int-06.mail-002.prod.us-west-2.aws.redhat.com [10.30.177.93]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (2048 bits) server-digest SHA256) (No client certificate requested) by mx-prod-mc-03.mail-002.prod.us-west-2.aws.redhat.com (Postfix) with ESMTPS id CECB21956048; Sun, 23 Nov 2025 01:10:31 +0000 (UTC) Received: from f41-zbm-amd (unknown [10.22.80.39]) by mx-prod-int-06.mail-002.prod.us-west-2.aws.redhat.com (Postfix) with ESMTPS id 08E8D18004A3; Sun, 23 Nov 2025 01:10:30 +0000 (UTC) Date: Sat, 22 Nov 2025 18:10:28 -0700 From: Kevin Buettner To: Tom Tromey Cc: gdb-patches@sourceware.org Subject: Re: [PATCH] Remove a call to blockvector::map Message-ID: <20251122180737.52f34c49@f41-zbm-amd> In-Reply-To: <20251119214559.1468541-1-tom@tromey.com> References: <20251119214559.1468541-1-tom@tromey.com> Organization: Red Hat MIME-Version: 1.0 X-Scanned-By: MIMEDefang 3.4.1 on 10.30.177.93 X-Mimecast-Spam-Score: 0 X-Mimecast-MFC-PROC-ID: Gs4sR3ocMcIwMbXHv-6NCjmMRZVwagASpuP0oejyZ-Y_1763860232 X-Mimecast-Originator: redhat.com Content-Type: text/plain; charset=US-ASCII Content-Transfer-Encoding: 7bit X-BeenThere: gdb-patches@sourceware.org X-Mailman-Version: 2.1.30 Precedence: list List-Id: Gdb-patches mailing list List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: gdb-patches-bounces~public-inbox=simark.ca@sourceware.org On Wed, 19 Nov 2025 14:45:59 -0700 Tom Tromey wrote: > block_starting_point_at checks blockvector::map before doing a lookup. > > This patch removes this call, a step toward making the blockvector API > a bit more opaque. It arranges to find the necessary blockvector just > once, in gather_inline_frames, and then uses the 'lookup' method to > find the desired block. > > Note that this is a slight change of semantics, in that the old code > looked only in the map while the new code looks in the blockvector, > regardless of whether a map was made. However, I don't think this > should matter, and furthermore this seems like an abstraction > violation, with the inline-frame code knowing details of how buildsym > decided to create the blockvector. > > in the longer run, I think only the 'lookup' method should be provided > by blockvector -- that is, separately checking the map should be > impossible. The idea here is that eventually, for lazy CU expansion, > we will want to be able to expand the blockvector. This may be easier > with a different underlying data structure, so perhaps the map will go > away entirely. After this patch, one such use remains. > > Regression tested on x86-64 Fedora 40. LGTM. Approved-by: Kevin Buettner