Nuke the old JIT.
[oota-llvm.git] / examples / Kaleidoscope / MCJIT / cached / toy.cpp
index b14847955941d0c8d4ce9b332be569aa259027cd..af51b4a8314cc03119fb26b823c510fa85432c65 100644 (file)
@@ -715,7 +715,7 @@ public:
         // This file isn't in our cache
         return NULL;
       }
-      OwningPtr<MemoryBuffer> IRObjectBuffer;
+      std::unique_ptr<MemoryBuffer> IRObjectBuffer;
       MemoryBuffer::getFile(IRCacheFile.c_str(), IRObjectBuffer, -1, false);
       // MCJIT will want to write into this buffer, and we don't want that
       // because the file has probably just been mmapped.  Instead we make
@@ -897,7 +897,6 @@ ExecutionEngine *MCJITHelper::compileModule(Module *M) {
   std::string ErrStr;
   ExecutionEngine *NewEngine = EngineBuilder(M)
                                             .setErrorStr(&ErrStr)
-                                            .setUseMCJIT(true)
                                             .setMCJITMemoryManager(new HelpingMemoryManager(this))
                                             .create();
   if (!NewEngine) {