ABC: A System for Sequential Synthesis and Verification
 
Loading...
Searching...
No Matches
mfsWin.c File Reference
#include "mfsInt.h"
Include dependency graph for mfsWin.c:

Go to the source code of this file.

Functions

void Abc_MfsComputeRoots_rec (Abc_Obj_t *pNode, int nLevelMax, int nFanoutLimit, Vec_Ptr_t *vRoots)
 
Vec_Ptr_tAbc_MfsComputeRoots (Abc_Obj_t *pNode, int nWinTfoMax, int nFanoutLimit)
 

Function Documentation

◆ Abc_MfsComputeRoots()

Vec_Ptr_t * Abc_MfsComputeRoots ( Abc_Obj_t * pNode,
int nWinTfoMax,
int nFanoutLimit )

Function*************************************************************

Synopsis [Recursively collects the root candidates.]

Description [Returns 1 if the only root is this node.]

SideEffects []

SeeAlso []

Definition at line 99 of file mfsWin.c.

100{
101 Vec_Ptr_t * vRoots;
102 vRoots = Vec_PtrAlloc( 10 );
103 Abc_NtkIncrementTravId( pNode->pNtk );
104 Abc_MfsComputeRoots_rec( pNode, pNode->Level + nWinTfoMax, nFanoutLimit, vRoots );
105 assert( Vec_PtrSize(vRoots) > 0 );
106// if ( Vec_PtrSize(vRoots) == 1 && Vec_PtrEntry(vRoots, 0) == pNode )
107// return 0;
108 return vRoots;
109}
void Abc_MfsComputeRoots_rec(Abc_Obj_t *pNode, int nLevelMax, int nFanoutLimit, Vec_Ptr_t *vRoots)
Definition mfsWin.c:72
Abc_Ntk_t * pNtk
Definition abc.h:130
unsigned Level
Definition abc.h:142
#define assert(ex)
Definition util_old.h:213
typedefABC_NAMESPACE_HEADER_START struct Vec_Ptr_t_ Vec_Ptr_t
INCLUDES ///.
Definition vecPtr.h:42
Here is the call graph for this function:
Here is the caller graph for this function:

◆ Abc_MfsComputeRoots_rec()

void Abc_MfsComputeRoots_rec ( Abc_Obj_t * pNode,
int nLevelMax,
int nFanoutLimit,
Vec_Ptr_t * vRoots )

Function*************************************************************

Synopsis [Recursively collects the root candidates.]

Description []

SideEffects []

SeeAlso []

Definition at line 72 of file mfsWin.c.

73{
74 Abc_Obj_t * pFanout;
75 int i;
76 assert( Abc_ObjIsNode(pNode) );
77 if ( Abc_NodeIsTravIdCurrent(pNode) )
78 return;
79 Abc_NodeSetTravIdCurrent( pNode );
80 // check if the node should be the root
81 if ( Abc_MfsComputeRootsCheck( pNode, nLevelMax, nFanoutLimit ) )
82 Vec_PtrPush( vRoots, pNode );
83 else // if not, explore its fanouts
84 Abc_ObjForEachFanout( pNode, pFanout, i )
85 Abc_MfsComputeRoots_rec( pFanout, nLevelMax, nFanoutLimit, vRoots );
86}
struct Abc_Obj_t_ Abc_Obj_t
Definition abc.h:116
#define Abc_ObjForEachFanout(pObj, pFanout, i)
Definition abc.h:529
Here is the call graph for this function:
Here is the caller graph for this function: