[CMake] Update LLVM_LINK_COMPONENTS for each CMakeLists.txt.
[oota-llvm.git] / unittests / ExecutionEngine / MCJIT / MCJITCAPITest.cpp
index c434a7c0b25b149e121dd8d3bec8b31051143c42..46d6d9b8a9a600c281475274e0c7e6fc116927f7 100644 (file)
@@ -28,18 +28,20 @@ static bool didCallAllocateCodeSection;
 
 static uint8_t *roundTripAllocateCodeSection(void *object, uintptr_t size,
                                              unsigned alignment,
-                                             unsigned sectionID) {
+                                             unsigned sectionID,
+                                             const char *sectionName) {
   didCallAllocateCodeSection = true;
   return static_cast<SectionMemoryManager*>(object)->allocateCodeSection(
-    size, alignment, sectionID);
+    size, alignment, sectionID, sectionName);
 }
 
 static uint8_t *roundTripAllocateDataSection(void *object, uintptr_t size,
                                              unsigned alignment,
                                              unsigned sectionID,
+                                             const char *sectionName,
                                              LLVMBool isReadOnly) {
   return static_cast<SectionMemoryManager*>(object)->allocateDataSection(
-    size, alignment, sectionID, isReadOnly);
+    size, alignment, sectionID, sectionName, isReadOnly);
 }
 
 static LLVMBool roundTripFinalizeMemory(void *object, char **errMsg) {
@@ -57,6 +59,7 @@ static void roundTripDestroy(void *object) {
   delete static_cast<SectionMemoryManager*>(object);
 }
 
+namespace {
 class MCJITCAPITest : public testing::Test, public MCJITTestAPICommon {
 protected:
   MCJITCAPITest() {
@@ -154,6 +157,7 @@ protected:
   LLVMExecutionEngineRef Engine;
   char *Error;
 };
+} // end anonymous namespace
 
 TEST_F(MCJITCAPITest, simple_function) {
   SKIP_UNSUPPORTED_PLATFORM;