Bill Wendling | 53351a1 | 2010-03-12 02:00:43 +0000 | [diff] [blame] | 1 | //===-- llvm/Target/PPCTargetObjectFile.cpp - PPC Object Info Impl --------===// |
| 2 | // |
| 3 | // The LLVM Compiler Infrastructure |
| 4 | // |
| 5 | // This file is distributed under the University of Illinois Open Source |
| 6 | // License. See LICENSE.TXT for details. |
| 7 | // |
| 8 | //===----------------------------------------------------------------------===// |
| 9 | |
| 10 | #include "PPCTargetObjectFile.h" |
| 11 | #include "PPCSubtarget.h" |
| 12 | #include "llvm/MC/MCSectionMachO.h" |
| 13 | #include "llvm/Support/Dwarf.h" |
| 14 | #include "llvm/Target/TargetMachine.h" |
| 15 | using namespace llvm; |
| 16 | using namespace dwarf; |
| 17 | |
| 18 | //===----------------------------------------------------------------------===// |
| 19 | // Mach-O Target |
| 20 | //===----------------------------------------------------------------------===// |
| 21 | |
| 22 | void PPCMachOTargetObjectFile::Initialize(MCContext &Ctx, |
| 23 | const TargetMachine &TM) { |
| 24 | TargetLoweringObjectFileMachO::Initialize(Ctx, TM); |
| 25 | |
| 26 | // Exception Handling. |
| 27 | LSDASection = getMachOSection("__TEXT", "__gcc_except_tab", 0, |
| 28 | SectionKind::getReadOnlyWithRel()); |
| 29 | } |
| 30 | |
| 31 | unsigned PPCMachOTargetObjectFile::getTTypeEncoding() const { |
| 32 | return DW_EH_PE_indirect | DW_EH_PE_pcrel | DW_EH_PE_sdata4; |
| 33 | } |