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

The abstraction of the netlist that only contains gates of a specified type, e.g., flip-flops. More...

#include </home/runner/work/hal/hal/plugins/dataflow_analysis/include/dataflow_analysis/common/netlist_abstraction.h>

Collaboration diagram for hal::dataflow::NetlistAbstraction:
Collaboration graph

Public Member Functions

 NetlistAbstraction (const Netlist *nl_arg)
 Construct a netlist abstraction from a netlist. More...
 

Public Attributes

const Netlistnl
 
bool yosys
 
std::vector< Gate * > target_gates
 
std::unordered_map< u32, std::vector< u32 > > gate_to_fingerprint
 
std::unordered_map< u32, std::map< PinType, std::unordered_set< u32 > > > gate_to_control_signals
 
std::unordered_map< u32, std::unordered_set< u32 > > gate_to_register_stages
 
std::unordered_map< u32, std::unordered_set< u32 > > gate_to_predecessors
 
std::unordered_map< u32, std::unordered_set< u32 > > gate_to_successors
 
std::unordered_map< u32, std::unordered_set< u32 > > gate_to_known_predecessor_groups
 
std::unordered_map< u32, std::unordered_set< u32 > > gate_to_known_successor_groups
 
std::unordered_map< u32, std::vector< std::vector< u32 > > > gate_to_output_shape
 
std::unordered_map< u32, std::vector< std::vector< u32 > > > gate_to_input_shape
 

Detailed Description

The abstraction of the netlist that only contains gates of a specified type, e.g., flip-flops.

Definition at line 55 of file netlist_abstraction.h.

Constructor & Destructor Documentation

◆ NetlistAbstraction()

hal::dataflow::NetlistAbstraction::NetlistAbstraction ( const Netlist nl_arg)

Construct a netlist abstraction from a netlist.

Parameters
[in]nl_arg- The netlist.

Definition at line 13 of file netlist_abstraction.cpp.

Member Data Documentation

◆ gate_to_control_signals

std::unordered_map<u32, std::map<PinType, std::unordered_set<u32> > > hal::dataflow::NetlistAbstraction::gate_to_control_signals

A map from each target gate to the nets connected to its control pins, grouped by pin type.

Definition at line 83 of file netlist_abstraction.h.

Referenced by hal::dataflow::Grouping::get_control_signals_of_group().

◆ gate_to_fingerprint

std::unordered_map<u32, std::vector<u32> > hal::dataflow::NetlistAbstraction::gate_to_fingerprint

A map from each target gate to the fingerprint that summarizes its type and connectivity.

Definition at line 80 of file netlist_abstraction.h.

Referenced by hal::dataflow::Grouping::Grouping().

◆ gate_to_input_shape

std::unordered_map<u32, std::vector<std::vector<u32> > > hal::dataflow::NetlistAbstraction::gate_to_input_shape

A map from each target gate to the sizes of the pin groups that drive its inputs.

Definition at line 104 of file netlist_abstraction.h.

◆ gate_to_known_predecessor_groups

std::unordered_map<u32, std::unordered_set<u32> > hal::dataflow::NetlistAbstraction::gate_to_known_predecessor_groups

A map from each target gate to the previously known groups that precede it.

Definition at line 95 of file netlist_abstraction.h.

Referenced by hal::dataflow::Grouping::get_known_predecessor_groups_of_group().

◆ gate_to_known_successor_groups

std::unordered_map<u32, std::unordered_set<u32> > hal::dataflow::NetlistAbstraction::gate_to_known_successor_groups

A map from each target gate to the previously known groups that succeed it.

Definition at line 98 of file netlist_abstraction.h.

Referenced by hal::dataflow::Grouping::get_known_successor_groups_of_group().

◆ gate_to_output_shape

std::unordered_map<u32, std::vector<std::vector<u32> > > hal::dataflow::NetlistAbstraction::gate_to_output_shape

A map from each target gate to the sizes of the pin groups that its outputs feed into.

Definition at line 101 of file netlist_abstraction.h.

◆ gate_to_predecessors

std::unordered_map<u32, std::unordered_set<u32> > hal::dataflow::NetlistAbstraction::gate_to_predecessors

A map from each target gate to the target gates that precede it.

Definition at line 89 of file netlist_abstraction.h.

Referenced by hal::dataflow::Grouping::get_predecessor_groups_of_group(), and hal::dataflow::pre_processing::identify_register_stages().

◆ gate_to_register_stages

std::unordered_map<u32, std::unordered_set<u32> > hal::dataflow::NetlistAbstraction::gate_to_register_stages

A map from each target gate to the register stages it belongs to.

Definition at line 86 of file netlist_abstraction.h.

Referenced by hal::dataflow::Grouping::get_register_stage_intersect_of_group(), and hal::dataflow::pre_processing::identify_register_stages().

◆ gate_to_successors

std::unordered_map<u32, std::unordered_set<u32> > hal::dataflow::NetlistAbstraction::gate_to_successors

A map from each target gate to the target gates that succeed it.

Definition at line 92 of file netlist_abstraction.h.

Referenced by hal::dataflow::Grouping::get_successor_groups_of_group(), and hal::dataflow::pre_processing::identify_register_stages().

◆ nl

const Netlist* hal::dataflow::NetlistAbstraction::nl

The netlist associated with the netlist abstraction.

Definition at line 67 of file netlist_abstraction.h.

Referenced by hal::dataflow::Grouping::are_groups_allowed_to_merge().

◆ target_gates

std::vector<Gate*> hal::dataflow::NetlistAbstraction::target_gates

The target gates that should be grouped by dataflow analysis.

Definition at line 75 of file netlist_abstraction.h.

Referenced by hal::dataflow::Grouping::Grouping(), and hal::dataflow::pre_processing::identify_register_stages().

◆ yosys

bool hal::dataflow::NetlistAbstraction::yosys

Set true if the netlist was synthesized with Yosys, false otherwise.

Definition at line 70 of file netlist_abstraction.h.


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