pike.git/
src/
block_alloc.h
Branch:
Tag:
Non-build tags
All tags
No tags
2000-03-22
2000-03-22 00:55:07 by Fredrik Hübinette (Hubbe) <hubbe@hubbe.net>
ec6b78b851bb4823a9c32b85a01bacaaad676713 (
8
lines) (+
6
/-
2
)
[
Show
|
Annotate
]
Branch:
7.9
minor optimization?
Rev: src/block_alloc.h:1.17
1:
-
/* $Id: block_alloc.h,v 1.
16
2000/03/
20
21:
00:
03
hubbe Exp $ */
+
/* $Id: block_alloc.h,v 1.
17
2000/03/
22
00:
55:07
hubbe Exp $ */
#undef PRE_INIT_BLOCK #undef INIT_BLOCK #undef EXIT_BLOCK
111:
PIKE_CONCAT(really_low_find_,DATA)(void *ptr, int hval) \ { \ struct DATA *p,**pp; \
-
for(pp
=PIKE_CONCAT(DATA,_hash_table)
+hval
;(p=
*pp
);pp=&p->BLOCK_ALLOC_NEXT) \
+
p
=PIKE_CONCAT(DATA,_hash_table)
[hval]
;
\
+
if
(
!
p
) return 0; \
+
if(p->data
=
= ptr
)
return p
;
\
+
while((p=*(
pp=&p->BLOCK_ALLOC_NEXT)
))
\
{ \ if(p->data==ptr) \ { \