2005-09-02 17:01:00 +02:00
|
|
|
/**CFile****************************************************************
|
|
|
|
|
|
|
|
|
|
FileName [decMan.c]
|
|
|
|
|
|
|
|
|
|
PackageName [MVSIS 2.0: Multi-valued logic synthesis system.]
|
|
|
|
|
|
|
|
|
|
Synopsis [Decomposition manager.]
|
|
|
|
|
|
|
|
|
|
Author [MVSIS Group]
|
|
|
|
|
|
|
|
|
|
Affiliation [UC Berkeley]
|
|
|
|
|
|
|
|
|
|
Date [Ver. 1.0. Started - February 1, 2003.]
|
|
|
|
|
|
|
|
|
|
Revision [$Id: decMan.c,v 1.1 2003/05/22 19:20:05 alanmi Exp $]
|
|
|
|
|
|
|
|
|
|
***********************************************************************/
|
|
|
|
|
|
2012-07-08 05:14:12 +02:00
|
|
|
#include "base/abc/abc.h"
|
|
|
|
|
#include "misc/mvc/mvc.h"
|
2005-09-02 17:01:00 +02:00
|
|
|
#include "dec.h"
|
|
|
|
|
|
2010-11-01 09:35:04 +01:00
|
|
|
ABC_NAMESPACE_IMPL_START
|
|
|
|
|
|
|
|
|
|
|
2005-09-02 17:01:00 +02:00
|
|
|
////////////////////////////////////////////////////////////////////////
|
|
|
|
|
/// DECLARATIONS ///
|
|
|
|
|
////////////////////////////////////////////////////////////////////////
|
|
|
|
|
|
|
|
|
|
////////////////////////////////////////////////////////////////////////
|
2008-01-31 05:01:00 +01:00
|
|
|
/// FUNCTION DEFINITIONS ///
|
2005-09-02 17:01:00 +02:00
|
|
|
////////////////////////////////////////////////////////////////////////
|
|
|
|
|
|
|
|
|
|
/**Function*************************************************************
|
|
|
|
|
|
|
|
|
|
Synopsis [Start the MVC manager used in the factoring package.]
|
|
|
|
|
|
|
|
|
|
Description []
|
|
|
|
|
|
|
|
|
|
SideEffects []
|
|
|
|
|
|
|
|
|
|
SeeAlso []
|
|
|
|
|
|
|
|
|
|
***********************************************************************/
|
|
|
|
|
Dec_Man_t * Dec_ManStart()
|
|
|
|
|
{
|
|
|
|
|
Dec_Man_t * p;
|
2012-07-08 03:15:08 +02:00
|
|
|
// clock_t clk = clock();
|
2009-02-15 17:01:00 +01:00
|
|
|
p = ABC_ALLOC( Dec_Man_t, 1 );
|
2005-09-02 17:01:00 +02:00
|
|
|
p->pMvcMem = Mvc_ManagerStart();
|
|
|
|
|
p->vCubes = Vec_IntAlloc( 8 );
|
|
|
|
|
p->vLits = Vec_IntAlloc( 8 );
|
|
|
|
|
// canonical forms, phases, perms
|
|
|
|
|
Extra_Truth4VarNPN( &p->puCanons, &p->pPhases, &p->pPerms, &p->pMap );
|
2009-02-15 17:01:00 +01:00
|
|
|
//ABC_PRT( "NPN classes precomputation time", clock() - clk );
|
2005-09-02 17:01:00 +02:00
|
|
|
return p;
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
/**Function*************************************************************
|
|
|
|
|
|
|
|
|
|
Synopsis [Stops the MVC maanager used in the factoring package.]
|
|
|
|
|
|
|
|
|
|
Description []
|
|
|
|
|
|
|
|
|
|
SideEffects []
|
|
|
|
|
|
|
|
|
|
SeeAlso []
|
|
|
|
|
|
|
|
|
|
***********************************************************************/
|
|
|
|
|
void Dec_ManStop( Dec_Man_t * p )
|
|
|
|
|
{
|
2010-11-01 09:35:04 +01:00
|
|
|
Mvc_ManagerFree( (Mvc_Manager_t *)p->pMvcMem );
|
2005-09-02 17:01:00 +02:00
|
|
|
Vec_IntFree( p->vCubes );
|
|
|
|
|
Vec_IntFree( p->vLits );
|
2009-02-15 17:01:00 +01:00
|
|
|
ABC_FREE( p->puCanons );
|
|
|
|
|
ABC_FREE( p->pPhases );
|
|
|
|
|
ABC_FREE( p->pPerms );
|
|
|
|
|
ABC_FREE( p->pMap );
|
|
|
|
|
ABC_FREE( p );
|
2005-09-02 17:01:00 +02:00
|
|
|
}
|
|
|
|
|
|
|
|
|
|
////////////////////////////////////////////////////////////////////////
|
|
|
|
|
/// END OF FILE ///
|
|
|
|
|
////////////////////////////////////////////////////////////////////////
|
|
|
|
|
|
|
|
|
|
|
2010-11-01 09:35:04 +01:00
|
|
|
ABC_NAMESPACE_IMPL_END
|
|
|
|
|
|