ABC: A System for Sequential Synthesis and Verification
 
Loading...
Searching...
No Matches
ifCache.c File Reference
#include "if.h"
#include "misc/vec/vecHsh.h"
Include dependency graph for ifCache.c:

Go to the source code of this file.

Functions

ABC_NAMESPACE_IMPL_START void If_ManCacheRecord (If_Man_t *p, int iDsd0, int iDsd1, int nShared, int iDsd)
 DECLARATIONS ///.
 
void If_ManCacheAnalize (If_Man_t *p)
 

Function Documentation

◆ If_ManCacheAnalize()

void If_ManCacheAnalize ( If_Man_t * p)

Function*************************************************************

Synopsis []

Description []

SideEffects []

SeeAlso []

Definition at line 70 of file ifCache.c.

71{
72 Vec_Int_t * vRes, * vTest[32];
73 int i, Entry, uUnique;
74 vRes = Hsh_IntManHashArray( p->vCutData, 4 );
75 for ( i = 0; i <= p->pPars->nLutSize; i++ )
76 vTest[i] = Vec_IntAlloc( 1000 );
77 Vec_IntForEachEntry( vRes, Entry, i )
78 Vec_IntPush( vTest[Vec_IntEntry(p->vCutData, 4*i+2)], Entry );
79 for ( i = 0; i <= p->pPars->nLutSize; i++ )
80 {
81 uUnique = Vec_IntCountUnique(vTest[i]);
82 printf( "%2d-var entries = %8d. (%6.2f %%) Unique entries = %8d. (%6.2f %%)\n",
83 i, Vec_IntSize(vTest[i]), 100.0*Vec_IntSize(vTest[i])/Abc_MaxInt(1, Vec_IntSize(vRes)),
84 uUnique, 100.0*uUnique/Abc_MaxInt(1, Vec_IntSize(vTest[i])) );
85 }
86 for ( i = 0; i <= p->pPars->nLutSize; i++ )
87 Vec_IntFree( vTest[i] );
88 uUnique = Vec_IntCountUnique(vRes);
89 printf( "Total entries = %8d. (%6.2f %%) Unique entries = %8d. (%6.2f %%)\n",
90 Vec_IntSize(p->vCutData)/4, 100.0, uUnique, 100.0*uUnique/Abc_MaxInt(1, Vec_IntSize(p->vCutData)/4) );
91 Vec_IntFree( vRes );
92}
typedefABC_NAMESPACE_IMPL_START struct Vec_Int_t_ Vec_Int_t
DECLARATIONS ///.
Definition bblif.c:37
Cube * p
Definition exorList.c:222
#define Vec_IntForEachEntry(vVec, Entry, i)
MACRO DEFINITIONS ///.
Definition vecInt.h:54
Here is the caller graph for this function:

◆ If_ManCacheRecord()

ABC_NAMESPACE_IMPL_START void If_ManCacheRecord ( If_Man_t * p,
int iDsd0,
int iDsd1,
int nShared,
int iDsd )

DECLARATIONS ///.

CFile****************************************************************

FileName [ifCache.c]

SystemName [ABC: Logic synthesis and verification system.]

PackageName [FPGA mapping based on priority cuts.]

Synopsis []

Author [Alan Mishchenko]

Affiliation [UC Berkeley]

Date [Ver. 1.0. Started - November 21, 2006.]

Revision [

Id
ifCache.c,v 1.00 2006/11/21 00:00:00 alanmi Exp

] FUNCTION DEFINITIONS /// Function*************************************************************

Synopsis []

Description []

SideEffects []

SeeAlso []

Definition at line 45 of file ifCache.c.

46{
47 assert( nShared >= 0 && nShared <= p->pPars->nLutSize );
48 if ( p->vCutData == NULL )
49 p->vCutData = Vec_IntAlloc( 10000 );
50 if ( iDsd0 > iDsd1 )
51 ABC_SWAP( int, iDsd0, iDsd1 );
52 Vec_IntPush( p->vCutData, iDsd0 );
53 Vec_IntPush( p->vCutData, iDsd1 );
54 Vec_IntPush( p->vCutData, nShared );
55 Vec_IntPush( p->vCutData, iDsd );
56// printf( "%6d %6d %6d %6d\n", iDsd0, iDsd1, nShared, iDsd );
57}
#define ABC_SWAP(Type, a, b)
Definition abc_global.h:253
#define assert(ex)
Definition util_old.h:213
Here is the caller graph for this function: