52 return loadProgram(pFile,
true,
true, &actualFilename);
58 return loadProgram(pFile,
true);
65 bool loadProgram(
File* pFile,
bool bDryRun =
false,
bool bInterpreter =
false,
72 bool loadObject(
File* pFile,
bool bDryRun =
false);
76 static uintptr_t resolvePlt(SyscallState& state);
81 bool trap(uintptr_t address);
89 uintptr_t resolve(
String name);
91#if defined(PEDIGREE_HOSTED_PAGE_CONTENT_REGRESSIONS)
92 static bool loadDemandPageForTest(
Elf* pElf, uintptr_t buffer,
size_t size, uintptr_t offset,
94 return loadDemandPage(pElf, buffer, size, offset, pSymbols, address);
97 static void setDemandPageAllocationHookForTest(physical_uintptr_t (*hook)());
98 static void setDemandPageReadyHookForTest(
void (*hook)(uintptr_t));
99 static void setDemandPageFreeHookForTest(
void (*hook)(physical_uintptr_t));
109 : elf(e), file(f), buffer(b), address(a), size(s) {}
117 uintptr_t resolvePltSymbol(uintptr_t libraryId, uintptr_t symIdx);
119 void initPlt(
Elf* pElf, uintptr_t value);
121 static bool loadDemandPage(
Elf* pElf, uintptr_t buffer,
size_t size, uintptr_t offset,
125 uintptr_t m_ProgramStart;
126 size_t m_ProgramSize;
127 uintptr_t m_ProgramBuffer;