56 printf(
"Warning: only combinational portion is being written.\n" );
63 pFile = fopen( pFileName,
"w" );
66 fprintf( stdout,
"Io_WriteEqn(): Cannot open the output file \"%s\".\n", pFileName );
69 fprintf( pFile,
"# Equations for \"%s\" written by ABC on %s\n", pNtk->
pName,
Extra_TimeStamp() );
73 fprintf( pFile,
"\n" );
96 fprintf( pFile,
"INORDER =" );
98 fprintf( pFile,
";\n" );
101 fprintf( pFile,
"OUTORDER =" );
103 fprintf( pFile,
";\n" );
117 fprintf( pFile,
";\n" );
153 fprintf( pFile,
" \n" );
159 LineLength += AddedLength;
193 fprintf( pFile,
" \n" );
199 LineLength += AddedLength;
229 if ( pName[0] ==
'0' || pName[0] ==
'1' )
234 for ( k = 0; k < Length; k++ )
235 if ( pName[k] ==
'(' || pName[k] ==
')' || pName[k] ==
'!' || pName[k] ==
'*' || pName[k] ==
'+' )
245 printf(
"The network cannot be written in the EQN format because object %d has name \"%s\".\n", i, pName );
246 printf(
"Consider renaming the objects using command \"short_names\" and trying again.\n" );
static Vec_Vec_t * Vec_VecAlloc(int nCap)
FUNCTION DEFINITIONS ///.
static int Abc_NtkObjNumMax(Abc_Ntk_t *pNtk)
typedefABC_NAMESPACE_HEADER_START struct Vec_Vec_t_ Vec_Vec_t
INCLUDES ///.
static ABC_NAMESPACE_IMPL_START void Io_NtkWriteEqnOne(FILE *pFile, Abc_Ntk_t *pNtk)
DECLARATIONS ///.
static void Io_NtkWriteEqnCos(FILE *pFile, Abc_Ntk_t *pNtk)
static int Abc_NtkLatchNum(Abc_Ntk_t *pNtk)
#define Abc_NtkForEachCo(pNtk, pCo, i)
static void Vec_VecFree(Vec_Vec_t *p)
void Io_WriteEqn(Abc_Ntk_t *pNtk, char *pFileName)
FUNCTION DEFINITIONS ///.
static Abc_Obj_t * Abc_ObjFanin0(Abc_Obj_t *pObj)
static void Io_NtkWriteEqnCis(FILE *pFile, Abc_Ntk_t *pNtk)
#define IO_WRITE_LINE_LENGTH
MACRO DEFINITIONS ///.
static int Abc_NtkIsAigNetlist(Abc_Ntk_t *pNtk)
#define ABC_NAMESPACE_IMPL_END
char * Nm_ManFindNameById(Nm_Man_t *p, int ObjId)
#define Abc_NtkForEachNode(pNtk, pNode, i)
#define ABC_NAMESPACE_IMPL_START
#define Abc_NtkForEachCi(pNtk, pCi, i)
#define Abc_ObjForEachFanin(pObj, pFanin, i)
ABC_DLL char * Abc_ObjName(Abc_Obj_t *pNode)
DECLARATIONS ///.
#define Abc_NtkForEachObj(pNtk, pObj, i)
ITERATORS ///.
typedefABC_NAMESPACE_HEADER_START struct Hop_Man_t_ Hop_Man_t
INCLUDES ///.
Hop_Obj_t * Hop_IthVar(Hop_Man_t *p, int i)
FUNCTION DEFINITIONS ///.
static Abc_Obj_t * Abc_ObjFanout0(Abc_Obj_t *pObj)
void Hop_ObjPrintEqn(FILE *pFile, Hop_Obj_t *pObj, Vec_Vec_t *vLevels, int Level)
static int Io_NtkWriteEqnCheck(Abc_Ntk_t *pNtk)