blob: 71dbc6c881e56ce89680b1c56bf31d4b727f637c [file] [log] [blame]
Rafael Espindola9d06ab62015-09-22 00:01:39 +00001//===- InputSection.cpp ---------------------------------------------------===//
Michael J. Spencer84487f12015-07-24 21:03:07 +00002//
3// The LLVM Linker
4//
5// This file is distributed under the University of Illinois Open Source
6// License. See LICENSE.TXT for details.
7//
8//===----------------------------------------------------------------------===//
9
Rafael Espindola9d06ab62015-09-22 00:01:39 +000010#include "InputSection.h"
Rafael Espindola551dfd82015-09-25 19:24:57 +000011#include "Config.h"
Rafael Espindola192e1fa2015-08-06 15:08:23 +000012#include "Error.h"
Michael J. Spencer67bc8d62015-08-27 23:15:56 +000013#include "InputFiles.h"
Rafael Espindola4ea00212015-09-21 22:01:00 +000014#include "OutputSections.h"
Rafael Espindola01205f72015-09-22 18:19:46 +000015#include "Target.h"
Rafael Espindola4ea00212015-09-21 22:01:00 +000016
Michael J. Spencer84487f12015-07-24 21:03:07 +000017using namespace llvm;
18using namespace llvm::ELF;
Rafael Espindola4ea00212015-09-21 22:01:00 +000019using namespace llvm::object;
Michael J. Spencer84487f12015-07-24 21:03:07 +000020
21using namespace lld;
22using namespace lld::elf2;
23
24template <class ELFT>
Rafael Espindolac159c962015-10-19 21:00:02 +000025InputSectionBase<ELFT>::InputSectionBase(ObjectFile<ELFT> *File,
26 const Elf_Shdr *Header,
27 Kind SectionKind)
28 : Header(Header), File(File), SectionKind(SectionKind) {}
29
30template <class ELFT> StringRef InputSectionBase<ELFT>::getSectionName() const {
31 ErrorOr<StringRef> Name = File->getObj().getSectionName(this->Header);
32 error(Name);
33 return *Name;
34}
35
36template <class ELFT>
37ArrayRef<uint8_t> InputSectionBase<ELFT>::getSectionData() const {
38 ErrorOr<ArrayRef<uint8_t>> Ret =
39 this->File->getObj().getSectionContents(this->Header);
40 error(Ret);
41 return *Ret;
42}
43
44template <class ELFT>
45typename ELFFile<ELFT>::uintX_t
Rafael Espindoladb9bf4d2015-11-11 16:50:37 +000046InputSectionBase<ELFT>::getOffset(uintX_t Offset) {
47 switch (SectionKind) {
48 case Regular:
49 return cast<InputSection<ELFT>>(this)->OutSecOff + Offset;
Rafael Espindola0c6a4f12015-11-11 19:54:14 +000050 case EHFrame:
51 return cast<EHInputSection<ELFT>>(this)->getOffset(Offset);
Rafael Espindoladb9bf4d2015-11-11 16:50:37 +000052 case Merge:
53 return cast<MergeInputSection<ELFT>>(this)->getOffset(Offset);
Simon Atanasyan1d7df402015-12-20 10:57:34 +000054 case MipsReginfo:
55 return cast<MipsReginfoInputSection<ELFT>>(this)->getOffset(Offset);
Rafael Espindoladb9bf4d2015-11-11 16:50:37 +000056 }
Denis Protivensky1b1b34e2015-11-12 09:11:20 +000057 llvm_unreachable("Invalid section kind");
Rafael Espindoladb9bf4d2015-11-11 16:50:37 +000058}
59
60template <class ELFT>
61typename ELFFile<ELFT>::uintX_t
Rafael Espindola48225b42015-10-23 19:55:11 +000062InputSectionBase<ELFT>::getOffset(const Elf_Sym &Sym) {
Rafael Espindoladb9bf4d2015-11-11 16:50:37 +000063 return getOffset(Sym.st_value);
Rafael Espindolac159c962015-10-19 21:00:02 +000064}
65
Rui Ueyama12504642015-10-27 21:51:13 +000066// Returns a section that Rel relocation is pointing to.
67template <class ELFT>
68InputSectionBase<ELFT> *
69InputSectionBase<ELFT>::getRelocTarget(const Elf_Rel &Rel) {
70 // Global symbol
71 uint32_t SymIndex = Rel.getSymbol(Config->Mips64EL);
72 if (SymbolBody *B = File->getSymbolBody(SymIndex))
73 if (auto *D = dyn_cast<DefinedRegular<ELFT>>(B->repl()))
74 return &D->Section;
75 // Local symbol
76 if (const Elf_Sym *Sym = File->getLocalSymbol(SymIndex))
77 if (InputSectionBase<ELFT> *Sec = File->getSection(*Sym))
78 return Sec;
79 return nullptr;
80}
81
82template <class ELFT>
83InputSectionBase<ELFT> *
84InputSectionBase<ELFT>::getRelocTarget(const Elf_Rela &Rel) {
85 return getRelocTarget(reinterpret_cast<const Elf_Rel &>(Rel));
86}
87
Rafael Espindolac159c962015-10-19 21:00:02 +000088template <class ELFT>
Rafael Espindola53d5cea2015-09-21 17:47:00 +000089InputSection<ELFT>::InputSection(ObjectFile<ELFT> *F, const Elf_Shdr *Header)
Rafael Espindolac159c962015-10-19 21:00:02 +000090 : InputSectionBase<ELFT>(F, Header, Base::Regular) {}
91
92template <class ELFT>
93bool InputSection<ELFT>::classof(const InputSectionBase<ELFT> *S) {
94 return S->SectionKind == Base::Regular;
95}
Michael J. Spencer84487f12015-07-24 21:03:07 +000096
Rafael Espindola4ea00212015-09-21 22:01:00 +000097template <class ELFT>
Rafael Espindola4ea00212015-09-21 22:01:00 +000098template <bool isRela>
Simon Atanasyan09b3e362015-12-01 21:24:45 +000099uint8_t *
Simon Atanasyandddbeb72015-12-13 06:49:08 +0000100InputSectionBase<ELFT>::findMipsPairedReloc(uint8_t *Buf, uint32_t SymIndex,
101 uint32_t Type,
Simon Atanasyan09b3e362015-12-01 21:24:45 +0000102 RelIteratorRange<isRela> Rels) {
103 // Some MIPS relocations use addend calculated from addend of the relocation
104 // itself and addend of paired relocation. ABI requires to compute such
105 // combined addend in case of REL relocation record format only.
106 // See p. 4-17 at ftp://www.linux-mips.org/pub/linux/mips/doc/ABI/mipsabi.pdf
107 if (isRela || Config->EMachine != EM_MIPS)
108 return nullptr;
109 if (Type == R_MIPS_HI16)
110 Type = R_MIPS_LO16;
111 else if (Type == R_MIPS_PCHI16)
112 Type = R_MIPS_PCLO16;
113 else if (Type == R_MICROMIPS_HI16)
114 Type = R_MICROMIPS_LO16;
115 else
116 return nullptr;
117 for (const auto &RI : Rels) {
118 if (RI.getType(Config->Mips64EL) != Type)
119 continue;
Simon Atanasyandddbeb72015-12-13 06:49:08 +0000120 if (RI.getSymbol(Config->Mips64EL) != SymIndex)
121 continue;
Simon Atanasyan09b3e362015-12-01 21:24:45 +0000122 uintX_t Offset = getOffset(RI.r_offset);
123 if (Offset == (uintX_t)-1)
124 return nullptr;
125 return Buf + Offset;
126 }
127 return nullptr;
128}
129
130template <class ELFT>
George Rimar48651482015-12-11 08:59:37 +0000131static typename llvm::object::ELFFile<ELFT>::uintX_t
132getSymSize(SymbolBody &Body) {
133 if (auto *SS = dyn_cast<Defined<ELFT>>(&Body))
134 return SS->Sym.st_size;
135 return 0;
136}
137
138template <class ELFT>
Simon Atanasyan09b3e362015-12-01 21:24:45 +0000139template <bool isRela>
140void InputSectionBase<ELFT>::relocate(uint8_t *Buf, uint8_t *BufEnd,
141 RelIteratorRange<isRela> Rels) {
Rafael Espindola4ea00212015-09-21 22:01:00 +0000142 typedef Elf_Rel_Impl<ELFT, isRela> RelType;
George Rimar6713cf82015-11-25 21:46:05 +0000143 size_t Num = Rels.end() - Rels.begin();
144 for (size_t I = 0; I < Num; ++I) {
145 const RelType &RI = *(Rels.begin() + I);
Rui Ueyama64558522015-10-16 22:51:43 +0000146 uint32_t SymIndex = RI.getSymbol(Config->Mips64EL);
147 uint32_t Type = RI.getType(Config->Mips64EL);
Rafael Espindola0c6a4f12015-11-11 19:54:14 +0000148 uintX_t Offset = getOffset(RI.r_offset);
149 if (Offset == (uintX_t)-1)
150 continue;
151
152 uint8_t *BufLoc = Buf + Offset;
153 uintX_t AddrLoc = OutSec->getVA() + Offset;
Simon Atanasyan09b3e362015-12-01 21:24:45 +0000154 auto NextRelocs = llvm::make_range(&RI, Rels.end());
Michael J. Spencer1e225612015-11-11 01:00:24 +0000155
George Rimar6713cf82015-11-25 21:46:05 +0000156 if (Target->isTlsLocalDynamicReloc(Type) &&
157 !Target->isTlsOptimized(Type, nullptr)) {
Michael J. Spencer1e225612015-11-11 01:00:24 +0000158 Target->relocateOne(BufLoc, BufEnd, Type, AddrLoc,
George Rimarb17f7392015-12-01 18:24:07 +0000159 Out<ELFT>::Got->getLocalTlsIndexVA() +
Michael J. Spencer1e225612015-11-11 01:00:24 +0000160 getAddend<ELFT>(RI));
161 continue;
162 }
Rafael Espindola4ea00212015-09-21 22:01:00 +0000163
164 // Handle relocations for local symbols -- they never get
165 // resolved so we don't allocate a SymbolBody.
Rafael Espindola8e37f792015-11-11 10:23:32 +0000166 const Elf_Shdr *SymTab = File->getSymbolTable();
Rafael Espindola4ea00212015-09-21 22:01:00 +0000167 if (SymIndex < SymTab->sh_info) {
Rafael Espindola8e37f792015-11-11 10:23:32 +0000168 uintX_t SymVA = getLocalRelTarget(*File, RI);
George Rimar48651482015-12-11 08:59:37 +0000169 Target->relocateOne(BufLoc, BufEnd, Type, AddrLoc, SymVA, 0,
Simon Atanasyandddbeb72015-12-13 06:49:08 +0000170 findMipsPairedReloc(Buf, SymIndex, Type, NextRelocs));
Rui Ueyamabb3c3362015-10-12 20:28:23 +0000171 continue;
Rafael Espindola4ea00212015-09-21 22:01:00 +0000172 }
173
Rafael Espindola8e37f792015-11-11 10:23:32 +0000174 SymbolBody &Body = *File->getSymbolBody(SymIndex)->repl();
Michael J. Spencer627ae702015-11-13 00:28:34 +0000175
George Rimar6713cf82015-11-25 21:46:05 +0000176 if (Target->isTlsGlobalDynamicReloc(Type) &&
177 !Target->isTlsOptimized(Type, &Body)) {
Michael J. Spencer627ae702015-11-13 00:28:34 +0000178 Target->relocateOne(BufLoc, BufEnd, Type, AddrLoc,
George Rimar90cd0a82015-12-01 19:20:26 +0000179 Out<ELFT>::Got->getGlobalDynAddr(Body) +
Michael J. Spencer627ae702015-11-13 00:28:34 +0000180 getAddend<ELFT>(RI));
181 continue;
182 }
183
George Rimar6713cf82015-11-25 21:46:05 +0000184 if (Target->isTlsOptimized(Type, &Body)) {
George Rimar25411f252015-12-04 11:20:13 +0000185 uintX_t SymVA = Target->relocNeedsGot(Type, Body)
186 ? Out<ELFT>::Got->getEntryAddr(Body)
187 : getSymVA<ELFT>(Body);
George Rimar6713cf82015-11-25 21:46:05 +0000188 // By optimizing TLS relocations, it is sometimes needed to skip
189 // relocations that immediately follow TLS relocations. This function
190 // knows how many slots we need to skip.
George Rimar25411f252015-12-04 11:20:13 +0000191 I += Target->relocateTlsOptimize(BufLoc, BufEnd, Type, AddrLoc, SymVA,
192 Body);
George Rimar77d1cb12015-11-24 09:00:06 +0000193 continue;
194 }
195
Rui Ueyamabb3c3362015-10-12 20:28:23 +0000196 uintX_t SymVA = getSymVA<ELFT>(Body);
197 if (Target->relocNeedsPlt(Type, Body)) {
198 SymVA = Out<ELFT>::Plt->getEntryAddr(Body);
Igor Kudrine7ad0932015-11-17 17:47:53 +0000199 Type = Target->getPltRefReloc(Type);
Rui Ueyamabb3c3362015-10-12 20:28:23 +0000200 } else if (Target->relocNeedsGot(Type, Body)) {
201 SymVA = Out<ELFT>::Got->getEntryAddr(Body);
Rui Ueyama62d0e322015-12-17 00:04:18 +0000202 if (Body.isTls())
George Rimar6f17e092015-12-17 09:32:21 +0000203 Type = Target->getTlsGotReloc(Type);
Rui Ueyama02dfd492015-12-17 01:18:40 +0000204 } else if (!Target->needsCopyRel(Type, Body) &&
George Rimarbc590fe2015-10-28 16:48:58 +0000205 isa<SharedSymbol<ELFT>>(Body)) {
Rui Ueyamabb3c3362015-10-12 20:28:23 +0000206 continue;
George Rimar6f17e092015-12-17 09:32:21 +0000207 } else if (Target->isTlsDynReloc(Type, Body) ||
George Rimar48651482015-12-11 08:59:37 +0000208 Target->isSizeDynReloc(Type, Body)) {
George Rimard23970f2015-11-25 20:41:53 +0000209 continue;
Simon Atanasyan09dae7c2015-12-16 14:45:09 +0000210 } else if (Config->EMachine == EM_MIPS) {
211 if (Type == R_MIPS_HI16 && &Body == Config->MipsGpDisp)
212 SymVA = getMipsGpAddr<ELFT>() - AddrLoc;
213 else if (Type == R_MIPS_LO16 && &Body == Config->MipsGpDisp)
214 SymVA = getMipsGpAddr<ELFT>() - AddrLoc + 4;
Rui Ueyamabb3c3362015-10-12 20:28:23 +0000215 }
George Rimar48651482015-12-11 08:59:37 +0000216 uintX_t A = getAddend<ELFT>(RI);
217 uintX_t Size = getSymSize<ELFT>(Body);
218 Target->relocateOne(BufLoc, BufEnd, Type, AddrLoc, SymVA + A, Size + A,
Simon Atanasyandddbeb72015-12-13 06:49:08 +0000219 findMipsPairedReloc(Buf, SymIndex, Type, NextRelocs));
Rafael Espindola4ea00212015-09-21 22:01:00 +0000220 }
221}
222
Rui Ueyama15ef5e12015-10-07 19:18:16 +0000223template <class ELFT> void InputSection<ELFT>::writeTo(uint8_t *Buf) {
Rafael Espindolac159c962015-10-19 21:00:02 +0000224 if (this->Header->sh_type == SHT_NOBITS)
Michael J. Spencer84487f12015-07-24 21:03:07 +0000225 return;
226 // Copy section contents from source object file to output file.
Rafael Espindolac159c962015-10-19 21:00:02 +0000227 ArrayRef<uint8_t> Data = this->getSectionData();
Rui Ueyama55c3f892015-10-15 01:58:40 +0000228 memcpy(Buf + OutSecOff, Data.data(), Data.size());
Rafael Espindola4ea00212015-09-21 22:01:00 +0000229
Rafael Espindolac159c962015-10-19 21:00:02 +0000230 ELFFile<ELFT> &EObj = this->File->getObj();
Rafael Espindola0c6a4f12015-11-11 19:54:14 +0000231 uint8_t *BufEnd = Buf + OutSecOff + Data.size();
Rafael Espindola4ea00212015-09-21 22:01:00 +0000232 // Iterate over all relocation sections that apply to this section.
Rafael Espindola0c6a4f12015-11-11 19:54:14 +0000233 for (const Elf_Shdr *RelSec : this->RelocSections) {
Rafael Espindola4ea00212015-09-21 22:01:00 +0000234 if (RelSec->sh_type == SHT_RELA)
Rafael Espindola0c6a4f12015-11-11 19:54:14 +0000235 this->relocate(Buf, BufEnd, EObj.relas(RelSec));
Rafael Espindola4ea00212015-09-21 22:01:00 +0000236 else
Rafael Espindola0c6a4f12015-11-11 19:54:14 +0000237 this->relocate(Buf, BufEnd, EObj.rels(RelSec));
Rafael Espindola4ea00212015-09-21 22:01:00 +0000238 }
Michael J. Spencer84487f12015-07-24 21:03:07 +0000239}
240
Rafael Espindolac159c962015-10-19 21:00:02 +0000241template <class ELFT>
Rafael Espindola0c6a4f12015-11-11 19:54:14 +0000242SplitInputSection<ELFT>::SplitInputSection(
243 ObjectFile<ELFT> *File, const Elf_Shdr *Header,
244 typename InputSectionBase<ELFT>::Kind SectionKind)
245 : InputSectionBase<ELFT>(File, Header, SectionKind) {}
246
247template <class ELFT>
248EHInputSection<ELFT>::EHInputSection(ObjectFile<ELFT> *F,
249 const Elf_Shdr *Header)
250 : SplitInputSection<ELFT>(F, Header, InputSectionBase<ELFT>::EHFrame) {}
251
252template <class ELFT>
253bool EHInputSection<ELFT>::classof(const InputSectionBase<ELFT> *S) {
254 return S->SectionKind == InputSectionBase<ELFT>::EHFrame;
255}
256
257template <class ELFT>
258typename EHInputSection<ELFT>::uintX_t
259EHInputSection<ELFT>::getOffset(uintX_t Offset) {
260 std::pair<uintX_t, uintX_t> *I = this->getRangeAndSize(Offset).first;
261 uintX_t Base = I->second;
George Rimar4b40ebc2015-11-13 13:44:59 +0000262 if (Base == uintX_t(-1))
Rafael Espindola0c6a4f12015-11-11 19:54:14 +0000263 return -1; // Not in the output
264
265 uintX_t Addend = Offset - I->first;
266 return Base + Addend;
267}
268
269template <class ELFT>
Rafael Espindolac159c962015-10-19 21:00:02 +0000270MergeInputSection<ELFT>::MergeInputSection(ObjectFile<ELFT> *F,
271 const Elf_Shdr *Header)
Rafael Espindola0c6a4f12015-11-11 19:54:14 +0000272 : SplitInputSection<ELFT>(F, Header, InputSectionBase<ELFT>::Merge) {}
Rafael Espindolac159c962015-10-19 21:00:02 +0000273
274template <class ELFT>
275bool MergeInputSection<ELFT>::classof(const InputSectionBase<ELFT> *S) {
Rafael Espindola0c6a4f12015-11-11 19:54:14 +0000276 return S->SectionKind == InputSectionBase<ELFT>::Merge;
Rafael Espindolac159c962015-10-19 21:00:02 +0000277}
278
Rafael Espindolac159c962015-10-19 21:00:02 +0000279template <class ELFT>
Rafael Espindola0c6a4f12015-11-11 19:54:14 +0000280std::pair<std::pair<typename ELFFile<ELFT>::uintX_t,
281 typename ELFFile<ELFT>::uintX_t> *,
282 typename ELFFile<ELFT>::uintX_t>
283SplitInputSection<ELFT>::getRangeAndSize(uintX_t Offset) {
Rafael Espindolaf82ed2a2015-10-24 22:51:01 +0000284 ArrayRef<uint8_t> D = this->getSectionData();
Rui Ueyama7ba639b2015-10-25 16:25:04 +0000285 StringRef Data((const char *)D.data(), D.size());
Rafael Espindolaf82ed2a2015-10-24 22:51:01 +0000286 uintX_t Size = Data.size();
287 if (Offset >= Size)
Rafael Espindolac159c962015-10-19 21:00:02 +0000288 error("Entry is past the end of the section");
Rafael Espindolaf82ed2a2015-10-24 22:51:01 +0000289
290 // Find the element this offset points to.
291 auto I = std::upper_bound(
Rafael Espindolad04c12a2015-11-11 15:20:45 +0000292 Offsets.begin(), Offsets.end(), Offset,
Rafael Espindola1fe2d1e2015-11-11 15:55:00 +0000293 [](const uintX_t &A, const std::pair<uintX_t, uintX_t> &B) {
Rafael Espindolaf82ed2a2015-10-24 22:51:01 +0000294 return A < B.first;
295 });
Rafael Espindola32994992015-11-11 15:40:37 +0000296 uintX_t End = I == Offsets.end() ? Data.size() : I->first;
Rafael Espindolaf82ed2a2015-10-24 22:51:01 +0000297 --I;
Rafael Espindola0c6a4f12015-11-11 19:54:14 +0000298 return std::make_pair(&*I, End);
299}
300
301template <class ELFT>
302typename MergeInputSection<ELFT>::uintX_t
303MergeInputSection<ELFT>::getOffset(uintX_t Offset) {
George Rimar4b40ebc2015-11-13 13:44:59 +0000304 std::pair<std::pair<uintX_t, uintX_t> *, uintX_t> T =
Rafael Espindola0c6a4f12015-11-11 19:54:14 +0000305 this->getRangeAndSize(Offset);
306 std::pair<uintX_t, uintX_t> *I = T.first;
307 uintX_t End = T.second;
Rafael Espindolaf82ed2a2015-10-24 22:51:01 +0000308 uintX_t Start = I->first;
309
310 // Compute the Addend and if the Base is cached, return.
311 uintX_t Addend = Offset - Start;
Rafael Espindola32994992015-11-11 15:40:37 +0000312 uintX_t &Base = I->second;
Rafael Espindola1fe2d1e2015-11-11 15:55:00 +0000313 if (Base != uintX_t(-1))
Rafael Espindolaf82ed2a2015-10-24 22:51:01 +0000314 return Base + Addend;
315
Hal Finkelf9505952015-11-25 23:54:53 +0000316 // Map the base to the offset in the output section and cache it.
Rafael Espindola0c6a4f12015-11-11 19:54:14 +0000317 ArrayRef<uint8_t> D = this->getSectionData();
318 StringRef Data((const char *)D.data(), D.size());
Rafael Espindolaf82ed2a2015-10-24 22:51:01 +0000319 StringRef Entry = Data.substr(Start, End - Start);
320 Base =
321 static_cast<MergeOutputSection<ELFT> *>(this->OutSec)->getOffset(Entry);
322 return Base + Addend;
Rafael Espindola5d83ccd2015-08-13 19:18:30 +0000323}
324
Simon Atanasyan1d7df402015-12-20 10:57:34 +0000325template <class ELFT>
326MipsReginfoInputSection<ELFT>::MipsReginfoInputSection(ObjectFile<ELFT> *F,
327 const Elf_Shdr *Header)
328 : InputSectionBase<ELFT>(F, Header, InputSectionBase<ELFT>::MipsReginfo) {}
329
330template <class ELFT>
331uint32_t MipsReginfoInputSection<ELFT>::getGeneralMask() const {
332 ArrayRef<uint8_t> D = this->getSectionData();
333 if (D.size() != sizeof(Elf_Mips_RegInfo))
334 error("Invalid size of .reginfo section");
335 return reinterpret_cast<const Elf_Mips_RegInfo *>(D.data())->ri_gprmask;
336}
337
338template <class ELFT>
339bool MipsReginfoInputSection<ELFT>::classof(const InputSectionBase<ELFT> *S) {
340 return S->SectionKind == InputSectionBase<ELFT>::MipsReginfo;
341}
342
Michael J. Spencer84487f12015-07-24 21:03:07 +0000343namespace lld {
344namespace elf2 {
Rafael Espindolac159c962015-10-19 21:00:02 +0000345template class InputSectionBase<object::ELF32LE>;
346template class InputSectionBase<object::ELF32BE>;
347template class InputSectionBase<object::ELF64LE>;
348template class InputSectionBase<object::ELF64BE>;
349
Rafael Espindola53d5cea2015-09-21 17:47:00 +0000350template class InputSection<object::ELF32LE>;
351template class InputSection<object::ELF32BE>;
352template class InputSection<object::ELF64LE>;
353template class InputSection<object::ELF64BE>;
Rafael Espindolac159c962015-10-19 21:00:02 +0000354
Rafael Espindola0c6a4f12015-11-11 19:54:14 +0000355template class EHInputSection<object::ELF32LE>;
356template class EHInputSection<object::ELF32BE>;
357template class EHInputSection<object::ELF64LE>;
358template class EHInputSection<object::ELF64BE>;
359
Rafael Espindolac159c962015-10-19 21:00:02 +0000360template class MergeInputSection<object::ELF32LE>;
361template class MergeInputSection<object::ELF32BE>;
362template class MergeInputSection<object::ELF64LE>;
363template class MergeInputSection<object::ELF64BE>;
Simon Atanasyan1d7df402015-12-20 10:57:34 +0000364
365template class MipsReginfoInputSection<object::ELF32LE>;
366template class MipsReginfoInputSection<object::ELF32BE>;
367template class MipsReginfoInputSection<object::ELF64LE>;
368template class MipsReginfoInputSection<object::ELF64BE>;
Michael J. Spencer84487f12015-07-24 21:03:07 +0000369}
370}