ETISS 0.8.0
Extendable Translating Instruction Set Simulator (version 0.8.0)
Public Member Functions | Private Attributes | List of all members
etiss::JIT Class Referenceabstract

compiler interface for just in time compilation of generated C code More...

#include <JIT.h>

Inheritance diagram for etiss::JIT:
Inheritance graph
[legend]
Collaboration diagram for etiss::JIT:
Collaboration graph
[legend]

Public Member Functions

 JIT (std::string name)
 
virtual ~JIT ()
 
virtual void * translate (std::string code, std::set< std::string > headerpaths, std::set< std::string > librarypaths, std::set< std::string > libraries, std::string &error, bool debug=true)=0
 translate C code to executable code and return a handle/pointer that identifies the compilation result More...
 
virtual void * getFunction (void *handle, std::string name, std::string &error)=0
 returns a function pointer to a compiled function from the handle returned by etiss::JIT::translate More...
 
virtual void free (void *handle)=0
 clean up handled returned by etiss::JIT::translate More...
 
std::string getName ()
 returns the JIT instance name previously passed to the constructor More...
 

Private Attributes

std::string name_
 

Detailed Description

compiler interface for just in time compilation of generated C code

Definition at line 66 of file JIT.h.

Constructor & Destructor Documentation

◆ JIT()

JIT::JIT ( std::string  name)

Definition at line 56 of file JIT.cpp.

◆ ~JIT()

JIT::~JIT ( )
virtual

Definition at line 58 of file JIT.cpp.

Member Function Documentation

◆ free()

virtual void etiss::JIT::free ( void *  handle)
pure virtual

clean up handled returned by etiss::JIT::translate

Implemented in TCCJIT, etiss::LLVMJIT, and GCCJIT.

Referenced by verifyJITPragmaPack(), and verifyJITSizeOf().

Here is the caller graph for this function:

◆ getFunction()

virtual void* etiss::JIT::getFunction ( void *  handle,
std::string  name,
std::string &  error 
)
pure virtual

returns a function pointer to a compiled function from the handle returned by etiss::JIT::translate

Implemented in TCCJIT, etiss::LLVMJIT, and GCCJIT.

Referenced by etiss::Translation::getBlock(), verifyJITPragmaPack(), and verifyJITSizeOf().

Here is the caller graph for this function:

◆ getName()

std::string JIT::getName ( )

returns the JIT instance name previously passed to the constructor

Definition at line 60 of file JIT.cpp.

References name_.

◆ translate()

virtual void* etiss::JIT::translate ( std::string  code,
std::set< std::string >  headerpaths,
std::set< std::string >  librarypaths,
std::set< std::string >  libraries,
std::string &  error,
bool  debug = true 
)
pure virtual

translate C code to executable code and return a handle/pointer that identifies the compilation result

Parameters
codegenerated code
headerpathspaths where required header files are located
librarypathspaths where required libraries are located (usually not needed since libraries don't require full linking)
librariesfile names of required libraries (usually not needed since libraries don't require full linking)
errorstring to return additional error information
debugif true then compilation should try to enable gdb to jump into compiled functions

Implemented in TCCJIT, etiss::LLVMJIT, and GCCJIT.

Referenced by etiss::Translation::getBlock(), verifyJITPragmaPack(), and verifyJITSizeOf().

Here is the caller graph for this function:

Member Data Documentation

◆ name_

std::string etiss::JIT::name_
private

Definition at line 100 of file JIT.h.

Referenced by getName().


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