Re: [PATCH] [dwarf2read] Fix crash when loading dwp files: calculate num_sections based on actual section indices, not just the number of sections.

Simon Marchi
2019-02-27T18:13:02Z

On 2019-02-27 13:05, Adrian Prantl wrote:
> Split DWARF solves a problem that doesn't exist on Darwin (macOS/iOS,
> ...). The motivation behind split DWARF is to reduce the number of
> relocations in debug info that have to be processed by the linker. But
> on Darwin, debug info is not processed by the linker at all, instead a
> tool called dsymutil (cf. llvm/tools/dsymutil) serves a conceptually
> similar task to dwp and archives the debug info from the .o files into
> a .dSYM bundle, separate from the executable.
>
> -- adrian

Ok, thanks to both of you for confirming. I think we are fine using the
elf-specific function.

Simon