Lines Matching refs:Section

259 void RuntimeDyldELF::resolveX86_64Relocation(const SectionEntry &Section,  in resolveX86_64Relocation()  argument
273 *Section.getAddressWithOffset(Offset) = TruncatedAddr; in resolveX86_64Relocation()
275 << format("%p\n", Section.getAddressWithOffset(Offset))); in resolveX86_64Relocation()
282 support::ulittle16_t::ref(Section.getAddressWithOffset(Offset)) = in resolveX86_64Relocation()
285 << format("%p\n", Section.getAddressWithOffset(Offset))); in resolveX86_64Relocation()
289 support::ulittle64_t::ref(Section.getAddressWithOffset(Offset)) = in resolveX86_64Relocation()
292 << format("%p\n", Section.getAddressWithOffset(Offset))); in resolveX86_64Relocation()
302 support::ulittle32_t::ref(Section.getAddressWithOffset(Offset)) = in resolveX86_64Relocation()
305 << format("%p\n", Section.getAddressWithOffset(Offset))); in resolveX86_64Relocation()
309 uint64_t FinalAddress = Section.getLoadAddressWithOffset(Offset); in resolveX86_64Relocation()
313 Section.getAddress()[Offset] = TruncOffset; in resolveX86_64Relocation()
317 uint64_t FinalAddress = Section.getLoadAddressWithOffset(Offset); in resolveX86_64Relocation()
321 support::ulittle32_t::ref(Section.getAddressWithOffset(Offset)) = in resolveX86_64Relocation()
326 uint64_t FinalAddress = Section.getLoadAddressWithOffset(Offset); in resolveX86_64Relocation()
328 support::ulittle64_t::ref(Section.getAddressWithOffset(Offset)) = in resolveX86_64Relocation()
337 for (const auto &Section : Sections) { in resolveX86_64Relocation() local
338 if (Section.getName() == ".got") { in resolveX86_64Relocation()
339 GOTBase = Section.getLoadAddressWithOffset(0); in resolveX86_64Relocation()
345 support::ulittle64_t::ref(Section.getAddressWithOffset(Offset)) = GOTOffset; in resolveX86_64Relocation()
350 support::ulittle64_t::ref(Section.getAddressWithOffset(Offset)) = 1; in resolveX86_64Relocation()
359 support::ulittle64_t::ref(Section.getAddressWithOffset(Offset)) = in resolveX86_64Relocation()
370 support::ulittle32_t::ref(Section.getAddressWithOffset(Offset)) = in resolveX86_64Relocation()
377 void RuntimeDyldELF::resolveX86Relocation(const SectionEntry &Section, in resolveX86Relocation() argument
382 support::ulittle32_t::ref(Section.getAddressWithOffset(Offset)) = in resolveX86Relocation()
391 Section.getLoadAddressWithOffset(Offset) & 0xFFFFFFFF; in resolveX86Relocation()
393 support::ulittle32_t::ref(Section.getAddressWithOffset(Offset)) = in resolveX86Relocation()
405 void RuntimeDyldELF::resolveAArch64Relocation(const SectionEntry &Section, in resolveAArch64Relocation() argument
409 reinterpret_cast<uint32_t *>(Section.getAddressWithOffset(Offset)); in resolveAArch64Relocation()
410 uint64_t FinalAddress = Section.getLoadAddressWithOffset(Offset); in resolveAArch64Relocation()
415 << format("%llx", Section.getAddressWithOffset(Offset)) in resolveAArch64Relocation()
587 void RuntimeDyldELF::resolveARMRelocation(const SectionEntry &Section, in resolveARMRelocation() argument
592 reinterpret_cast<uint32_t *>(Section.getAddressWithOffset(Offset)); in resolveARMRelocation()
593 uint32_t FinalAddress = Section.getLoadAddressWithOffset(Offset) & 0xFFFFFFFF; in resolveARMRelocation()
597 << Section.getAddressWithOffset(Offset) in resolveARMRelocation()
674 for (auto &Section : Obj.sections()) { in findPPC64TOCSection() local
675 Expected<StringRef> NameOrErr = Section.getName(); in findPPC64TOCSection()
685 findOrEmitSection(Obj, Section, false, LocalSections)) in findPPC64TOCSection()
811 void RuntimeDyldELF::resolvePPC32Relocation(const SectionEntry &Section, in resolvePPC32Relocation() argument
814 uint8_t *LocalAddress = Section.getAddressWithOffset(Offset); in resolvePPC32Relocation()
831 void RuntimeDyldELF::resolvePPC64Relocation(const SectionEntry &Section, in resolvePPC64Relocation() argument
834 uint8_t *LocalAddress = Section.getAddressWithOffset(Offset); in resolvePPC64Relocation()
878 uint64_t FinalAddress = Section.getLoadAddressWithOffset(Offset); in resolvePPC64Relocation()
883 uint64_t FinalAddress = Section.getLoadAddressWithOffset(Offset); in resolvePPC64Relocation()
888 uint64_t FinalAddress = Section.getLoadAddressWithOffset(Offset); in resolvePPC64Relocation()
899 uint64_t FinalAddress = Section.getLoadAddressWithOffset(Offset); in resolvePPC64Relocation()
908 uint64_t FinalAddress = Section.getLoadAddressWithOffset(Offset); in resolvePPC64Relocation()
915 uint64_t FinalAddress = Section.getLoadAddressWithOffset(Offset); in resolvePPC64Relocation()
925 void RuntimeDyldELF::resolveSystemZRelocation(const SectionEntry &Section, in resolveSystemZRelocation() argument
928 uint8_t *LocalAddress = Section.getAddressWithOffset(Offset); in resolveSystemZRelocation()
935 int64_t Delta = (Value + Addend) - Section.getLoadAddressWithOffset(Offset); in resolveSystemZRelocation()
942 int64_t Delta = (Value + Addend) - Section.getLoadAddressWithOffset(Offset); in resolveSystemZRelocation()
948 int64_t Delta = (Value + Addend) - Section.getLoadAddressWithOffset(Offset); in resolveSystemZRelocation()
954 int64_t Delta = (Value + Addend) - Section.getLoadAddressWithOffset(Offset); in resolveSystemZRelocation()
960 int64_t Delta = (Value + Addend) - Section.getLoadAddressWithOffset(Offset); in resolveSystemZRelocation()
979 void RuntimeDyldELF::resolveBPFRelocation(const SectionEntry &Section, in resolveBPFRelocation() argument
994 write(isBE, Section.getAddressWithOffset(Offset), Value + Addend); in resolveBPFRelocation()
996 << format("%p\n", Section.getAddressWithOffset(Offset))); in resolveBPFRelocation()
1002 write(isBE, Section.getAddressWithOffset(Offset), static_cast<uint32_t>(Value)); in resolveBPFRelocation()
1004 << format("%p\n", Section.getAddressWithOffset(Offset))); in resolveBPFRelocation()
1032 const SectionEntry &Section = Sections[RE.SectionID]; in resolveRelocation() local
1033 return resolveRelocation(Section, RE.Offset, Value, RE.RelType, RE.Addend, in resolveRelocation()
1037 void RuntimeDyldELF::resolveRelocation(const SectionEntry &Section, in resolveRelocation() argument
1043 resolveX86_64Relocation(Section, Offset, Value, Type, Addend, SymOffset); in resolveRelocation()
1046 resolveX86Relocation(Section, Offset, (uint32_t)(Value & 0xffffffffL), Type, in resolveRelocation()
1051 resolveAArch64Relocation(Section, Offset, Value, Type, Addend); in resolveRelocation()
1057 resolveARMRelocation(Section, Offset, (uint32_t)(Value & 0xffffffffL), Type, in resolveRelocation()
1062 resolvePPC32Relocation(Section, Offset, Value, Type, Addend); in resolveRelocation()
1066 resolvePPC64Relocation(Section, Offset, Value, Type, Addend); in resolveRelocation()
1069 resolveSystemZRelocation(Section, Offset, Value, Type, Addend); in resolveRelocation()
1073 resolveBPFRelocation(Section, Offset, Value, Type, Addend); in resolveRelocation()
1163 SectionEntry &Section = Sections[SectionID]; in resolveAArch64Branch() local
1170 resolveRelocation(Section, Offset, in resolveAArch64Branch()
1171 (uint64_t)Section.getAddressWithOffset(i->second), in resolveAArch64Branch()
1177 Stubs[Value] = Section.getStubOffset(); in resolveAArch64Branch()
1179 Section.getAddressWithOffset(Section.getStubOffset())); in resolveAArch64Branch()
1181 RelocationEntry REmovz_g3(SectionID, StubTargetAddr - Section.getAddress(), in resolveAArch64Branch()
1184 StubTargetAddr - Section.getAddress() + 4, in resolveAArch64Branch()
1187 StubTargetAddr - Section.getAddress() + 8, in resolveAArch64Branch()
1190 StubTargetAddr - Section.getAddress() + 12, in resolveAArch64Branch()
1204 resolveRelocation(Section, Offset, in resolveAArch64Branch()
1205 reinterpret_cast<uint64_t>(Section.getAddressWithOffset( in resolveAArch64Branch()
1206 Section.getStubOffset())), in resolveAArch64Branch()
1208 Section.advanceStubOffset(getMaxStubSize()); in resolveAArch64Branch()
1331 SectionEntry &Section = Sections[SectionID]; in processRelocationRef() local
1337 Section, Offset, in processRelocationRef()
1338 reinterpret_cast<uint64_t>(Section.getAddressWithOffset(i->second)), in processRelocationRef()
1344 Stubs[Value] = Section.getStubOffset(); in processRelocationRef()
1346 Section.getAddressWithOffset(Section.getStubOffset())); in processRelocationRef()
1347 RelocationEntry RE(SectionID, StubTargetAddr - Section.getAddress(), in processRelocationRef()
1354 resolveRelocation(Section, Offset, reinterpret_cast<uint64_t>( in processRelocationRef()
1355 Section.getAddressWithOffset( in processRelocationRef()
1356 Section.getStubOffset())), in processRelocationRef()
1358 Section.advanceStubOffset(getMaxStubSize()); in processRelocationRef()
1379 SectionEntry &Section = Sections[SectionID]; in processRelocationRef() local
1397 Stubs[Value] = Section.getStubOffset(); in processRelocationRef()
1402 Section.getAddressWithOffset(Section.getStubOffset()), AbiVariant); in processRelocationRef()
1405 RelocationEntry REHi(SectionID, StubTargetAddr - Section.getAddress(), in processRelocationRef()
1408 StubTargetAddr - Section.getAddress() + 4, in processRelocationRef()
1419 RelocationEntry RE(SectionID, Offset, RelType, Section.getStubOffset()); in processRelocationRef()
1421 Section.advanceStubOffset(getMaxStubSize()); in processRelocationRef()
1481 SectionEntry &Section = Sections[SectionID]; in processRelocationRef() local
1492 Stubs[Value] = Section.getStubOffset(); in processRelocationRef()
1497 Section.getAddressWithOffset(Section.getStubOffset()), AbiVariant); in processRelocationRef()
1501 RelocationEntry REHi(SectionID, StubTargetAddr - Section.getAddress(), in processRelocationRef()
1504 StubTargetAddr - Section.getAddress() + 4, in processRelocationRef()
1517 StubTargetAddr - Section.getAddress(), in processRelocationRef()
1520 StubTargetAddr - Section.getAddress() + 4, in processRelocationRef()
1523 StubTargetAddr - Section.getAddress() + 12, in processRelocationRef()
1526 StubTargetAddr - Section.getAddress() + 20, in processRelocationRef()
1540 RelocationEntry RE(SectionID, Offset, RelType, Section.getStubOffset()); in processRelocationRef()
1542 Section.advanceStubOffset(getMaxStubSize()); in processRelocationRef()
1557 SectionEntry &Section = Sections[SectionID]; in processRelocationRef() local
1558 uint8_t *Target = Section.getAddressWithOffset(Offset); in processRelocationRef()
1595 resolveRelocation(Section, Offset, in processRelocationRef()
1597 Section.getAddressWithOffset(i->second)), in processRelocationRef()
1603 Stubs[Value] = Section.getStubOffset(); in processRelocationRef()
1605 Section.getAddressWithOffset(Section.getStubOffset()), in processRelocationRef()
1607 RelocationEntry RE(SectionID, StubTargetAddr - Section.getAddress(), in processRelocationRef()
1614 uint64_t StubRelocOffset = StubTargetAddr - Section.getAddress(); in processRelocationRef()
1639 resolveRelocation(Section, Offset, reinterpret_cast<uint64_t>( in processRelocationRef()
1640 Section.getAddressWithOffset( in processRelocationRef()
1641 Section.getStubOffset())), in processRelocationRef()
1643 Section.advanceStubOffset(getMaxStubSize()); in processRelocationRef()
1720 SectionEntry &Section = Sections[SectionID]; in processRelocationRef() local
1726 StubAddress = uintptr_t(Section.getAddressWithOffset(i->second)); in processRelocationRef()
1732 uintptr_t BaseAddress = uintptr_t(Section.getAddress()); in processRelocationRef()
1735 (BaseAddress + Section.getStubOffset() + StubAlignment - 1) & in processRelocationRef()
1747 Section.advanceStubOffset(getMaxStubSize()); in processRelocationRef()
1751 resolveRelocation(Section, Offset, StubAddress + 8, ELF::R_390_PC32DBL, in processRelocationRef()
1754 resolveRelocation(Section, Offset, StubAddress, RelType, Addend); in processRelocationRef()
1776 SectionEntry *Section = &Sections[SectionID]; in processRelocationRef() local
1780 StubAddress = uintptr_t(Section->getAddress()) + i->second; in processRelocationRef()
1786 uintptr_t BaseAddress = uintptr_t(Section->getAddress()); in processRelocationRef()
1789 (BaseAddress + Section->getStubOffset() + StubAlignment - 1) & in processRelocationRef()
1796 Section->advanceStubOffset(getMaxStubSize()); in processRelocationRef()
1802 Section = &Sections[SectionID]; in processRelocationRef()
1815 resolveRelocation(*Section, Offset, StubAddress, ELF::R_X86_64_PC32, in processRelocationRef()
1953 auto &Section = Sections[SectionID]; in processX86_64GOTTPOFFRelocation() local
1960 Section.getSize()) { in processX86_64GOTTPOFFRelocation()
1967 auto *TLSSequence = Section.getAddressWithOffset(TLSSequenceStartOffset); in processX86_64GOTTPOFFRelocation()
2196 auto &Section = Sections[SectionID]; in processX86_64TLSRelocation() local
2199 Section.getSize()) { in processX86_64TLSRelocation()
2203 auto *TLSSequence = Section.getAddressWithOffset(Offset - TLSSequenceOffset); in processX86_64TLSRelocation()
2340 const SectionRef &Section = i->first; in finalizeLoad() local
2343 Expected<StringRef> NameOrErr = Section.getName(); in finalizeLoad()