mirror of https://github.com/YosysHQ/abc.git
Several small bug fixes.
This commit is contained in:
parent
17610c039f
commit
d688af2601
|
|
@ -328,6 +328,7 @@ Gia_Man_t * Gia_ManFxInsert( Gia_Man_t * p, Vec_Wec_t * vCubes, Vec_Str_t * vCom
|
|||
pNew = Gia_ManStart( Gia_ManObjNum(p) );
|
||||
pNew->pName = Abc_UtilStrsav( p->pName );
|
||||
pNew->pSpec = Abc_UtilStrsav( p->pSpec );
|
||||
pNew->vLevels = Vec_IntStart( 6*Gia_ManObjNum(p)/5 + 100 );
|
||||
Gia_ManHashStart( pNew );
|
||||
// create primary inputs
|
||||
vMap = Vec_IntStartFull( Vec_IntSize(vOrder) );
|
||||
|
|
|
|||
|
|
@ -1589,6 +1589,7 @@ Gia_Man_t * Jf_ManDeriveGia( Jf_Man_t * p )
|
|||
pNew = Gia_ManStart( Gia_ManObjNum(p->pGia) );
|
||||
pNew->pName = Abc_UtilStrsav( p->pGia->pName );
|
||||
pNew->pSpec = Abc_UtilStrsav( p->pGia->pSpec );
|
||||
pNew->vLevels = Vec_IntStart( 6*Gia_ManObjNum(p->pGia)/5 + 100 );
|
||||
// map primary inputs
|
||||
Vec_IntWriteEntry( vCopies, 0, 0 );
|
||||
Gia_ManForEachCi( p->pGia, pObj, i )
|
||||
|
|
|
|||
|
|
@ -50,7 +50,7 @@ void Cba_ManPrepareGates( Cba_Man_t * p )
|
|||
if ( p->pMioLib == NULL )
|
||||
return;
|
||||
assert( p->ppGraphs == NULL );
|
||||
p->ppGraphs = ABC_ALLOC( Dec_Graph_t *, Abc_NamObjNumMax(p->pFuncs) );
|
||||
p->ppGraphs = (Dec_Graph_t **)ABC_ALLOC( Dec_Graph_t *, Abc_NamObjNumMax(p->pFuncs) );
|
||||
p->ppGraphs[0] = NULL;
|
||||
for ( i = 1; i < Abc_NamObjNumMax(p->pFuncs); i++ )
|
||||
{
|
||||
|
|
|
|||
|
|
@ -167,13 +167,19 @@ void Cba_ManWriteBlifLines( FILE * pFile, Cba_Ntk_t * p )
|
|||
{
|
||||
if ( Type == CBA_OBJ_NODE ) // .names/assign/box2 (no formal/actual binding)
|
||||
{
|
||||
if ( Abc_NamObjNumMax(p->pDesign->pFuncs) > 1 ) // mapped
|
||||
if ( p->pDesign->pMioLib ) // mapped
|
||||
{
|
||||
char * pGateName = Abc_NamStr( p->pDesign->pFuncs, Cba_ObjFuncId(p, i) );
|
||||
Mio_Gate_t * pGate = Mio_LibraryReadGateByName( (Mio_Library_t *)p->pDesign->pMioLib, pGateName, NULL );
|
||||
fprintf( pFile, ".gate" );
|
||||
Cba_ManWriteBlifGate( pFile, p, pGate, Cba_ObjFaninVec(p, i), i );
|
||||
}
|
||||
else if ( Abc_NamObjNumMax(p->pDesign->pFuncs) > 1 ) // SOP functions
|
||||
{
|
||||
fprintf( pFile, ".names" );
|
||||
Cba_ManWriteBlifArray( pFile, p, Cba_ObjFaninVec(p, i), i );
|
||||
fprintf( pFile, "%s", Cba_ObjFuncStr(p, i) );
|
||||
}
|
||||
else
|
||||
{
|
||||
fprintf( pFile, ".names" );
|
||||
|
|
|
|||
Loading…
Reference in New Issue