forked from OSchip/llvm-project
[BinaryFormat] Fix bitfield-ordering of MachO::relocation_info on big-endian.
Hopefully this will fix the JITLink regression test failures on big-endian testers (e.g. http://lab.llvm.org:8011/builders/clang-s390x-linux-lnt/builds/12702) llvm-svn: 358839
This commit is contained in:
parent
0191531a76
commit
3ccd677bf8
|
@ -942,8 +942,13 @@ struct fat_arch_64 {
|
||||||
// Structs from <mach-o/reloc.h>
|
// Structs from <mach-o/reloc.h>
|
||||||
struct relocation_info {
|
struct relocation_info {
|
||||||
int32_t r_address;
|
int32_t r_address;
|
||||||
|
#if defined(BYTE_ORDER) && defined(BIG_ENDIAN) && (BYTE_ORDER == BIG_ENDIAN)
|
||||||
|
uint32_t r_type : 4, r_extern : 1, r_length : 2, r_pcrel : 1,
|
||||||
|
r_symbolnum : 24;
|
||||||
|
#else
|
||||||
uint32_t r_symbolnum : 24, r_pcrel : 1, r_length : 2, r_extern : 1,
|
uint32_t r_symbolnum : 24, r_pcrel : 1, r_length : 2, r_extern : 1,
|
||||||
r_type : 4;
|
r_type : 4;
|
||||||
|
#endif
|
||||||
};
|
};
|
||||||
|
|
||||||
struct scattered_relocation_info {
|
struct scattered_relocation_info {
|
||||||
|
|
Loading…
Reference in New Issue