From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from simark.ca by simark.ca with LMTP id afmvLuex4medaRoAWB0awg (envelope-from ) for ; Tue, 25 Mar 2025 09:38:47 -0400 Authentication-Results: simark.ca; dkim=fail reason="signature verification failed" (768-bit key; unprotected) header.d=tromey.com header.i=@tromey.com header.a=rsa-sha256 header.s=default header.b=tDPcr8Uw; dkim-atps=neutral Received: by simark.ca (Postfix, from userid 112) id B505E1E100; Tue, 25 Mar 2025 09:38:47 -0400 (EDT) X-Spam-Checker-Version: SpamAssassin 4.0.1 (2024-03-25) on simark.ca X-Spam-Level: X-Spam-Status: No, score=-5.1 required=5.0 tests=ARC_SIGNED,ARC_VALID,BAYES_00, DKIM_INVALID,DKIM_SIGNED,MAILING_LIST_MULTI,RCVD_IN_DNSWL_MED autolearn=unavailable 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 69FD21E05C for ; Tue, 25 Mar 2025 09:38:47 -0400 (EDT) Received: from server2.sourceware.org (localhost [IPv6:::1]) by sourceware.org (Postfix) with ESMTP id F2A32385772A for ; Tue, 25 Mar 2025 13:38:31 +0000 (GMT) DKIM-Filter: OpenDKIM Filter v2.11.0 sourceware.org F2A32385772A Authentication-Results: sourceware.org; dkim=fail reason="signature verification failed" (768-bit key, unprotected) header.d=tromey.com header.i=@tromey.com header.a=rsa-sha256 header.s=default header.b=tDPcr8Uw Received: from omta36.uswest2.a.cloudfilter.net (omta36.uswest2.a.cloudfilter.net [35.89.44.35]) by sourceware.org (Postfix) with ESMTPS id 8A1EC3858C41 for ; Tue, 25 Mar 2025 13:37:27 +0000 (GMT) DMARC-Filter: OpenDMARC Filter v1.4.2 sourceware.org 8A1EC3858C41 Authentication-Results: sourceware.org; dmarc=none (p=none dis=none) header.from=tromey.com Authentication-Results: sourceware.org; spf=pass smtp.mailfrom=tromey.com ARC-Filter: OpenARC Filter v1.0.0 sourceware.org 8A1EC3858C41 Authentication-Results: server2.sourceware.org; arc=none smtp.remote-ip=35.89.44.35 ARC-Seal: i=1; a=rsa-sha256; d=sourceware.org; s=key; t=1742909847; cv=none; b=vurZJ4ZuOQIF5LYex4iKV+uWQ+MMFWbLqrRPfEQobJWMW6Oj05V1pBqRQ5KZvVZEdaqLQKECy/mnKZLwbVcYLHyhkNbVA4XDHXU0D/lIFWzEHgE3S7+ghWEz85tnN7ljcwMeZmxhXDQVWc8HaPL5Wqck3JNdmtRzBtpIUu173NM= ARC-Message-Signature: i=1; a=rsa-sha256; d=sourceware.org; s=key; t=1742909847; c=relaxed/simple; bh=K7FxRtojpLy2xcM+yx/pvpQXDduWGxy3NnMGpqQBgB8=; h=DKIM-Signature:From:To:Subject:Date:Message-ID:MIME-Version; b=d/XT1308QuRHFeUUH89GlWVgBXIpBC9ZrJRGRKIIVKUTVUbE525vNHB1Kykb/giMvc8QIlbFTh0klzPGCT2Cdq7Em9gKq6zZLdwYJKKxTc8VmmRbwCZJtGO92wR52pE3XJycvLiM6vRoGsmMODlBvCHNBfPEzd/MEdxkCDLyfPk= ARC-Authentication-Results: i=1; server2.sourceware.org DKIM-Filter: OpenDKIM Filter v2.11.0 sourceware.org 8A1EC3858C41 Received: from eig-obgw-5007a.ext.cloudfilter.net ([10.0.29.141]) by cmsmtp with ESMTPS id wdnQt2HweMETlx4T8tgPem; Tue, 25 Mar 2025 13:37:26 +0000 Received: from box5379.bluehost.com ([162.241.216.53]) by cmsmtp with ESMTPS id x4T7tDSjyiHrex4T8tJ3Ps; Tue, 25 Mar 2025 13:37:26 +0000 X-Authority-Analysis: v=2.4 cv=H43dwfYi c=1 sm=1 tr=0 ts=67e2b196 a=ApxJNpeYhEAb1aAlGBBbmA==:117 a=ApxJNpeYhEAb1aAlGBBbmA==:17 a=Vs1iUdzkB0EA:10 a=ItBw4LHWJt0A:10 a=dzWzf_mpAAAA:8 a=GM3J0E7-wskllInXpKIA:9 a=b4DR9a7p2ZdsqdHBznES:22 a=6Ogn3jAGHLSNbaov7Orx:22 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:Date:References:In-Reply-To :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=x1oAtzPFr8Tf5dIczXVCWzu9r1XGB6Fw3w6hZNGbwL4=; b=tDPcr8UwD/h0Km3U/dsHxEVxP+ fW4vrwC7KbuuWnZkeMGlgYR6mBMqbiaV7OohhilgjA61XXNFicvh8Q9LOAg1iHWLq32Erv7vtxgNp Yfv8jy5xjBWEa8Ps7vSyGp1zh; Received: from 97-122-123-18.hlrn.qwest.net ([97.122.123.18]:34564 helo=murgatroyd) by box5379.bluehost.com with esmtpsa (TLS1.2) tls TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384 (Exim 4.98.1) (envelope-from ) id 1tx4T6-00000003Ku8-3hPt; Tue, 25 Mar 2025 07:37:24 -0600 From: Tom Tromey To: Simon Marchi Cc: Tom Tromey , gdb-patches@sourceware.org Subject: Re: [PATCH 2/3] Handle DWARF 5 separate debug sections In-Reply-To: <4301b473-7127-4c95-9f7a-d938f1bdb868@simark.ca> (Simon Marchi's message of "Mon, 24 Mar 2025 16:52:59 -0400") References: <20250323-dwz-dwarf-5-v2-v1-0-3c0775ca5514@tromey.com> <20250323-dwz-dwarf-5-v2-v1-2-3c0775ca5514@tromey.com> <4301b473-7127-4c95-9f7a-d938f1bdb868@simark.ca> X-Attribution: Tom Date: Tue, 25 Mar 2025 07:37:22 -0600 Message-ID: <87jz8dgrjh.fsf@tromey.com> User-Agent: Gnus/5.13 (Gnus v5.13) MIME-Version: 1.0 Content-Type: text/plain X-AntiAbuse: This header was added to track abuse, please include it with any abuse report X-AntiAbuse: Primary Hostname - box5379.bluehost.com X-AntiAbuse: Original Domain - sourceware.org X-AntiAbuse: Originator/Caller UID/GID - [47 12] / [47 12] X-AntiAbuse: Sender Address Domain - tromey.com X-BWhitelist: no X-Source-IP: 97.122.123.18 X-Source-L: No X-Exim-ID: 1tx4T6-00000003Ku8-3hPt X-Source: X-Source-Args: X-Source-Dir: X-Source-Sender: 97-122-123-18.hlrn.qwest.net (murgatroyd) [97.122.123.18]:34564 X-Source-Auth: tom+tromey.com X-Email-Count: 2 X-Org: HG=bhshared;ORG=bluehost; X-Source-Cap: ZWx5bnJvYmk7ZWx5bnJvYmk7Ym94NTM3OS5ibHVlaG9zdC5jb20= X-Local-Domain: yes X-CMAE-Envelope: MS4xfOYkW/0CY6+fSmeF/sZZJMzklDdcISYxDPV75BWrWUpkhLTKhG28OkWXVwd/grKUBoek3opwXapLLmvvrpA/pEQlszqZpTkEnCfNtsk5deXeuDyFVjiI dOmH+Fx+ra9IiS2vwb+xDsucC9W3r/1yZhPnZxybDy286dmpMy+qr3vawkR1TFVlJQiWCiOmRgaGUDHYr1jEVvMSSGMkIGk0OdU= 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 >>>>> "Simon" == Simon Marchi writes: >> + if (*buildid_len != 0) >> + buildid->reset ((bfd_byte *) xmemdup (contents, *buildid_len, >> + *buildid_len)); Simon> Could we return a view inside the section, instead of copying the bytes? Simon> It seems like we are just copying the bytes as is. In this code, the section isn't mapped but instead just read in and then discarded. That's done because it's only needed for a moment while reading -- once the file is found the .debug_sup contents aren't needed. Tom