Home
last modified time | relevance | path

Searched refs:isec (Results 1 – 25 of 98) sorted by relevance

1234

/openbsd/gnu/llvm/lld/MachO/
H A DMarkLive.cpp27 InputSection *isec; member
32 : isec(isec), prev(prev) {} in WhyLiveEntry()
55 enqueue(isec, off, nullptr); in enqueue()
78 if (isec->isLive(off)) in enqueue()
80 isec->markLive(off); in enqueue()
113 if (d->isec) in addSym()
124 return entry->isec; in getInputSection()
132 InputSection *isec, in makeEntry() argument
135 if (!isec) { in makeEntry()
141 return isec; in makeEntry()
[all …]
H A DConcatOutputSection.cpp129 isecAddr = alignTo(isecAddr, isec->align) + isec->getSize(); in needsThunks()
175 isecEnd = alignTo(isecEnd, isec->align) + isec->getSize(); in estimateStubsInRangeVA()
199 isec->outSecOff = size; in finalizeOne()
200 isec->isFinal = true; in finalizeOne()
201 size += isec->getSize(); in finalizeOne()
207 finalizeOne(isec); in finalizeContents()
213 finalizeOne(isec); in finalize()
318 thunkInfo.isec = in finalize()
319 makeSyntheticInputSection(isec->getSegName(), isec->getName()); in finalize()
361 isec->writeTo(buf + isec->outSecOff); in writeTo()
[all …]
H A DICF.cpp136 if (!da->isec || !db->isec) { in equalsConstant()
140 isecA = da->isec; in equalsConstant()
142 isecB = db->isec; in equalsConstant()
292 if (defined->isec) { in run()
371 if (d->isec) in markSymAsAddrSig()
372 d->isec->keepUnique = true; in markSymAsAddrSig()
387 const InputSection *isec = addrSigSection->subsections[0].isec; in markAddrSigSymbols() local
428 !isec->keepUnique && !isec->hasAltEntry && in foldIdenticalSections()
431 foldable.push_back(isec); in foldIdenticalSections()
448 isec->data = copy; in foldIdenticalSections()
[all …]
H A DSymbols.cpp66 weakDef(isWeakDef), external(isExternal), isec(isec), value(value), in Defined()
68 if (isec) { in Defined()
69 isec->symbols.push_back(this); in Defined()
71 for (auto it = isec->symbols.rbegin(), rend = isec->symbols.rend(); in Defined()
94 if (!isec->isFinal) { in getVA()
105 return isec->getVA(value); in getVA()
109 return isec ? dyn_cast_or_null<ObjFile>(isec->getFile()) : nullptr; in getObjectFile()
115 if (isec) in canonicalize()
116 isec = isec->canonical(); in canonicalize()
120 if (!isec) in getSourceLocation()
[all …]
H A DInputSection.cpp78 if (subsec.isec == this) { in getLocation()
99 if (subsec.isec == this) { in getSourceLocation()
230 section.subsections.push_back({0, isec}); in makeSyntheticInputSection()
231 return isec; in makeSyntheticInputSection()
305 uint32_t type = sectionType(isec->getFlags()); in isCodeSection()
313 if (isec->getSegName() == segment_names::text) in isCodeSection()
314 return StringSwitch<bool>(isec->getName()) in isCodeSection()
323 isec->getSegName() == segment_names::data; in isCfStringSection()
328 isec->getSegName() == segment_names::data; in isClassRefsSection()
333 isec->getSegName() == segment_names::data; in isSelRefsSection()
[all …]
H A DSyntheticSections.cpp73 isec->parent = this; in SyntheticSection()
85 isec->isFinal = true; in MachHeaderSection()
234 loc.isec->parent->getSegmentOffset() + loc.isec->getOffset(loc.offset); in encodeRebases()
290 return a.isec->getVA(a.offset) < b.isec->getVA(b.offset); in finalizeContents()
1011 const InputSection *isec = subsec.isec; in collectDataInCodeEntries() local
1061 if (!defined->isec || !isCodeSection(defined->isec) || in finalizeContents()
1179 InputSection *isec = defined->isec; in emitStabs() local
1618 isec->parent = this; in addInput()
1621 align = isec->align; in addInput()
1759 isec->parent = this; in addInput()
[all …]
H A DRelocations.cpp25 const InputSection *isec, const Reloc &r) { in validateSymbolRelocation() argument
30 return (isec->getLocation(r.offset) + ": " + relocAttrs.name + in validateSymbolRelocation()
73 const ConcatInputSection *isec = osec->inputs[isecIdx]; in offsetToInputSection() local
74 if (*off < isec->outSecOff) in offsetToInputSection()
78 ConcatInputSection *isec = osec->inputs[isecIdx - 1]; in offsetToInputSection() local
79 *off -= isec->outSecOff; in offsetToInputSection()
80 return isec; in offsetToInputSection()
89 const InputSection *isec = offsetToInputSection(&off); in reportRangeError() local
90 std::string locStr = isec ? isec->getLocation(off) : "(invalid location)"; in reportRangeError()
H A DInputFiles.cpp461 return it->isec; in findContainingSubsection()
704 name, isec->getFile(), isec, value, size, sym.n_desc & N_WEAK_DEF, in createDefined()
711 name, isec->getFile(), isec, value, size, sym.n_desc & N_WEAK_DEF, in createDefined()
867 InputSection *isec = subsec.isec; in parseSymbols() local
908 isec->data = isec->data.slice(0, symbolOffset); in parseSymbols()
943 isec->live = true; in OpaqueFile()
1140 for (auto it = isec->relocs.begin(); it != isec->relocs.end();) { in registerCompactUnwind()
1337 if (pcSym->isec == isec) { in targetSymFromCanonicalSubtractor()
1379 auto *isec = cast<ConcatInputSection>(subsec.isec); in registerEhFrames() local
1386 make<Defined>("EH_Frame", isec->getFile(), isec, /*value=*/0, in registerEhFrames()
[all …]
H A DSymbolTable.cpp73 assert(!file || !isa<BitcodeFile>(file) || !isec); in addDefined()
100 std::string srcLoc2 = isec ? isec->getSourceLocation(value) : ""; in addDefined()
256 assert(!isec || !isec->getFile()); // See makeSyntheticInputSection(). in addSynthetic()
292 osec = ssec->isec->parent; in handleSectionBoundarySymbol()
303 isec->live = true; in handleSectionBoundarySymbol()
307 osec = isec->parent = ConcatOutputSection::getOrCreateForInput(isec); in handleSectionBoundarySymbol()
308 inputSections.push_back(isec); in handleSectionBoundarySymbol()
376 const InputSection *isec; member
552 std::string src = loc.isec->getSourceLocation(loc.offset); in reportUndefinedSymbol()
555 message += loc.isec->getLocation(loc.offset); in reportUndefinedSymbol()
[all …]
H A DMapFile.cpp80 if (d->isec && d->getFile() == file && in gatherMapInfo()
81 !isa<CStringInputSection>(d->isec)) { in gatherMapInfo()
93 if (auto isec = dyn_cast<CStringInputSection>(subsec.isec)) { in gatherMapInfo() local
94 auto &liveCStrings = info.liveCStringsForSection[isec->parent]; in gatherMapInfo()
95 for (const auto &[i, piece] : llvm::enumerate(isec->pieces)) { in gatherMapInfo()
97 liveCStrings.push_back({isec->parent->addr + piece.outSecOff, in gatherMapInfo()
98 {fileIndex, isec->getStringRef(i)}}); in gatherMapInfo()
100 info.deadCStrings.push_back({fileIndex, isec->getStringRef(i)}); in gatherMapInfo()
194 for (const InputSection *isec : concatOsec->inputs) { in writeMapFile() local
195 for (Defined *sym : isec->symbols) in writeMapFile()
H A DInputSection.h126 static bool classof(const InputSection *isec) { in classof() argument
127 return isec->kind() == ConcatKind; in classof()
158 inline bool shouldOmitFromOutput(InputSection *isec) { in shouldOmitFromOutput() argument
159 return isa<ConcatInputSection>(isec) && in shouldOmitFromOutput()
163 inline bool isCoalescedWeak(InputSection *isec) { in isCoalescedWeak() argument
164 return isa<ConcatInputSection>(isec) && in isCoalescedWeak()
165 cast<ConcatInputSection>(isec)->isCoalescedWeak(); in isCoalescedWeak()
229 static bool classof(const InputSection *isec) { in classof() argument
230 return isec->kind() == CStringLiteralKind; in classof()
249 static bool classof(const InputSection *isec) { in classof() argument
[all …]
H A DSectionPriorities.cpp85 auto getOrCreateCluster = [&](const InputSection *isec) -> int { in CallGraphSort() argument
86 auto res = secToCluster.try_emplace(isec, clusters.size()); in CallGraphSort()
88 sections.push_back(isec); in CallGraphSort()
89 clusters.emplace_back(clusters.size(), isec->getSize()); in CallGraphSort()
233 const InputSection *isec = sections[i]; in run() local
237 for (Symbol *sym : isec->getFile()->symbols) { in run()
239 if (d->isec == isec) in run()
261 const InputFile *f = sym->isec->getFile(); in getSymbolPriority()
290 callGraphProfile[{fromSym->isec, toSym->isec}] += entry.count; in extractCallGraphProfile()
373 size_t &priority = sectionPriorities[sym->isec]; in buildInputSectionPriorities()
H A DSyntheticSections.h53 InputSection *isec; variable
144 const InputSection *isec; member
147 Location(const InputSection *isec, uint64_t offset) in Location()
148 : isec(isec), offset(offset) {} in Location()
149 uint64_t getVA() const { return isec->getVA(offset); } in getVA()
163 void addEntry(const InputSection *isec, uint64_t offset) { in addEntry() argument
165 locations.push_back({isec, offset}); in addEntry()
330 void finalize() override { isec->isFinal = true; } in finalize()
678 void addInput(ConcatInputSection *isec) { sections.push_back(isec); } in addInput() argument
741 void addRebase(const InputSection *isec, uint64_t offset) { in addRebase() argument
[all …]
H A DEhFrame.h93 EhRelocator(InputSection *isec) : isec(isec) {} in EhRelocator() argument
108 InputSection *isec;
/openbsd/gnu/llvm/lld/ELF/
H A DThunks.cpp496 STT_FUNC, 0, isec); in addSymbols()
522 STT_FUNC, 0, isec); in addSymbols()
634 STT_FUNC, 0, isec); in addSymbols()
652 STT_FUNC, 1, isec); in addSymbols()
673 STT_FUNC, 0, isec); in addSymbols()
694 STT_FUNC, 1, isec); in addSymbols()
917 isec); in addSymbols()
1036 isec); in addSymbols()
1160 isec); in addSymbols()
1196 isec); in addSymbols()
[all …]
H A DARMErrataFix.cpp208 uint64_t sourceAddr = isec->getVA(0) + off; in branchDestInFirstRegion()
238 isec->getVA() + isec->getSize() + 0x100); in patchInRange()
257 uint64_t isecAddr = isec->getVA(0); in scanCortexA8Errata657417()
269 const uint8_t *buf = isec->content().begin(); in scanCortexA8Errata657417()
289 if (relIt != isec->relocs().end()) in scanCortexA8Errata657417()
296 warn(toString(isec->file) + in scanCortexA8Errata657417()
377 for (const InputSection *isec : isd.sections) { in insertPatches() local
378 isecLimit = isec->outSecOff + isec->getSize(); in insertPatches()
485 for (InputSection *isec : isd.sections) { in patchInputSectionDescription()
487 if (isa<SyntheticSection>(isec)) in patchInputSectionDescription()
[all …]
H A DTarget.cpp97 auto *isec = dyn_cast<InputSection>(d); in getErrorPlace() local
98 if (!isec || !isec->getParent() || (isec->type & SHT_NOBITS)) in getErrorPlace()
103 ? (Out::bufferStart + isec->getParent()->offset + isec->outSecOff) in getErrorPlace()
104 : isec->contentMaybeDecompress().data(); in getErrorPlace()
106 assert(isa<SyntheticSection>(isec) && "No data but not synthetic?"); in getErrorPlace()
109 if (isecLoc <= loc && loc < isecLoc + isec->getSize()) { in getErrorPlace()
110 std::string objLoc = isec->getLocation(loc - isecLoc); in getErrorPlace()
114 return {isec, objLoc + ": ", in getErrorPlace()
115 isec->file ? isec->getSrcMsg(dummy, loc - isecLoc) : ""}; in getErrorPlace()
H A DAArch64ErrataFix.cpp338 uint64_t isecAddr = isec->getVA(0); in scanCortexA53Errata843419()
353 const uint8_t *buf = isec->content().begin(); in scanCortexA53Errata843419()
493 for (const InputSection *isec : isd.sections) { in insertPatches() local
494 isecLimit = isec->outSecOff + isec->getSize(); in insertPatches()
531 InputSection *isec, in implementPatch() argument
550 if (relIt != isec->relocs().end() && in implementPatch()
557 auto *ps = make<Patch843419Section>(isec, patcheeOffset); in implementPatch()
564 if (relIt != isec->relocs().end()) { in implementPatch()
578 for (InputSection *isec : isd.sections) { in patchInputSectionDescription()
580 if (isa<SyntheticSection>(isec)) in patchInputSectionDescription()
[all …]
H A DOutputSections.cpp103 partition = isec->partition; in recordSection()
104 isec->parent = this; in recordSection()
133 type = isec->type; in commitSection()
140 entsize = isec->entsize; in commitSection()
141 flags = isec->flags; in commitSection()
146 toString(isec) + ": 0x" + utohexstr(isec->flags) + in commitSection()
150 isec->parent = this; in commitSection()
165 if (entsize != isec->entsize) in commitSection()
495 isec->writeTo<ELFT>(buf + isec->outSecOff); in writeTo()
499 uint8_t *start = buf + isec->outSecOff + isec->getSize(); in writeTo()
[all …]
H A DLinkerScript.cpp715 osd->osec.recordSection(isec); in createSection()
728 if (isec->type == SHT_GROUP || (isec->flags & SHF_GROUP)) in addInputSec()
737 if (!isa<SyntheticSection>(isec) && in addInputSec()
738 (isec->type == SHT_REL || isec->type == SHT_RELA)) { in addInputSec()
739 auto *sec = cast<InputSection>(isec); in addInputSec()
814 sec->recordSection(isec); in addInputSec()
854 ctx.inputSections[n++] = isec; in addOrphanSections()
866 add(isec); in addOrphanSections()
1061 assert(isec->getParent() == sec); in assignOffsets()
1064 isec->outSecOff = dot - sec->addr; in assignOffsets()
[all …]
H A DMapFile.cpp178 for (InputSection *isec : isd->sections) { in writeMapFile()
179 if (auto *ehSec = dyn_cast<EhFrameSection>(isec)) { in writeMapFile()
184 writeHeader(os, isec->getVA(), osec->getLMA() + isec->outSecOff, in writeMapFile()
185 isec->getSize(), isec->addralign); in writeMapFile()
186 os << indent8 << toString(isec) << '\n'; in writeMapFile()
187 for (Symbol *sym : llvm::make_first_range(sectionSyms[isec])) in writeMapFile()
H A DRelocations.cpp109 if (errPlace.isec && errPlace.isec->name.startswith(".debug")) in reportRangeError()
870 Partition &part = isec.getPartition(); in addRelativeReloc()
882 {&isec, offsetInSec}); in addRelativeReloc()
1960 uint64_t thunkSecOff = isec->outSecOff; in getISDThunkSec()
1963 thunkSecOff = isec->outSecOff + isec->getSize(); in getISDThunkSec()
1967 isec->getObjMsg(src - (os->addr + isec->outSecOff))); in getISDThunkSec()
1981 OutputSection *tos = isec->getParent(); in getISThunkSec()
1990 if (isec->outSecOff < first->outSecOff || last->outSecOff < isec->outSecOff) in getISThunkSec()
1994 thunkedSections[isec] = ts; in getISThunkSec()
2038 isecLimit = isec->outSecOff + isec->getSize(); in createInitialThunkSections()
[all …]
/openbsd/gnu/usr.bin/binutils-2.17/ld/emultempl/
H A Dsh64elf.em100 isec = isec->next)
152 isec = isec->next)
156 && (bfd_get_section_flags (isec->owner, isec)
179 isec = isec->next)
183 && (bfd_get_section_flags (isec->owner, isec)
283 isec = isec->next)
287 && (bfd_get_section_flags (isec->owner, isec)
310 isec = isec->next)
314 && (bfd_get_section_flags (isec->owner, isec)
363 isec = isec->next)
[all …]
/openbsd/gnu/usr.bin/binutils/ld/emultempl/
H A Dsh64elf.em100 isec = isec->next)
152 isec = isec->next)
156 && (bfd_get_section_flags (isec->owner, isec)
179 isec = isec->next)
183 && (bfd_get_section_flags (isec->owner, isec)
283 isec = isec->next)
287 && (bfd_get_section_flags (isec->owner, isec)
310 isec = isec->next)
363 isec = isec->next)
433 isec = isec->next)
[all …]
/openbsd/gnu/llvm/lld/MachO/Arch/
H A DARM64.cpp345 uint64_t addr1 = isec->getVA() + offset1; in applyAdrpAdd()
401 uint64_t addr1 = isec->getVA() + offset1; in applyAdrpLdr()
402 uint64_t addr2 = isec->getVA() + offset2; in applyAdrpLdr()
421 applyAdrpAdd(buf, isec, offset1, offset2); in applyAdrpLdrGot()
457 uint64_t addr1 = isec->getVA() + offset1; in applyAdrpAddLdr()
458 uint64_t addr3 = isec->getVA() + offset3; in applyAdrpAddLdr()
532 uint64_t addr1 = isec->getVA() + offset1; in applyAdrpLdrGotLdr()
533 uint64_t addr2 = isec->getVA() + offset2; in applyAdrpLdrGotLdr()
614 const ConcatInputSection *isec = in applyOptimizationHints() local
616 if (!isec || isec->shouldOmitFromOutput()) in applyOptimizationHints()
[all …]

1234