LLVM  14.0.0git
EPCGenericRTDyldMemoryManager.cpp
Go to the documentation of this file.
1 //===----- EPCGenericRTDyldMemoryManager.cpp - EPC-bbasde MemMgr -----===//
2 //
3 // Part of the LLVM Project, under the Apache License v2.0 with LLVM Exceptions.
4 // See https://llvm.org/LICENSE.txt for license information.
5 // SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception
6 //
7 //===----------------------------------------------------------------------===//
8 
12 #include "llvm/Support/Alignment.h"
14 
15 #define DEBUG_TYPE "orc"
16 
17 namespace llvm {
18 namespace orc {
19 
20 Expected<std::unique_ptr<EPCGenericRTDyldMemoryManager>>
23  SymbolAddrs SAs;
24  if (auto Err = EPC.getBootstrapSymbols(
25  {{SAs.Instance, rt::SimpleExecutorMemoryManagerInstanceName},
26  {SAs.Reserve, rt::SimpleExecutorMemoryManagerReserveWrapperName},
27  {SAs.Finalize, rt::SimpleExecutorMemoryManagerFinalizeWrapperName},
28  {SAs.Deallocate,
29  rt::SimpleExecutorMemoryManagerDeallocateWrapperName},
30  {SAs.RegisterEHFrame,
31  rt::RegisterEHFrameSectionCustomDirectWrapperName},
32  {SAs.DeregisterEHFrame,
33  rt::DeregisterEHFrameSectionCustomDirectWrapperName}}))
34  return std::move(Err);
35  return std::make_unique<EPCGenericRTDyldMemoryManager>(EPC, std::move(SAs));
36 }
37 
38 EPCGenericRTDyldMemoryManager::EPCGenericRTDyldMemoryManager(
40  : EPC(EPC), SAs(std::move(SAs)) {
41  LLVM_DEBUG(dbgs() << "Created remote allocator " << (void *)this << "\n");
42 }
43 
45  LLVM_DEBUG(dbgs() << "Destroyed remote allocator " << (void *)this << "\n");
46  if (!ErrMsg.empty())
47  errs() << "Destroying with existing errors:\n" << ErrMsg << "\n";
48 
49  Error Err = Error::success();
50  if (auto Err2 = EPC.callSPSWrapper<
52  SAs.Reserve, Err, SAs.Instance, FinalizedAllocs)) {
53  // FIXME: Report errors through EPC once that functionality is available.
54  logAllUnhandledErrors(std::move(Err2), errs(), "");
55  return;
56  }
57 
58  if (Err)
60 }
61 
63  uintptr_t Size, unsigned Alignment, unsigned SectionID,
65  std::lock_guard<std::mutex> Lock(M);
66  LLVM_DEBUG({
67  dbgs() << "Allocator " << (void *)this << " allocating code section "
68  << SectionName << ": size = " << formatv("{0:x}", Size)
69  << " bytes, alignment = " << Alignment << "\n";
70  });
71  auto &Seg = Unmapped.back().CodeAllocs;
72  Seg.emplace_back(Size, Alignment);
73  return reinterpret_cast<uint8_t *>(
74  alignAddr(Seg.back().Contents.get(), Align(Alignment)));
75 }
76 
78  uintptr_t Size, unsigned Alignment, unsigned SectionID,
79  StringRef SectionName, bool IsReadOnly) {
80  std::lock_guard<std::mutex> Lock(M);
81  LLVM_DEBUG({
82  dbgs() << "Allocator " << (void *)this << " allocating "
83  << (IsReadOnly ? "ro" : "rw") << "-data section " << SectionName
84  << ": size = " << formatv("{0:x}", Size) << " bytes, alignment "
85  << Alignment << ")\n";
86  });
87 
88  auto &Seg =
89  IsReadOnly ? Unmapped.back().RODataAllocs : Unmapped.back().RWDataAllocs;
90 
91  Seg.emplace_back(Size, Alignment);
92  return reinterpret_cast<uint8_t *>(
93  alignAddr(Seg.back().Contents.get(), Align(Alignment)));
94 }
95 
97  uintptr_t CodeSize, uint32_t CodeAlign, uintptr_t RODataSize,
98  uint32_t RODataAlign, uintptr_t RWDataSize, uint32_t RWDataAlign) {
99 
100  {
101  std::lock_guard<std::mutex> Lock(M);
102  // If there's already an error then bail out.
103  if (!ErrMsg.empty())
104  return;
105 
106  if (!isPowerOf2_32(CodeAlign) || CodeAlign > EPC.getPageSize()) {
107  ErrMsg = "Invalid code alignment in reserveAllocationSpace";
108  return;
109  }
110  if (!isPowerOf2_32(RODataAlign) || RODataAlign > EPC.getPageSize()) {
111  ErrMsg = "Invalid ro-data alignment in reserveAllocationSpace";
112  return;
113  }
114  if (!isPowerOf2_32(RWDataAlign) || RWDataAlign > EPC.getPageSize()) {
115  ErrMsg = "Invalid rw-data alignment in reserveAllocationSpace";
116  return;
117  }
118  }
119 
120  uint64_t TotalSize = 0;
121  TotalSize += alignTo(CodeSize, EPC.getPageSize());
122  TotalSize += alignTo(RODataSize, EPC.getPageSize());
123  TotalSize += alignTo(RWDataSize, EPC.getPageSize());
124 
125  LLVM_DEBUG({
126  dbgs() << "Allocator " << (void *)this << " reserving "
127  << formatv("{0:x}", TotalSize) << " bytes.\n";
128  });
129 
130  Expected<ExecutorAddr> TargetAllocAddr((ExecutorAddr()));
131  if (auto Err = EPC.callSPSWrapper<
133  SAs.Reserve, TargetAllocAddr, SAs.Instance, TotalSize)) {
134  std::lock_guard<std::mutex> Lock(M);
135  ErrMsg = toString(std::move(Err));
136  return;
137  }
138  if (!TargetAllocAddr) {
139  std::lock_guard<std::mutex> Lock(M);
140  ErrMsg = toString(TargetAllocAddr.takeError());
141  return;
142  }
143 
144  std::lock_guard<std::mutex> Lock(M);
145  Unmapped.push_back(AllocGroup());
146  Unmapped.back().RemoteCode = {
147  *TargetAllocAddr, ExecutorAddrDiff(alignTo(CodeSize, EPC.getPageSize()))};
148  Unmapped.back().RemoteROData = {
149  Unmapped.back().RemoteCode.End,
150  ExecutorAddrDiff(alignTo(RODataSize, EPC.getPageSize()))};
151  Unmapped.back().RemoteRWData = {
152  Unmapped.back().RemoteROData.End,
153  ExecutorAddrDiff(alignTo(RWDataSize, EPC.getPageSize()))};
154 }
155 
157  return true;
158 }
159 
161  uint64_t LoadAddr,
162  size_t Size) {
163  LLVM_DEBUG({
164  dbgs() << "Allocator " << (void *)this << " added unfinalized eh-frame "
165  << formatv("[ {0:x} {1:x} ]", LoadAddr, LoadAddr + Size) << "\n";
166  });
167  std::lock_guard<std::mutex> Lock(M);
168  // Bail out early if there's already an error.
169  if (!ErrMsg.empty())
170  return;
171 
172  ExecutorAddr LA(LoadAddr);
173  for (auto &Alloc : llvm::reverse(Unfinalized)) {
174  if (Alloc.RemoteCode.contains(LA) || Alloc.RemoteROData.contains(LA) ||
175  Alloc.RemoteRWData.contains(LA)) {
176  Alloc.UnfinalizedEHFrames.push_back({LA, Size});
177  return;
178  }
179  }
180  ErrMsg = "eh-frame does not lie inside unfinalized alloc";
181 }
182 
184  // This is a no-op for us: We've registered a deallocation action for it.
185 }
186 
188  RuntimeDyld &Dyld, const object::ObjectFile &Obj) {
189  std::lock_guard<std::mutex> Lock(M);
190  LLVM_DEBUG(dbgs() << "Allocator " << (void *)this << " applied mappings:\n");
191  for (auto &ObjAllocs : Unmapped) {
192  mapAllocsToRemoteAddrs(Dyld, ObjAllocs.CodeAllocs,
193  ObjAllocs.RemoteCode.Start);
194  mapAllocsToRemoteAddrs(Dyld, ObjAllocs.RODataAllocs,
195  ObjAllocs.RemoteROData.Start);
196  mapAllocsToRemoteAddrs(Dyld, ObjAllocs.RWDataAllocs,
197  ObjAllocs.RemoteRWData.Start);
198  Unfinalized.push_back(std::move(ObjAllocs));
199  }
200  Unmapped.clear();
201 }
202 
204  LLVM_DEBUG(dbgs() << "Allocator " << (void *)this << " finalizing:\n");
205 
206  // If there's an error then bail out here.
207  std::vector<AllocGroup> Allocs;
208  {
209  std::lock_guard<std::mutex> Lock(M);
210  if (ErrMsg && !this->ErrMsg.empty()) {
211  *ErrMsg = std::move(this->ErrMsg);
212  return true;
213  }
214  std::swap(Allocs, Unfinalized);
215  }
216 
217  // Loop over unfinalized objects to make finalization requests.
218  for (auto &ObjAllocs : Allocs) {
219 
220  tpctypes::WireProtectionFlags SegProts[3] = {
228 
229  ExecutorAddrRange *RemoteAddrs[3] = {&ObjAllocs.RemoteCode,
230  &ObjAllocs.RemoteROData,
231  &ObjAllocs.RemoteRWData};
232 
233  std::vector<Alloc> *SegSections[3] = {&ObjAllocs.CodeAllocs,
234  &ObjAllocs.RODataAllocs,
235  &ObjAllocs.RWDataAllocs};
236 
238  std::unique_ptr<char[]> AggregateContents[3];
239 
240  for (unsigned I = 0; I != 3; ++I) {
241  FR.Segments.push_back({});
242  auto &Seg = FR.Segments.back();
243  Seg.Prot = SegProts[I];
244  Seg.Addr = RemoteAddrs[I]->Start;
245  for (auto &SecAlloc : *SegSections[I]) {
246  Seg.Size = alignTo(Seg.Size, SecAlloc.Align);
247  Seg.Size += SecAlloc.Size;
248  }
249  AggregateContents[I] = std::make_unique<char[]>(Seg.Size);
250  size_t SecOffset = 0;
251  for (auto &SecAlloc : *SegSections[I]) {
252  SecOffset = alignTo(SecOffset, SecAlloc.Align);
253  memcpy(&AggregateContents[I][SecOffset],
254  reinterpret_cast<const char *>(
255  alignAddr(SecAlloc.Contents.get(), Align(SecAlloc.Align))),
256  SecAlloc.Size);
257  SecOffset += SecAlloc.Size;
258  // FIXME: Can we reset SecAlloc.Content here, now that it's copied into
259  // the aggregated content?
260  }
261  Seg.Content = {AggregateContents[I].get(), SecOffset};
262  }
263 
264  for (auto &Frame : ObjAllocs.UnfinalizedEHFrames)
265  FR.Actions.push_back(
266  {{SAs.RegisterEHFrame,
267  {ExecutorAddr(Frame.Addr), ExecutorAddrDiff(Frame.Size)}},
268  {SAs.DeregisterEHFrame,
269  {ExecutorAddr(Frame.Addr), ExecutorAddrDiff(Frame.Size)}}});
270 
271  // We'll also need to make an extra allocation for the eh-frame wrapper call
272  // arguments.
273  Error FinalizeErr = Error::success();
274  if (auto Err = EPC.callSPSWrapper<
276  SAs.Finalize, FinalizeErr, SAs.Instance, std::move(FR))) {
277  std::lock_guard<std::mutex> Lock(M);
278  this->ErrMsg = toString(std::move(Err));
279  dbgs() << "Serialization error: " << this->ErrMsg << "\n";
280  if (ErrMsg)
281  *ErrMsg = this->ErrMsg;
282  return true;
283  }
284  if (FinalizeErr) {
285  std::lock_guard<std::mutex> Lock(M);
286  this->ErrMsg = toString(std::move(FinalizeErr));
287  dbgs() << "Finalization error: " << this->ErrMsg << "\n";
288  if (ErrMsg)
289  *ErrMsg = this->ErrMsg;
290  return true;
291  }
292  }
293 
294  return false;
295 }
296 
297 void EPCGenericRTDyldMemoryManager::mapAllocsToRemoteAddrs(
298  RuntimeDyld &Dyld, std::vector<Alloc> &Allocs, ExecutorAddr NextAddr) {
299  for (auto &Alloc : Allocs) {
300  NextAddr.setValue(alignTo(NextAddr.getValue(), Alloc.Align));
301  LLVM_DEBUG({
302  dbgs() << " " << static_cast<void *>(Alloc.Contents.get()) << " -> "
303  << format("0x%016" PRIx64, NextAddr.getValue()) << "\n";
304  });
305  Dyld.mapSectionAddress(reinterpret_cast<const void *>(alignAddr(
306  Alloc.Contents.get(), Align(Alloc.Align))),
307  NextAddr.getValue());
308  Alloc.RemoteAddr = NextAddr;
309  // Only advance NextAddr if it was non-null to begin with,
310  // otherwise leave it as null.
311  if (NextAddr)
312  NextAddr += ExecutorAddrDiff(Alloc.Size);
313  }
314 }
315 
316 } // end namespace orc
317 } // end namespace llvm
llvm::Check::Size
@ Size
Definition: FileCheck.h:73
llvm::orc::ExecutorAddr
Represents an address in the executor process.
Definition: ExecutorAddress.h:37
llvm::orc::tpctypes::toWireProtectionFlags
WireProtectionFlags toWireProtectionFlags(sys::Memory::ProtectionFlags PF)
Convert from sys::Memory::ProtectionFlags.
Definition: TargetProcessControlTypes.h:41
llvm::alignTo
uint64_t alignTo(uint64_t Size, Align A)
Returns a multiple of A needed to store Size bytes.
Definition: Alignment.h:148
llvm::orc::EPCGenericRTDyldMemoryManager::deregisterEHFrames
void deregisterEHFrames() override
Definition: EPCGenericRTDyldMemoryManager.cpp:183
llvm::orc::ExecutorAddrDiff
Represents the difference between two addresses in the executor process.
Definition: ExecutorAddress.h:25
llvm::sys::Memory::MF_READ
@ MF_READ
Definition: Memory.h:55
llvm
This is an optimization pass for GlobalISel generic memory operations.
Definition: AllocatorList.h:23
llvm::sys::Memory::MF_WRITE
@ MF_WRITE
Definition: Memory.h:56
llvm::orc::EPCGenericRTDyldMemoryManager::SymbolAddrs::DeregisterEHFrame
ExecutorAddr DeregisterEHFrame
Definition: EPCGenericRTDyldMemoryManager.h:35
llvm::orc::ExecutorProcessControl::getBootstrapSymbols
Error getBootstrapSymbols(ArrayRef< std::pair< ExecutorAddr &, StringRef >> Pairs) const
For each (ExecutorAddr&, StringRef) pair, looks up the string in the bootstrap symbols map and writes...
Definition: ExecutorProcessControl.h:229
llvm::toString
std::string toString(Error E)
Write all error messages (if any) in E to a string.
Definition: Error.h:1030
llvm::orc::tpctypes::WireProtectionFlags
WireProtectionFlags
Definition: TargetProcessControlTypes.h:31
llvm::Error::success
static ErrorSuccess success()
Create a success value.
Definition: Error.h:331
llvm::orc::EPCGenericRTDyldMemoryManager::reserveAllocationSpace
void reserveAllocationSpace(uintptr_t CodeSize, uint32_t CodeAlign, uintptr_t RODataSize, uint32_t RODataAlign, uintptr_t RWDataSize, uint32_t RWDataAlign) override
Inform the memory manager about the total amount of memory required to allocate all sections to be lo...
Definition: EPCGenericRTDyldMemoryManager.cpp:96
llvm::orc::EPCGenericRTDyldMemoryManager::SymbolAddrs::Finalize
ExecutorAddr Finalize
Definition: EPCGenericRTDyldMemoryManager.h:32
llvm::alignAddr
uintptr_t alignAddr(const void *Addr, Align Alignment)
Aligns Addr to Alignment bytes, rounding up.
Definition: Alignment.h:186
llvm::orc::ExecutorAddr::getValue
uint64_t getValue() const
Definition: ExecutorAddress.h:60
llvm::orc::EPCGenericRTDyldMemoryManager::allocateCodeSection
uint8_t * allocateCodeSection(uintptr_t Size, unsigned Alignment, unsigned SectionID, StringRef SectionName) override
Allocate a memory block of (at least) the given size suitable for executable code.
Definition: EPCGenericRTDyldMemoryManager.cpp:62
llvm::reverse
auto reverse(ContainerTy &&C, std::enable_if_t< has_rbegin< ContainerTy >::value > *=nullptr)
Definition: STLExtras.h:359
llvm::orc::ExecutorProcessControl
ExecutorProcessControl supports interaction with a JIT target process.
Definition: ExecutorProcessControl.h:38
llvm::orc::rt::SPSSimpleExecutorMemoryManagerFinalizeSignature
shared::SPSError(shared::SPSExecutorAddr, shared::SPSFinalizeRequest) SPSSimpleExecutorMemoryManagerFinalizeSignature
Definition: OrcRTBridge.h:57
llvm::errs
raw_fd_ostream & errs()
This returns a reference to a raw_ostream for standard error.
Definition: raw_ostream.cpp:893
llvm::Expected
Tagged union holding either a T or a Error.
Definition: APFloat.h:42
llvm::orc::EPCGenericRTDyldMemoryManager::notifyObjectLoaded
void notifyObjectLoaded(RuntimeDyld &Dyld, const object::ObjectFile &Obj) override
This method is called after an object has been loaded into memory but before relocations are applied ...
Definition: EPCGenericRTDyldMemoryManager.cpp:187
llvm::isPowerOf2_32
constexpr bool isPowerOf2_32(uint32_t Value)
Return true if the argument is a power of two > 0.
Definition: MathExtras.h:491
LLVM_DEBUG
#define LLVM_DEBUG(X)
Definition: Debug.h:101
llvm::orc::EPCGenericRTDyldMemoryManager::CreateWithDefaultBootstrapSymbols
static Expected< std::unique_ptr< EPCGenericRTDyldMemoryManager > > CreateWithDefaultBootstrapSymbols(ExecutorProcessControl &EPC)
Create an EPCGenericRTDyldMemoryManager using the given EPC, looking up the default symbol names in t...
Definition: EPCGenericRTDyldMemoryManager.cpp:21
llvm::dbgs
raw_ostream & dbgs()
dbgs() - This returns a reference to a raw_ostream for debugging messages.
Definition: Debug.cpp:163
llvm::Lock
static sys::Mutex Lock
Definition: NVPTXUtilities.cpp:39
llvm::formatv
auto formatv(const char *Fmt, Ts &&... Vals) -> formatv_object< decltype(std::make_tuple(detail::build_format_adapter(std::forward< Ts >(Vals))...))>
Definition: FormatVariadic.h:250
llvm::orc::tpctypes::FinalizeRequest
Definition: TargetProcessControlTypes.h:123
llvm::orc::EPCGenericRTDyldMemoryManager::SymbolAddrs
Symbol addresses for memory access.
Definition: EPCGenericRTDyldMemoryManager.h:29
llvm::sys::Memory::ProtectionFlags
ProtectionFlags
Definition: Memory.h:54
llvm::orc::rt::SPSSimpleExecutorMemoryManagerReserveSignature
shared::SPSExpected< shared::SPSExecutorAddr >(shared::SPSExecutorAddr, uint64_t) SPSSimpleExecutorMemoryManagerReserveSignature
Definition: OrcRTBridge.h:55
llvm::orc::EPCGenericRTDyldMemoryManager::allocateDataSection
uint8_t * allocateDataSection(uintptr_t Size, unsigned Alignment, unsigned SectionID, StringRef SectionName, bool IsReadOnly) override
Allocate a memory block of (at least) the given size suitable for data.
Definition: EPCGenericRTDyldMemoryManager.cpp:77
EPCGenericMemoryAccess.h
llvm::orc::EPCGenericRTDyldMemoryManager::registerEHFrames
void registerEHFrames(uint8_t *Addr, uint64_t LoadAddr, size_t Size) override
Register the EH frames with the runtime so that c++ exceptions work.
Definition: EPCGenericRTDyldMemoryManager.cpp:160
llvm::orc::ExecutorAddrRange
Represents an address range in the exceutor process.
Definition: ExecutorAddress.h:134
llvm::orc::ExecutorAddr::setValue
void setValue(uint64_t Addr)
Definition: ExecutorAddress.h:61
llvm::orc::EPCGenericRTDyldMemoryManager::needsToReserveAllocationSpace
bool needsToReserveAllocationSpace() override
Override to return true to enable the reserveAllocationSpace callback.
Definition: EPCGenericRTDyldMemoryManager.cpp:156
llvm::Align
This struct is a compact representation of a valid (non-zero power of two) alignment.
Definition: Alignment.h:39
llvm::orc::EPCGenericRTDyldMemoryManager::SymbolAddrs::Reserve
ExecutorAddr Reserve
Definition: EPCGenericRTDyldMemoryManager.h:31
FormatVariadic.h
llvm::sys::Memory::MF_EXEC
@ MF_EXEC
Definition: Memory.h:57
uint64_t
Addr
uint64_t Addr
Definition: ELFObjHandler.cpp:80
move
compiles ldr LCPI1_0 ldr ldr mov lsr tst moveq r1 ldr LCPI1_1 and r0 bx lr It would be better to do something like to fold the shift into the conditional move
Definition: README.txt:546
I
#define I(x, y, z)
Definition: MD5.cpp:59
llvm::orc::tpctypes::FinalizeRequest::Actions
std::vector< AllocationActionsPair > Actions
Definition: TargetProcessControlTypes.h:125
llvm::move
OutputIt move(R &&Range, OutputIt Out)
Provide wrappers to std::move which take ranges instead of having to pass begin/end explicitly.
Definition: STLExtras.h:1658
std::swap
void swap(llvm::BitVector &LHS, llvm::BitVector &RHS)
Implement std::swap in terms of BitVector swap.
Definition: BitVector.h:840
memcpy
<%struct.s * > cast struct s *S to sbyte *< sbyte * > sbyte uint cast struct s *agg result to sbyte *< sbyte * > sbyte uint cast struct s *memtmp to sbyte *< sbyte * > sbyte uint ret void llc ends up issuing two memcpy or custom lower memcpy(of small size) to be ldmia/stmia. I think option 2 is better but the current register allocator cannot allocate a chunk of registers at a time. A feasible temporary solution is to use specific physical registers at the lowering time for small(<
llvm::orc::tpctypes::FinalizeRequest::Segments
std::vector< SegFinalizeRequest > Segments
Definition: TargetProcessControlTypes.h:124
llvm::orc::ExecutorAddrRange::Start
ExecutorAddr Start
Definition: ExecutorAddress.h:157
llvm::StringRef
StringRef - Represent a constant reference to a string, i.e.
Definition: StringRef.h:57
llvm::object::ObjectFile
This class is the base class for all object file types.
Definition: ObjectFile.h:228
uint32_t
llvm::orc::ExecutorProcessControl::callSPSWrapper
Error callSPSWrapper(ExecutorAddr WrapperFnAddr, WrapperCallArgTs &&...WrapperCallArgs)
Run a wrapper function using SPS to serialize the arguments and deserialize the results.
Definition: ExecutorProcessControl.h:342
llvm::format
format_object< Ts... > format(const char *Fmt, const Ts &... Vals)
These are helper functions used to produce formatted output.
Definition: Format.h:124
llvm::logAllUnhandledErrors
void logAllUnhandledErrors(Error E, raw_ostream &OS, Twine ErrorBanner={})
Log all errors (if any) in E to OS.
Definition: Error.cpp:61
llvm::orc::EPCGenericRTDyldMemoryManager::SymbolAddrs::Instance
ExecutorAddr Instance
Definition: EPCGenericRTDyldMemoryManager.h:30
Alignment.h
std
Definition: BitVector.h:838
llvm::SectionName
Definition: DWARFSection.h:21
llvm::Error
Lightweight error class with error context and mandatory checking.
Definition: Error.h:157
llvm::orc::ExecutorProcessControl::getPageSize
unsigned getPageSize() const
Get the page size for the target process.
Definition: ExecutorProcessControl.h:204
llvm::orc::EPCGenericRTDyldMemoryManager::SymbolAddrs::RegisterEHFrame
ExecutorAddr RegisterEHFrame
Definition: EPCGenericRTDyldMemoryManager.h:34
EPCGenericRTDyldMemoryManager.h
llvm::RuntimeDyld
Definition: RuntimeDyld.h:58
llvm::orc::EPCGenericRTDyldMemoryManager::~EPCGenericRTDyldMemoryManager
~EPCGenericRTDyldMemoryManager()
Definition: EPCGenericRTDyldMemoryManager.cpp:44
llvm::orc::EPCGenericRTDyldMemoryManager::finalizeMemory
bool finalizeMemory(std::string *ErrMsg=nullptr) override
This method is called when object loading is complete and section page permissions can be applied.
Definition: EPCGenericRTDyldMemoryManager.cpp:203
OrcRTBridge.h
llvm::RuntimeDyld::mapSectionAddress
void mapSectionAddress(const void *LocalAddress, uint64_t TargetAddress)
Map a section to its target address space value.
Definition: RuntimeDyld.cpp:1405
llvm::orc::rt::SPSSimpleExecutorMemoryManagerDeallocateSignature
shared::SPSError(shared::SPSExecutorAddr, shared::SPSSequence< shared::SPSExecutorAddr >) SPSSimpleExecutorMemoryManagerDeallocateSignature
Definition: OrcRTBridge.h:59