1 /**CFile**************************************************************** 2 3 FileName [dar.h] 4 5 SystemName [ABC: Logic synthesis and verification system.] 6 7 PackageName [DAG-aware AIG rewriting.] 8 9 Synopsis [External declarations.] 10 11 Author [Alan Mishchenko] 12 13 Affiliation [UC Berkeley] 14 15 Date [Ver. 1.0. Started - April 28, 2007.] 16 17 Revision [$Id: dar.h,v 1.00 2007/04/28 00:00:00 alanmi Exp $] 18 19 ***********************************************************************/ 20 21 #ifndef ABC__aig__dar__dar_h 22 #define ABC__aig__dar__dar_h 23 24 25 //////////////////////////////////////////////////////////////////////// 26 /// INCLUDES /// 27 //////////////////////////////////////////////////////////////////////// 28 29 //////////////////////////////////////////////////////////////////////// 30 /// PARAMETERS /// 31 //////////////////////////////////////////////////////////////////////// 32 33 34 35 ABC_NAMESPACE_HEADER_START 36 37 38 //////////////////////////////////////////////////////////////////////// 39 /// BASIC TYPES /// 40 //////////////////////////////////////////////////////////////////////// 41 42 typedef struct Dar_RwrPar_t_ Dar_RwrPar_t; 43 typedef struct Dar_RefPar_t_ Dar_RefPar_t; 44 45 struct Dar_RwrPar_t_ 46 { 47 int nCutsMax; // the maximum number of cuts to try 48 int nSubgMax; // the maximum number of subgraphs to try 49 int fFanout; // support fanout representation 50 int fUpdateLevel; // update level 51 int fUseZeros; // performs zero-cost replacement 52 int fPower; // enables power-aware rewriting 53 int fRecycle; // enables cut recycling 54 int fVerbose; // enables verbose output 55 int fVeryVerbose; // enables very verbose output 56 }; 57 58 struct Dar_RefPar_t_ 59 { 60 int nMffcMin; // the min MFFC size for which refactoring is used 61 int nLeafMax; // the max number of leaves of a cut 62 int nCutsMax; // the max number of cuts to consider 63 int fExtend; // extends the cut below MFFC 64 int fUpdateLevel; // updates the level after each move 65 int fUseZeros; // perform zero-cost replacements 66 int fVerbose; // verbosity level 67 int fVeryVerbose; // enables very verbose output 68 }; 69 70 //////////////////////////////////////////////////////////////////////// 71 /// MACRO DEFINITIONS /// 72 //////////////////////////////////////////////////////////////////////// 73 74 //////////////////////////////////////////////////////////////////////// 75 /// ITERATORS /// 76 //////////////////////////////////////////////////////////////////////// 77 78 //////////////////////////////////////////////////////////////////////// 79 /// FUNCTION DECLARATIONS /// 80 //////////////////////////////////////////////////////////////////////// 81 82 /*=== darLib.c ========================================================*/ 83 extern void Dar_LibStart(); 84 extern void Dar_LibStop(); 85 extern void Dar_LibPrepare( int nSubgraphs ); 86 extern int Dar_LibReturnClass( unsigned uTruth ); 87 /*=== darBalance.c ========================================================*/ 88 extern Aig_Man_t * Dar_ManBalance( Aig_Man_t * p, int fUpdateLevel ); 89 extern Aig_Man_t * Dar_ManBalanceXor( Aig_Man_t * pAig, int fExor, int fUpdateLevel, int fVerbose ); 90 extern void Dar_BalancePrintStats( Aig_Man_t * p ); 91 /*=== darCore.c ========================================================*/ 92 extern void Dar_ManDefaultRwrParams( Dar_RwrPar_t * pPars ); 93 extern int Dar_ManRewrite( Aig_Man_t * pAig, Dar_RwrPar_t * pPars ); 94 extern Aig_MmFixed_t * Dar_ManComputeCuts( Aig_Man_t * pAig, int nCutsMax, int fSkipTtMin, int fVerbose ); 95 /*=== darRefact.c ========================================================*/ 96 extern void Dar_ManDefaultRefParams( Dar_RefPar_t * pPars ); 97 extern int Dar_ManRefactor( Aig_Man_t * pAig, Dar_RefPar_t * pPars ); 98 /*=== darScript.c ========================================================*/ 99 extern Aig_Man_t * Dar_ManRewriteDefault( Aig_Man_t * pAig ); 100 extern Aig_Man_t * Dar_ManRwsat( Aig_Man_t * pAig, int fBalance, int fVerbose ); 101 extern Aig_Man_t * Dar_ManCompress( Aig_Man_t * pAig, int fBalance, int fUpdateLevel, int fPower, int fVerbose ); 102 extern Aig_Man_t * Dar_ManCompress2( Aig_Man_t * pAig, int fBalance, int fUpdateLevel, int fFanout, int fPower, int fVerbose ); 103 extern Aig_Man_t * Dar_ManChoice( Aig_Man_t * pAig, int fBalance, int fUpdateLevel, int fConstruct, int nConfMax, int nLevelMax, int fVerbose ); 104 105 106 107 ABC_NAMESPACE_HEADER_END 108 109 110 111 #endif 112 113 //////////////////////////////////////////////////////////////////////// 114 /// END OF FILE /// 115 //////////////////////////////////////////////////////////////////////// 116 117