summaryrefslogtreecommitdiff
path: root/src/lib/eo/eo_ptr_indirection.c
diff options
context:
space:
mode:
authorCarsten Haitzler (Rasterman) <raster@rasterman.com>2013-04-23 18:48:35 +0900
committerCarsten Haitzler (Rasterman) <raster@rasterman.com>2013-04-23 23:39:37 +0900
commitc9ad644be22e5174c84d7108e415dbc8ad0c6422 (patch)
treeb500be5819a3bffe05e3c3268b18e62736ca62c5 /src/lib/eo/eo_ptr_indirection.c
parentba57a1c7954224ef6d2dde1ed328745d3d2d8bd0 (diff)
eoid -> rjid 64bit bit allocations for.. not so much bloat.
Diffstat (limited to 'src/lib/eo/eo_ptr_indirection.c')
-rw-r--r--src/lib/eo/eo_ptr_indirection.c20
1 files changed, 10 insertions, 10 deletions
diff --git a/src/lib/eo/eo_ptr_indirection.c b/src/lib/eo/eo_ptr_indirection.c
index a77b854..19ca52b 100644
--- a/src/lib/eo/eo_ptr_indirection.c
+++ b/src/lib/eo/eo_ptr_indirection.c
@@ -45,16 +45,16 @@
45 45
46#if SIZEOF_UINTPTR_T == 4 46#if SIZEOF_UINTPTR_T == 4
47/* 32 bits */ 47/* 32 bits */
48# define BITS_FOR_IDS_TABLE 8 48# define BITS_FOR_IDS_TABLE 8
49# define BITS_FOR_IDS_INTER_TABLE 4 49# define BITS_FOR_IDS_INTER_TABLE 4
50# define BITS_FOR_ID_IN_TABLE 10 50# define BITS_FOR_ID_IN_TABLE 10
51# define BITS_FOR_GENERATION_COUNTER 10 51# define BITS_FOR_GENERATION_COUNTER 10
52#else 52#else
53/* 64 bits */ 53/* 64 bits */
54# define BITS_FOR_IDS_TABLE 8 54# define BITS_FOR_IDS_TABLE 11
55# define BITS_FOR_IDS_INTER_TABLE 20 55# define BITS_FOR_IDS_INTER_TABLE 11
56# define BITS_FOR_ID_IN_TABLE 16 56# define BITS_FOR_ID_IN_TABLE 12
57# define BITS_FOR_GENERATION_COUNTER 20 57# define BITS_FOR_GENERATION_COUNTER 30
58#endif 58#endif
59 59
60typedef uintptr_t Table_Index; 60typedef uintptr_t Table_Index;
@@ -69,10 +69,10 @@ typedef uintptr_t Table_Index;
69#define SHIFT_FOR_ID_IN_TABLE (BITS_FOR_GENERATION_COUNTER) 69#define SHIFT_FOR_ID_IN_TABLE (BITS_FOR_GENERATION_COUNTER)
70 70
71/* Maximum ranges */ 71/* Maximum ranges */
72#define MAX_IDS_TABLES (1 << BITS_FOR_IDS_TABLE) 72#define MAX_IDS_TABLES (1 << BITS_FOR_IDS_TABLE)
73#define MAX_IDS_INTER_TABLES (1 << BITS_FOR_IDS_INTER_TABLE) 73#define MAX_IDS_INTER_TABLES (1 << BITS_FOR_IDS_INTER_TABLE)
74#define MAX_IDS_PER_TABLE (1 << BITS_FOR_ID_IN_TABLE) 74#define MAX_IDS_PER_TABLE (1 << BITS_FOR_ID_IN_TABLE)
75#define MAX_GENERATIONS (1 << BITS_FOR_GENERATION_COUNTER) 75#define MAX_GENERATIONS (1 << BITS_FOR_GENERATION_COUNTER)
76 76
77/* Table */ 77/* Table */
78typedef struct 78typedef struct