Home
last modified time | relevance | path

Searched refs:Phdr (Results 1 – 25 of 33) sorted by relevance

12

/freebsd-14.2/contrib/llvm-project/llvm/include/llvm/Object/
H A DELF.h153 const typename ELFT::Phdr &Phdr) { in getPhdrIndexForError() argument
167 bool checkSectionOffsets(const typename ELFT::Phdr &Phdr, in checkSectionOffsets() argument
178 return (Sec.sh_offset + 1 <= Phdr.p_offset + Phdr.p_filesz); in checkSectionOffsets()
179 return Sec.sh_offset + Sec.sh_size <= Phdr.p_offset + Phdr.p_filesz; in checkSectionOffsets()
185 bool checkSectionVMA(const typename ELFT::Phdr &Phdr, in checkSectionVMA() argument
199 return Sec.sh_addr + 1 <= Phdr.p_vaddr + Phdr.p_memsz; in checkSectionVMA()
200 return Sec.sh_addr + Sec.sh_size <= Phdr.p_vaddr + Phdr.p_memsz; in checkSectionVMA()
204 bool isSectionInSegment(const typename ELFT::Phdr &Phdr, in isSectionInSegment() argument
356 if (Phdr.p_offset + Phdr.p_filesz > getBufSize()) { in notes_begin()
364 if (Phdr.p_align != 0 && Phdr.p_align != 1 && Phdr.p_align != 4 && in notes_begin()
[all …]
H A DELFTypes.h62 using Phdr = Elf_Phdr_Impl<ELFType<E, Is64>>; member
84 using PhdrRange = ArrayRef<Phdr>;
117 using Elf_Phdr = typename ELFT::Phdr; \
/freebsd-14.2/contrib/llvm-project/llvm/tools/llvm-objdump/
H A DELFDump.cpp183 for (const typename ELFT::Phdr &Phdr : *PhdrRangeOrErr) in getSectionLMA()
184 if ((Phdr.p_type == ELF::PT_LOAD) && in getSectionLMA()
186 Phdr, *cast<const ELFObjectFile<ELFT>>(Sec.getObject()) in getSectionLMA()
188 return Sec.getAddress() - Phdr.p_vaddr + Phdr.p_paddr; in getSectionLMA()
256 for (const typename ELFT::Phdr &Phdr : *ProgramHeaderOrError) { in printProgramHeaders()
257 switch (Phdr.p_type) { in printProgramHeaders()
313 << format(Fmt, (uint64_t)Phdr.p_vaddr) << "paddr " in printProgramHeaders()
314 << format(Fmt, (uint64_t)Phdr.p_paddr) in printProgramHeaders()
318 << ((Phdr.p_flags & ELF::PF_R) ? "r" : "-") in printProgramHeaders()
319 << ((Phdr.p_flags & ELF::PF_W) ? "w" : "-") in printProgramHeaders()
[all …]
/freebsd-14.2/contrib/llvm-project/llvm/lib/Object/
H A DELF.cpp558 for (const Elf_Phdr &Phdr : *ProgramHeadersOrError) { in dynamicEntries()
559 if (Phdr.p_type == ELF::PT_DYNAMIC) { in dynamicEntries()
561 Phdr.p_filesz / sizeof(Elf_Dyn)); in dynamicEntries()
606 for (const Elf_Phdr &Phdr : *ProgramHeadersOrError) in toMappedAddr()
607 if (Phdr.p_type == ELF::PT_LOAD) in toMappedAddr()
623 return VAddr < Phdr->p_vaddr; in toMappedAddr()
630 const Elf_Phdr &Phdr = **I; in toMappedAddr() local
631 uint64_t Delta = VAddr - Phdr.p_vaddr; in toMappedAddr()
632 if (Delta >= Phdr.p_filesz) in toMappedAddr()
636 uint64_t Offset = Phdr.p_offset + Delta; in toMappedAddr()
[all …]
/freebsd-14.2/contrib/llvm-project/llvm/tools/llvm-readobj/
H A DDwarfCFIEHPrinter.h33 using Elf_Phdr = typename ELFT::Phdr;
70 for (const Elf_Phdr &Phdr : *PhdrsOrErr) { in printUnwindInformation()
71 if (Phdr.p_type != ELF::PT_GNU_EH_FRAME) in printUnwindInformation()
74 if (Phdr.p_memsz != Phdr.p_filesz) in printUnwindInformation()
78 printEHFrameHdr(&Phdr); in printUnwindInformation()
H A DELFDumper.cpp1808 if (Phdr.p_type != ELF::PT_DYNAMIC) in findDynamic()
1810 DynamicPhdr = &Phdr; in findDynamic()
4574 static bool checkTLSSections(const typename ELFT::Phdr &Phdr, in checkTLSSections() argument
4579 return Phdr.p_type == ELF::PT_TLS; in checkTLSSections()
4583 return (Phdr.p_type == ELF::PT_TLS) || (Phdr.p_type == ELF::PT_LOAD) || in checkTLSSections()
4588 return Phdr.p_type != ELF::PT_TLS; in checkTLSSections()
4592 static bool checkPTDynamic(const typename ELFT::Phdr &Phdr, in checkPTDynamic() argument
4594 if (Phdr.p_type != ELF::PT_DYNAMIC || Phdr.p_memsz == 0 || Sec.sh_size != 0) in checkPTDynamic()
4602 Sec.sh_offset < Phdr.p_offset + Phdr.p_filesz); in checkPTDynamic()
4604 (Sec.sh_addr > Phdr.p_vaddr && Sec.sh_addr < Phdr.p_memsz); in checkPTDynamic()
[all …]
/freebsd-14.2/contrib/llvm-project/compiler-rt/lib/hwasan/
H A Dhwasan_globals.cpp29 static void CheckCodeModel(ElfW(Addr) base, const ElfW(Phdr) * phdr, in CheckCodeModel()
53 const ElfW(Phdr) * phdr, in HwasanGlobalsFor()
H A Dhwasan_globals.h45 const ElfW(Phdr) * phdr,
H A Dhwasan_interface_internal.h30 void __hwasan_library_loaded(ElfW(Addr) base, const ElfW(Phdr) * phdr,
34 void __hwasan_library_unloaded(ElfW(Addr) base, const ElfW(Phdr) * phdr,
H A Dhwasan.cpp347 reinterpret_cast<const ElfW(Phdr) *>( in __hwasan_init_static()
417 void __hwasan_library_loaded(ElfW(Addr) base, const ElfW(Phdr) * phdr, in __hwasan_library_loaded()
423 void __hwasan_library_unloaded(ElfW(Addr) base, const ElfW(Phdr) * phdr, in __hwasan_library_unloaded()
/freebsd-14.2/contrib/llvm-project/llvm/lib/ProfileData/
H A DRawMemProfReader.cpp307 for (const auto &Phdr : *PHdrsOr) { in initialize()
308 if (Phdr.p_type == ELF::PT_LOAD) { in initialize()
309 if (Phdr.p_flags & ELF::PF_X) { in initialize()
324 PreferredTextSegmentAddress = Phdr.p_vaddr; in initialize()
325 assert(Phdr.p_vaddr == (Phdr.p_vaddr & ~(0x1000 - 1U)) && in initialize()
327 assert(Phdr.p_offset == 0 && "Expect p_offset = 0 for symbolization."); in initialize()
/freebsd-14.2/contrib/llvm-project/llvm/lib/ObjCopy/ELF/
H A DELFObject.cpp41 Phdr.p_type = Seg.Type; in writePhdr()
42 Phdr.p_flags = Seg.Flags; in writePhdr()
43 Phdr.p_offset = Seg.Offset; in writePhdr()
44 Phdr.p_vaddr = Seg.VAddr; in writePhdr()
45 Phdr.p_paddr = Seg.PAddr; in writePhdr()
46 Phdr.p_filesz = Seg.FileSize; in writePhdr()
47 Phdr.p_memsz = Seg.MemSize; in writePhdr()
48 Phdr.p_align = Seg.Align; in writePhdr()
1427 if (Phdr.p_offset + Phdr.p_filesz > HeadersFile.getBufSize()) in readProgramHeaders()
1437 Seg.Type = Phdr.p_type; in readProgramHeaders()
[all …]
/freebsd-14.2/contrib/llvm-project/compiler-rt/lib/profile/
H A DInstrProfilingPlatformLinux.c161 const ElfW(Phdr) *ProgramHeader = in __llvm_write_binary_ids()
162 (const ElfW(Phdr) *)((uintptr_t)ElfHeader + ElfHeader->e_phoff); in __llvm_write_binary_ids()
/freebsd-14.2/contrib/llvm-project/compiler-rt/lib/sanitizer_common/
H A Dsanitizer_solaris.h44 const ElfW(Phdr) * dlpi_phdr;
H A Dsanitizer_platform_limits_solaris.cpp123 unsigned struct_ElfW_Phdr_sz = sizeof(ElfW(Phdr));
/freebsd-14.2/contrib/llvm-project/llvm/lib/Support/Unix/
H A DSignals.inc536 const auto *Phdr = &Info->dlpi_phdr[I];
537 if (Phdr->p_type != PT_LOAD)
539 uintptr_t StartAddress = Info->dlpi_addr + Phdr->p_vaddr;
540 uintptr_t ModuleRelativeAddress = Phdr->p_vaddr;
541 std::array<char, 4> ModeStr = modeStrFromFlags(Phdr->p_flags);
543 Phdr->p_memsz, ModuleCount, &ModeStr[0],
561 const auto *Phdr = &Info->dlpi_phdr[I];
562 if (Phdr->p_type != PT_NOTE)
566 reinterpret_cast<const uint8_t *>(Info->dlpi_addr + Phdr->p_vaddr),
567 Phdr->p_memsz);
/freebsd-14.2/sys/sys/
H A Delf_generic.h68 __ElfType(Phdr);
/freebsd-14.2/contrib/llvm-project/compiler-rt/lib/lsan/
H A Dlsan_common_linux.cpp83 const ElfW(Phdr) *phdr = &(info->dlpi_phdr[j]); in ProcessGlobalRegionsCallback()
/freebsd-14.2/contrib/llvm-project/llvm/lib/ObjectYAML/
H A DELFYAML.cpp1128 IO &IO, ELFYAML::ProgramHeader &Phdr) { in mapping() argument
1129 IO.mapRequired("Type", Phdr.Type); in mapping()
1130 IO.mapOptional("Flags", Phdr.Flags, ELFYAML::ELF_PF(0)); in mapping()
1131 IO.mapOptional("FirstSec", Phdr.FirstSec); in mapping()
1132 IO.mapOptional("LastSec", Phdr.LastSec); in mapping()
1133 IO.mapOptional("VAddr", Phdr.VAddr, Hex64(0)); in mapping()
1134 IO.mapOptional("PAddr", Phdr.PAddr, Phdr.VAddr); in mapping()
1135 IO.mapOptional("Align", Phdr.Align); in mapping()
1136 IO.mapOptional("FileSize", Phdr.FileSize); in mapping()
1137 IO.mapOptional("MemSize", Phdr.MemSize); in mapping()
[all …]
H A DELFEmitter.cpp240 getPhdrFragments(const ELFYAML::ProgramHeader &Phdr,
547 Elf_Phdr Phdr; in initProgramHeaders() local
548 zero(Phdr); in initProgramHeaders()
549 Phdr.p_type = YamlPhdr.Type; in initProgramHeaders()
550 Phdr.p_flags = YamlPhdr.Flags; in initProgramHeaders()
551 Phdr.p_vaddr = YamlPhdr.VAddr; in initProgramHeaders()
552 Phdr.p_paddr = YamlPhdr.PAddr; in initProgramHeaders()
553 PHeaders.push_back(Phdr); in initProgramHeaders()
1148 ELFState<ELFT>::getPhdrFragments(const ELFYAML::ProgramHeader &Phdr, in getPhdrFragments() argument
1151 for (const ELFYAML::Chunk *C : Phdr.Chunks) { in getPhdrFragments()
/freebsd-14.2/contrib/elftoolchain/libelf/
H A Dlibelf_align.c73 [ELF_T_PHDR] = MALIGN(Phdr),
H A Delf_types.m450 `PHDR, Phdr',
/freebsd-14.2/sys/cddl/compat/opensolaris/sys/
H A Delf.h38 __sElfN(Phdr);
/freebsd-14.2/contrib/llvm-project/llvm/lib/InterfaceStub/
H A DELFObjHandler.cpp70 ElfHeader.e_phentsize = sizeof(typename ELFT::Phdr); in initELFHeader()
174 using Elf_Phdr = typename ELFT::Phdr;
/freebsd-14.2/contrib/llvm-project/compiler-rt/lib/cfi/
H A Dcfi.cpp26 typedef ElfW(Phdr) Elf_Phdr;

12