ProvSQL C/C++ API
Adding support for provenance and uncertainty management to PostgreSQL databases
Loading...
Searching...
No Matches
GateInformation Struct Reference

Per-gate metadata stored in the gates MMappedVector. More...

#include "MMappedCircuit.h"

Public Member Functions

 GateInformation (gate_type t, unsigned n, unsigned long i)
 Construct a GateInformation with mandatory fields.
 

Public Attributes

gate_type type
 Kind of gate (input, plus, times, …)
 
unsigned nb_children
 Number of children.
 
unsigned long children_idx
 Start index of this gate's children in wires.
 
double prob
 Associated probability (default 1.0)
 
unsigned info1
 General-purpose integer annotation 1.
 
unsigned info2
 General-purpose integer annotation 2.
 
unsigned long extra_idx
 Start index in extra for string data.
 
unsigned extra_len
 Byte length of the string data in extra.
 

Detailed Description

Per-gate metadata stored in the gates MMappedVector.

Each gate in the persistent circuit has exactly one GateInformation record. The children_idx and nb_children fields together index into the wires MMappedVector to find the gate's children. Similarly, extra_idx and extra_len index into the extra vector for variable-length string annotations.

Definition at line 44 of file MMappedCircuit.h.

Constructor & Destructor Documentation

◆ GateInformation()

GateInformation::GateInformation ( gate_type  t,
unsigned  n,
unsigned long  i 
)
inline

Construct a GateInformation with mandatory fields.

Parameters
tGate type.
nNumber of children.
iStart index of children in the wires vector.

Definition at line 61 of file MMappedCircuit.h.

Member Data Documentation

◆ children_idx

unsigned long GateInformation::children_idx

Start index of this gate's children in wires.

Definition at line 48 of file MMappedCircuit.h.

◆ extra_idx

unsigned long GateInformation::extra_idx

Start index in extra for string data.

Definition at line 52 of file MMappedCircuit.h.

◆ extra_len

unsigned GateInformation::extra_len

Byte length of the string data in extra.

Definition at line 53 of file MMappedCircuit.h.

◆ info1

unsigned GateInformation::info1

General-purpose integer annotation 1.

Definition at line 50 of file MMappedCircuit.h.

◆ info2

unsigned GateInformation::info2

General-purpose integer annotation 2.

Definition at line 51 of file MMappedCircuit.h.

◆ nb_children

unsigned GateInformation::nb_children

Number of children.

Definition at line 47 of file MMappedCircuit.h.

◆ prob

double GateInformation::prob

Associated probability (default 1.0)

Definition at line 49 of file MMappedCircuit.h.

◆ type

gate_type GateInformation::type

Kind of gate (input, plus, times, …)

Definition at line 46 of file MMappedCircuit.h.


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