initial draft of PPCMachObjectWriter.cpp

this records relocation entries in the mach-o object file
for PIC code generation.
tested on powerpc-darwin8, validated against darwin otool -rvV

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@188004 91177308-0d34-0410-b5e6-96231b3b80d8
This commit is contained in:
David Fang
2013-08-08 20:14:40 +00:00
parent 783a0387c5
commit d4f9d05fde
7 changed files with 502 additions and 22 deletions

View File

@@ -425,6 +425,25 @@ namespace macho {
};
/// PPC relocation types from <mach-o/ppc/reloc.h>
enum RelocationInfoTypePPC {
RIT_PPC_BR14 = RIT_Pair +1,
RIT_PPC_BR24,
RIT_PPC_HI16,
RIT_PPC_LO16,
RIT_PPC_HA16,
RIT_PPC_LO14,
RIT_PPC_SECTDIFF,
RIT_PPC_PB_LA_PTR,
RIT_PPC_HI16_SECTDIFF,
RIT_PPC_LO16_SECTDIFF,
RIT_PPC_HA16_SECTDIFF,
RIT_PPC_JBSR,
RIT_PPC_LO14_SECTDIFF,
RIT_PPC_LOCAL_SECTDIFF,
RIT_PPC_TLV
};
} // end namespace macho
} // end namespace object