abc/src/base/abci/abcExact.c
// returns 0, if current max depth and #gates are not consistent
returns 0, if current max depth and #gates are not consistent
returns 0 if current max depth and #gates are not consistent
static int Ses_CheckGatesConsistency( Ses_Man_t * pSes, int nGates )
{
    if ( pSes->nMaxDepth != -1 && nGates >= ( 1 << pSes->nMaxDepth ) )
    {
        if ( pSes->fReasonVerbose )
            printf( "give up due to impossible depth (depth = %d, gates = %d)", pSes->nMaxDepth, nGates );
        return 0;
    }
    if ( pSes->nMaxDepth != -1 && pSes->pArrTimeProfile && nGates > pSes->nMaxGates )
    {
        if ( pSes->fReasonVerbose )
            printf( "give up due to impossible depth and arrival times (depth = %d, gates = %d)", pSes->nMaxDepth, nGates );
        return 0;
    }
    if ( pSes->fDecStructure && nGates >= ( 1 << ( pSes->nMaxDepth - 1 ) ) + 1 )
    {
        if ( pSes->fReasonVerbose )
            printf( "give up due to impossible depth in AND-dec structure (depth = %d, gates = %d)", pSes->nMaxDepth, nGates );
        return 0;
    }
    if ( nGates >= ( 1 << pSes->nSpecVars ) )
    {
        if ( pSes->fReasonVerbose )
            printf( "give up due to impossible number of gates" );
        return 0;
    }
    return 1;
}
static int Ses_CheckGatesConsistency ( Ses_Man_t * pSes , int nGates ) { if ( pSes -> nMaxDepth != -1 && nGates >= ( 1 << pSes -> nMaxDepth ) ) { if ( pSes -> fReasonVerbose ) printf ( " " , pSes -> nMaxDepth , nGates ) ; return 0 ; } if ( pSes -> nMaxDepth != -1 && pSes -> pArrTimeProfile && nGates > pSes -> nMaxGates ) { if ( pSes -> fReasonVerbose ) printf ( " " , pSes -> nMaxDepth , nGates ) ; return 0 ; } if ( pSes -> fDecStructure && nGates >= ( 1 << ( pSes -> nMaxDepth - 1 ) ) + 1 ) { if ( pSes -> fReasonVerbose ) printf ( " " , pSes -> nMaxDepth , nGates ) ; return 0 ; } if ( nGates >= ( 1 << pSes -> nSpecVars ) ) { if ( pSes -> fReasonVerbose ) printf ( " " ) ; return 0 ; } return 1 ; }
returns 0, if current max depth and #gates are not consistent
returns 0 if current max depth and #gates are not consistent
/* give up if number of gates is impossible for given depth */ /* give up if number of gates is impossible for given depth and arrival times */ /* give up if number of gates gets practically too large */