From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 61330 invoked by alias); 5 Aug 2019 15:37:46 -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 61204 invoked by uid 89); 5 Aug 2019 15:37:46 -0000 Authentication-Results: sourceware.org; auth=none X-Spam-SWARE-Status: No, score=-32.4 required=5.0 tests=AWL,BAYES_00,ENV_AND_HDR_SPF_MATCH,GIT_PATCH_0,GIT_PATCH_1,GIT_PATCH_2,GIT_PATCH_3,RCVD_IN_DNSWL_NONE,SPF_PASS,USER_IN_DEF_SPF_WL autolearn=ham version=3.3.1 spammy=HX-Google-Smtp-Source:APXvYqx, HX-Spam-Relays-External:209.85.167.196, H*RU:209.85.167.196 X-HELO: mail-oi1-f196.google.com Received: from mail-oi1-f196.google.com (HELO mail-oi1-f196.google.com) (209.85.167.196) by sourceware.org (qpsmtpd/0.93/v0.84-503-g423c35a) with ESMTP; Mon, 05 Aug 2019 15:37:45 +0000 Received: by mail-oi1-f196.google.com with SMTP id u15so62373891oiv.0 for ; Mon, 05 Aug 2019 08:37:45 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=20161025; h=mime-version:references:in-reply-to:from:date:message-id:subject:to :cc; bh=hVh4Qe6xM26+Uq1P+84eqeA7VzzzbpBPYmYr80PSIOI=; b=psXp08hqWFotB1rOtenJBoFjRCzj4etm1PhO46lTPHSUdd41+xe/E3Si8Kez2fouFf uNVDxkP4flf2P7h6kmaQJXNV7VGZXBfEccD+955lzamWgbuHotkjPLrPyAXDEmOOnGMH MDw7PRiAVMwoL+9FRvr1+tZ+GQEATU0SE/4uUK9qb93n/ESzEbDJarEk99KjXR87/eBT pEqAGLsHcPhpjjwff4jPcY3uU3nv9kr6gRn/Ecwg5OgPngm0g4IVblcgv431MfmjwSmh D5kdtmTdSseKpfM4vzwOE8bYOiw2d1b74UiBmwdbCiS4n8YS18ZhBTV9f62WQPd04496 xMhQ== MIME-Version: 1.0 References: <20190731221252.143637-1-cbiesinger@google.com> In-Reply-To: From: "Christian Biesinger via gdb-patches" Reply-To: Christian Biesinger Date: Mon, 05 Aug 2019 15:37:00 -0000 Message-ID: Subject: Re: [PATCH] Add a comment briefly explaining partial symbols To: Simon Marchi Cc: Christian Biesinger via gdb-patches Content-Type: text/plain; charset="UTF-8" X-SW-Source: 2019-08/txt/msg00114.txt.bz2 On Wed, Jul 31, 2019 at 6:59 PM Simon Marchi wrote: > > On 2019-07-31 6:12 p.m., Christian Biesinger via gdb-patches wrote: > > Based on an explanation by tromey on IRC. > > > > gdb/ChangeLog: > > > > 2019-07-31 Christian Biesinger > > > > * objfiles.h (objfile): Add a comment describing partial symbols. > > --- > > gdb/objfiles.h | 8 +++++++- > > 1 file changed, 7 insertions(+), 1 deletion(-) > > > > diff --git a/gdb/objfiles.h b/gdb/objfiles.h > > index a0c106be3d..c7e0be1955 100644 > > --- a/gdb/objfiles.h > > +++ b/gdb/objfiles.h > > @@ -382,7 +382,13 @@ private: > > 2. Additional symbol files added by the add-symbol-file command, > > 3. Shared library objfiles, added by ADD_SOLIB, 4. symbol files > > for modules that were loaded when GDB attached to a remote system > > - (see remote-vx.c). */ > > + (see remote-vx.c). > > + > > + GDB typically reads symbols twice -- first an initial scan which just > > + reads "partial symbols"; these are partial information for the > > + static/global symbols in a symbol file. When later looking up symbols, > > + objfile->sf->qf->lookup_symbol is used to check if we only have a partial > > + symbol and if so, read and expand the full compunit. */ > > > > struct objfile > > { > > > > Hi Christian, > > Thanks, that LGTM. But please wait a few days before pushing to see if others have things to add. Thanks, pushed now. Christian