ETISS 0.8.0
Extendable Translating Instruction Set Simulator (version 0.8.0)
Namespaces | Functions | Variables
ETISSInit.cpp File Reference

implementation of etiss::preloadLibraries More...

#include "etiss/ETISS.h"
#include "etiss/config.h"
#include <cstdlib>
#include <fstream>
#include <sstream>
#include <string>
#include <vector>
#include <boost/filesystem.hpp>
Include dependency graph for ETISSInit.cpp:

Go to the source code of this file.

Namespaces

 etiss
 Page Table Entry (PTE) defines the composition of Page Frame Number (PFN) and relavant flags.
 

Functions

std::vector< std::string > & etiss::split (const std::string &s, char delim, std::vector< std::string > &elems)
 
static bool loadLibraryList (const std::string &path)
 Load libraries specified in a list.txt file. More...
 
static void findLibs (const boost::filesystem::path &path, std::vector< std::string > &libs)
 Find all dynamically linked libraries in a folder and its subfolders. More...
 

Variables

bool etiss_preload_libraries = false
 This flag indicate whether the preloading of the libraries has been executed or not. More...
 

Detailed Description

implementation of etiss::preloadLibraries


Copyright 2018 Infineon Technologies AG

This file is part of ETISS tool, see https://github.com/tum-ei-eda/etiss.

The initial version of this software has been created with the funding support by the German Federal
Ministry of Education and Research (BMBF) in the project EffektiV under grant 01IS13022.

Redistribution and use in source and binary forms, with or without modification, are permitted
provided that the following conditions are met:

1. Redistributions of source code must retain the above copyright notice, this list of conditions and
the following disclaimer.

2. Redistributions in binary form must reproduce the above copyright notice, this list of conditions
and the following disclaimer in the documentation and/or other materials provided with the distribution.

3. Neither the name of the copyright holder nor the names of its contributors may be used to endorse
or promote products derived from this software without specific prior written permission.

THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND ANY EXPRESS OR IMPLIED
WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A
PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR CONTRIBUTORS BE LIABLE FOR ANY
DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO,
PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION)
HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING
NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE
POSSIBILITY OF SUCH DAMAGE.

Author
Marc Greim marc..nosp@m.grei.nosp@m.m@myt.nosp@m.um.d.nosp@m.e, Chair of Electronic Design Automation, TUM
Date
July 29, 2014
Version
0.1

Definition in file ETISSInit.cpp.

Function Documentation

◆ findLibs()

static void findLibs ( const boost::filesystem::path &  path,
std::vector< std::string > &  libs 
)
static

Find all dynamically linked libraries in a folder and its subfolders.

This function searchs a folder and its subfolders for dynamically linked libraries. The folder is provided by a string of the folder path. The strings of the library paths are inserted into the provided vector.

Parameters
pathboost::filesystem::path& Reference to a path of a folder.
libsstd::vector<std::string>& Reference to the vector where the library paths shall be stored.

Definition at line 169 of file ETISSInit.cpp.

Referenced by etiss::preloadLibraries().

Here is the caller graph for this function:

◆ loadLibraryList()

static bool loadLibraryList ( const std::string &  path)
static

Load libraries specified in a list.txt file.

This function loads the libraries specified in a list.txt file. The list.txt is a special configuration file, that contains references to libraries. list.txt Syntax in Bachus-Naur Form: <list-file> ::= <lib-ref>*

<lib-ref> ::= <remote-lib-ref> | <local-lib-ref>

<remote-lib-ref> ::= <lib-name> COMMA <lib-path> COMMA <lib-name> NEWLINE

<local-lib-ref> ::= <lib-name> NEWLINE

<lib-name> ::= The name of the library without the prefix und suffix

<lib-path> ::= The file path of the folder where the library resides

Example list.txt:

QEMU TCCJIT OR1KArch LLVMJIT,/etiss/lib/Jits,LLVMJIT ARMv6M,/etiss/lib/Archs,ARMv6M

Parameters
pathstd::string A Reference to a string of the path were the list.txt file can be found.
Returns
bool Returns true or false.

Definition at line 114 of file ETISSInit.cpp.

References etiss::ERROR, length(), etiss::loadLibrary(), etiss::log(), and etiss::split().

Referenced by etiss::preloadLibraries().

Here is the call graph for this function:
Here is the caller graph for this function:

Variable Documentation

◆ etiss_preload_libraries

bool etiss_preload_libraries = false

This flag indicate whether the preloading of the libraries has been executed or not.

Definition at line 190 of file ETISSInit.cpp.

Referenced by etiss::preloadLibraries().