diff options
author | Alan Mishchenko <alanmi@berkeley.edu> | 2014-10-03 17:15:43 -0700 |
---|---|---|
committer | Alan Mishchenko <alanmi@berkeley.edu> | 2014-10-03 17:15:43 -0700 |
commit | fa5f05e3a2e0e866184d5597f442a3362ff2ab76 (patch) | |
tree | 5d992dbb3e452bcfaa1ab9217df3eabb5ad480e1 /src/base | |
parent | 3f31a8580f38b676b4fa8607d0e3863cc160cd48 (diff) | |
download | abc-fa5f05e3a2e0e866184d5597f442a3362ff2ab76.tar.gz abc-fa5f05e3a2e0e866184d5597f442a3362ff2ab76.tar.bz2 abc-fa5f05e3a2e0e866184d5597f442a3362ff2ab76.zip |
Deriving AIG after cell mapping.
Diffstat (limited to 'src/base')
-rw-r--r-- | src/base/cmd/cmd.c | 29 | ||||
-rw-r--r-- | src/base/io/ioReadBlifMv.c | 2 |
2 files changed, 29 insertions, 2 deletions
diff --git a/src/base/cmd/cmd.c b/src/base/cmd/cmd.c index 511cee68..42274433 100644 --- a/src/base/cmd/cmd.c +++ b/src/base/cmd/cmd.c @@ -1319,6 +1319,32 @@ int CmfFindNumber( char * pName ) /**Function************************************************************* + Synopsis [] + + Description [] + + SideEffects [] + + SeeAlso [] + +***********************************************************************/ +void CnfDupFileUnzip( char * pOldName ) +{ + extern char * Io_MvLoadFileBz2( char * pFileName, int * pnFileSize ); + char pNewName[1000]; + FILE * pFile; + int nFileSize; + char * pBuffer = Io_MvLoadFileBz2( pOldName, &nFileSize ); + assert( strlen(pOldName) < 1000 ); + sprintf( pNewName, "%s.v", pOldName ); + pFile = fopen( pNewName, "wb" ); + fwrite( pBuffer, nFileSize, 1, pFile ); + fclose( pFile ); + ABC_FREE( pBuffer ); +} + +/**Function************************************************************* + Synopsis [Command to print the contents of the current directory (Windows).] Description [] @@ -1446,8 +1472,9 @@ int CmdCommandRenameFiles( Abc_Frame_t * pAbc, int argc, char **argv ) { pOldName = (char *)Vec_PtrEntry( vNames, pOrder[i] ); sprintf( pNewName, "%s%0*d.%s", pNameNew ? pNameNew : "", nDigits, nBase+Vec_IntEntry(vNums, pOrder[i]), pNameExt ); - printf( "%s -> %s\n", pOldName, pNewName ); rename( pOldName, pNewName ); + printf( "%s -> %s\n", pOldName, pNewName ); +// CnfDupFileUnzip( pOldName ); } // cleanup Vec_PtrFreeFree( vNames ); diff --git a/src/base/io/ioReadBlifMv.c b/src/base/io/ioReadBlifMv.c index bd7aa78a..d78f567a 100644 --- a/src/base/io/ioReadBlifMv.c +++ b/src/base/io/ioReadBlifMv.c @@ -548,7 +548,7 @@ typedef struct buflist { struct buflist * next; } buflist; -static char * Io_MvLoadFileBz2( char * pFileName, int * pnFileSize ) +char * Io_MvLoadFileBz2( char * pFileName, int * pnFileSize ) { FILE * pFile; int nFileSize = 0; |