Commit 518410af by Alan Mishchenko

Compiler warnings.

parent 20518f59
...@@ -85,7 +85,7 @@ void sortAndUnique(word** a, Abc_TtStore_t* p) ...@@ -85,7 +85,7 @@ void sortAndUnique(word** a, Abc_TtStore_t* p)
{ {
int i, count=1, WordsPtrN = p->nFuncs; int i, count=1, WordsPtrN = p->nFuncs;
word* tempWordPtr; word* tempWordPtr;
qsort(a,WordsPtrN,sizeof(word*),compareWords3); qsort(a,WordsPtrN,sizeof(word*),(int(*)(const void *,const void *))compareWords3);
tempWordPtr = a[0]; tempWordPtr = a[0];
for(i=1;i<WordsPtrN;i++) for(i=1;i<WordsPtrN;i++)
if(memcmp(a[i],tempWordPtr,sizeof(word)*(p->nWords)) != 0) if(memcmp(a[i],tempWordPtr,sizeof(word)*(p->nWords)) != 0)
......
...@@ -35,27 +35,15 @@ ...@@ -35,27 +35,15 @@
#define ABC_NAMESPACE_IMPL_START #define ABC_NAMESPACE_IMPL_START
#define ABC_NAMESPACE_IMPL_END #define ABC_NAMESPACE_IMPL_END
typedef unsigned __int64 word; typedef unsigned __int64 word;
#endif
ABC_NAMESPACE_HEADER_START
#define bool int #define bool int
#define false 0 #define false 0
#define true 1 #define true 1
#define inline __inline // compatible with MS VS 6.0 #define inline __inline // compatible with MS VS 6.0
#define ABC_ALLOC(type, num) ((type *) malloc(sizeof(type) * (num))) #define ABC_ALLOC(type, num) ((type *) malloc(sizeof(type) * (num)))
static word mask1[6] = { 0xAAAAAAAAAAAAAAAA,0xCCCCCCCCCCCCCCCC, 0xF0F0F0F0F0F0F0F0,0xFF00FF00FF00FF00,0xFFFF0000FFFF0000, 0xFFFFFFFF00000000 }; #endif
static word mask0[6] = { 0x5555555555555555,0x3333333333333333, 0x0F0F0F0F0F0F0F0F,0x00FF00FF00FF00FF,0x0000FFFF0000FFFF, 0x00000000FFFFFFFF};
static word mask[6][2] = {
{0x5555555555555555,0xAAAAAAAAAAAAAAAA}, ABC_NAMESPACE_HEADER_START
{0x3333333333333333,0xCCCCCCCCCCCCCCCC},
{0x0F0F0F0F0F0F0F0F,0xF0F0F0F0F0F0F0F0},
{0x00FF00FF00FF00FF,0xFF00FF00FF00FF00},
{0x0000FFFF0000FFFF,0xFFFF0000FFFF0000},
{0x00000000FFFFFFFF,0xFFFFFFFF00000000}
};
typedef struct typedef struct
{ {
......
...@@ -19,6 +19,19 @@ ...@@ -19,6 +19,19 @@
ABC_NAMESPACE_IMPL_START ABC_NAMESPACE_IMPL_START
static word mask0[6] = { 0x5555555555555555,0x3333333333333333, 0x0F0F0F0F0F0F0F0F,0x00FF00FF00FF00FF,0x0000FFFF0000FFFF, 0x00000000FFFFFFFF};
/*
static word mask1[6] = { 0xAAAAAAAAAAAAAAAA,0xCCCCCCCCCCCCCCCC, 0xF0F0F0F0F0F0F0F0,0xFF00FF00FF00FF00,0xFFFF0000FFFF0000, 0xFFFFFFFF00000000 };
static word mask[6][2] = {
{0x5555555555555555,0xAAAAAAAAAAAAAAAA},
{0x3333333333333333,0xCCCCCCCCCCCCCCCC},
{0x0F0F0F0F0F0F0F0F,0xF0F0F0F0F0F0F0F0},
{0x00FF00FF00FF00FF,0xFF00FF00FF00FF00},
{0x0000FFFF0000FFFF,0xFFFF0000FFFF0000},
{0x00000000FFFFFFFF,0xFFFFFFFF00000000}
};
*/
inline int Kit_TruthWordNum_64bit( int nVars ) { return nVars <= 6 ? 1 : (1 << (nVars - 6));} inline int Kit_TruthWordNum_64bit( int nVars ) { return nVars <= 6 ? 1 : (1 << (nVars - 6));}
inline int Kit_WordCountOnes_64bit(word x) inline int Kit_WordCountOnes_64bit(word x)
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment