Mercurial > hg > graal-compiler
comparison src/share/vm/shark/sharkMemoryManager.cpp @ 7195:2cd5e15048e6
8003868: fix shark for latest HotSpot and LLVM
Reviewed-by: twisti
Contributed-by: Roman Kennke <rkennke@redhat.com>
author | twisti |
---|---|
date | Tue, 27 Nov 2012 12:48:52 -0800 |
parents | f95d63e2154a |
children | 81ccf2c854c7 |
comparison
equal
deleted
inserted
replaced
7194:beebba0acc11 | 7195:2cd5e15048e6 |
---|---|
77 | 77 |
78 void SharkMemoryManager::setMemoryExecutable() { | 78 void SharkMemoryManager::setMemoryExecutable() { |
79 mm()->setMemoryExecutable(); | 79 mm()->setMemoryExecutable(); |
80 } | 80 } |
81 | 81 |
82 #if SHARK_LLVM_VERSION >= 27 | |
83 void SharkMemoryManager::deallocateExceptionTable(void *ptr) { | 82 void SharkMemoryManager::deallocateExceptionTable(void *ptr) { |
84 mm()->deallocateExceptionTable(ptr); | 83 mm()->deallocateExceptionTable(ptr); |
85 } | 84 } |
86 | 85 |
87 void SharkMemoryManager::deallocateFunctionBody(void *ptr) { | 86 void SharkMemoryManager::deallocateFunctionBody(void *ptr) { |
88 mm()->deallocateFunctionBody(ptr); | 87 mm()->deallocateFunctionBody(ptr); |
89 } | 88 } |
90 #else | |
91 void SharkMemoryManager::deallocateMemForFunction(const Function* F) { | |
92 return mm()->deallocateMemForFunction(F); | |
93 } | |
94 #endif | |
95 | 89 |
96 uint8_t* SharkMemoryManager::allocateGlobal(uintptr_t Size, | 90 uint8_t* SharkMemoryManager::allocateGlobal(uintptr_t Size, |
97 unsigned int Alignment) { | 91 unsigned int Alignment) { |
98 return mm()->allocateGlobal(Size, Alignment); | 92 return mm()->allocateGlobal(Size, Alignment); |
99 } | 93 } |
100 | 94 |
101 #if SHARK_LLVM_VERSION < 27 | 95 void* SharkMemoryManager::getPointerToNamedFunction(const std::string &Name, bool AbortOnFailure) { |
102 void* SharkMemoryManager::getDlsymTable() const { | 96 return mm()->getPointerToNamedFunction(Name, AbortOnFailure); |
103 return mm()->getDlsymTable(); | |
104 } | 97 } |
105 | 98 |
106 void SharkMemoryManager::SetDlsymTable(void *ptr) { | 99 uint8_t* SharkMemoryManager::allocateCodeSection(uintptr_t Size, unsigned Alignment, unsigned SectionID) { |
107 mm()->SetDlsymTable(ptr); | 100 return mm()->allocateCodeSection(Size, Alignment, SectionID); |
108 } | 101 } |
109 #endif | 102 |
103 uint8_t* SharkMemoryManager::allocateDataSection(uintptr_t Size, unsigned Alignment, unsigned SectionID) { | |
104 return mm()->allocateDataSection(Size, Alignment, SectionID); | |
105 } | |
110 | 106 |
111 void SharkMemoryManager::setPoisonMemory(bool poison) { | 107 void SharkMemoryManager::setPoisonMemory(bool poison) { |
112 mm()->setPoisonMemory(poison); | 108 mm()->setPoisonMemory(poison); |
113 } | 109 } |
114 | 110 |