1 // **************************************************************************** 2 // Quick and dirty header file for use with old Judy.h without JudyHS defs 3 // May 2004 (dlb) - No copyright or license -- it is free period. 4 5 #include <stdint.h> 6 7 // **************************************************************************** 8 // JUDYHSL MACROS: 9 10 #define JHSI(PV, PArray, PIndex, Count) \ 11 J_2P(PV, (&(PArray)), PIndex, Count, JudyHSIns, "JudyHSIns") 12 #define JHSG(PV, PArray, PIndex, Count) \ 13 (PV) = (Pvoid_t) JudyHSGet(PArray, PIndex, Count) 14 #define JHSD(Rc, PArray, PIndex, Count) \ 15 J_2I(Rc, (&(PArray)), PIndex, Count, JudyHSDel, "JudyHSDel") 16 #define JHSFA(Rc, PArray) \ 17 J_0I(Rc, (&(PArray)), JudyHSFreeArray, "JudyHSFreeArray") 18 19 // **************************************************************************** 20 // JUDY memory interface to malloc() FUNCTIONS: 21 22 extern Word_t JudyMalloc(Word_t); // words reqd => words allocd. 23 extern Word_t JudyMallocVirtual(Word_t); // words reqd => words allocd. 24 extern void JudyFree(Pvoid_t, Word_t); // block to free and its size in words. 25 extern void JudyFreeVirtual(Pvoid_t, Word_t); // block to free and its size in words. 26 27 // **************************************************************************** 28 // JUDYHS FUNCTIONS: 29 30 extern PPvoid_t JudyHSGet( Pcvoid_t, void *, Word_t); 31 extern PPvoid_t JudyHSIns( PPvoid_t, void *, Word_t, P_JE); 32 extern int JudyHSDel( PPvoid_t, void *, Word_t, P_JE); 33 extern Word_t JudyHSFreeArray( PPvoid_t, P_JE); 34 35 extern uint32_t JudyHashStr( void *, Word_t); 36