Searched refs:ehdr (Results 1 – 7 of 7) sorted by relevance
/bionic/libc/malloc_debug/ |
D | MapData.cpp | 92 ElfW(Ehdr) ehdr; in Init() local 94 struct iovec dst_io = {.iov_base = ehdr.e_ident, .iov_len = SELFMAG}; in Init() 96 valid_ = rc == SELFMAG && IS_ELF(ehdr); in Init() 110 ElfW(Ehdr) ehdr; in GetLoadBias() local 111 struct iovec src_io = {.iov_base = reinterpret_cast<void*>(start_), .iov_len = sizeof(ehdr)}; in GetLoadBias() 112 struct iovec dst_io = {.iov_base = &ehdr, .iov_len = sizeof(ehdr)}; in GetLoadBias() 114 if (rc != sizeof(ehdr)) { in GetLoadBias() 118 uintptr_t addr = start_ + ehdr.e_phoff; in GetLoadBias() 119 for (size_t i = 0; i < ehdr.e_phnum; i++) { in GetLoadBias()
|
/bionic/libc/bionic/ |
D | dl_iterate_phdr_static.cpp | 43 ElfW(Ehdr)* ehdr = reinterpret_cast<ElfW(Ehdr)*>(&__executable_start); in dl_iterate_phdr() 45 if (memcmp(ehdr->e_ident, ELFMAG, SELFMAG) != 0) { in dl_iterate_phdr() 57 …exe_info.dlpi_phdr = reinterpret_cast<ElfW(Phdr)*>(reinterpret_cast<uintptr_t>(ehdr) + ehdr->e_pho… in dl_iterate_phdr() 58 exe_info.dlpi_phnum = ehdr->e_phnum; in dl_iterate_phdr()
|
/bionic/linker/ |
D | linker_main.cpp | 612 auto ehdr = reinterpret_cast<ElfW(Addr)>(&__ehdr_start); in call_ifunc_resolvers_for_section() local 617 ElfW(Addr)* offset = reinterpret_cast<ElfW(Addr)*>(ehdr + r->r_offset); in call_ifunc_resolvers_for_section() 619 ElfW(Addr) resolver = ehdr + r->r_addend; in call_ifunc_resolvers_for_section() 621 ElfW(Addr) resolver = ehdr + *offset; in call_ifunc_resolvers_for_section() 631 auto ehdr = reinterpret_cast<ElfW(Addr)>(&__ehdr_start); in relocate_linker() local 632 auto* phdr = reinterpret_cast<ElfW(Phdr)*>(ehdr + __ehdr_start.e_phoff); in relocate_linker() 637 auto *dyn = reinterpret_cast<ElfW(Dyn)*>(ehdr + phdr[i].p_vaddr); in relocate_linker() 662 relocate_relr(reinterpret_cast<ElfW(Relr*)>(ehdr + relr), in relocate_linker() 663 reinterpret_cast<ElfW(Relr*)>(ehdr + relr + relrsz), ehdr); in relocate_linker() 666 call_ifunc_resolvers_for_section(reinterpret_cast<RelType*>(ehdr + pltrel), in relocate_linker() [all …]
|
D | linker_phdr.cpp | 1432 const ElfW(Ehdr)* ehdr = reinterpret_cast<const ElfW(Ehdr)*>(elf_addr); in FindPhdr() 1433 ElfW(Addr) offset = ehdr->e_phoff; in FindPhdr() 1434 return CheckPhdr(reinterpret_cast<ElfW(Addr)>(ehdr) + offset); in FindPhdr()
|
/bionic/tests/ |
D | link_test.cpp | 67 const ElfW(Ehdr)* ehdr = reinterpret_cast<const ElfW(Ehdr)*>(info->dlpi_addr + in TEST() 70 ASSERT_EQ(0, memcmp(ehdr, ELFMAG, SELFMAG)); in TEST() 72 ASSERT_EQ(info->dlpi_phnum, ehdr->e_phnum); in TEST()
|
D | malloc_test.cpp | 1131 Elf64_Ehdr ehdr; in IsDynamic() local 1133 Elf32_Ehdr ehdr; in IsDynamic() 1142 bool read_completed = android::base::ReadFully(fd, &ehdr, sizeof(ehdr)); in IsDynamic() 1145 return !read_completed || ehdr.e_type == ET_DYN; in IsDynamic()
|
/bionic/libc/include/bits/ |
D | elf_common.h | 194 #define IS_ELF(ehdr) ((ehdr).e_ident[EI_MAG0] == ELFMAG0 && \ argument 195 (ehdr).e_ident[EI_MAG1] == ELFMAG1 && \ 196 (ehdr).e_ident[EI_MAG2] == ELFMAG2 && \ 197 (ehdr).e_ident[EI_MAG3] == ELFMAG3)
|