summaryrefslogtreecommitdiffstats
path: root/src
diff options
context:
space:
mode:
authorAlan Mishchenko <alanmi@berkeley.edu>2018-02-28 19:38:55 -0800
committerAlan Mishchenko <alanmi@berkeley.edu>2018-02-28 19:38:55 -0800
commitf6b9cc013dda69b7ec5cb513cfa10b9f6492c0fe (patch)
treea80d35f7cbb01f4071d2933f9350678c7cf51116 /src
parent7e9f3f027b8de37480cc8dd6d3de17541a8caeba (diff)
downloadabc-f6b9cc013dda69b7ec5cb513cfa10b9f6492c0fe.tar.gz
abc-f6b9cc013dda69b7ec5cb513cfa10b9f6492c0fe.tar.bz2
abc-f6b9cc013dda69b7ec5cb513cfa10b9f6492c0fe.zip
Adding parameters and improvements to %blast.
Diffstat (limited to 'src')
-rw-r--r--src/base/main/abcapis.h1
-rw-r--r--src/base/main/main.h1
-rw-r--r--src/base/main/mainFrame.c4
-rw-r--r--src/base/main/mainInt.h1
-rw-r--r--src/base/wlc/wlcBlast.c1
-rw-r--r--src/base/wlc/wlcUif.c13
6 files changed, 20 insertions, 1 deletions
diff --git a/src/base/main/abcapis.h b/src/base/main/abcapis.h
index 4b1d7fb4..af7888e1 100644
--- a/src/base/main/abcapis.h
+++ b/src/base/main/abcapis.h
@@ -92,6 +92,7 @@ extern ABC_DLL void Abc_NtkSetAndGateDelay( Abc_Frame_t * pAbc, float Delay );
extern ABC_DLL int * Abc_NtkOutputMiniMapping( Abc_Frame_t * pAbc );
extern ABC_DLL void Abc_NtkPrintMiniMapping( int * pArray );
extern ABC_DLL int * Abc_FrameReadArrayMapping( Abc_Frame_t * pAbc );
+extern ABC_DLL int * Abc_FrameReadBoxes( Abc_Frame_t * pAbc );
// procedures to access verifization status and a counter-example
extern ABC_DLL int Abc_FrameReadProbStatus( Abc_Frame_t * pAbc );
diff --git a/src/base/main/main.h b/src/base/main/main.h
index 3887d764..d7f68be4 100644
--- a/src/base/main/main.h
+++ b/src/base/main/main.h
@@ -161,6 +161,7 @@ extern ABC_DLL void Abc_FrameSetDrivingCell( char * pName );
extern ABC_DLL void Abc_FrameSetMaxLoad( float Load );
extern ABC_DLL void Abc_FrameSetArrayMapping( int * p );
+extern ABC_DLL void Abc_FrameSetBoxes( int * p );
ABC_NAMESPACE_HEADER_END
diff --git a/src/base/main/mainFrame.c b/src/base/main/mainFrame.c
index e496d8ee..eff730d8 100644
--- a/src/base/main/mainFrame.c
+++ b/src/base/main/mainFrame.c
@@ -111,6 +111,9 @@ void Abc_FrameSetMaxLoad( float Load ) { s_GlobalFrame->Ma
int * Abc_FrameReadArrayMapping( Abc_Frame_t * pAbc ) { return pAbc->pArray; }
void Abc_FrameSetArrayMapping( int * p ) { ABC_FREE( s_GlobalFrame->pArray ); s_GlobalFrame->pArray = p; }
+int * Abc_FrameReadBoxes( Abc_Frame_t * pAbc ) { return pAbc->pBoxes; }
+void Abc_FrameSetBoxes( int * p ) { ABC_FREE( s_GlobalFrame->pBoxes ); s_GlobalFrame->pBoxes = p; }
+
/**Function*************************************************************
Synopsis [Returns 1 if the flag is enabled without value or with value 1.]
@@ -236,6 +239,7 @@ void Abc_FrameDeallocate( Abc_Frame_t * p )
Vec_IntFreeP( &p->vCopyMiniAig );
Vec_IntFreeP( &p->vCopyMiniLut );
ABC_FREE( p->pArray );
+ ABC_FREE( p->pBoxes );
ABC_FREE( p );
s_GlobalFrame = NULL;
diff --git a/src/base/main/mainInt.h b/src/base/main/mainInt.h
index 66432c78..e55e6e7f 100644
--- a/src/base/main/mainInt.h
+++ b/src/base/main/mainInt.h
@@ -149,6 +149,7 @@ struct Abc_Frame_t_
Vec_Int_t * vCopyMiniAig;
Vec_Int_t * vCopyMiniLut;
int * pArray;
+ int * pBoxes;
Abc_Frame_Callback_BmcFrameDone_Func pFuncOnFrameDone;
};
diff --git a/src/base/wlc/wlcBlast.c b/src/base/wlc/wlcBlast.c
index dcdf99bc..a81a28db 100644
--- a/src/base/wlc/wlcBlast.c
+++ b/src/base/wlc/wlcBlast.c
@@ -1082,7 +1082,6 @@ Gia_Man_t * Wlc_NtkBitBlast( Wlc_Ntk_t * p, Wlc_BstPar_t * pParIn )
If_LibBoxAdd( pBoxLib, pBox );
for ( k = 0; k < pBox->nPis * pBox->nPos; k++ )
pBox->pDelays[k] = 1;
- printf( "adding box %s\n", Buffer);
}
else if ( Wlc_ObjIsCi(pObj) )
{
diff --git a/src/base/wlc/wlcUif.c b/src/base/wlc/wlcUif.c
index 3c7a08ac..0b3eed01 100644
--- a/src/base/wlc/wlcUif.c
+++ b/src/base/wlc/wlcUif.c
@@ -41,6 +41,16 @@ ABC_NAMESPACE_IMPL_START
SeeAlso []
***********************************************************************/
+void Wlc_NtkCollectBoxes( Wlc_Ntk_t * p, Vec_Int_t * vBoxIds )
+{
+ int i, iObj;
+ Vec_Int_t * vBoxes = Vec_IntAlloc( Vec_IntSize(vBoxIds) + 1 );
+ Vec_IntPush( vBoxes, Vec_IntSize(vBoxIds) );
+ Vec_IntForEachEntry( vBoxIds, iObj, i )
+ Vec_IntPush( vBoxes, Wlc_ObjNameId(p, iObj) );
+ Abc_FrameSetBoxes( Vec_IntReleaseArray(vBoxes) );
+ Vec_IntFree( vBoxes );
+}
Vec_Int_t * Wlc_NtkCollectAddMult( Wlc_Ntk_t * p, Wlc_BstPar_t * pPar, int * pCountA, int * pCountM )
{
Vec_Int_t * vBoxIds;
@@ -57,7 +67,10 @@ Vec_Int_t * Wlc_NtkCollectAddMult( Wlc_Ntk_t * p, Wlc_BstPar_t * pPar, int * pCo
Vec_IntPush( vBoxIds, i ), (*pCountM)++;
}
if ( Vec_IntSize( vBoxIds ) > 0 )
+ {
+ Wlc_NtkCollectBoxes( p, vBoxIds );
return vBoxIds;
+ }
Vec_IntFree( vBoxIds );
return NULL;
}