Commit b6b9d284 by Alan Mishchenko

Several additional fixed in the timing manager.

parent 452ff273
...@@ -489,7 +489,7 @@ Abc_ManTime_t * Abc_ManTimeStart( Abc_Ntk_t * pNtk ) ...@@ -489,7 +489,7 @@ Abc_ManTime_t * Abc_ManTimeStart( Abc_Ntk_t * pNtk )
Abc_NtkTimeSetArrival( pNtk, Abc_ObjId(pObj), p->tArrDef.Rise, p->tArrDef.Rise ); Abc_NtkTimeSetArrival( pNtk, Abc_ObjId(pObj), p->tArrDef.Rise, p->tArrDef.Rise );
// set the default timing for COs // set the default timing for COs
Abc_NtkForEachCo( pNtk, pObj, i ) Abc_NtkForEachCo( pNtk, pObj, i )
Abc_NtkTimeSetArrival( pNtk, Abc_ObjId(pObj), p->tReqDef.Rise, p->tReqDef.Rise ); Abc_NtkTimeSetRequired( pNtk, Abc_ObjId(pObj), p->tReqDef.Rise, p->tReqDef.Rise );
return p; return p;
} }
......
...@@ -56,6 +56,10 @@ struct Io_ReadBlif_t_ ...@@ -56,6 +56,10 @@ struct Io_ReadBlif_t_
float DefInDriFall; // input drive default float DefInDriFall; // input drive default
float DefOutLoadRise;// output load default float DefOutLoadRise;// output load default
float DefOutLoadFall;// output load default float DefOutLoadFall;// output load default
int fHaveDefInArr; // provided in the file
int fHaveDefOutReq; // provided in the file
int fHaveDefInDri; // provided in the file
int fHaveDefOutLoad;// provided in the file
// the error message // the error message
FILE * Output; // the output stream FILE * Output; // the output stream
char sError[1000]; // the error string generated during parsing char sError[1000]; // the error string generated during parsing
...@@ -969,6 +973,7 @@ int Io_ReadBlifNetworkDefaultInputArrival( Io_ReadBlif_t * p, Vec_Ptr_t * vToken ...@@ -969,6 +973,7 @@ int Io_ReadBlifNetworkDefaultInputArrival( Io_ReadBlif_t * p, Vec_Ptr_t * vToken
//Abc_NtkTimeSetDefaultArrival( p->pNtkCur, (float)TimeRise, (float)TimeFall ); //Abc_NtkTimeSetDefaultArrival( p->pNtkCur, (float)TimeRise, (float)TimeFall );
p->DefInArrRise = (float)TimeRise; p->DefInArrRise = (float)TimeRise;
p->DefInArrFall = (float)TimeFall; p->DefInArrFall = (float)TimeFall;
p->fHaveDefInArr = 1;
return 0; return 0;
} }
...@@ -1010,6 +1015,7 @@ int Io_ReadBlifNetworkDefaultOutputRequired( Io_ReadBlif_t * p, Vec_Ptr_t * vTok ...@@ -1010,6 +1015,7 @@ int Io_ReadBlifNetworkDefaultOutputRequired( Io_ReadBlif_t * p, Vec_Ptr_t * vTok
// Abc_NtkTimeSetDefaultRequired( p->pNtkCur, (float)TimeRise, (float)TimeFall ); // Abc_NtkTimeSetDefaultRequired( p->pNtkCur, (float)TimeRise, (float)TimeFall );
p->DefOutReqRise = (float)TimeRise; p->DefOutReqRise = (float)TimeRise;
p->DefOutReqFall = (float)TimeFall; p->DefOutReqFall = (float)TimeFall;
p->fHaveDefOutReq = 1;
return 0; return 0;
} }
...@@ -1172,6 +1178,7 @@ int Io_ReadBlifNetworkDefaultInputDrive( Io_ReadBlif_t * p, Vec_Ptr_t * vTokens ...@@ -1172,6 +1178,7 @@ int Io_ReadBlifNetworkDefaultInputDrive( Io_ReadBlif_t * p, Vec_Ptr_t * vTokens
// Abc_NtkTimeSetDefaultInputDrive( p->pNtkCur, (float)TimeRise, (float)TimeFall ); // Abc_NtkTimeSetDefaultInputDrive( p->pNtkCur, (float)TimeRise, (float)TimeFall );
p->DefInDriRise = (float)TimeRise; p->DefInDriRise = (float)TimeRise;
p->DefInDriFall = (float)TimeFall; p->DefInDriFall = (float)TimeFall;
p->fHaveDefInDri = 1;
return 0; return 0;
} }
...@@ -1213,6 +1220,7 @@ int Io_ReadBlifNetworkDefaultOutputLoad( Io_ReadBlif_t * p, Vec_Ptr_t * vTokens ...@@ -1213,6 +1220,7 @@ int Io_ReadBlifNetworkDefaultOutputLoad( Io_ReadBlif_t * p, Vec_Ptr_t * vTokens
// Abc_NtkTimeSetDefaultOutputLoad( p->pNtkCur, (float)TimeRise, (float)TimeFall ); // Abc_NtkTimeSetDefaultOutputLoad( p->pNtkCur, (float)TimeRise, (float)TimeFall );
p->DefOutLoadRise = (float)TimeRise; p->DefOutLoadRise = (float)TimeRise;
p->DefOutLoadFall = (float)TimeFall; p->DefOutLoadFall = (float)TimeFall;
p->fHaveDefOutLoad = 1;
return 0; return 0;
} }
...@@ -1608,21 +1616,25 @@ int Io_ReadBlifCreateTiming( Io_ReadBlif_t * p, Abc_Ntk_t * pNtk ) ...@@ -1608,21 +1616,25 @@ int Io_ReadBlifCreateTiming( Io_ReadBlif_t * p, Abc_Ntk_t * pNtk )
//Abc_NtkTimeSetDefaultArrival( p->pNtkCur, (float)TimeRise, (float)TimeFall ); //Abc_NtkTimeSetDefaultArrival( p->pNtkCur, (float)TimeRise, (float)TimeFall );
// p->DefInArrRise = (float)TimeRise; // p->DefInArrRise = (float)TimeRise;
// p->DefInArrFall = (float)TimeFall; // p->DefInArrFall = (float)TimeFall;
if ( p->fHaveDefInArr )
Abc_NtkTimeSetDefaultArrival( pNtk, p->DefInArrRise, p->DefInArrFall ); Abc_NtkTimeSetDefaultArrival( pNtk, p->DefInArrRise, p->DefInArrFall );
// set timing info // set timing info
//Abc_NtkTimeSetDefaultRequired( p->pNtkCur, (float)TimeRise, (float)TimeFall ); //Abc_NtkTimeSetDefaultRequired( p->pNtkCur, (float)TimeRise, (float)TimeFall );
// p->DefOutReqRise = (float)TimeRise; // p->DefOutReqRise = (float)TimeRise;
// p->DefOutReqFall = (float)TimeFall; // p->DefOutReqFall = (float)TimeFall;
if ( p->fHaveDefOutReq )
Abc_NtkTimeSetDefaultRequired( pNtk, p->DefOutReqRise, p->DefOutReqFall ); Abc_NtkTimeSetDefaultRequired( pNtk, p->DefOutReqRise, p->DefOutReqFall );
// set timing info // set timing info
//Abc_NtkTimeSetDefaultInputDrive( p->pNtkCur, (float)TimeRise, (float)TimeFall ); //Abc_NtkTimeSetDefaultInputDrive( p->pNtkCur, (float)TimeRise, (float)TimeFall );
// p->DefInDriRise = (float)TimeRise; // p->DefInDriRise = (float)TimeRise;
// p->DefInDriFall = (float)TimeFall; // p->DefInDriFall = (float)TimeFall;
if ( p->fHaveDefInDri )
Abc_NtkTimeSetDefaultInputDrive( pNtk, p->DefInDriRise, p->DefInDriFall ); Abc_NtkTimeSetDefaultInputDrive( pNtk, p->DefInDriRise, p->DefInDriFall );
// set timing info // set timing info
//Abc_NtkTimeSetDefaultOutputLoad( p->pNtkCur, (float)TimeRise, (float)TimeFall ); //Abc_NtkTimeSetDefaultOutputLoad( p->pNtkCur, (float)TimeRise, (float)TimeFall );
// p->DefOutLoadRise = (float)TimeRise; // p->DefOutLoadRise = (float)TimeRise;
// p->DefOutLoadFall = (float)TimeFall; // p->DefOutLoadFall = (float)TimeFall;
if ( p->fHaveDefOutLoad )
Abc_NtkTimeSetDefaultOutputLoad( pNtk, p->DefOutLoadRise, p->DefOutLoadFall ); Abc_NtkTimeSetDefaultOutputLoad( pNtk, p->DefOutLoadRise, p->DefOutLoadFall );
// set timing info // set timing info
......
...@@ -684,10 +684,10 @@ void Io_WriteTimingInfo( FILE * pFile, Abc_Ntk_t * pNtk ) ...@@ -684,10 +684,10 @@ void Io_WriteTimingInfo( FILE * pFile, Abc_Ntk_t * pNtk )
if ( pNtk->AndGateDelay != 0.0 ) if ( pNtk->AndGateDelay != 0.0 )
fprintf( pFile, ".and_gate_delay %g\n", pNtk->AndGateDelay ); fprintf( pFile, ".and_gate_delay %g\n", pNtk->AndGateDelay );
pTimeDefIn = Abc_NtkReadDefaultArrival( pNtk ); pTimeDefIn = Abc_NtkReadDefaultArrival( pNtk );
if ( pTimeDefIn->Rise != 0.0 || pTimeDefIn->Fall != 0.0 ) //if ( pTimeDefIn->Rise != 0.0 || pTimeDefIn->Fall != 0.0 )
fprintf( pFile, ".default_input_arrival %g %g\n", pTimeDefIn->Rise, pTimeDefIn->Fall ); fprintf( pFile, ".default_input_arrival %g %g\n", pTimeDefIn->Rise, pTimeDefIn->Fall );
pTimeDefOut = Abc_NtkReadDefaultRequired( pNtk ); pTimeDefOut = Abc_NtkReadDefaultRequired( pNtk );
if ( pTimeDefOut->Rise != ABC_INFINITY || pTimeDefOut->Fall != ABC_INFINITY ) //if ( pTimeDefOut->Rise != ABC_INFINITY || pTimeDefOut->Fall != ABC_INFINITY )
fprintf( pFile, ".default_output_required %g %g\n", pTimeDefOut->Rise, pTimeDefOut->Fall ); fprintf( pFile, ".default_output_required %g %g\n", pTimeDefOut->Rise, pTimeDefOut->Fall );
fprintf( pFile, "\n" ); fprintf( pFile, "\n" );
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment