[ELF2] Fix mixed-Endian handling in DynamicSection<ELFT>::writeTo
Using the "raw" Elf64_Dyn or Elf32_Dyn structures in DynamicSection<ELFT>::writeTo does not correctly handle mixed-Endian situations. Instead, use the corresponding llvm::object::* structures which have Endian-converting members (like the rest of the code). This fixes all currently-failing elf2 tests when running on big-Endian PPC64/Linux (I've added a big-Endian test case which should fail on little-Endian machines in the same way that test/elf2/shared.s failed on big-Endian machines prior to this change). llvm-svn: 249150
Loading
Please sign in to comment