15 #ifndef LLVM_EXECUTIONENGINE_SECTIONMEMORYMANAGER_H 16 #define LLVM_EXECUTIONENGINE_SECTIONMEMORYMANAGER_H 24 #include <system_error> 77 unsigned Flags, std::error_code &EC) = 0;
129 unsigned SectionID,
StringRef SectionName,
130 bool isReadOnly)
override;
155 struct FreeMemBlock {
162 unsigned PendingPrefixIndex;
182 std::error_code applyMemoryGroupPermissions(MemoryGroup &MemGroup,
183 unsigned Permissions);
185 void anchor()
override;
188 MemoryGroup RWDataMem;
189 MemoryGroup RODataMem;
195 #endif // LLVM_EXECUTION_ENGINE_SECTION_MEMORY_MANAGER_H
This class represents lattice values for constants.
SectionMemoryManager(MemoryMapper *MM=nullptr)
Creates a SectionMemoryManager instance with MM as the associated memory mapper.
Implementations of this interface are used by SectionMemoryManager to request pages from the operatin...
~SectionMemoryManager() override
AllocationPurpose
This enum describes the various reasons to allocate pages from allocateMappedMemory.
virtual void invalidateInstructionCache()
Invalidate instruction cache for code sections.
uint8_t * allocateCodeSection(uintptr_t Size, unsigned Alignment, unsigned SectionID, StringRef SectionName) override
Allocates a memory block of (at least) the given size suitable for executable code.
uint8_t * allocateDataSection(uintptr_t Size, unsigned Alignment, unsigned SectionID, StringRef SectionName, bool isReadOnly) override
Allocates a memory block of (at least) the given size suitable for executable code.
This is a 'vector' (really, a variable-sized array), optimized for the case when the array is small...
This class encapsulates the notion of a memory block which has an address and a size.
void operator=(const SectionMemoryManager &)=delete
bool finalizeMemory(std::string *ErrMsg=nullptr) override
Update section-specific memory permissions and other attributes.
This is a simple memory manager which implements the methods called by the RuntimeDyld class to alloc...
StringRef - Represent a constant reference to a string, i.e.