btftoolchain
btf Namespace Reference

Classes

struct  PairHash
 This struct generates a hash out of two values (uses a pair). More...
 
struct  TupleHash
 This struct generates a hash out of three values (uses a tuple). More...
 
struct  QuadrupleHash
 This struct generates a hash out of four values (uses a pair where the first parameter is a tuple). More...
 
class  BtfEntry
 Class for a BtfEntry. More...
 
class  BtfFile
 Main class of the btf lib. It contains all necessary functions to import and export a BTF file. More...
 
class  Signal
 Class for Signal (SIG) Events (see BTF Specification Chapter 2.3.6). More...
 
class  Core
 Class for the core (C) events. More...
 
class  OS
 Class for OS (EVENT) Events (see BTF Specification Chapter 2.3.5). More...
 
class  Process
 Class for Process Events (see BTF Specification Chapter 2.3.2). More...
 
class  Runnable
 Class for Runnable Events (see BTF Specification Chapter 2.3.3). More...
 
class  Scheduler
 Class for Scheduler (SCHED) Events (see BTF Specification Chapter 2.3.4). More...
 
class  Semaphore
 Class for Semaphore (SEM) Events (see BTF Specification Chapter 2.3.7). More...
 
class  Simulation
 Class for the Simulation (SIM) events. More...
 
class  Stimulus
 Class for Stimulus (STIM) Events (see BTF Specification Chapter 2.3.1). More...
 

Enumerations

enum class  EntityTypes {
  core , os , task , isr ,
  stimulus , scheduler , semaphore , runnable ,
  signal , comment , simulation , syscall ,
  thread , unknown
}
 All types of entities that are supported by the btf lib. More...
 
enum class  ErrorCodes {
  success , already_in_state , invalid_state_transition , descending_timestamp ,
  invalid_type , invalid_event , core_idle_task_still_running , multiple_tasks_running ,
  event_on_idle_core , runnable_source_task_not_running , no_task_running , terminate_on_runnable_with_running_sub_runnable ,
  terminate_on_task_with_running_runnables , allocated_to_different_core , source_and_target_not_equal , amount_of_semaphore_accesses_invalid
}
 Error Codes for the btf library. More...
 

Functions

std::string entityTypeToString (EntityTypes type)
 Converts the enum EntityTypes into string. More...
 
EntityTypes stringToEntityType (const std::string &str)
 Converts a string into the enum EntityTypes. More...
 
std::string errorCodeToString (ErrorCodes code)
 Converts the enum ErrorCode into string. More...
 

Enumeration Type Documentation

◆ EntityTypes

enum btf::EntityTypes
strong

All types of entities that are supported by the btf lib.

Enumerator
core 

"C"

os 

"EVENT"

task 

"T"

isr 

"I"

stimulus 

STI.

scheduler 

SCHED.

semaphore 

SEM.

runnable 

"R"

signal 

"SIG"

comment 
simulation 

"SIM"

syscall 

"SYSC"

thread 

"THR"

unknown 

default value

◆ ErrorCodes

enum btf::ErrorCodes
strong

Error Codes for the btf library.

Enumerator
success 

No error occured.

already_in_state 

Entity wants to go in a state, in which it already was.

invalid_state_transition 

The state transition of an entity is not valid.

descending_timestamp 

The timestamp of an event is smaller than the timestamp of the last event.

invalid_type 

The type of the object is invalid, e.g. the entity was previously used as another type.

invalid_event 

The type of the event is invalid, e.g. the given source cannot issue that event.

core_idle_task_still_running 

A core wants to switch to idle while a task is still running on it.

multiple_tasks_running 

Multiple tasks are running at the same time on the same core.

event_on_idle_core 

An Event appeared on an idle core.

runnable_source_task_not_running 

The source task of a runnable is not running.

no_task_running 

No task is running, hence no runnable event is possible.

terminate_on_runnable_with_running_sub_runnable 

The system tried to terminate a runnable with at least one running sub-runnable.

terminate_on_task_with_running_runnables 

The system tried to terminate a task, which has running runnables.

allocated_to_different_core 

The entity is currently running on a different core.

source_and_target_not_equal 

Although required, the source and target are not equal.

amount_of_semaphore_accesses_invalid 

Function Documentation

◆ entityTypeToString()

std::string btf::entityTypeToString ( EntityTypes  type)

Converts the enum EntityTypes into string.

Parameters
[in]typeEntityType that will be converted.
Returns
String if EntityType is valid, else a fatal error is triggered.
Here is the caller graph for this function:

◆ errorCodeToString()

std::string btf::errorCodeToString ( ErrorCodes  code)

Converts the enum ErrorCode into string.

Parameters
[in]codeErrorCode that will be converted.
Returns
String if ErrorCode is valid, else a fatal error is triggered.
Here is the caller graph for this function:

◆ stringToEntityType()

EntityTypes btf::stringToEntityType ( const std::string &  str)

Converts a string into the enum EntityTypes.

Parameters
[in]strString that will be converted.
Returns
EntityType enum.
Here is the caller graph for this function: