Lines Matching refs:rel
359 const coff_relocation &rel, in maybeReportRelocationToDiscarded() argument
376 check(file->getCOFFObj()->getSymbol(rel.SymbolTableIndex)); in maybeReportRelocationToDiscarded()
381 getSymbolLocations(file, rel.SymbolTableIndex); in maybeReportRelocationToDiscarded()
401 for (const coff_relocation &rel : getRelocs()) { in writeTo() local
406 if (rel.VirtualAddress >= inputSize) { in writeTo()
411 applyRelocation(buf + rel.VirtualAddress, rel); in writeTo()
422 const coff_relocation &rel) const { in applyRelocation()
423 auto *sym = dyn_cast_or_null<Defined>(file->getSymbol(rel.SymbolTableIndex)); in applyRelocation()
437 maybeReportRelocationToDiscarded(this, sym, rel, file->ctx.config.mingw); in applyRelocation()
444 uint64_t p = rva + rel.VirtualAddress; in applyRelocation()
448 applyRelX64(off, rel.Type, os, s, p, imageBase); in applyRelocation()
451 applyRelX86(off, rel.Type, os, s, p, imageBase); in applyRelocation()
454 applyRelARM(off, rel.Type, os, s, p, imageBase); in applyRelocation()
457 applyRelARM64(off, rel.Type, os, s, p, imageBase); in applyRelocation()
492 const coff_relocation &rel = relocsData[nextRelocIndex]; in writeAndRelocateSubsection() local
496 if (rel.VirtualAddress < vaBegin) in writeAndRelocateSubsection()
498 if (rel.VirtualAddress + 1 >= vaEnd) in writeAndRelocateSubsection()
500 applyRelocation(&buf[rel.VirtualAddress - vaBegin], rel); in writeAndRelocateSubsection()
522 static uint8_t getBaserelType(const coff_relocation &rel, in getBaserelType() argument
526 if (rel.Type == IMAGE_REL_AMD64_ADDR64) in getBaserelType()
528 if (rel.Type == IMAGE_REL_AMD64_ADDR32) in getBaserelType()
532 if (rel.Type == IMAGE_REL_I386_DIR32) in getBaserelType()
536 if (rel.Type == IMAGE_REL_ARM_ADDR32) in getBaserelType()
538 if (rel.Type == IMAGE_REL_ARM_MOV32T) in getBaserelType()
542 if (rel.Type == IMAGE_REL_ARM64_ADDR64) in getBaserelType()
555 for (const coff_relocation &rel : getRelocs()) { in getBaserels() local
556 uint8_t ty = getBaserelType(rel, getArch()); in getBaserels()
559 Symbol *target = file->getSymbol(rel.SymbolTableIndex); in getBaserels()
562 res->emplace_back(rva + rel.VirtualAddress, ty); in getBaserels()
652 for (const coff_relocation &rel : getRelocs()) { in getRuntimePseudoRelocs() local
654 dyn_cast_or_null<Defined>(file->getSymbol(rel.SymbolTableIndex)); in getRuntimePseudoRelocs()
665 getRuntimePseudoRelocSize(rel.Type, file->ctx.config.machine); in getRuntimePseudoRelocs()
669 file->getCOFFObj()->getRelocationTypeName(rel.Type) + " in " + in getRuntimePseudoRelocs()
682 res.emplace_back(target, this, rel.VirtualAddress, sizeInBits); in getRuntimePseudoRelocs()