llvm-project
2210c85a - Reapply [libomptarget] Support BE ELF files in plugins-nextgen (#85246)

Commit
1 year ago
Reapply [libomptarget] Support BE ELF files in plugins-nextgen (#85246) Code in plugins-nextgen reading ELF files is currently hard-coded to assume a 64-bit little-endian ELF format. Unfortunately, this assumption is even embedded in the interface between GlobalHandler and Utils/ELF routines, which use ELF64LE types. To fix this, I've refactored the interface to use generic types, in particular by using (a unique_ptr to) ObjectFile instead of ELF64LEObjectFile, and ELFSymbolRef instead of ELF64LE::Sym. This allows properly templating over multiple ELF format variants inside Utils/ELF; specifically, this patch adds support for 64-bit big-endian ELF files in addition to 64-bit little-endian files.
Author
Committer
Parents
Loading