blob: de81040021e28baf0eaa2fa39e94bc94fc0f67ee [file] [log] [blame]
Bill Wendling53351a12010-03-12 02:00:43 +00001//===-- 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"
15using namespace llvm;
16using namespace dwarf;
17
18//===----------------------------------------------------------------------===//
19// Mach-O Target
20//===----------------------------------------------------------------------===//
21
22void 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
31unsigned PPCMachOTargetObjectFile::getTTypeEncoding() const {
32 return DW_EH_PE_indirect | DW_EH_PE_pcrel | DW_EH_PE_sdata4;
33}