ULONGEST length = extract_unsigned_integer (cu_list + 8, 8, BFD_ENDIAN_LITTLE);
cu_list += 2 * 8;
- dwarf2_per_cu_up per_cu
- = create_cu_from_index_list (per_bfd, section, is_dwz, sect_off,
- length);
+ dwarf2_per_cu_up per_cu = per_bfd->allocate_per_cu (section, sect_off, length);
+ per_cu->is_dwz = is_dwz;
+
per_bfd->all_units.push_back (std::move (per_cu));
}
}
return result;
}
-/* See read.h. */
-
-dwarf2_per_cu_up
-create_cu_from_index_list (dwarf2_per_bfd *per_bfd,
- struct dwarf2_section_info *section,
- int is_dwz,
- sect_offset sect_off, ULONGEST length)
-{
- dwarf2_per_cu_up the_cu
- = per_bfd->allocate_per_cu (section, sect_off, length);
- the_cu->is_dwz = is_dwz;
- return the_cu;
-}
-
/* die_reader_func for dw2_get_file_names. */
static void
extern const char *read_indirect_string_at_offset
(dwarf2_per_objfile *per_objfile, LONGEST str_offset);
-/* Return a new dwarf2_per_cu allocated on the per-bfd obstack, and constructed
- with the specified field values. */
-
-extern dwarf2_per_cu_up create_cu_from_index_list
- (dwarf2_per_bfd *per_bfd, struct dwarf2_section_info *section,
- int is_dwz, sect_offset sect_off, ULONGEST length);
-
/* Initialize the views on all_units. */
extern void finalize_all_units (dwarf2_per_bfd *per_bfd);