| /freebsd/contrib/llvm-project/lld/MachO/ |
| H A D | Symbols.cpp | 48 uint64_t Symbol::getStubVA() const { return in.stubs->getVA(stubsIndex); } in getStubVA() 50 return in.lazyPointers->getVA(stubsIndex); in getLazyPtrVA() 52 uint64_t Symbol::getGotVA() const { return in.got->getVA(gotIndex); } in getGotVA() 53 uint64_t Symbol::getTlvVA() const { return in.tlvPointers->getVA(gotIndex); } in getTlvVA() 88 uint64_t Defined::getVA() const { in getVA() function in Defined 105 return isec()->getVA(value); in getVA() 129 uint64_t DylibSymbol::getVA() const { in getVA() function in DylibSymbol 130 return isInStubs() ? getStubVA() : Symbol::getVA(); in getVA()
|
| H A D | Symbols.h | 57 virtual uint64_t getVA() const { return 0; } in getVA() function 80 return isInStubs() ? getStubVA() : getVA(); in resolveBranchVA() 82 uint64_t resolveGotVA() const { return isInGot() ? getGotVA() : getVA(); } in resolveGotVA() 83 uint64_t resolveTlvVA() const { return isInGot() ? getTlvVA() : getVA(); } in resolveTlvVA() 132 uint64_t getVA() const override; 265 uint64_t getVA() const override;
|
| H A D | InputSection.cpp | 90 uint64_t InputSection::getVA(uint64_t off) const { in getVA() function in InputSection 102 return sym->getVA(); in resolveSymbolVA() 231 minuendVA = toSym->getVA() + minuend.addend; in writeTo() 235 minuendVA = referentIsec->getVA(minuend.addend); in writeTo() 237 referentVA = minuendVA - fromSym->getVA(); in writeTo() 262 referentVA = referentIsec->getVA(r.addend); in writeTo() 269 target->relocateOne(loc, r, referentVA, getVA() + r.offset); in writeTo()
|
| H A D | ConcatOutputSection.cpp | 188 uint64_t isecVA = inputs[callIdx]->getVA(); in estimateBranchTargetThresholdVA() 200 return t->getVA() <= isecVA; in estimateBranchTargetThresholdVA() 300 uint64_t isecVA = isec->getVA(); in finalize() 375 uint64_t thunkVA = thunkInfo.isec->getVA(); in finalize()
|
| H A D | SyntheticSections.cpp | 283 return a.isec->getVA(a.offset) < b.isec->getVA(b.offset); in finalizeContents() 380 writeChainedRebase(buf, sym->getVA() + addend); in writeChainedFixup() 390 write64le(&buf[i * target->wordSize], defined->getVA()); in writeTo() 612 return a.target.getVA() < b.target.getVA(); in sortBindings() 616 return a.second[0].target.getVA() < b.second[0].target.getVA(); in sortBindings() 954 auto selrefAddr = selRef->getVA(0); in writeTo() 985 write64le(buf + off, sym->getVA()); in writeTo() 1102 {static_cast<uint32_t>(isec->getVA(it->offset - beginAddr) - in collectDataInCodeEntries() 1140 addrs.push_back(defined->getVA()); in finalizeContents() 1282 symStab.value = target->getVA(); in emitStabs() [all …]
|
| H A D | InputSection.h | 51 uint64_t getVA(uint64_t off) const; 112 uint64_t getVA() const { return InputSection::getVA(0); } in getVA() function
|
| H A D | SyntheticSections.h | 126 uint64_t getVA(uint32_t gotIndex) const { in getVA() function 150 uint64_t getVA() const { return isec->getVA(offset); } in getVA() function 291 uint64_t getVA(uint32_t stubsIndex) const { in getVA() function 365 uint64_t getVA(uint32_t index) const { in getVA() function
|
| /freebsd/contrib/llvm-project/lld/ELF/ |
| H A D | InputSection.cpp | 230 uint64_t SectionBase::getVA(uint64_t offset) const { in getVA() function in SectionBase 489 p->r_offset = sec->getVA(rel.offset); in copyRelocations() 546 sym.getVA(ctx, addend) - section->getOutputSection()->addr; in copyRelocations() 741 return s.getVA(ctx, 0) + ctx.arg.wordsize * 2 + in getTlsTpOffset() 749 return s.getVA(ctx, 0) + (tls->p_vaddr & (tls->p_align - 1)) - 0x7000; in getTlsTpOffset() 757 return s.getVA(ctx, 0) + (tls->p_vaddr & (tls->p_align - 1)); in getTlsTpOffset() 765 return s.getVA(ctx, 0) - tls->p_memsz - in getTlsTpOffset() 783 return r.sym->getVA(ctx, a); in getRelocTargetVA() 789 return r.sym->getVA(ctx, a) - getARMStaticBase(*r.sym); in getRelocTargetVA() 803 return ctx.in.got->getVA() + a - p; in getRelocTargetVA() [all …]
|
| H A D | Thunks.cpp | 547 return destination.getVA(ctx) - (getThunkTargetSym()->getVA(ctx) + 4); in computeOffset() 634 uint64_t v = s.isInPlt(ctx) ? s.getPltVA(ctx) : s.getVA(ctx, a); in getAArch64ThunkDestVA() 642 uint64_t p = getThunkTargetSym()->getVA(ctx); in getMayUseShortThunk() 655 uint64_t p = getThunkTargetSym()->getVA(ctx); in writeTo() 678 ? landingPad->getVA(ctx, 0) in writeLong() 711 ? landingPad->getVA(ctx, 0) in writeLong() 741 ? landingPad->getVA(ctx, 0) in writeLong() 743 uint64_t p = getThunkTargetSym()->getVA(ctx); in writeLong() 776 uint64_t s = destination.getVA(ctx, addend); in getMayUseShortThunk() 777 uint64_t p = getThunkTargetSym()->getVA(ctx); in getMayUseShortThunk() [all …]
|
| H A D | ARMErrataFix.cpp | 149 return patchee->getVA(patcheeOffset); in getBranchAddr() 200 uint64_t p = getVA(pcBias); in writeTo() 211 uint64_t sourceAddr = isec->getVA(0) + off; in branchDestInFirstRegion() 219 r->expr == R_PLT_PC ? r->sym->getPltVA(ctx) : r->sym->getVA(ctx); in branchDestInFirstRegion() 241 isBcc(instr) ? R_ARM_THM_JUMP19 : R_ARM_THM_JUMP24, isec->getVA(off), in patchInRange() 242 isec->getVA() + isec->getSize() + 0x100); in patchInRange() 262 uint64_t isecAddr = isec->getVA(0); in scanCortexA8Errata657417() 422 utohexstr(isec->getVA(sr.off)) << " in unpatched output"; in implementPatch() 450 : sr.rel->sym->getVA(ctx); in implementPatch()
|
| H A D | MapFile.cpp | 72 ret[dr->section].emplace_back(dr, dr->getVA(ctx)); in getSectionSyms() 99 uint64_t vma = syms[i]->getVA(ctx); in getSymbolStrings() 100 uint64_t lma = osec ? osec->getLMA() + vma - osec->getVA(0) : 0; in getSymbolStrings() 166 uint64_t lma = osec ? osec->getLMA() + assign->addr - osec->getVA(0) : 0; in writeMapFile() 188 writeHeader(ctx, os, isec->getVA(), osec->getLMA() + isec->outSecOff, in writeMapFile() 208 osec->getLMA() + assign->addr - osec->getVA(0), in writeMapFile()
|
| H A D | Symbols.cpp | 104 uint64_t va = isec->getVA(offset); in getSymVA() 149 uint64_t Symbol::getVA(Ctx &ctx, int64_t addend) const { in getVA() function in Symbol 155 return ctx.in.igotPlt->getVA() + getGotPltOffset(ctx); in getGotVA() 156 return ctx.in.got->getVA() + getGotOffset(ctx); in getGotVA() 165 return ctx.in.igotPlt->getVA() + getGotPltOffset(ctx); in getGotPltVA() 166 return ctx.in.gotPlt->getVA() + getGotPltOffset(ctx); in getGotPltVA() 177 uint64_t outVA = isInIplt ? ctx.in.iplt->getVA() + in getPltVA() 179 : ctx.in.plt->getVA() + ctx.in.plt->headerSize + in getPltVA()
|
| H A D | AArch64ErrataFix.cpp | 337 uint64_t isecAddr = isec->getVA(0); in scanCortexA53Errata843419() 405 return patchee->getVA(patcheeOffset); in getLDSTAddr() 418 uint64_t p = patchSym->getVA(ctx) + 4; in writeTo() 597 uint64_t startAddr = isec->getVA(off); in patchInputSectionDescription()
|
| H A D | SyntheticSections.cpp | 578 uint64_t va = getPartition(ctx).ehFrameHdr->getVA(); in getFdeData() 723 return getVA() + getTlsDescOffset(sym); in getTlsDescAddr() 727 return this->getVA() + b.getTlsGdIdx(ctx) * ctx.target->gotEntrySize; in getGlobalDynAddr() 791 g.local16.insert({{nullptr, getMipsPageAddr(sym.getVA(ctx, addend))}, 0}); in addEntry() 850 uint64_t symAddr = getMipsPageAddr(sym.getVA(ctx, addend)); in getPageEntryOffset() 854 g.local16.lookup({nullptr, getMipsPageAddr(sym.getVA(ctx, addend))}); in getPageEntryOffset() 1142 return ctx.sym.mipsGp->getVA(ctx, 0); in getGp() 1143 return getVA() + gots[f->mipsGotIndex].startIndex * ctx.arg.wordsize + 0x7ff0; in getGp() 1167 va = s->getVA(ctx, a); in writeTo() 1376 entries.emplace_back(tag, sec.getVA()); in computeContents() [all …]
|
| /freebsd/contrib/llvm-project/lld/ELF/Arch/ |
| H A D | X86.cpp | 172 write32le(buf, ctx.mainPart->dynamic->getVA()); in writeGotPltHeader() 183 write32le(buf, s.getVA(ctx)); in writeIgotPlt() 211 uint32_t gotPlt = ctx.in.gotPlt->getVA(); in writePltHeader() 226 write32le(buf + 2, sym.getGotPltVA(ctx) - ctx.in.gotPlt->getVA()); in writePlt() 238 write32le(buf + 12, ctx.in.plt->getVA() - pltEntryAddr - 16); in writePlt() 540 uint64_t va = ctx.in.ibtPlt->getVA() + IBTPltHeaderSize + in writeGotPlt() 554 write32le(buf + 6, sym.getGotPltVA(ctx) - ctx.in.gotPlt->getVA()); in writePlt() 651 uint32_t ebx = ctx.in.gotPlt->getVA(); in writePlt() 652 unsigned off = pltEntryAddr - ctx.in.plt->getVA(); in writePlt() 691 uint32_t gotPlt = ctx.in.gotPlt->getVA(); in writePltHeader() [all …]
|
| H A D | ARM.cpp | 210 write32(ctx, buf, ctx.in.plt->getVA()); in writeGotPlt() 215 write32(ctx, buf, s.getVA(ctx)); in writeIgotPlt() 229 uint64_t gotPlt = ctx.in.gotPlt->getVA(); in writePltHeaderLong() 230 uint64_t l1 = ctx.in.plt->getVA() + 8; in writePltHeaderLong() 255 uint64_t offset = ctx.in.gotPlt->getVA() - ctx.in.plt->getVA() - 16; in writePltHeader() 283 uint64_t offset = ctx.in.gotPlt->getVA() - ctx.in.plt->getVA() - 4; in writePltHeader() 406 if (s.isFunc() && expr == R_PC && (s.getVA(ctx) & 1)) in needsThunk() 410 uint64_t dst = (expr == R_PLT_PC) ? s.getPltVA(ctx) : s.getVA(ctx); in needsThunk() 412 (!ctx.arg.armHasBlx && (s.getVA(ctx) & 1)); in needsThunk() 419 (s.isFunc() && (s.getVA(ctx) & 1) == 0)) in needsThunk() [all …]
|
| H A D | RISCV.cpp | 203 write64le(buf, ctx.mainPart->dynamic->getVA()); in writeGotHeader() 205 write32le(buf, ctx.mainPart->dynamic->getVA()); in writeGotHeader() 210 write64le(buf, ctx.in.plt->getVA()); in writeGotPlt() 212 write32le(buf, ctx.in.plt->getVA()); in writeGotPlt() 218 write64le(buf, s.getVA(ctx)); in writeIgotPlt() 220 write32le(buf, s.getVA(ctx)); in writeIgotPlt() 233 uint32_t offset = ctx.in.gotPlt->getVA() - ctx.in.plt->getVA(); in writePltHeader() 468 int64_t displace = SignExtend64(val - gp->getVA(ctx), bits); in relocate() 659 auto val = rel.sym->getVA(ctx, rel.addend) - in relocateAlloc() 660 rel1.sym->getVA(ctx, rel1.addend); in relocateAlloc() [all …]
|
| H A D | AArch64.cpp | 372 write64(ctx, buf, ctx.in.plt->getVA()); in writeGotPlt() 377 write64(ctx, buf, s.getVA(ctx)); in writeIgotPlt() 393 uint64_t got = ctx.in.gotPlt->getVA(); in writePltHeader() 394 uint64_t plt = ctx.in.plt->getVA(); in writePltHeader() 433 uint64_t dst = expr == R_PLT_PC ? s.getPltVA(ctx) : s.getVA(ctx, a); in needsThunk() 833 int64_t val = sym.getVA(ctx) - (secAddr + addRel.offset); in tryRelaxAdrpAdd() 899 getAArch64Page(sym.getVA(ctx)) - getAArch64Page(secAddr + adrpRel.offset); in tryRelaxAdrpLdr() 915 SignExtend64(getAArch64Page(sym.getVA(ctx)) - in tryRelaxAdrpLdr() 919 SignExtend64(sym.getVA(ctx), 64)); in tryRelaxAdrpLdr() 1131 uint64_t got = ctx.in.gotPlt->getVA(); in writePltHeader() [all …]
|
| H A D | X86_64.cpp | 430 write64le(buf, ctx.mainPart->dynamic->getVA()); in writeGotPltHeader() 441 write64le(buf, s.getVA(ctx)); in writeIgotPlt() 451 uint64_t gotPlt = ctx.in.gotPlt->getVA(); in writePltHeader() 452 uint64_t plt = ctx.in.ibtPlt ? ctx.in.ibtPlt->getVA() : ctx.in.plt->getVA(); in writePltHeader() 468 write32le(buf + 12, ctx.in.plt->getVA() - pltEntryAddr - 16); in writePlt() 1251 uint64_t va = ctx.in.ibtPlt->getVA() + IBTPltHeaderSize + in writeGotPlt() 1341 uint64_t gotPlt = ctx.in.gotPlt->getVA(); in writePltHeader() 1342 uint64_t plt = ctx.in.plt->getVA(); in writePltHeader() 1359 uint64_t off = pltEntryAddr - ctx.in.plt->getVA(); in writePlt() 1400 write32le(buf + 8, ctx.in.plt->getVA() - pltEntryAddr - 12); in writePlt()
|
| H A D | SystemZ.cpp | 181 write64be(buf, ctx.mainPart->dynamic->getVA()); in writeGotHeader() 190 write64be(buf, s.getVA(ctx)); in writeIgotPlt() 205 uint64_t got = ctx.in.got->getVA(); in writePltHeader() 206 uint64_t plt = ctx.in.plt->getVA(); in writePltHeader() 230 write32be(buf + 24, (ctx.in.plt->getVA() - pltEntryAddr - 22) >> 1); in writePlt()
|
| H A D | LoongArch.cpp | 333 write64le(buf, ctx.in.plt->getVA()); in writeGotPlt() 335 write32le(buf, ctx.in.plt->getVA()); in writeGotPlt() 341 write64le(buf, s.getVA(ctx)); in writeIgotPlt() 343 write32le(buf, s.getVA(ctx)); in writeIgotPlt() 366 uint32_t offset = ctx.in.gotPlt->getVA() - ctx.in.plt->getVA(); in writePltHeader() 828 dest = rHi20.sym->getVA(ctx); in relaxPCHi20Lo12() 883 (r.expr == R_PLT_PC ? r.sym->getPltVA(ctx) : r.sym->getVA(ctx)) + in relaxCall36() 914 uint64_t val = r.sym->getVA(ctx, r.addend); in relaxTlsLe() 933 const uint64_t secAddr = sec.getVA(); in relax() 998 isUInt<12>(r.sym->getVA(ctx, r.addend))) in relax() [all …]
|
| H A D | PPC.cpp | 76 uint32_t glink = ctx.in.plt->getVA(); // VA of .glink in writePPC32GlinkSection() 103 uint32_t got = ctx.in.got->getVA(); in writePPC32GlinkSection() 193 write32(ctx, buf, ctx.mainPart->dynamic->getVA()); in writeGotHeader() 199 ctx.in.plt->getVA() + ctx.in.plt->headerSize + 4 * s.getPltIdx(ctx)); in writeGotPlt() 210 return !PPC::inBranchRange(type, branchAddr, s.getVA(ctx, a)); in needsThunk()
|
| H A D | Mips.cpp | 97 if (!s.isPreemptible && !(s.getVA(ctx) & 0x1)) in getRelExpr() 206 uint64_t va = ctx.in.plt->getVA(); in writeGotPlt() 259 uint64_t gotPlt = ctx.in.gotPlt->getVA(); in writePltHeader() 260 uint64_t plt = ctx.in.plt->getVA(); in writePltHeader() 313 uint64_t gotPlt = ctx.in.gotPlt->getVA(); in writePltHeader()
|
| H A D | Hexagon.cpp | 302 return !ctx.target->inBranchRange(type, branchAddr, s.getVA(ctx, a)); in needsThunk() 428 uint64_t off = ctx.in.gotPlt->getVA() - ctx.in.plt->getVA(); in writePltHeader()
|
| /freebsd/contrib/llvm-project/lld/MachO/Arch/ |
| H A D | ARM64.cpp | 147 objcMsgSendAddr = d->getVA(); in writeObjCMsgSendStub() 406 uint64_t addr1 = isec->getVA() + offset1; in applyAdrpAdd() 435 uint64_t page1 = pageBits(offset1 + isec->getVA()) + adrp1.addend; in applyAdrpAdrp() 436 uint64_t page2 = pageBits(offset2 + isec->getVA()) + adrp2.addend; in applyAdrpAdrp() 463 uint64_t addr1 = isec->getVA() + offset1; in applyAdrpLdr() 464 uint64_t addr2 = isec->getVA() + offset2; in applyAdrpLdr() 515 uint64_t addr1 = isec->getVA() + offset1; in applyAdrpAddLdr() 516 uint64_t addr3 = isec->getVA() + offset3; in applyAdrpAddLdr()
|