#include "mioInt.h"
#include "exp.h"
Go to the source code of this file.
#define MIO_SYMB_AFTNOT '\'' |
DECLARATIONS ///.
CFile****************************************************************
FileName [mioFunc.c]
PackageName [MVSIS 1.3: Multi-valued logic synthesis system.]
Synopsis [File reading/writing for technology mapping.]
Author [MVSIS Group]
Affiliation [UC Berkeley]
Date [Ver. 1.0. Started - September 8, 2003.]
Revision [
- Id:
- mioFunc.c,v 1.4 2004/06/28 14:20:25 alanmi Exp
]
Definition at line 31 of file mioFunc.c.
#define MIO_SYMB_AND2 '&' |
#define MIO_SYMB_CLOSE ')' |
#define MIO_SYMB_OPEN '(' |
int Mio_GateCollectNames |
( |
char * |
pFormula, |
|
|
char * |
pPinNames[] |
|
) |
| |
Function*************************************************************
Synopsis [Collect the pin names in the formula.]
Description []
SideEffects []
SeeAlso []
Definition at line 76 of file mioFunc.c.
83 strcpy( Buffer, pFormula );
86 for ( pTemp = Buffer; *pTemp; pTemp++ )
96 pTemp =
strtok( Buffer,
" " );
99 for ( i = 0; i < nPins; i++ )
100 if (
strcmp( pTemp, pPinNames[i] ) == 0 )
107 pTemp =
strtok( NULL,
" " );
#define MIO_SYMB_AND
DECLARATIONS ///.
char * Abc_UtilStrsav(char *s)
Function*************************************************************
Synopsis [Deriving the functionality of the gates.]
Description []
SideEffects []
SeeAlso []
Definition at line 123 of file mioFunc.c.
125 char * pPinNames[100];
126 char * pPinNamesCopy[100];
163 printf(
"Cannot parse formula \"%s\" of gate \"%s\".\n", pGate->
pForm, pGate->
pName );
174 printf(
"Cannot read formula \"%s\" of gate \"%s\".\n", pGate->
pForm, pGate->
pName );
189 ppPin = &pPin->
pNext;
190 for ( i = 1; i < nPins; i++ )
195 (*ppPin)->pName = pPinNames[i];
197 ppPin = &((*ppPin)->pNext);
202 pPin->
pName = pPinNames[0];
211 for ( i = 0; i < nPins; i++ )
213 if ( pPinNames[i] &&
strcmp( pPinNames[i], pPin->
pName ) == 0 )
219 pPinNamesCopy[iPin++] = pPin->
pName;
224 printf(
"Cannot find pin name \"%s\" in the formula \"%s\" of gate \"%s\".\n",
232 for ( i = 0; i < nPins; i++ )
235 printf(
"Name \"%s\" appears in the formula \"%s\" of gate \"%s\" but there is no such pin.\n",
241 memcpy( pPinNames, pPinNamesCopy, nPins *
sizeof(
char *) );
Vec_Int_t * Mio_ParseFormula(char *pFormInit, char **ppVarNames, int nVars)
char * Mio_LibDeriveSop(int nVars, Vec_Int_t *vExpr, Vec_Str_t *vStr)
#define Mio_GateForEachPin(Gate, Pin)
static word Exp_Truth6(int nVars, Vec_Int_t *p, word *puFanins)
static Vec_Int_t * Exp_Const0()
unsigned __int64 word
DECLARATIONS ///.
Mio_Pin_t * Mio_PinDup(Mio_Pin_t *pPin)
char * Mio_SopRegister(Mem_Flex_t *pMan, char *pName)
FUNCTION DEFINITIONS ///.
#define MIO_STRING_CONST1
#define MIO_STRING_CONST0
static Vec_Int_t * Exp_Const1()
int Mio_GateCollectNames(char *pFormula, char *pPinNames[])
FUNCTION DEFINITIONS ///.
Function*************************************************************
Synopsis [Deriving the functionality of the gates.]
Description []
SideEffects []
SeeAlso []
Definition at line 298 of file mioFunc.c.
int Mio_GateParseFormula(Mio_Gate_t *pGate)
#define Mio_LibraryForEachGate(Lib, Gate)
GLOBAL VARIABLES ///.
char* Mio_SopRegister |
( |
Mem_Flex_t * |
pMan, |
|
|
char * |
pName |
|
) |
| |
FUNCTION DEFINITIONS ///.
Function*************************************************************
Synopsis [Registers the cube string with the network.]
Description []
SideEffects []
SeeAlso []
Definition at line 56 of file mioFunc.c.
59 if ( pName == NULL )
return NULL;
char * Mem_FlexEntryFetch(Mem_Flex_t *p, int nBytes)