Only use the per-BFD object to write a DWARF index
The DWARF index does not need access to the objfile or per-objfile objects when writing -- it's entirely based on the objfile-independent per-BFD data. This patch implements this idea by changing the entire API to only be passed the per-BFD object. This simplifies some lifetime reasoning for the next patch. This patch removes some code that ensures that the BFD came from a file. It seems to me that checking for the existence of a build-id is good enough for the index cache.
This commit is contained in:
parent
71797f1221
commit
542a33e348
5 changed files with 48 additions and 60 deletions
|
@ -33,7 +33,7 @@
|
|||
same, but for the dwz file's index. */
|
||||
|
||||
extern void write_dwarf_index
|
||||
(dwarf2_per_objfile *per_objfile, const char *dir, const char *basename,
|
||||
(dwarf2_per_bfd *per_bfd, const char *dir, const char *basename,
|
||||
const char *dwz_basename, dw_index_kind index_kind);
|
||||
|
||||
#endif /* DWARF_INDEX_WRITE_H */
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue