OLD | NEW |
1 //===-- lib/Target/TargetELFWriterInfo.cpp - ELF Writer Info --0-*- C++ -*-===// | 1 //===-- lib/Target/TargetELFWriterInfo.cpp - ELF Writer Info --0-*- C++ -*-===// |
2 // | 2 // |
3 // The LLVM Compiler Infrastructure | 3 // The LLVM Compiler Infrastructure |
4 // | 4 // |
5 // This file is distributed under the University of Illinois Open Source | 5 // This file is distributed under the University of Illinois Open Source |
6 // License. See LICENSE.TXT for details. | 6 // License. See LICENSE.TXT for details. |
7 // | 7 // |
8 //===----------------------------------------------------------------------===// | 8 //===----------------------------------------------------------------------===// |
9 // | 9 // |
10 // This file implements the TargetELFWriterInfo class. | 10 // This file implements the TargetELFWriterInfo class. |
11 // | 11 // |
12 //===----------------------------------------------------------------------===// | 12 //===----------------------------------------------------------------------===// |
13 | 13 |
| 14 #include <cassert> |
14 #include "llvm/Function.h" | 15 #include "llvm/Function.h" |
15 #include "llvm/Target/TargetELFWriterInfo.h" | 16 #include "llvm/Target/TargetELFWriterInfo.h" |
16 #include "llvm/Target/TargetData.h" | 17 #include "llvm/Target/TargetData.h" |
17 #include "llvm/Target/TargetMachine.h" | 18 #include "llvm/Target/TargetMachine.h" |
18 using namespace llvm; | 19 using namespace llvm; |
19 | 20 |
| 21 //===----------------------------------------------------------------------===// |
| 22 // TargetELFWriterInfo implementation |
| 23 //===----------------------------------------------------------------------===// |
| 24 |
20 TargetELFWriterInfo::TargetELFWriterInfo(bool is64Bit_, bool isLittleEndian_) : | 25 TargetELFWriterInfo::TargetELFWriterInfo(bool is64Bit_, bool isLittleEndian_) : |
21 is64Bit(is64Bit_), isLittleEndian(isLittleEndian_) { | 26 is64Bit(is64Bit_), isLittleEndian(isLittleEndian_) { |
22 } | 27 } |
23 | 28 |
24 TargetELFWriterInfo::~TargetELFWriterInfo() {} | 29 TargetELFWriterInfo::~TargetELFWriterInfo() {} |
25 | 30 |
| 31 TargetELFRelocHelper *TargetELFWriterInfo::getRelocHelper() const { |
| 32 return new TargetELFRelocHelper(); |
| 33 } |
| 34 |
| 35 //===----------------------------------------------------------------------===// |
| 36 // TargetELFRelocHelper implementation |
| 37 //===----------------------------------------------------------------------===// |
| 38 |
| 39 TargetELFRelocHelper::~TargetELFRelocHelper() {} |
| 40 |
| 41 void TargetELFRelocHelper::RelocateField(BinaryObject &BO, uint32_t Offset, |
| 42 int64_t Value, unsigned Size, |
| 43 const MachineRelocation &MR) { |
| 44 assert(0 && "unimplemented RelocateField()"); |
| 45 } |
OLD | NEW |