abc/src/bdd/reo/reoTest.c
/**Function*************************************************************

  Synopsis    []

  Description [Transfers the BDD into another manager minimizes it and 
  returns the min number of nodes; disposes of the BDD in the new manager.
  Useful for debugging or comparing the performance of other reordering
  procedures.]

  SideEffects []

  SeeAlso     []

***********************************************************************/
Function
Synopsis    []

Description [Transfers the BDD into another manager minimizes it and
returns the min number of nodes; disposes of the BDD in the new manager.
Useful for debugging or comparing the performance of other reordering
procedures.]




Function Synopsis [] Description [ Transfers the BDD into another manager minimizes it and returns the min number of nodes ; disposes of the BDD in the new manager . Useful for debugging or comparing the performance of other reordering procedures . ]
int Extra_bddReorderTest( DdManager * dd, DdNode * bF )
{
    static DdManager * s_ddmin;
    DdNode * bFmin;
    int  nNodes;
    if ( s_ddmin == NULL )
        s_ddmin = Cudd_Init( dd->size, 0, CUDD_UNIQUE_SLOTS, CUDD_CACHE_SLOTS, 0);
    bFmin = Cudd_bddTransfer( dd, s_ddmin, bF );  Cudd_Ref( bFmin );
    Cudd_ReduceHeap(s_ddmin,CUDD_REORDER_SIFT,1);
    nNodes = Cudd_DagSize( bFmin );
    Cudd_RecursiveDeref( s_ddmin, bFmin );
    return nNodes;
}
int Extra_bddReorderTest ( DdManager * dd , DdNode * bF ) { static DdManager * s_ddmin ; DdNode * bFmin ; int nNodes ; if ( s_ddmin == NULL ) s_ddmin = Cudd_Init ( dd -> size , 0 , CUDD_UNIQUE_SLOTS , CUDD_CACHE_SLOTS , 0 ) ; bFmin = Cudd_bddTransfer ( dd , s_ddmin , bF ) ; Cudd_Ref ( bFmin ) ; Cudd_ReduceHeap ( s_ddmin , CUDD_REORDER_SIFT , 1 ) ; nNodes = Cudd_DagSize ( bFmin ) ; Cudd_RecursiveDeref ( s_ddmin , bFmin ) ; return nNodes ; }
Function
Synopsis    []
Function Synopsis []
//    abctime clk1; //    Cudd_ShuffleHeap( s_ddmin, dd->invperm ); //    clk1 = Abc_Clock(); //    Cudd_ReduceHeap(s_ddmin,CUDD_REORDER_SYMM_SIFT,1); //    printf( "Classical variable reordering time = %.2f sec\n", (float)(Abc_Clock() - clk1)/(float)(CLOCKS_PER_SEC) );