psymtab_to_fullname if the basenames are different.
+2013-04-03 Doug Evans <dje@google.com>
+
+ * psymtab.c (read_psymtabs_with_fullname): Don't call
+ psymtab_to_fullname if the basenames are different.
+
2013-04-03 Jan Kratochvil <jan.kratochvil@redhat.com>
* NEWS (Changes in GDB 7.6): Update the data-disassemble for "fullname".
if (p->anonymous)
continue;
- if (filename_cmp (fullname, psymtab_to_fullname (p)) == 0)
+ /* psymtab_to_fullname tries to open the file which is slow.
+ Don't call it if we know the basenames don't match. */
+ if ((basenames_may_differ
+ || filename_cmp (lbasename (fullname), lbasename (p->filename)) == 0)
+ && filename_cmp (fullname, psymtab_to_fullname (p)) == 0)
psymtab_to_symtab (objfile, p);
}
}