ETISS 0.11.2
ExtendableTranslatingInstructionSetSimulator(version0.11.2)
Loading...
Searching...
No Matches
GCCJITLIB.cpp
Go to the documentation of this file.
1// SPDX-License-Identifier: BSD-3-Clause
2//
3// This file is part of ETISS. It is licensed under the BSD 3-Clause License; you may not use this file except in
4// compliance with the License. You should have received a copy of the license along with this project. If not, see the
5// LICENSE file.
6
7#include "GCCJIT.h"
8
9#define ETISS_LIBNAME GCCJIT
10
11#include "etiss/Misc.h"
13
14extern "C"
15{
16
17 const char *GCCJIT_versionInfo()
18 {
19 return "0.4";
20 }
21
22 // implement version function
24
25 unsigned GCCJIT_countJIT()
26 {
27 return 1;
28 }
29
30 const char *GCCJIT_nameJIT(unsigned i)
31 {
32 return "GCCJIT";
33 }
34
35 etiss::JIT *GCCJIT_createJIT(unsigned i, std::map<std::string, std::string> options)
36 {
38 cfg.config() = options;
39 return new GCCJIT(cfg.get<bool>("jit.gcc.cleanup", true), cfg.get<std::string>("jit.gcc.opt_level", "fast"),
40 cfg.get<bool>("jit.gcc.quiet", false));
41 }
42
44 {
45 delete (GCCJIT *)jit;
46 }
47}
ETISS_PLUGIN_EXPORT etiss::CPUArch std::map< std::string, std::string > options
create new instance of the CPUArch type at index
void GCCJIT_deleteJIT(etiss::JIT *jit)
Definition GCCJITLIB.cpp:43
ETISS_LIBRARYIF_VERSION_FUNC_IMPL unsigned GCCJIT_countJIT()
Definition GCCJITLIB.cpp:25
etiss::JIT * GCCJIT_createJIT(unsigned i, std::map< std::string, std::string > options)
Definition GCCJITLIB.cpp:35
const char * GCCJIT_versionInfo()
Definition GCCJITLIB.cpp:17
const char * GCCJIT_nameJIT(unsigned i)
Definition GCCJITLIB.cpp:30
defines the functions needed for a library that provides etiss::JIT implementations
general configuration and logging
provides compilation via gcc and load the compilation result with dlopen/dlsym functions
Definition GCCJIT.h:14
simple class to hold configuration options
Definition Misc.h:296
compiler interface for just in time compilation of generated C code
Definition JIT.h:29
#define ETISS_LIBRARYIF_VERSION_FUNC_IMPL
Definition Misc.h:47