From patchwork Tue Mar 21 19:18:25 2023 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Tom Tromey X-Patchwork-Id: 55605 Return-Path: X-Original-To: patchwork@sourceware.org Delivered-To: patchwork@sourceware.org Received: from server2.sourceware.org (localhost [IPv6:::1]) by sourceware.org (Postfix) with ESMTP id 54E793857B8E for ; Tue, 21 Mar 2023 19:18:47 +0000 (GMT) X-Original-To: gdb-patches@sourceware.org Delivered-To: gdb-patches@sourceware.org Received: from gproxy1-pub.mail.unifiedlayer.com (gproxy1-pub.mail.unifiedlayer.com [69.89.25.95]) by sourceware.org (Postfix) with ESMTPS id 1CD403858C5F for ; Tue, 21 Mar 2023 19:18:33 +0000 (GMT) DMARC-Filter: OpenDMARC Filter v1.4.2 sourceware.org 1CD403858C5F Authentication-Results: sourceware.org; dmarc=none (p=none dis=none) header.from=tromey.com Authentication-Results: sourceware.org; spf=pass smtp.mailfrom=tromey.com Received: from cmgw13.mail.unifiedlayer.com (unknown [10.0.90.128]) by progateway3.mail.pro1.eigbox.com (Postfix) with ESMTP id 0C8EC1003F4E1 for ; Tue, 21 Mar 2023 19:18:32 +0000 (UTC) Received: from box5379.bluehost.com ([162.241.216.53]) by cmsmtp with ESMTP id ehV9pZXinNX2aehV9pFZmA; Tue, 21 Mar 2023 19:18:31 +0000 X-Authority-Reason: nr=8 X-Authority-Analysis: v=2.4 cv=NMAQR22g c=1 sm=1 tr=0 ts=641a0307 a=ApxJNpeYhEAb1aAlGBBbmA==:117 a=ApxJNpeYhEAb1aAlGBBbmA==:17 a=dLZJa+xiwSxG16/P+YVxDGlgEgI=:19 a=IkcTkHD0fZMA:10:nop_charset_1 a=k__wU0fu6RkA:10:nop_rcvd_month_year a=Qbun_eYptAEA:10:endurance_base64_authed_username_1 a=zstS-IiYAAAA:8 a=-relrwNofmP11ID1AL4A:9 a=QEXdDO2ut3YA:10:nop_charset_2 a=4G6NA9xxw8l3yy4pmD5M:22 DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=tromey.com; s=default; h=To:Content-Transfer-Encoding:Content-Type:MIME-Version: Message-Id:Date:Subject:From:Sender:Reply-To:Cc:Content-ID: Content-Description:Resent-Date:Resent-From:Resent-Sender:Resent-To:Resent-Cc :Resent-Message-ID:In-Reply-To:References:List-Id:List-Help:List-Unsubscribe: List-Subscribe:List-Post:List-Owner:List-Archive; bh=4YsHwCupVuY5MYV3LMkGejFvGJkUjEul1ksEHxURyZ0=; b=Rh70imarYhrWlRevJm1vMM8P5e b7penT+DuKcH+sORl85LGdQKCjW1Es9aO4PIpjpDqkb2mNHiJXnOv38OvBKmzYcUtdcFYb6b0gXj9 5Kmp/Kx7h42IolV/TQBF58LSs; Received: from 71-211-185-113.hlrn.qwest.net ([71.211.185.113]:53618 helo=[192.168.0.21]) by box5379.bluehost.com with esmtpsa (TLS1.2) tls TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384 (Exim 4.95) (envelope-from ) id 1pehV9-00150d-EL for gdb-patches@sourceware.org; Tue, 21 Mar 2023 13:18:31 -0600 From: Tom Tromey Subject: [PATCH 0/6] Use unrelocate_addr in more places Date: Tue, 21 Mar 2023 13:18:25 -0600 Message-Id: <20230321-submit-unrelocated-type-v1-0-2a1fb6117abf@tromey.com> MIME-Version: 1.0 X-B4-Tracking: v=1; b=H4sIAAIDGmQC/x2NwQrCMBAFf6Xs2YU0pQr+injYpE8bsGnZTUUp/ XdTj8MwzEYGTTC6Nhsp3snSnCu0p4biKPkJTkNl8s53rvMt2xqmVHjNitccpWDg8l3A0fdnOFw G6R3VOoiBg0qO49FPYgV6iEXxSJ//8nbf9x/S+kaPggAAAA== To: gdb-patches@sourceware.org X-Mailer: b4 0.12.1 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: 71.211.185.113 X-Source-L: No X-Exim-ID: 1pehV9-00150d-EL X-Source: X-Source-Args: X-Source-Dir: X-Source-Sender: 71-211-185-113.hlrn.qwest.net ([192.168.0.21]) [71.211.185.113]:53618 X-Source-Auth: tom+tromey.com X-Email-Count: 1 X-Source-Cap: ZWx5bnJvYmk7ZWx5bnJvYmk7Ym94NTM3OS5ibHVlaG9zdC5jb20= X-Local-Domain: yes X-Spam-Status: No, score=-3017.2 required=5.0 tests=BAYES_00, DKIM_SIGNED, DKIM_VALID, JMQ_SPF_NEUTRAL, RCVD_IN_ABUSEAT, RCVD_IN_DNSWL_NONE, RCVD_IN_MSPIKE_H2, SPF_HELO_NONE, SPF_PASS, TXREP autolearn=no autolearn_force=no version=3.4.6 X-Spam-Checker-Version: SpamAssassin 3.4.6 (2021-04-09) on server2.sourceware.org X-BeenThere: gdb-patches@sourceware.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: Gdb-patches mailing list List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: gdb-patches-bounces+patchwork=sourceware.org@sourceware.org Sender: "Gdb-patches" Minimal symbols, partial symbols, and partial symtabs all use unrelocated addresses right now. This series converts these to use the unrelocated_addr type, revealing (I believe) a few latent bugs. Regression tested on x86-64 Fedora 36. Tom --- Tom Tromey (6): Use function_view in gdb_bfd_lookup_symbol Move definition of unrelocated_addr earlier Use unrelocated_addr in partial symbol tables Use unrelocated_addr in psymbols Use unrelocated_addr in minimal symbols Rename "raw" to "unrelocated" gdb/coff-pe-read.c | 13 +++--- gdb/coffread.c | 12 +++--- gdb/ctfread.c | 27 +++++++------ gdb/dbxread.c | 114 ++++++++++++++++++++++++++++++++--------------------- gdb/elfread.c | 22 ++++++----- gdb/findvar.c | 4 +- gdb/machoread.c | 4 +- gdb/mdebugread.c | 104 +++++++++++++++++++++++++++++------------------- gdb/minsyms.c | 68 ++++++++++++++++---------------- gdb/minsyms.h | 6 +-- gdb/mips-tdep.c | 6 ++- gdb/mipsread.c | 2 +- gdb/parse.c | 2 +- gdb/printcmd.c | 2 +- gdb/psympriv.h | 42 ++++++++++---------- gdb/psymtab.c | 11 +++--- gdb/solib-dsbt.c | 17 ++++---- gdb/solib-frv.c | 15 +++---- gdb/solib-svr4.c | 20 +++++----- gdb/solib.c | 31 ++++++--------- gdb/solib.h | 14 +++---- gdb/stabsread.h | 2 +- gdb/symmisc.c | 2 +- gdb/symtab.c | 2 +- gdb/symtab.h | 43 ++++++++++++++++---- gdb/xcoffread.c | 55 +++++++++++++++----------- 26 files changed, 358 insertions(+), 282 deletions(-) --- base-commit: 70ea5a46bd926149fb4a9c3da32c2fc14f6e83c3 change-id: 20230321-submit-unrelocated-type-c256e0e7da50 Best regards,