Fix for 64bit OS
authornvalimak <nvalimak@3cdefd35-fc62-479d-8e8d-bae585ffb9ca>
Fri, 9 Jan 2009 13:37:50 +0000 (13:37 +0000)
committernvalimak <nvalimak@3cdefd35-fc62-479d-8e8d-bae585ffb9ca>
Fri, 9 Jan 2009 13:37:50 +0000 (13:37 +0000)
git-svn-id: svn+ssh://idea.nguyen.vg/svn/sxsi/trunk/TextCollection@49 3cdefd35-fc62-479d-8e8d-bae585ffb9ca

bittree.h

index 5344f74..8427e90 100644 (file)
--- a/bittree.h
+++ b/bittree.h
@@ -39,7 +39,7 @@
 #include <cstdio>
 
 #include "rbtree.h"
-
+#include "Tools.h"
 
 #ifndef uchar
 #define uchar unsigned char
 #endif
 
 
-#ifndef LOGN
-#define LOGN 64
-#endif
 
-const int logn = LOGN;
+const int logn = (W * 2);
 
 //upperBound = 2 * logn;
 //lowerBound = logn / 2;
@@ -73,7 +70,7 @@ class BVNode : public RBNode
        ulong subTreePositions; //number of positions stored in the subtree rooted at this node
        ulong subTreeRank;      //number of bits set in the subtree rooted at this node
 
-        std::bitset<2*logn> *block; // 4 bytes
+        std::bitset<2*logn> *block; // 4 words
        
 
        BVNode()