This is the mail archive of the gdb-patches@sources.redhat.com mailing list for the GDB project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

Re: [PATCH/RFC] faster language identification


On Thu, Nov 07, 2002 at 11:03:21PM +0200, Elias Athanasopoulos wrote:
> Hi Daniel,
> 
> On Thu, Nov 07, 2002 at 02:34:09PM -0500, Daniel Jacobowitz wrote:
> > Please don't.  See:
> > 
> > /* Set the initial language.
> > 
> >    A better solution would be to record the language in the psymtab when reading
> >    partial symbols, and then use it (if known) to set the language.  This would
> >    be a win for formats that encode the language in an easily discoverable place,
> >    such as DWARF.  For stabs, we can jump through hoops looking for specially
> >    named symbols or try to intuit the language from the specific type of stabs
> >    we find, but we can't do that until later when we read in full symbols.
> >    FIXME.  */
> > 
> > static void
> > set_initial_language (void)
> > 
> > Either that or there should be a psymtab_language() method somewhere.
> 
> Actually, this is what the patch does. :-) It sets the language according
> to the information recorded in the psymtab (_if_ it is recorded, as it does with
> DWARF).

No, the patch converts the psymtab to a symtab and uses the language in
the symtab.  That's what I want you NOT to do.  psymtab_to_symtab is
expensive!

-- 
Daniel Jacobowitz
MontaVista Software                         Debian GNU/Linux Developer


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]