diff options
-rw-r--r-- | tensorflow/compiler/xla/service/cpu/simple_orc_jit.cc | 10 | ||||
-rw-r--r-- | tensorflow/compiler/xla/service/cpu/simple_orc_jit.h | 2 |
2 files changed, 4 insertions, 8 deletions
diff --git a/tensorflow/compiler/xla/service/cpu/simple_orc_jit.cc b/tensorflow/compiler/xla/service/cpu/simple_orc_jit.cc index d5b157b7f6..b284543299 100644 --- a/tensorflow/compiler/xla/service/cpu/simple_orc_jit.cc +++ b/tensorflow/compiler/xla/service/cpu/simple_orc_jit.cc @@ -166,12 +166,8 @@ SimpleOrcJIT::SimpleOrcJIT(const llvm::TargetOptions &target_options, SimpleOrcJIT::ModuleHandleT SimpleOrcJIT::AddModule( std::unique_ptr<llvm::Module> module) { - // The Orc API adds a whole iterable "set" of modules, so we wrap the module - // in a vector. - std::vector<std::unique_ptr<llvm::Module>> module_set; - module_set.push_back(std::move(module)); - auto handle = compile_layer_.addModuleSet( - std::move(module_set), MakeUnique<llvm::SectionMemoryManager>(), + auto handle = compile_layer_.addModule( + std::move(module), MakeUnique<llvm::SectionMemoryManager>(), MakeUnique<SimpleResolver>()); module_handles_.push_back(handle); return handle; @@ -181,7 +177,7 @@ void SimpleOrcJIT::RemoveModule(SimpleOrcJIT::ModuleHandleT handle) { module_handles_.erase( std::remove(module_handles_.begin(), module_handles_.end(), handle), module_handles_.end()); - compile_layer_.removeModuleSet(handle); + compile_layer_.removeModule(handle); } llvm::JITSymbol SimpleOrcJIT::FindSymbol(const std::string &name) { diff --git a/tensorflow/compiler/xla/service/cpu/simple_orc_jit.h b/tensorflow/compiler/xla/service/cpu/simple_orc_jit.h index 0a3b992403..e28717bcd1 100644 --- a/tensorflow/compiler/xla/service/cpu/simple_orc_jit.h +++ b/tensorflow/compiler/xla/service/cpu/simple_orc_jit.h @@ -47,7 +47,7 @@ class SimpleOrcJIT { std::function<llvm::object::OwningBinary<llvm::object::ObjectFile>( llvm::Module&)>; using CompileLayerT = llvm::orc::IRCompileLayer<ObjLayerT, CompileFtor>; - using ModuleHandleT = CompileLayerT::ModuleSetHandleT; + using ModuleHandleT = CompileLayerT::ModuleHandleT; using OptimizationCallback = CompilerFunctor::OptimizationCallback; // Create a new JIT, targeting the host architecture. |