abc/src/opt/cut/cutTruth.c
/**Function*************************************************************

  Synopsis    [Performs truth table computation.]

  Description [This procedure cannot be used while recording oracle
  because it will overwrite Num0 and Num1.]
               
  SideEffects []

  SeeAlso     []

***********************************************************************/
Function
Synopsis    [Performs truth table computation.]

Description [This procedure cannot be used while recording oracle
because it will overwrite Num0 and Num1.]




Function Synopsis [ Performs truth table computation . ] Description [ This procedure cannot be used while recording oracle because it will overwrite Num0 and Num1 . ]
void Cut_TruthNCanonicize( Cut_Cut_t * pCut )
{
    unsigned uTruth;
    unsigned * uCanon2;
    char * pPhases2;
    assert( pCut->nVarsMax < 6 );
    uTruth = *Cut_CutReadTruth(pCut);
    Extra_TruthCanonFastN( pCut->nVarsMax, pCut->nLeaves, &uTruth, &uCanon2, &pPhases2 );
    pCut->uCanon0 = uCanon2[0];
    pCut->Num0    = pPhases2[0];
    uTruth = ~*Cut_CutReadTruth(pCut);
    Extra_TruthCanonFastN( pCut->nVarsMax, pCut->nLeaves, &uTruth, &uCanon2, &pPhases2 );
    pCut->uCanon1 = uCanon2[0];
    pCut->Num1    = pPhases2[0];
}
void Cut_TruthNCanonicize ( Cut_Cut_t * pCut ) { unsigned uTruth ; unsigned * uCanon2 ; char * pPhases2 ; assert ( pCut -> nVarsMax < 6 ) ; uTruth = * Cut_CutReadTruth ( pCut ) ; Extra_TruthCanonFastN ( pCut -> nVarsMax , pCut -> nLeaves , & uTruth , & uCanon2 , & pPhases2 ) ; pCut -> uCanon0 = uCanon2 [ 0 ] ; pCut -> Num0 = pPhases2 [ 0 ] ; uTruth = ~ * Cut_CutReadTruth ( pCut ) ; Extra_TruthCanonFastN ( pCut -> nVarsMax , pCut -> nLeaves , & uTruth , & uCanon2 , & pPhases2 ) ; pCut -> uCanon1 = uCanon2 [ 0 ] ; pCut -> Num1 = pPhases2 [ 0 ] ; }
Function
Synopsis    [Performs truth table computation.]
Function Synopsis [ Performs truth table computation . ]
// get the direct truth table // compute the direct truth table //    uCanon[0] = uCanon2[0]; //    uCanon[1] = (p->nVarsMax == 6)? uCanon2[1] : uCanon2[0]; //    uPhases[0] = pPhases2[0]; // get the complemented truth table // compute the direct truth table //    uCanon[0] = uCanon2[0]; //    uCanon[1] = (p->nVarsMax == 6)? uCanon2[1] : uCanon2[0]; //    uPhases[0] = pPhases2[0];