OmniSciDB  2e3a973ef4
ExecutionEngineWrapper Class Reference

#include <CompilationContext.h>

Public Member Functions

 ExecutionEngineWrapper ()
 
 ExecutionEngineWrapper (llvm::ExecutionEngine *execution_engine)
 
 ExecutionEngineWrapper (llvm::ExecutionEngine *execution_engine, const CompilationOptions &co)
 
 ExecutionEngineWrapper (const ExecutionEngineWrapper &other)=delete
 
 ExecutionEngineWrapper (ExecutionEngineWrapper &&other)=default
 
ExecutionEngineWrapperoperator= (const ExecutionEngineWrapper &other)=delete
 
ExecutionEngineWrapperoperator= (ExecutionEngineWrapper &&other)=default
 
ExecutionEngineWrapperoperator= (llvm::ExecutionEngine *execution_engine)
 
llvm::ExecutionEngine * get ()
 
const llvm::ExecutionEngine * get () const
 
llvm::ExecutionEngine & operator* ()
 
const llvm::ExecutionEngine & operator* () const
 
llvm::ExecutionEngine * operator-> ()
 
const llvm::ExecutionEngine * operator-> () const
 

Private Attributes

std::unique_ptr< llvm::ExecutionEngine > execution_engine_
 
std::unique_ptr< llvm::JITEventListener > intel_jit_listener_
 

Detailed Description

Definition at line 32 of file CompilationContext.h.

Constructor & Destructor Documentation

◆ ExecutionEngineWrapper() [1/5]

ExecutionEngineWrapper::ExecutionEngineWrapper ( )

Definition at line 174 of file NativeCodegen.cpp.

174 {}

◆ ExecutionEngineWrapper() [2/5]

ExecutionEngineWrapper::ExecutionEngineWrapper ( llvm::ExecutionEngine *  execution_engine)

Definition at line 176 of file NativeCodegen.cpp.

177  : execution_engine_(execution_engine) {}
std::unique_ptr< llvm::ExecutionEngine > execution_engine_

◆ ExecutionEngineWrapper() [3/5]

ExecutionEngineWrapper::ExecutionEngineWrapper ( llvm::ExecutionEngine *  execution_engine,
const CompilationOptions co 
)

Definition at line 179 of file NativeCodegen.cpp.

References CHECK, execution_engine_, logger::INFO, intel_jit_listener_, LOG, CompilationOptions::register_intel_jit_listener, and logger::WARNING.

181  : execution_engine_(execution_engine) {
182  if (execution_engine_) {
184 #ifdef ENABLE_INTEL_JIT_LISTENER
185  intel_jit_listener_.reset(llvm::JITEventListener::createIntelJITEventListener());
187  execution_engine_->RegisterJITEventListener(intel_jit_listener_.get());
188  LOG(INFO) << "Registered IntelJITEventListener";
189 #else
190  LOG(WARNING) << "This build is not Intel JIT Listener enabled. Ignoring Intel JIT "
191  "listener configuration parameter.";
192 #endif // ENABLE_INTEL_JIT_LISTENER
193  }
194  }
195 }
#define LOG(tag)
Definition: Logger.h:188
std::unique_ptr< llvm::JITEventListener > intel_jit_listener_
std::unique_ptr< llvm::ExecutionEngine > execution_engine_
#define CHECK(condition)
Definition: Logger.h:197

◆ ExecutionEngineWrapper() [4/5]

ExecutionEngineWrapper::ExecutionEngineWrapper ( const ExecutionEngineWrapper other)
delete

◆ ExecutionEngineWrapper() [5/5]

ExecutionEngineWrapper::ExecutionEngineWrapper ( ExecutionEngineWrapper &&  other)
default

Member Function Documentation

◆ get() [1/2]

llvm::ExecutionEngine* ExecutionEngineWrapper::get ( )
inline

Definition at line 47 of file CompilationContext.h.

47 { return execution_engine_.get(); }
std::unique_ptr< llvm::ExecutionEngine > execution_engine_

◆ get() [2/2]

const llvm::ExecutionEngine* ExecutionEngineWrapper::get ( ) const
inline

Definition at line 48 of file CompilationContext.h.

48 { return execution_engine_.get(); }
std::unique_ptr< llvm::ExecutionEngine > execution_engine_

◆ operator*() [1/2]

llvm::ExecutionEngine& ExecutionEngineWrapper::operator* ( )
inline

Definition at line 50 of file CompilationContext.h.

50 { return *execution_engine_; }
std::unique_ptr< llvm::ExecutionEngine > execution_engine_

◆ operator*() [2/2]

const llvm::ExecutionEngine& ExecutionEngineWrapper::operator* ( ) const
inline

Definition at line 51 of file CompilationContext.h.

51 { return *execution_engine_; }
std::unique_ptr< llvm::ExecutionEngine > execution_engine_

◆ operator->() [1/2]

llvm::ExecutionEngine* ExecutionEngineWrapper::operator-> ( )
inline

Definition at line 53 of file CompilationContext.h.

53 { return execution_engine_.get(); }
std::unique_ptr< llvm::ExecutionEngine > execution_engine_

◆ operator->() [2/2]

const llvm::ExecutionEngine* ExecutionEngineWrapper::operator-> ( ) const
inline

Definition at line 54 of file CompilationContext.h.

54 { return execution_engine_.get(); }
std::unique_ptr< llvm::ExecutionEngine > execution_engine_

◆ operator=() [1/3]

ExecutionEngineWrapper& ExecutionEngineWrapper::operator= ( const ExecutionEngineWrapper other)
delete

◆ operator=() [2/3]

ExecutionEngineWrapper& ExecutionEngineWrapper::operator= ( ExecutionEngineWrapper &&  other)
default

◆ operator=() [3/3]

ExecutionEngineWrapper & ExecutionEngineWrapper::operator= ( llvm::ExecutionEngine *  execution_engine)

Definition at line 197 of file NativeCodegen.cpp.

References execution_engine_, and intel_jit_listener_.

198  {
199  execution_engine_.reset(execution_engine);
200  intel_jit_listener_ = nullptr;
201  return *this;
202 }
std::unique_ptr< llvm::JITEventListener > intel_jit_listener_
std::unique_ptr< llvm::ExecutionEngine > execution_engine_

Member Data Documentation

◆ execution_engine_

std::unique_ptr<llvm::ExecutionEngine> ExecutionEngineWrapper::execution_engine_
private

Definition at line 57 of file CompilationContext.h.

Referenced by ExecutionEngineWrapper(), and operator=().

◆ intel_jit_listener_

std::unique_ptr<llvm::JITEventListener> ExecutionEngineWrapper::intel_jit_listener_
private

Definition at line 58 of file CompilationContext.h.

Referenced by ExecutionEngineWrapper(), and operator=().


The documentation for this class was generated from the following files: