Memory Object Locks
API Reference Manual  /  Simulator API  /  Simulator API Functions  / 

Modules

SIM_add_module_dir

Name

SIM_add_module_dir — add loadable module search path

Synopsis

C and DML

#include <simics/simulator-api.h> // in C
import "simics/simulator-api.dml"; // in DML

void
SIM_add_module_dir(const char *path);

Python

import simics

simics.SIM_add_module_dir(...)

Description

Add given path to the list of paths where Simics searches for loadable modules. The function SIM_module_list_refresh has to be called after calling this function, for the change to take effect.

Execution Context

Global Context

SIM_get_all_failed_modules

Name

SIM_get_all_failed_modules — return a list of all modules that failed to load

Synopsis

C and DML

#include <simics/simulator-api.h> // in C
import "simics/simulator-api.dml"; // in DML

attr_value_t
SIM_get_all_failed_modules();

Python

import simics

simics.SIM_get_all_failed_modules(...)

Description

A failed module is a module that is not loadable by the current version of Simics. The list returned contains information about why the module failed. Each list entry is another list with module specific information. The layout of this sub-list is described below. The list may change in future Simics versions.

Execution Context

Cell Context

See Also

SIM_get_all_modules

SIM_get_all_modules

Name

SIM_get_all_modules — return a list of all modules

Synopsis

C and DML

#include <simics/simulator-api.h> // in C
import "simics/simulator-api.dml"; // in DML

attr_value_t
SIM_get_all_modules();

Python

import simics

simics.SIM_get_all_modules(...)

Description

The list returned contains information about all modules that can be loaded into Simics. Each list entry is another list with module specific information. The layout of this sub-list is described below. The list may grow in future Simics version, but the currently defined fields will not change.

Execution Context

Cell Context

See Also

SIM_get_all_failed_modules

SIM_load_module

Name

SIM_load_module — load a module

Synopsis

C and DML

#include <simics/simulator-api.h> // in C
import "simics/simulator-api.dml"; // in DML

void
SIM_load_module(const char *NOTNULL module);

Python

import simics

simics.SIM_load_module(...)

Description

Load a Simics module. Normally, modules are loaded automatically as needed for the configuration classes they implement, and there is rarely any need to call this function explicitly.

The module argument is the name of the module (not file name) to be loaded.

Exceptions

SimExc_License Thrown if the module requires a non-existing license feature.

SimExc_General Thrown if the module failed to load for other reasons.

Execution Context

Global Context

SIM_module_list_refresh

Name

SIM_module_list_refresh — refresh list of loadable modules

Synopsis

C and DML

#include <simics/simulator-api.h> // in C
import "simics/simulator-api.dml"; // in DML

void
SIM_module_list_refresh();

Python

import simics

simics.SIM_module_list_refresh(...)

Description

Simics maintains a list of all modules that can be loaded successfully. If a module is changed or added, the list has to be refreshed before Simics can load this module.

Execution Context

Global Context

Memory Object Locks