abc-master
|
#include "extraBdd.h"
Go to the source code of this file.
Data Structures | |
struct | _HashEntry_cof |
struct | _HashEntry_mint |
struct | traventry |
Macros | |
#define | _TABLESIZE_COF 51113 |
#define | _TABLESIZE_MINT 15113 |
Functions | |
static DdNode * | CreateTheCodes_rec (DdManager *dd, DdNode *bEncoded, int Level, DdNode **pCVars) |
static void | EvaluateEncodings_rec (DdManager *dd, DdNode *bVarsCol, int nVarsCol, int nMulti, int Level) |
static DdNode * | ComputeVarSetAndCountMinterms (DdManager *dd, DdNode *bVars, DdNode *bVarTop, unsigned *Cost) |
static DdNode * | ComputeVarSetAndCountMinterms2 (DdManager *dd, DdNode *bVars, DdNode *bVarTop, unsigned *Cost) |
unsigned | Extra_CountCofactorMinterms (DdManager *dd, DdNode *bFunc, DdNode *bVarsCof, DdNode *bVarsAll) |
static unsigned | Extra_CountMintermsSimple (DdNode *bFunc, unsigned max) |
static void | CountNodeVisits_rec (DdManager *dd, DdNode *aFunc, st__table *Visited) |
static void | CollectNodesAndComputePaths_rec (DdManager *dd, DdNode *aFunc, DdNode *bCube, st__table *Visited, st__table *CutNodes) |
DdNode * | Extra_bddEncodingBinary (DdManager *dd, DdNode **pbFuncs, int nFuncs, DdNode **pbVars, int nVars) |
DdNode * | Extra_bddEncodingNonStrict (DdManager *dd, DdNode **pbColumns, int nColumns, DdNode *bVarsCol, DdNode **pCVars, int nMulti, int *pSimple) |
st__table * | Extra_bddNodePathsUnderCut (DdManager *dd, DdNode *bFunc, int CutLevel) |
int | Extra_bddNodePathsUnderCutArray (DdManager *dd, DdNode **paNodes, DdNode **pbCubes, int nNodes, DdNode **paNodesRes, DdNode **pbCubesRes, int CutLevel) |
void | extraCollectNodes (DdNode *Func, st__table *tNodes) |
st__table * | Extra_CollectNodes (DdNode *Func) |
void | extraProfileUpdateTopLevel (st__table *tNodeTopRef, int TopLevelNew, DdNode *node) |
int | Extra_ProfileWidth (DdManager *dd, DdNode *Func, int *pProfile, int CutLevel) |
Variables | |
_HashEntry_cof | HHTable1 [_TABLESIZE_COF] |
_HashEntry_mint | HHTable2 [_TABLESIZE_MINT] |
static unsigned | s_Signature = 1 |
static int | s_CutLevel = 0 |
static int | s_MaxDepth = 5 |
static int | s_nVarsBest |
static int | s_VarOrderBest [32] |
static int | s_VarOrderCur [32] |
static DdNode * | s_Field [8][256] |
static DdNode * | s_Encoded |
static DdNode * | s_VarAll |
static int | s_MultiStart |
static DdNode ** | s_pbTemp |
static int | s_BackTracks |
static int | s_BackTrackLimit = 100 |
static DdNode * | s_Terminal |
static int | s_EncodingVarsLevel |
#define _TABLESIZE_COF 51113 |
CFile****************************************************************
FileName [extraBddCas.c]
PackageName [extra]
Synopsis [Procedures related to LUT cascade synthesis.]
Author [Alan Mishchenko]
Affiliation [UC Berkeley]
Date [Ver. 2.0. Started - September 1, 2003.]
Revision [
]
Definition at line 37 of file extraBddCas.c.
#define _TABLESIZE_MINT 15113 |
Definition at line 46 of file extraBddCas.c.
|
static |
Function********************************************************************
Synopsis [Revisits the nodes and computes the paths.]
Description [This function visits the nodes above the cut having the goal of summing all the incomming BDD edges; when this function comes across the node below the cut, it saves this node in the CutNode table.]
SideEffects []
SeeAlso []
Definition at line 1159 of file extraBddCas.c.
|
static |
Function********************************************************************
Synopsis [Computes the current set of variables and counts the number of minterms.]
Description []
SideEffects []
SeeAlso []
Definition at line 852 of file extraBddCas.c.
|
static |
Function********************************************************************
Synopsis [Computes the current set of variables and counts the number of minterms.]
Description [The old implementation, which is approximately 4 times slower.]
SideEffects []
SeeAlso []
Definition at line 882 of file extraBddCas.c.
Function********************************************************************
Synopsis [Visits the nodes.]
Description [Visits the nodes above the cut and the nodes pointed to below the cut; collects the visited nodes, counts how many times each node is visited, and sets the path-sum to be the constant zero BDD.]
SideEffects []
SeeAlso []
Definition at line 1113 of file extraBddCas.c.
|
static |
AutomaticStart
Function********************************************************************
Synopsis [Computes the non-strict codes when evaluation is finished.]
Description [The information about the best code is stored in s_VarOrderBest, which has s_nVarsBest entries.]
SideEffects [None]
Definition at line 599 of file extraBddCas.c.
|
static |
Function********************************************************************
Synopsis [Computes the current set of variables and counts the number of minterms.]
Description [Old implementation.]
SideEffects []
SeeAlso []
Definition at line 730 of file extraBddCas.c.
DdNode* Extra_bddEncodingBinary | ( | DdManager * | dd, |
DdNode ** | pbFuncs, | ||
int | nFuncs, | ||
DdNode ** | pbVars, | ||
int | nVars | ||
) |
AutomaticEnd Function********************************************************************
Synopsis [Performs the binary encoding of the set of function using the given vars.]
Description [Performs a straight binary encoding of the set of functions using the variable cubes formed from the given set of variables. ]
SideEffects []
SeeAlso []
Definition at line 138 of file extraBddCas.c.
DdNode* Extra_bddEncodingNonStrict | ( | DdManager * | dd, |
DdNode ** | pbColumns, | ||
int | nColumns, | ||
DdNode * | bVarsCol, | ||
DdNode ** | pCVars, | ||
int | nMulti, | ||
int * | pSimple | ||
) |
Function********************************************************************
Synopsis [Solves the column encoding problem using a sophisticated method.]
Description [The encoding is based on the idea of deriving functions which depend on only one variable, which corresponds to the case of non-disjoint decompostion. It is assumed that the variables pCVars are ordered below the variables representing the solumns, and the first variable pCVars[0] is the topmost one.]
SideEffects []
SeeAlso [Extra_bddEncodingBinary]
Definition at line 184 of file extraBddCas.c.
Function********************************************************************
Synopsis [Collects the nodes under the cut and, for each node, computes the sum of paths leading to it from the root.]
Description [The table returned contains the set of BDD nodes pointed to under the cut and, for each node, the BDD of the sum of paths leading to this node from the root The sums of paths in the table are referenced. CutLevel is the first DD level considered to be under the cut.]
SideEffects []
SeeAlso [Extra_bddNodePaths]
Definition at line 263 of file extraBddCas.c.
int Extra_bddNodePathsUnderCutArray | ( | DdManager * | dd, |
DdNode ** | paNodes, | ||
DdNode ** | pbCubes, | ||
int | nNodes, | ||
DdNode ** | paNodesRes, | ||
DdNode ** | pbCubesRes, | ||
int | CutLevel | ||
) |
Function********************************************************************
Synopsis [Collects the nodes under the cut in the ADD starting from the given set of ADD nodes.]
Description [Takes the array, paNodes, of ADD nodes to start the traversal, the array, pbCubes, of BDD cubes to start the traversal with in each node, and the number, nNodes, of ADD nodes and BDD cubes in paNodes and pbCubes. Returns the number of columns found. Fills in paNodesRes (pbCubesRes) with the set of ADD columns (BDD paths). These arrays should be allocated by the user.]
SideEffects []
SeeAlso [Extra_bddNodePaths]
Definition at line 355 of file extraBddCas.c.
Function*************************************************************
Synopsis [Collects all the nodes of one DD into the table.]
Description []
SideEffects []
SeeAlso []
Definition at line 458 of file extraBddCas.c.
unsigned Extra_CountCofactorMinterms | ( | DdManager * | dd, |
DdNode * | bFunc, | ||
DdNode * | bVarsCof, | ||
DdNode * | bVarsAll | ||
) |
Function********************************************************************
Synopsis [Counts the number of encoding minterms pointed to by the cofactor of the function.]
Description []
SideEffects [None]
Definition at line 910 of file extraBddCas.c.
|
static |
Function********************************************************************
Synopsis [Counts the number of minterms.]
Description [This function counts minterms for functions up to 32 variables using a local cache. The terminal value (s_Termina) should be adjusted for BDDs and ADDs.]
SideEffects [None]
Definition at line 1069 of file extraBddCas.c.
Function*************************************************************
Synopsis [Fast computation of the BDD profile.]
Description [The array to store the profile is given by the user and should contain at least as many entries as there is the maximum of the BDD/ZDD size of the manager PLUS ONE. When we say that the widths of the DD on level L is W, we mean the following. Let us create the cut between the level L-1 and the level L and count the number of different DD nodes pointed to across the cut. This number is the width W. From this it follows the on level 0, the width is equal to the number of external pointers to the considered DDs. If there is only one DD, then the profile on level 0 is always 1. If this DD is rooted in the topmost variable, then the width on level 1 is always 2, etc. The width at the level equal to dd->size is the number of terminal nodes in the DD. (Because we consider the first level #0 and the last level #dd->size, the profile array should contain dd->size+1 entries.) ]
SideEffects [This procedure will not work for BDDs w/ complement edges, only for ADDs and ZDDs]
SeeAlso []
Definition at line 519 of file extraBddCas.c.
Function*************************************************************
Synopsis [Collects all the BDD nodes into the table.]
Description []
SideEffects []
SeeAlso []
Definition at line 435 of file extraBddCas.c.
Function*************************************************************
Synopsis [Updates the topmost level from which the given node is referenced.]
Description [Takes the table which maps each BDD nodes (including the constants) into the topmost level on which this node counts as a cofactor. Takes the topmost level, on which this node counts as a cofactor (see Extra_ProfileWidthFast(). Takes the node, for which the table entry should be updated.]
SideEffects []
SeeAlso []
Definition at line 480 of file extraBddCas.c.
_HashEntry_cof HHTable1[_TABLESIZE_COF] |
Definition at line 43 of file extraBddCas.c.
_HashEntry_mint HHTable2[_TABLESIZE_MINT] |
Definition at line 53 of file extraBddCas.c.
|
static |
Definition at line 88 of file extraBddCas.c.
|
static |
Definition at line 87 of file extraBddCas.c.
|
static |
Definition at line 64 of file extraBddCas.c.
|
static |
Definition at line 80 of file extraBddCas.c.
|
static |
Definition at line 93 of file extraBddCas.c.
|
static |
Definition at line 79 of file extraBddCas.c.
|
static |
Definition at line 72 of file extraBddCas.c.
|
static |
Definition at line 82 of file extraBddCas.c.
|
static |
Definition at line 74 of file extraBddCas.c.
|
static |
Definition at line 85 of file extraBddCas.c.
|
static |
Definition at line 62 of file extraBddCas.c.
|
static |
Definition at line 90 of file extraBddCas.c.
|
static |
Definition at line 81 of file extraBddCas.c.
|
static |
Definition at line 75 of file extraBddCas.c.
|
static |
Definition at line 76 of file extraBddCas.c.