From 6ab0d68d5653b5411c298116c9502a23a50cdbf0 Mon Sep 17 00:00:00 2001 From: Alan Mishchenko Date: Fri, 4 Apr 2014 16:38:46 -0700 Subject: Tuning LUT mapping to work while saving the best network. --- src/base/abci/abcPrint.c | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) (limited to 'src/base/abci/abcPrint.c') diff --git a/src/base/abci/abcPrint.c b/src/base/abci/abcPrint.c index 4493a5a2..b13018fc 100644 --- a/src/base/abci/abcPrint.c +++ b/src/base/abci/abcPrint.c @@ -101,7 +101,10 @@ int Abc_NtkCompareAndSaveBest( Abc_Ntk_t * pNtk ) ParsBest.nPis = ParsNew.nPis; ParsBest.nPos = ParsNew.nPos; // writ the network - pFileNameOut = Extra_FileNameGenericAppend( pNtk->pSpec, "_best.blif" ); + if ( strcmp(pNtk->pSpec + strlen(pNtk->pSpec) - strlen("_best.blif"), "_best.blif") ) + pFileNameOut = Extra_FileNameGenericAppend( pNtk->pSpec, "_best.blif" ); + else + pFileNameOut = pNtk->pSpec; Io_Write( pNtk, pFileNameOut, IO_FILE_BLIF ); return 1; } -- cgit v1.2.3