HAL  v4.5.0-83-g30c8f0afc
The Hardware Analyzer - a comprehensive reverse engineering and manipulation framework for gate-level netlists.
hal::Simulation Class Reference

#include </home/runner/work/hal/hal/plugins/simulator/hal_simulator/include/netlist_simulator/simulation.h>

Collaboration diagram for hal::Simulation:
Collaboration graph

Public Member Functions

BooleanFunction::Value get_net_value (const Net *net, u64 time) const
 
void add_event (const WaveEvent &event)
 
std::unordered_map< const Net *, std::vector< WaveEvent > > get_events () const
 
std::vector< WaveEventget_events_by_net_id (u32 netId, bool *found=nullptr) const
 

Friends

class NetlistSimulator
 

Detailed Description

The result of a simulation run, i.e., the events that occurred on every net over time.

Definition at line 40 of file simulation.h.

Member Function Documentation

◆ add_event()

void hal::Simulation::add_event ( const WaveEvent event)

Adds a custom event to the simulation.

Parameters
[in]event- The event to add.

Definition at line 26 of file simulation.cpp.

Referenced by hal::PYBIND11_PLUGIN().

◆ get_events()

std::unordered_map< const Net *, std::vector< WaveEvent > > hal::Simulation::get_events ( ) const

Get all events of the simulation.

Returns
A map from net to associated events for that net sorted by time.

Definition at line 31 of file simulation.cpp.

Referenced by hal::PYBIND11_PLUGIN().

◆ get_events_by_net_id()

std::vector< WaveEvent > hal::Simulation::get_events_by_net_id ( u32  netId,
bool *  found = nullptr 
) const

Get events of simulation for net identified by netId

Parameters
[in]netId- ID of net for simulation
[out]found- true simulation events for net found, false otherwise
Returns
A vector of simulation events

Definition at line 36 of file simulation.cpp.

Referenced by hal::NetlistSimulator::get_simulation_events().

◆ get_net_value()

BooleanFunction::Value hal::Simulation::get_net_value ( const Net net,
u64  time 
) const

Get the signal value of a specific net at a specific point in time specified in picoseconds.

Parameters
[in]net- The net to inspect.
[in]time- The time in .
Returns
The net's signal value.

Definition at line 8 of file simulation.cpp.

References net, hal::WaveEvent::new_value, and hal::WaveEvent::time.

Referenced by hal::PYBIND11_PLUGIN().

Friends And Related Function Documentation

◆ NetlistSimulator

friend class NetlistSimulator
friend

Definition at line 75 of file simulation.h.


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