Added random generation of 64-bit numbers.

This commit is contained in:
Alan Mishchenko 2011-07-27 18:30:08 +07:00
parent 701296451e
commit ff963167fe
2 changed files with 21 additions and 3 deletions

View File

@ -676,6 +676,7 @@ extern void Aig_ManCleanPioNumbers( Aig_Man_t * p );
extern int Aig_ManChoiceNum( Aig_Man_t * p );
extern char * Aig_FileNameGenericAppend( char * pBase, char * pSuffix );
extern unsigned Aig_ManRandom( int fReset );
extern word Aig_ManRandom64( int fReset );
extern void Aig_ManRandomInfo( Vec_Ptr_t * vInfo, int iInputStart, int iWordStart, int iWordStop );
extern void Aig_NodeUnionLists( Vec_Ptr_t * vArr1, Vec_Ptr_t * vArr2, Vec_Ptr_t * vArr );
extern void Aig_NodeIntersectLists( Vec_Ptr_t * vArr1, Vec_Ptr_t * vArr2, Vec_Ptr_t * vArr );

View File

@ -1118,7 +1118,7 @@ char * Aig_FileNameGenericAppend( char * pBase, char * pSuffix )
/**Function*************************************************************
Synopsis [Creates a sequence or random numbers.]
Synopsis [Creates a sequence of random numbers.]
Description []
@ -1148,7 +1148,7 @@ void Aig_ManRandomTest2()
/**Function*************************************************************
Synopsis [Creates a sequence or random numbers.]
Synopsis [Creates a sequence of random numbers.]
Description []
@ -1181,7 +1181,7 @@ void Aig_ManRandomTest1()
/**Function*************************************************************
Synopsis [Creates a sequence or random numbers.]
Synopsis [Creates a sequence of random numbers.]
Description []
@ -1204,6 +1204,23 @@ unsigned Aig_ManRandom( int fReset )
return (m_z << 16) + m_w;
}
/**Function*************************************************************
Synopsis [Creates a sequence of random numbers.]
Description []
SideEffects []
SeeAlso []
***********************************************************************/
word Aig_ManRandom64( int fReset )
{
word Res = ((word)Aig_ManRandom(fReset)) << 32;
return Res | (word)Aig_ManRandom(0);
}
/**Function*************************************************************