Adding new external APIs.

This commit is contained in:
Alan Mishchenko 2025-03-03 19:40:11 -08:00
parent e462caed8f
commit c25bf73466
3 changed files with 21 additions and 0 deletions

View File

@ -555,6 +555,23 @@ char * Abc_FrameGiaOutputMiniLutAttr( Abc_Frame_t * pAbc, void * pMiniLut )
printf( "Current network in ABC framework is not defined.\n" );
return Gia_ManToMiniLutAttr( pGia, pMiniLut );
}
int * Abc_FrameGiaOutputMiniLutObj( Abc_Frame_t * pAbc )
{
int * pRes = NULL;
if ( pAbc == NULL )
printf( "ABC framework is not initialized by calling Abc_Start()\n" );
if ( pAbc->vMiniLutObjs == NULL )
printf( "MiniLut objects are not defined.\n" );
pRes = Vec_IntReleaseArray( pAbc->vMiniLutObjs );
Vec_IntFreeP( &pAbc->vMiniLutObjs );
return pRes;
}
void Abc_FrameSetObjDelays( Abc_Frame_t * pAbc, int * pDelays, int nDelays )
{
Vec_IntFreeP( &pAbc->vObjDelays );
pAbc->vObjDelays = Vec_IntAllocArrayCopy( pDelays, nDelays );
}
/**Function*************************************************************

View File

@ -81,6 +81,8 @@ extern ABC_DLL void Abc_FrameGiaInputMiniLut( Abc_Frame_t * pAbc, void * pMini
extern ABC_DLL void Abc_FrameGiaInputMiniLut2( Abc_Frame_t * pAbc, void * pMiniLut );
extern ABC_DLL void * Abc_FrameGiaOutputMiniLut( Abc_Frame_t * pAbc );
extern ABC_DLL char * Abc_FrameGiaOutputMiniLutAttr( Abc_Frame_t * pAbc, void * pMiniLut );
extern ABC_DLL int * Abc_FrameGiaOutputMiniLutObj( Abc_Frame_t * pAbc );
extern ABC_DLL void Abc_FrameSetObjDelays( Abc_Frame_t * pAbc, int * pDelays, int nDelays );
extern ABC_DLL int * Abc_FrameReadMiniLutSwitching( Abc_Frame_t * pAbc );
extern ABC_DLL int * Abc_FrameReadMiniLutSwitching2( Abc_Frame_t * pAbc, int nRandPiFactor );
extern ABC_DLL int * Abc_FrameReadMiniLutSwitchingPo( Abc_Frame_t * pAbc );

View File

@ -158,6 +158,8 @@ struct Abc_Frame_t_
Gia_Man_t * pGiaMiniLut;
Vec_Int_t * vCopyMiniAig;
Vec_Int_t * vCopyMiniLut;
Vec_Int_t * vMiniLutObjs;
Vec_Int_t * vObjDelays;
int * pArray;
int * pBoxes;
void * pNdr;