28static const uint32_t prime_numbers[] =
29 {5, 11, 19, 53, 107, 223, 463, 983, 1979, 3907, 7963, 16229, 32531, 65407, 130987, 262237, 524521, 1048793 };
30static const uint32_t num_prime_numbers =
sizeof(prime_numbers) /
sizeof(uint32_t);
43 for (i=0; i<num_prime_numbers; i++) {
44 if (hash_size <= prime_numbers[i]) {
45 hash_size = prime_numbers[i];
88 hash_value = zend_string_hash_val(
key);
90 hash_value ^=
ZCG(root_hash);
98 && zend_string_equals(entry->
key,
key)) {
101 if (indirect_bucket) {
102 entry->
data = indirect_bucket;
107 if (indirect_bucket) {
109 entry->
data = indirect_bucket;
127 entry->
data = indirect_bucket;
147 hash_value = zend_string_hash_val(
key);
149 hash_value ^=
ZCG(root_hash);
156 && zend_string_equals(entry->
key,
key)) {
181 return zend_accel_hash_find_ex(accel_hash,
key, 1);
198 hash_value = zend_string_hash_val(
key);
200 hash_value ^=
ZCG(root_hash);
207 && zend_string_equals(entry->
key,
key)) {
memset(ptr, 0, type->size)
unsigned char key[REFLECTION_KEY_LEN]
zend_accel_hash_entry * next
zend_accel_hash_entry * hash_entries
zend_accel_hash_entry ** hash_table
uint32_t num_direct_entries
ZEND_NORETURN void zend_accel_error_noreturn(int type, const char *format,...)
void zend_accel_hash_init(zend_accel_hash *accel_hash, uint32_t hash_size)
zend_accel_hash_entry * zend_accel_hash_find_entry(zend_accel_hash *accel_hash, zend_string *key)
void * zend_accel_hash_find(zend_accel_hash *accel_hash, zend_string *key)
int zend_accel_hash_unlink(zend_accel_hash *accel_hash, zend_string *key)
zend_accel_hash_entry * zend_accel_hash_update(zend_accel_hash *accel_hash, zend_string *key, bool indirect, void *data)
void zend_accel_hash_clean(zend_accel_hash *accel_hash)
struct _zend_accel_hash zend_accel_hash
struct _zend_accel_hash_entry zend_accel_hash_entry
struct _zend_string zend_string
#define zend_always_inline
void * zend_shared_alloc(size_t size)