|
|
1ac6d5 |
diff -crb judy-1.0.5-orig/src/JudyCommon/JudyByCount.c judy-1.0.5/src/JudyCommon/JudyByCount.c
|
|
|
1ac6d5 |
*** judy-1.0.5-orig/src/JudyCommon/JudyByCount.c 2005-02-15 15:06:07.000000000 -0600
|
|
|
1ac6d5 |
--- judy-1.0.5/src/JudyCommon/JudyByCount.c 2014-02-18 13:45:35.225145230 -0600
|
|
|
1ac6d5 |
***************
|
|
|
1ac6d5 |
*** 817,823 ****
|
|
|
1ac6d5 |
// Shorthand for where to find start of Index bytes array:
|
|
|
1ac6d5 |
|
|
|
1ac6d5 |
#ifdef JUDY1
|
|
|
1ac6d5 |
! #define PJI (Pjp->jp_1Index)
|
|
|
1ac6d5 |
#else
|
|
|
1ac6d5 |
#define PJI (Pjp->jp_LIndex)
|
|
|
1ac6d5 |
#endif
|
|
|
1ac6d5 |
--- 817,823 ----
|
|
|
1ac6d5 |
// Shorthand for where to find start of Index bytes array:
|
|
|
1ac6d5 |
|
|
|
1ac6d5 |
#ifdef JUDY1
|
|
|
1ac6d5 |
! #define PJI (Pjp->jp_2Index)
|
|
|
1ac6d5 |
#else
|
|
|
1ac6d5 |
#define PJI (Pjp->jp_LIndex)
|
|
|
1ac6d5 |
#endif
|
|
|
1ac6d5 |
diff -crb judy-1.0.5-orig/src/JudyCommon/JudyGet.c judy-1.0.5/src/JudyCommon/JudyGet.c
|
|
|
1ac6d5 |
*** judy-1.0.5-orig/src/JudyCommon/JudyGet.c 2005-02-15 15:06:07.000000000 -0600
|
|
|
1ac6d5 |
--- judy-1.0.5/src/JudyCommon/JudyGet.c 2014-02-18 13:49:50.840632644 -0600
|
|
|
1ac6d5 |
***************
|
|
|
1ac6d5 |
*** 630,636 ****
|
|
|
1ac6d5 |
#ifdef JUDY1
|
|
|
1ac6d5 |
|
|
|
1ac6d5 |
#define CHECKINDEXNATIVE(LEAF_T, PJP, IDX, INDEX) \
|
|
|
1ac6d5 |
! if (((LEAF_T *)((PJP)->jp_1Index))[(IDX) - 1] == (LEAF_T)(INDEX)) \
|
|
|
1ac6d5 |
return(1)
|
|
|
1ac6d5 |
|
|
|
1ac6d5 |
#define CHECKLEAFNONNAT(LFBTS, PJP, INDEX, IDX, COPY) \
|
|
|
1ac6d5 |
--- 630,636 ----
|
|
|
1ac6d5 |
#ifdef JUDY1
|
|
|
1ac6d5 |
|
|
|
1ac6d5 |
#define CHECKINDEXNATIVE(LEAF_T, PJP, IDX, INDEX) \
|
|
|
1ac6d5 |
! if (((LEAF_T *)((PJP)->jp_2Index))[(IDX) - 1] == (LEAF_T)(INDEX)) \
|
|
|
1ac6d5 |
return(1)
|
|
|
1ac6d5 |
|
|
|
1ac6d5 |
#define CHECKLEAFNONNAT(LFBTS, PJP, INDEX, IDX, COPY) \
|
|
|
1ac6d5 |
diff -crb judy-1.0.5-orig/src/JudyCommon/JudyIns.c judy-1.0.5/src/JudyCommon/JudyIns.c
|
|
|
1ac6d5 |
*** judy-1.0.5-orig/src/JudyCommon/JudyIns.c 2005-02-15 15:06:07.000000000 -0600
|
|
|
1ac6d5 |
--- judy-1.0.5/src/JudyCommon/JudyIns.c 2014-02-18 13:00:49.871850635 -0600
|
|
|
1ac6d5 |
***************
|
|
|
1ac6d5 |
*** 1503,1509 ****
|
|
|
1ac6d5 |
JU_BITMAPSETL(Pjlb, Index);
|
|
|
1ac6d5 |
|
|
|
1ac6d5 |
for (offset = 0; offset < 15; ++offset)
|
|
|
1ac6d5 |
! JU_BITMAPSETL(Pjlb, Pjp->jp_1Index[offset]);
|
|
|
1ac6d5 |
|
|
|
1ac6d5 |
// Set jp_DcdPopO including the current pop0; incremented later:
|
|
|
1ac6d5 |
DcdP0 = (Index & cJU_DCDMASK(1)) + 15 - 1;
|
|
|
1ac6d5 |
--- 1503,1510 ----
|
|
|
1ac6d5 |
JU_BITMAPSETL(Pjlb, Index);
|
|
|
1ac6d5 |
|
|
|
1ac6d5 |
for (offset = 0; offset < 15; ++offset)
|
|
|
1ac6d5 |
! // JU_BITMAPSETL(Pjlb, Pjp->jp_1Index[offset]); // elements 8..15 are optimized out by gcc, so need to do the following
|
|
|
1ac6d5 |
! JU_BITMAPSETL(Pjlb, Pjp->jp_2Index[offset]);
|
|
|
1ac6d5 |
|
|
|
1ac6d5 |
// Set jp_DcdPopO including the current pop0; incremented later:
|
|
|
1ac6d5 |
DcdP0 = (Index & cJU_DCDMASK(1)) + 15 - 1;
|
|
|
1ac6d5 |
diff -crb judy-1.0.5-orig/src/JudyCommon/JudyPrevNext.c judy-1.0.5/src/JudyCommon/JudyPrevNext.c
|
|
|
1ac6d5 |
*** judy-1.0.5-orig/src/JudyCommon/JudyPrevNext.c 2005-02-15 15:06:07.000000000 -0600
|
|
|
1ac6d5 |
--- judy-1.0.5/src/JudyCommon/JudyPrevNext.c 2014-02-18 13:45:40.972875737 -0600
|
|
|
1ac6d5 |
***************
|
|
|
1ac6d5 |
*** 907,913 ****
|
|
|
1ac6d5 |
// Shorthand for where to find start of Index bytes array:
|
|
|
1ac6d5 |
|
|
|
1ac6d5 |
#ifdef JUDY1
|
|
|
1ac6d5 |
! #define PJI (Pjp->jp_1Index)
|
|
|
1ac6d5 |
#else
|
|
|
1ac6d5 |
#define PJI (Pjp->jp_LIndex)
|
|
|
1ac6d5 |
#endif
|
|
|
1ac6d5 |
--- 907,913 ----
|
|
|
1ac6d5 |
// Shorthand for where to find start of Index bytes array:
|
|
|
1ac6d5 |
|
|
|
1ac6d5 |
#ifdef JUDY1
|
|
|
1ac6d5 |
! #define PJI (Pjp->jp_2Index)
|
|
|
1ac6d5 |
#else
|
|
|
1ac6d5 |
#define PJI (Pjp->jp_LIndex)
|
|
|
1ac6d5 |
#endif
|
|
|
1ac6d5 |
diff -crb judy-1.0.5-orig/src/JudyCommon/JudyPrivateBranch.h judy-1.0.5/src/JudyCommon/JudyPrivateBranch.h
|
|
|
1ac6d5 |
*** judy-1.0.5-orig/src/JudyCommon/JudyPrivateBranch.h 2005-02-15 15:06:07.000000000 -0600
|
|
|
1ac6d5 |
--- judy-1.0.5/src/JudyCommon/JudyPrivateBranch.h 2014-02-18 13:00:39.510533765 -0600
|
|
|
1ac6d5 |
***************
|
|
|
1ac6d5 |
*** 86,91 ****
|
|
|
1ac6d5 |
--- 86,98 ----
|
|
|
1ac6d5 |
} jpi_t;
|
|
|
1ac6d5 |
|
|
|
1ac6d5 |
|
|
|
1ac6d5 |
+ typedef struct _JUDY_POINTER_IMMED2 // JPI2.
|
|
|
1ac6d5 |
+ {
|
|
|
1ac6d5 |
+ uint8_t j_pi_2Index[2 * sizeof(Word_t) - 1]; // see above.
|
|
|
1ac6d5 |
+ uint8_t j_pi_Type; // JP type, 1 of cJ*_JPIMMED*.
|
|
|
1ac6d5 |
+ } jpi2_t;
|
|
|
1ac6d5 |
+
|
|
|
1ac6d5 |
+
|
|
|
1ac6d5 |
// UNION OF JP TYPES:
|
|
|
1ac6d5 |
//
|
|
|
1ac6d5 |
// A branch is an array of cJU_BRANCHUNUMJPS (256) of this object, or an
|
|
|
1ac6d5 |
***************
|
|
|
1ac6d5 |
*** 97,102 ****
|
|
|
1ac6d5 |
--- 104,110 ----
|
|
|
1ac6d5 |
{
|
|
|
1ac6d5 |
jpo_t j_po; // other than immediate indexes.
|
|
|
1ac6d5 |
jpi_t j_pi; // immediate indexes.
|
|
|
1ac6d5 |
+ jpi2_t j_pi2; // immediate indexes using j_pi_LIndex as well
|
|
|
1ac6d5 |
} jp_t, *Pjp_t;
|
|
|
1ac6d5 |
|
|
|
1ac6d5 |
// For coding convenience:
|
|
|
1ac6d5 |
***************
|
|
|
1ac6d5 |
*** 105,110 ****
|
|
|
1ac6d5 |
--- 113,119 ----
|
|
|
1ac6d5 |
|
|
|
1ac6d5 |
#define jp_1Index j_pi.j_pi_1Index // for storing Indexes in first word.
|
|
|
1ac6d5 |
#define jp_LIndex j_pi.j_pi_LIndex // for storing Indexes in second word.
|
|
|
1ac6d5 |
+ #define jp_2Index j_pi2.j_pi_2Index // for storing Indexes spanning both words.
|
|
|
1ac6d5 |
#define jp_Addr j_po.j_po_Addr
|
|
|
1ac6d5 |
//#define jp_DcdPop0 j_po.jpo_u.j_po_DcdPop0
|
|
|
1ac6d5 |
#define jp_Type j_po.jpo_u.j_po_Bytes[sizeof(Word_t) - 1]
|