]> granicus.if.org Git - php/commitdiff
Use fastcall calling convention for most critical ZE subsystems.
authorDmitry Stogov <dmitry@zend.com>
Fri, 13 Mar 2015 18:10:09 +0000 (21:10 +0300)
committerDmitry Stogov <dmitry@zend.com>
Fri, 13 Mar 2015 18:10:09 +0000 (21:10 +0300)
14 files changed:
Zend/zend_compile.h
Zend/zend_execute.c
Zend/zend_gc.c
Zend/zend_gc.h
Zend/zend_hash.c
Zend/zend_hash.h
Zend/zend_operators.c
Zend/zend_operators.h
Zend/zend_variables.c
Zend/zend_variables.h
Zend/zend_vm_def.h
Zend/zend_vm_execute.h
ext/opcache/Optimizer/block_pass.c
ext/opcache/Optimizer/pass1_5.c

index 42f55f952172094017ac075ef588ec398728ee5a..72f61ac433371a1bbfe2b1eaee795b7b689f9d7c 100644 (file)
@@ -632,8 +632,9 @@ int zend_get_zendleng(void);
 #endif
 
 
-typedef int (*unary_op_type)(zval *, zval *);
-typedef int (*binary_op_type)(zval *, zval *, zval *);
+typedef int ZEND_FASTCALL (*unary_op_type)(zval *, zval *);
+typedef int ZEND_FASTCALL (*binary_op_type)(zval *, zval *, zval *);
+
 ZEND_API unary_op_type get_unary_op(int opcode);
 ZEND_API binary_op_type get_binary_op(int opcode);
 
index 163f8c1ae79c13ff2dca6e82bb54ea894d7f7576..49b2c5add0a8f70f01b76e026cce56cb0db62801 100644 (file)
@@ -49,7 +49,7 @@
 #define _UNUSED_CODE 3
 #define _CV_CODE     4
 
-typedef int (*incdec_t)(zval *);
+typedef int ZEND_FASTCALL (*incdec_t)(zval *);
 
 #define get_zval_ptr(op_type, node, ex, should_free, type) _get_zval_ptr(op_type, node, ex, should_free, type)
 #define get_zval_ptr_deref(op_type, node, ex, should_free, type) _get_zval_ptr_deref(op_type, node, ex, should_free, type)
@@ -1054,7 +1054,7 @@ static zend_never_inline void zend_assign_to_object_dim(zval *retval, zval *obje
        }
 }
 
-static zend_never_inline void zend_binary_assign_op_obj_dim(zval *object, zval *property, zval *value, zval *retval, int (*binary_op)(zval *result, zval *op1, zval *op2))
+static zend_never_inline void zend_binary_assign_op_obj_dim(zval *object, zval *property, zval *value, zval *retval, binary_op_type binary_op)
 {
        zval *z;
        zval rv, res;
index 13d3ee7f0194cc0fc2853a4e500213bca966aa5a..8eb53e9e1dae9b85bb6efa58e864a8cd21d1493a 100644 (file)
@@ -137,7 +137,7 @@ ZEND_API void gc_init(void)
        }
 }
 
-ZEND_API void gc_possible_root(zend_refcounted *ref)
+ZEND_API void ZEND_FASTCALL gc_possible_root(zend_refcounted *ref)
 {
        if (UNEXPECTED(GC_TYPE(ref) == IS_NULL) || UNEXPECTED(CG(unclean_shutdown))) {
                return;
@@ -189,7 +189,7 @@ ZEND_API void gc_possible_root(zend_refcounted *ref)
        }
 }
 
-ZEND_API void gc_remove_from_buffer(zend_refcounted *ref)
+ZEND_API void ZEND_FASTCALL gc_remove_from_buffer(zend_refcounted *ref)
 {
        gc_root_buffer *root;
 
index 2be98ee8ec7ca89830adb4eebbb1b1e76afcc75f..94a8332a68590ef4849d77e69877ee1b392c10da 100644 (file)
@@ -121,8 +121,8 @@ extern ZEND_API zend_gc_globals gc_globals;
 BEGIN_EXTERN_C()
 ZEND_API extern int (*gc_collect_cycles)(void);
 
-ZEND_API void gc_possible_root(zend_refcounted *ref);
-ZEND_API void gc_remove_from_buffer(zend_refcounted *ref);
+ZEND_API void ZEND_FASTCALL gc_possible_root(zend_refcounted *ref);
+ZEND_API void ZEND_FASTCALL gc_remove_from_buffer(zend_refcounted *ref);
 ZEND_API void gc_globals_ctor(void);
 ZEND_API void gc_globals_dtor(void);
 ZEND_API void gc_init(void);
index 681b8d0ec29a81fd78feedc0f6cefa447238b0a9..a00f46e7b3788ce367321ab53bc90e492ccc5381 100644 (file)
@@ -87,7 +87,7 @@ static void _zend_is_inconsistent(const HashTable *ht, const char *file, int lin
                zend_hash_do_resize(ht);                                        \
        }
 
-static void zend_hash_do_resize(HashTable *ht);
+static void ZEND_FASTCALL zend_hash_do_resize(HashTable *ht);
 
 static uint32_t zend_always_inline zend_hash_check_size(uint32_t nSize)
 {
@@ -143,7 +143,7 @@ static void zend_always_inline zend_hash_check_init(HashTable *ht, int packed)
 static const uint32_t uninitialized_bucket[-HT_MIN_MASK] =
        {HT_INVALID_IDX, HT_INVALID_IDX};
 
-ZEND_API void _zend_hash_init(HashTable *ht, uint32_t nSize, dtor_func_t pDestructor, zend_bool persistent ZEND_FILE_LINE_DC)
+ZEND_API void ZEND_FASTCALL _zend_hash_init(HashTable *ht, uint32_t nSize, dtor_func_t pDestructor, zend_bool persistent ZEND_FILE_LINE_DC)
 {
        GC_REFCOUNT(ht) = 1;
        GC_TYPE_INFO(ht) = IS_ARRAY;
@@ -158,7 +158,7 @@ ZEND_API void _zend_hash_init(HashTable *ht, uint32_t nSize, dtor_func_t pDestru
        ht->pDestructor = pDestructor;
 }
 
-static void zend_hash_packed_grow(HashTable *ht)
+static void ZEND_FASTCALL zend_hash_packed_grow(HashTable *ht)
 {
        HT_ASSERT(GC_REFCOUNT(ht) == 1);
        if (ht->nTableSize >= HT_MAX_SIZE) {
@@ -170,7 +170,7 @@ static void zend_hash_packed_grow(HashTable *ht)
        HANDLE_UNBLOCK_INTERRUPTIONS();
 }
 
-ZEND_API void zend_hash_real_init(HashTable *ht, zend_bool packed)
+ZEND_API void ZEND_FASTCALL zend_hash_real_init(HashTable *ht, zend_bool packed)
 {
        IS_CONSISTENT(ht);
 
@@ -178,7 +178,7 @@ ZEND_API void zend_hash_real_init(HashTable *ht, zend_bool packed)
        CHECK_INIT(ht, packed);
 }
 
-ZEND_API void zend_hash_packed_to_hash(HashTable *ht)
+ZEND_API void ZEND_FASTCALL zend_hash_packed_to_hash(HashTable *ht)
 {
        void *old_data = HT_GET_DATA_ADDR(ht);
        Bucket *old_buckets = ht->arData;
@@ -194,7 +194,7 @@ ZEND_API void zend_hash_packed_to_hash(HashTable *ht)
        HANDLE_UNBLOCK_INTERRUPTIONS();
 }
 
-ZEND_API void zend_hash_to_packed(HashTable *ht)
+ZEND_API void ZEND_FASTCALL zend_hash_to_packed(HashTable *ht)
 {
        void *old_data = HT_GET_DATA_ADDR(ht);
        Bucket *old_buckets = ht->arData;
@@ -210,7 +210,7 @@ ZEND_API void zend_hash_to_packed(HashTable *ht)
        HANDLE_UNBLOCK_INTERRUPTIONS();
 }
 
-ZEND_API void _zend_hash_init_ex(HashTable *ht, uint32_t nSize, dtor_func_t pDestructor, zend_bool persistent, zend_bool bApplyProtection ZEND_FILE_LINE_DC)
+ZEND_API void ZEND_FASTCALL _zend_hash_init_ex(HashTable *ht, uint32_t nSize, dtor_func_t pDestructor, zend_bool persistent, zend_bool bApplyProtection ZEND_FILE_LINE_DC)
 {
        _zend_hash_init(ht, nSize, pDestructor, persistent ZEND_FILE_LINE_CC);
        if (!bApplyProtection) {
@@ -218,7 +218,7 @@ ZEND_API void _zend_hash_init_ex(HashTable *ht, uint32_t nSize, dtor_func_t pDes
        }
 }
 
-ZEND_API void zend_hash_extend(HashTable *ht, uint32_t nSize, zend_bool packed)
+ZEND_API void ZEND_FASTCALL zend_hash_extend(HashTable *ht, uint32_t nSize, zend_bool packed)
 {
        HT_ASSERT(GC_REFCOUNT(ht) == 1);
        if (nSize == 0) return;
@@ -255,7 +255,7 @@ ZEND_API void zend_hash_extend(HashTable *ht, uint32_t nSize, zend_bool packed)
        }
 }
 
-ZEND_API void zend_hash_set_apply_protection(HashTable *ht, zend_bool bApplyProtection)
+ZEND_API void ZEND_FASTCALL zend_hash_set_apply_protection(HashTable *ht, zend_bool bApplyProtection)
 {
        if (bApplyProtection) {
                ht->u.flags |= HASH_FLAG_APPLY_PROTECTION;
@@ -264,7 +264,7 @@ ZEND_API void zend_hash_set_apply_protection(HashTable *ht, zend_bool bApplyProt
        }
 }
 
-ZEND_API uint32_t zend_hash_iterator_add(HashTable *ht, HashPosition pos)
+ZEND_API uint32_t ZEND_FASTCALL zend_hash_iterator_add(HashTable *ht, HashPosition pos)
 {
        HashTableIterator *iter = EG(ht_iterators);
        HashTableIterator *end  = iter + EG(ht_iterators_count);
@@ -301,7 +301,7 @@ ZEND_API uint32_t zend_hash_iterator_add(HashTable *ht, HashPosition pos)
        return idx;
 }
 
-ZEND_API HashPosition zend_hash_iterator_pos(uint32_t idx, HashTable *ht)
+ZEND_API HashPosition ZEND_FASTCALL zend_hash_iterator_pos(uint32_t idx, HashTable *ht)
 {
        HashTableIterator *iter = EG(ht_iterators) + idx;
 
@@ -321,7 +321,7 @@ ZEND_API HashPosition zend_hash_iterator_pos(uint32_t idx, HashTable *ht)
        return iter->pos;
 }
 
-ZEND_API void zend_hash_iterator_del(uint32_t idx)
+ZEND_API void ZEND_FASTCALL zend_hash_iterator_del(uint32_t idx)
 {
        HashTableIterator *iter = EG(ht_iterators) + idx;
 
@@ -340,7 +340,7 @@ ZEND_API void zend_hash_iterator_del(uint32_t idx)
        }
 }
 
-static zend_never_inline void _zend_hash_iterators_remove(HashTable *ht)
+static zend_never_inline void ZEND_FASTCALL _zend_hash_iterators_remove(HashTable *ht)
 {
        HashTableIterator *iter = EG(ht_iterators);
        HashTableIterator *end  = iter + EG(ht_iterators_used);
@@ -367,7 +367,7 @@ static zend_always_inline void zend_hash_iterators_remove(HashTable *ht)
        }
 }
 
-ZEND_API HashPosition zend_hash_iterators_lower_pos(HashTable *ht, HashPosition start)
+ZEND_API HashPosition ZEND_FASTCALL zend_hash_iterators_lower_pos(HashTable *ht, HashPosition start)
 {
        HashTableIterator *iter = EG(ht_iterators);
        HashTableIterator *end  = iter + EG(ht_iterators_used);
@@ -384,7 +384,7 @@ ZEND_API HashPosition zend_hash_iterators_lower_pos(HashTable *ht, HashPosition
        return res;
 }
 
-ZEND_API void _zend_hash_iterators_update(HashTable *ht, HashPosition from, HashPosition to)
+ZEND_API void ZEND_FASTCALL _zend_hash_iterators_update(HashTable *ht, HashPosition from, HashPosition to)
 {
        HashTableIterator *iter = EG(ht_iterators);
        HashTableIterator *end  = iter + EG(ht_iterators_used);
@@ -527,32 +527,32 @@ add_to_hash:
        return &p->val;
 }
 
-ZEND_API zval *_zend_hash_add_or_update(HashTable *ht, zend_string *key, zval *pData, uint32_t flag ZEND_FILE_LINE_DC)
+ZEND_API zval* ZEND_FASTCALL _zend_hash_add_or_update(HashTable *ht, zend_string *key, zval *pData, uint32_t flag ZEND_FILE_LINE_DC)
 {
        return _zend_hash_add_or_update_i(ht, key, pData, flag ZEND_FILE_LINE_RELAY_CC);
 }
 
-ZEND_API zval *_zend_hash_add(HashTable *ht, zend_string *key, zval *pData ZEND_FILE_LINE_DC)
+ZEND_API zval* ZEND_FASTCALL _zend_hash_add(HashTable *ht, zend_string *key, zval *pData ZEND_FILE_LINE_DC)
 {
        return _zend_hash_add_or_update_i(ht, key, pData, HASH_ADD ZEND_FILE_LINE_RELAY_CC);
 }
 
-ZEND_API zval *_zend_hash_update(HashTable *ht, zend_string *key, zval *pData ZEND_FILE_LINE_DC)
+ZEND_API zval* ZEND_FASTCALL _zend_hash_update(HashTable *ht, zend_string *key, zval *pData ZEND_FILE_LINE_DC)
 {
        return _zend_hash_add_or_update_i(ht, key, pData, HASH_UPDATE ZEND_FILE_LINE_RELAY_CC);
 }
 
-ZEND_API zval *_zend_hash_update_ind(HashTable *ht, zend_string *key, zval *pData ZEND_FILE_LINE_DC)
+ZEND_API zval* ZEND_FASTCALL _zend_hash_update_ind(HashTable *ht, zend_string *key, zval *pData ZEND_FILE_LINE_DC)
 {
        return _zend_hash_add_or_update_i(ht, key, pData, HASH_UPDATE | HASH_UPDATE_INDIRECT ZEND_FILE_LINE_RELAY_CC);
 }
 
-ZEND_API zval *_zend_hash_add_new(HashTable *ht, zend_string *key, zval *pData ZEND_FILE_LINE_DC)
+ZEND_API zval* ZEND_FASTCALL _zend_hash_add_new(HashTable *ht, zend_string *key, zval *pData ZEND_FILE_LINE_DC)
 {
        return _zend_hash_add_or_update_i(ht, key, pData, HASH_ADD_NEW ZEND_FILE_LINE_RELAY_CC);
 }
 
-ZEND_API zval *_zend_hash_str_add_or_update(HashTable *ht, const char *str, size_t len, zval *pData, uint32_t flag ZEND_FILE_LINE_DC)
+ZEND_API zval* ZEND_FASTCALL _zend_hash_str_add_or_update(HashTable *ht, const char *str, size_t len, zval *pData, uint32_t flag ZEND_FILE_LINE_DC)
 {
        zend_string *key = zend_string_init(str, len, ht->u.flags & HASH_FLAG_PERSISTENT);
        zval *ret = _zend_hash_add_or_update_i(ht, key, pData, flag ZEND_FILE_LINE_CC);
@@ -560,7 +560,7 @@ ZEND_API zval *_zend_hash_str_add_or_update(HashTable *ht, const char *str, size
        return ret;
 }
 
-ZEND_API zval *_zend_hash_str_update(HashTable *ht, const char *str, size_t len, zval *pData ZEND_FILE_LINE_DC)
+ZEND_API zval* ZEND_FASTCALL _zend_hash_str_update(HashTable *ht, const char *str, size_t len, zval *pData ZEND_FILE_LINE_DC)
 {
        zend_string *key = zend_string_init(str, len, ht->u.flags & HASH_FLAG_PERSISTENT);
        zval *ret = _zend_hash_add_or_update_i(ht, key, pData, HASH_UPDATE ZEND_FILE_LINE_CC);
@@ -568,7 +568,7 @@ ZEND_API zval *_zend_hash_str_update(HashTable *ht, const char *str, size_t len,
        return ret;
 }
 
-ZEND_API zval *_zend_hash_str_update_ind(HashTable *ht, const char *str, size_t len, zval *pData ZEND_FILE_LINE_DC)
+ZEND_API zval* ZEND_FASTCALL _zend_hash_str_update_ind(HashTable *ht, const char *str, size_t len, zval *pData ZEND_FILE_LINE_DC)
 {
        zend_string *key = zend_string_init(str, len, ht->u.flags & HASH_FLAG_PERSISTENT);
        zval *ret = _zend_hash_add_or_update_i(ht, key, pData, HASH_UPDATE | HASH_UPDATE_INDIRECT ZEND_FILE_LINE_CC);
@@ -576,7 +576,7 @@ ZEND_API zval *_zend_hash_str_update_ind(HashTable *ht, const char *str, size_t
        return ret;
 }
 
-ZEND_API zval *_zend_hash_str_add(HashTable *ht, const char *str, size_t len, zval *pData ZEND_FILE_LINE_DC)
+ZEND_API zval* ZEND_FASTCALL _zend_hash_str_add(HashTable *ht, const char *str, size_t len, zval *pData ZEND_FILE_LINE_DC)
 {
        zend_string *key = zend_string_init(str, len, ht->u.flags & HASH_FLAG_PERSISTENT);
        zval *ret = _zend_hash_add_or_update_i(ht, key, pData, HASH_ADD ZEND_FILE_LINE_CC);
@@ -584,7 +584,7 @@ ZEND_API zval *_zend_hash_str_add(HashTable *ht, const char *str, size_t len, zv
        return ret;
 }
 
-ZEND_API zval *_zend_hash_str_add_new(HashTable *ht, const char *str, size_t len, zval *pData ZEND_FILE_LINE_DC)
+ZEND_API zval* ZEND_FASTCALL _zend_hash_str_add_new(HashTable *ht, const char *str, size_t len, zval *pData ZEND_FILE_LINE_DC)
 {
        zend_string *key = zend_string_init(str, len, ht->u.flags & HASH_FLAG_PERSISTENT);
        zval *ret = _zend_hash_add_or_update_i(ht, key, pData, HASH_ADD_NEW ZEND_FILE_LINE_CC);
@@ -592,7 +592,7 @@ ZEND_API zval *_zend_hash_str_add_new(HashTable *ht, const char *str, size_t len
        return ret;
 }
 
-ZEND_API zval *zend_hash_index_add_empty_element(HashTable *ht, zend_ulong h)
+ZEND_API zval* ZEND_FASTCALL zend_hash_index_add_empty_element(HashTable *ht, zend_ulong h)
 {
 
        zval dummy;
@@ -601,7 +601,7 @@ ZEND_API zval *zend_hash_index_add_empty_element(HashTable *ht, zend_ulong h)
        return zend_hash_index_add(ht, h, &dummy);
 }
 
-ZEND_API zval *zend_hash_add_empty_element(HashTable *ht, zend_string *key)
+ZEND_API zval* ZEND_FASTCALL zend_hash_add_empty_element(HashTable *ht, zend_string *key)
 {
 
        zval dummy;
@@ -610,7 +610,7 @@ ZEND_API zval *zend_hash_add_empty_element(HashTable *ht, zend_string *key)
        return zend_hash_add(ht, key, &dummy);
 }
 
-ZEND_API zval *zend_hash_str_add_empty_element(HashTable *ht, const char *str, size_t len)
+ZEND_API zval* ZEND_FASTCALL zend_hash_str_add_empty_element(HashTable *ht, const char *str, size_t len)
 {
 
        zval dummy;
@@ -741,37 +741,37 @@ add_to_hash:
        return &p->val;
 }
 
-ZEND_API zval *_zend_hash_index_add_or_update(HashTable *ht, zend_ulong h, zval *pData, uint32_t flag ZEND_FILE_LINE_DC)
+ZEND_API zval* ZEND_FASTCALL _zend_hash_index_add_or_update(HashTable *ht, zend_ulong h, zval *pData, uint32_t flag ZEND_FILE_LINE_DC)
 {
        return _zend_hash_index_add_or_update_i(ht, h, pData, flag ZEND_FILE_LINE_RELAY_CC);
 }
 
-ZEND_API zval *_zend_hash_index_add(HashTable *ht, zend_ulong h, zval *pData ZEND_FILE_LINE_DC)
+ZEND_API zval* ZEND_FASTCALL _zend_hash_index_add(HashTable *ht, zend_ulong h, zval *pData ZEND_FILE_LINE_DC)
 {
        return _zend_hash_index_add_or_update_i(ht, h, pData, HASH_ADD ZEND_FILE_LINE_RELAY_CC);
 }
 
-ZEND_API zval *_zend_hash_index_add_new(HashTable *ht, zend_ulong h, zval *pData ZEND_FILE_LINE_DC)
+ZEND_API zval* ZEND_FASTCALL _zend_hash_index_add_new(HashTable *ht, zend_ulong h, zval *pData ZEND_FILE_LINE_DC)
 {
        return _zend_hash_index_add_or_update_i(ht, h, pData, HASH_ADD | HASH_ADD_NEW ZEND_FILE_LINE_RELAY_CC);
 }
 
-ZEND_API zval *_zend_hash_index_update(HashTable *ht, zend_ulong h, zval *pData ZEND_FILE_LINE_DC)
+ZEND_API zval* ZEND_FASTCALL _zend_hash_index_update(HashTable *ht, zend_ulong h, zval *pData ZEND_FILE_LINE_DC)
 {
        return _zend_hash_index_add_or_update_i(ht, h, pData, HASH_UPDATE ZEND_FILE_LINE_RELAY_CC);
 }
 
-ZEND_API zval *_zend_hash_next_index_insert(HashTable *ht, zval *pData ZEND_FILE_LINE_DC)
+ZEND_API zval* ZEND_FASTCALL _zend_hash_next_index_insert(HashTable *ht, zval *pData ZEND_FILE_LINE_DC)
 {
        return _zend_hash_index_add_or_update_i(ht, ht->nNextFreeElement, pData, HASH_ADD | HASH_ADD_NEXT ZEND_FILE_LINE_RELAY_CC);
 }
 
-ZEND_API zval *_zend_hash_next_index_insert_new(HashTable *ht, zval *pData ZEND_FILE_LINE_DC)
+ZEND_API zval* ZEND_FASTCALL _zend_hash_next_index_insert_new(HashTable *ht, zval *pData ZEND_FILE_LINE_DC)
 {
        return _zend_hash_index_add_or_update_i(ht, ht->nNextFreeElement, pData, HASH_ADD | HASH_ADD_NEW | HASH_ADD_NEXT ZEND_FILE_LINE_RELAY_CC);
 }
 
-static void zend_hash_do_resize(HashTable *ht)
+static void ZEND_FASTCALL zend_hash_do_resize(HashTable *ht)
 {
 
        IS_CONSISTENT(ht);
@@ -798,7 +798,7 @@ static void zend_hash_do_resize(HashTable *ht)
        }
 }
 
-ZEND_API int zend_hash_rehash(HashTable *ht)
+ZEND_API int ZEND_FASTCALL zend_hash_rehash(HashTable *ht)
 {
        Bucket *p;
        uint32_t nIndex, i, j;
@@ -921,7 +921,7 @@ static zend_always_inline void _zend_hash_del_el(HashTable *ht, uint32_t idx, Bu
        _zend_hash_del_el_ex(ht, idx, p, prev);
 }
 
-ZEND_API int zend_hash_del(HashTable *ht, zend_string *key)
+ZEND_API int ZEND_FASTCALL zend_hash_del(HashTable *ht, zend_string *key)
 {
        zend_ulong h;
        uint32_t nIndex;
@@ -952,7 +952,7 @@ ZEND_API int zend_hash_del(HashTable *ht, zend_string *key)
        return FAILURE;
 }
 
-ZEND_API int zend_hash_del_ind(HashTable *ht, zend_string *key)
+ZEND_API int ZEND_FASTCALL zend_hash_del_ind(HashTable *ht, zend_string *key)
 {
        zend_ulong h;
        uint32_t nIndex;
@@ -996,7 +996,7 @@ ZEND_API int zend_hash_del_ind(HashTable *ht, zend_string *key)
        return FAILURE;
 }
 
-ZEND_API int zend_hash_str_del(HashTable *ht, const char *str, size_t len)
+ZEND_API int ZEND_FASTCALL zend_hash_str_del(HashTable *ht, const char *str, size_t len)
 {
        zend_ulong h;
        uint32_t nIndex;
@@ -1039,7 +1039,7 @@ ZEND_API int zend_hash_str_del(HashTable *ht, const char *str, size_t len)
        return FAILURE;
 }
 
-ZEND_API int zend_hash_str_del_ind(HashTable *ht, const char *str, size_t len)
+ZEND_API int ZEND_FASTCALL zend_hash_str_del_ind(HashTable *ht, const char *str, size_t len)
 {
        zend_ulong h;
        uint32_t nIndex;
@@ -1069,7 +1069,7 @@ ZEND_API int zend_hash_str_del_ind(HashTable *ht, const char *str, size_t len)
        return FAILURE;
 }
 
-ZEND_API int zend_hash_index_del(HashTable *ht, zend_ulong h)
+ZEND_API int ZEND_FASTCALL zend_hash_index_del(HashTable *ht, zend_ulong h)
 {
        uint32_t nIndex;
        uint32_t idx;
@@ -1104,7 +1104,7 @@ ZEND_API int zend_hash_index_del(HashTable *ht, zend_ulong h)
        return FAILURE;
 }
 
-ZEND_API void zend_hash_destroy(HashTable *ht)
+ZEND_API void ZEND_FASTCALL zend_hash_destroy(HashTable *ht)
 {
        Bucket *p, *end;
 
@@ -1153,7 +1153,7 @@ ZEND_API void zend_hash_destroy(HashTable *ht)
        pefree(HT_GET_DATA_ADDR(ht), ht->u.flags & HASH_FLAG_PERSISTENT);
 }
 
-ZEND_API void zend_array_destroy(HashTable *ht)
+ZEND_API void ZEND_FASTCALL zend_array_destroy(HashTable *ht)
 {
        Bucket *p, *end;
 
@@ -1196,7 +1196,7 @@ free_ht:
        FREE_HASHTABLE(ht);
 }
 
-ZEND_API void zend_hash_clean(HashTable *ht)
+ZEND_API void ZEND_FASTCALL zend_hash_clean(HashTable *ht)
 {
        Bucket *p, *end;
 
@@ -1244,7 +1244,7 @@ ZEND_API void zend_hash_clean(HashTable *ht)
        ht->nInternalPointer = HT_INVALID_IDX;
 }
 
-ZEND_API void zend_symtable_clean(HashTable *ht)
+ZEND_API void ZEND_FASTCALL zend_symtable_clean(HashTable *ht)
 {
        Bucket *p, *end;
 
@@ -1272,7 +1272,7 @@ ZEND_API void zend_symtable_clean(HashTable *ht)
        ht->nInternalPointer = HT_INVALID_IDX;
 }
 
-ZEND_API void zend_hash_graceful_destroy(HashTable *ht)
+ZEND_API void ZEND_FASTCALL zend_hash_graceful_destroy(HashTable *ht)
 {
        uint32_t idx;
        Bucket *p;
@@ -1292,7 +1292,7 @@ ZEND_API void zend_hash_graceful_destroy(HashTable *ht)
        SET_INCONSISTENT(HT_DESTROYED);
 }
 
-ZEND_API void zend_hash_graceful_reverse_destroy(HashTable *ht)
+ZEND_API void ZEND_FASTCALL zend_hash_graceful_reverse_destroy(HashTable *ht)
 {
        uint32_t idx;
        Bucket *p;
@@ -1324,7 +1324,7 @@ ZEND_API void zend_hash_graceful_reverse_destroy(HashTable *ht)
  * ZEND_HASH_APPLY_REMOVE - delete the element, combineable with the former
  */
 
-ZEND_API void zend_hash_apply(HashTable *ht, apply_func_t apply_func)
+ZEND_API void ZEND_FASTCALL zend_hash_apply(HashTable *ht, apply_func_t apply_func)
 {
        uint32_t idx;
        Bucket *p;
@@ -1351,7 +1351,7 @@ ZEND_API void zend_hash_apply(HashTable *ht, apply_func_t apply_func)
 }
 
 
-ZEND_API void zend_hash_apply_with_argument(HashTable *ht, apply_func_arg_t apply_func, void *argument)
+ZEND_API void ZEND_FASTCALL zend_hash_apply_with_argument(HashTable *ht, apply_func_arg_t apply_func, void *argument)
 {
     uint32_t idx;
        Bucket *p;
@@ -1378,7 +1378,7 @@ ZEND_API void zend_hash_apply_with_argument(HashTable *ht, apply_func_arg_t appl
 }
 
 
-ZEND_API void zend_hash_apply_with_arguments(HashTable *ht, apply_func_args_t apply_func, int num_args, ...)
+ZEND_API void ZEND_FASTCALL zend_hash_apply_with_arguments(HashTable *ht, apply_func_args_t apply_func, int num_args, ...)
 {
        uint32_t idx;
        Bucket *p;
@@ -1414,7 +1414,7 @@ ZEND_API void zend_hash_apply_with_arguments(HashTable *ht, apply_func_args_t ap
 }
 
 
-ZEND_API void zend_hash_reverse_apply(HashTable *ht, apply_func_t apply_func)
+ZEND_API void ZEND_FASTCALL zend_hash_reverse_apply(HashTable *ht, apply_func_t apply_func)
 {
        uint32_t idx;
        Bucket *p;
@@ -1443,7 +1443,7 @@ ZEND_API void zend_hash_reverse_apply(HashTable *ht, apply_func_t apply_func)
 }
 
 
-ZEND_API void zend_hash_copy(HashTable *target, HashTable *source, copy_ctor_func_t pCopyConstructor)
+ZEND_API void ZEND_FASTCALL zend_hash_copy(HashTable *target, HashTable *source, copy_ctor_func_t pCopyConstructor)
 {
     uint32_t idx;
        Bucket *p;
@@ -1489,7 +1489,7 @@ ZEND_API void zend_hash_copy(HashTable *target, HashTable *source, copy_ctor_fun
 }
 
 
-ZEND_API HashTable *zend_array_dup(HashTable *source)
+ZEND_API HashTable* ZEND_FASTCALL zend_array_dup(HashTable *source)
 {
     uint32_t idx, target_idx;
        uint32_t nIndex;
@@ -1614,7 +1614,7 @@ ZEND_API HashTable *zend_array_dup(HashTable *source)
 }
 
 
-ZEND_API void _zend_hash_merge(HashTable *target, HashTable *source, copy_ctor_func_t pCopyConstructor, zend_bool overwrite ZEND_FILE_LINE_DC)
+ZEND_API void ZEND_FASTCALL _zend_hash_merge(HashTable *target, HashTable *source, copy_ctor_func_t pCopyConstructor, zend_bool overwrite ZEND_FILE_LINE_DC)
 {
     uint32_t idx;
        Bucket *p;
@@ -1652,7 +1652,7 @@ ZEND_API void _zend_hash_merge(HashTable *target, HashTable *source, copy_ctor_f
 }
 
 
-static zend_bool zend_hash_replace_checker_wrapper(HashTable *target, zval *source_data, Bucket *p, void *pParam, merge_checker_func_t merge_checker_func)
+static zend_bool ZEND_FASTCALL zend_hash_replace_checker_wrapper(HashTable *target, zval *source_data, Bucket *p, void *pParam, merge_checker_func_t merge_checker_func)
 {
        zend_hash_key hash_key;
 
@@ -1662,7 +1662,7 @@ static zend_bool zend_hash_replace_checker_wrapper(HashTable *target, zval *sour
 }
 
 
-ZEND_API void zend_hash_merge_ex(HashTable *target, HashTable *source, copy_ctor_func_t pCopyConstructor, merge_checker_func_t pMergeSource, void *pParam)
+ZEND_API void ZEND_FASTCALL zend_hash_merge_ex(HashTable *target, HashTable *source, copy_ctor_func_t pCopyConstructor, merge_checker_func_t pMergeSource, void *pParam)
 {
        uint32_t idx;
        Bucket *p;
@@ -1696,7 +1696,7 @@ ZEND_API void zend_hash_merge_ex(HashTable *target, HashTable *source, copy_ctor
  * data is returned in pData. The reason is that there's no reason
  * someone using the hash table might not want to have NULL data
  */
-ZEND_API zval *zend_hash_find(const HashTable *ht, zend_string *key)
+ZEND_API zval* ZEND_FASTCALL zend_hash_find(const HashTable *ht, zend_string *key)
 {
        Bucket *p;
 
@@ -1706,7 +1706,7 @@ ZEND_API zval *zend_hash_find(const HashTable *ht, zend_string *key)
        return p ? &p->val : NULL;
 }
 
-ZEND_API zval *zend_hash_str_find(const HashTable *ht, const char *str, size_t len)
+ZEND_API zval* ZEND_FASTCALL zend_hash_str_find(const HashTable *ht, const char *str, size_t len)
 {
        zend_ulong h;
        Bucket *p;
@@ -1718,7 +1718,7 @@ ZEND_API zval *zend_hash_str_find(const HashTable *ht, const char *str, size_t l
        return p ? &p->val : NULL;
 }
 
-ZEND_API zend_bool zend_hash_exists(const HashTable *ht, zend_string *key)
+ZEND_API zend_bool ZEND_FASTCALL zend_hash_exists(const HashTable *ht, zend_string *key)
 {
        Bucket *p;
 
@@ -1728,7 +1728,7 @@ ZEND_API zend_bool zend_hash_exists(const HashTable *ht, zend_string *key)
        return p ? 1 : 0;
 }
 
-ZEND_API zend_bool zend_hash_str_exists(const HashTable *ht, const char *str, size_t len)
+ZEND_API zend_bool ZEND_FASTCALL zend_hash_str_exists(const HashTable *ht, const char *str, size_t len)
 {
        zend_ulong h;
        Bucket *p;
@@ -1740,7 +1740,7 @@ ZEND_API zend_bool zend_hash_str_exists(const HashTable *ht, const char *str, si
        return p ? 1 : 0;
 }
 
-ZEND_API zval *zend_hash_index_find(const HashTable *ht, zend_ulong h)
+ZEND_API zval* ZEND_FASTCALL zend_hash_index_find(const HashTable *ht, zend_ulong h)
 {
        Bucket *p;
 
@@ -1761,7 +1761,7 @@ ZEND_API zval *zend_hash_index_find(const HashTable *ht, zend_ulong h)
 }
 
 
-ZEND_API zend_bool zend_hash_index_exists(const HashTable *ht, zend_ulong h)
+ZEND_API zend_bool ZEND_FASTCALL zend_hash_index_exists(const HashTable *ht, zend_ulong h)
 {
        Bucket *p;
 
@@ -1781,7 +1781,7 @@ ZEND_API zend_bool zend_hash_index_exists(const HashTable *ht, zend_ulong h)
 }
 
 
-ZEND_API void zend_hash_internal_pointer_reset_ex(HashTable *ht, HashPosition *pos)
+ZEND_API void ZEND_FASTCALL zend_hash_internal_pointer_reset_ex(HashTable *ht, HashPosition *pos)
 {
     uint32_t idx;
 
@@ -1801,7 +1801,7 @@ ZEND_API void zend_hash_internal_pointer_reset_ex(HashTable *ht, HashPosition *p
 /* This function will be extremely optimized by remembering
  * the end of the list
  */
-ZEND_API void zend_hash_internal_pointer_end_ex(HashTable *ht, HashPosition *pos)
+ZEND_API void ZEND_FASTCALL zend_hash_internal_pointer_end_ex(HashTable *ht, HashPosition *pos)
 {
        uint32_t idx;
 
@@ -1820,7 +1820,7 @@ ZEND_API void zend_hash_internal_pointer_end_ex(HashTable *ht, HashPosition *pos
 }
 
 
-ZEND_API int zend_hash_move_forward_ex(HashTable *ht, HashPosition *pos)
+ZEND_API int ZEND_FASTCALL zend_hash_move_forward_ex(HashTable *ht, HashPosition *pos)
 {
        uint32_t idx = *pos;
 
@@ -1844,7 +1844,7 @@ ZEND_API int zend_hash_move_forward_ex(HashTable *ht, HashPosition *pos)
        }
 }
 
-ZEND_API int zend_hash_move_backwards_ex(HashTable *ht, HashPosition *pos)
+ZEND_API int ZEND_FASTCALL zend_hash_move_backwards_ex(HashTable *ht, HashPosition *pos)
 {
        uint32_t idx = *pos;
 
@@ -1868,7 +1868,7 @@ ZEND_API int zend_hash_move_backwards_ex(HashTable *ht, HashPosition *pos)
 
 
 /* This function should be made binary safe  */
-ZEND_API int zend_hash_get_current_key_ex(const HashTable *ht, zend_string **str_index, zend_ulong *num_index, HashPosition *pos)
+ZEND_API int ZEND_FASTCALL zend_hash_get_current_key_ex(const HashTable *ht, zend_string **str_index, zend_ulong *num_index, HashPosition *pos)
 {
        uint32_t idx = *pos;
        Bucket *p;
@@ -1887,7 +1887,7 @@ ZEND_API int zend_hash_get_current_key_ex(const HashTable *ht, zend_string **str
        return HASH_KEY_NON_EXISTENT;
 }
 
-ZEND_API void zend_hash_get_current_key_zval_ex(const HashTable *ht, zval *key, HashPosition *pos)
+ZEND_API void ZEND_FASTCALL zend_hash_get_current_key_zval_ex(const HashTable *ht, zval *key, HashPosition *pos)
 {
        uint32_t idx = *pos;
        Bucket *p;
@@ -1905,7 +1905,7 @@ ZEND_API void zend_hash_get_current_key_zval_ex(const HashTable *ht, zval *key,
        }
 }
 
-ZEND_API int zend_hash_get_current_key_type_ex(HashTable *ht, HashPosition *pos)
+ZEND_API int ZEND_FASTCALL zend_hash_get_current_key_type_ex(HashTable *ht, HashPosition *pos)
 {
     uint32_t idx = *pos;
        Bucket *p;
@@ -1923,7 +1923,7 @@ ZEND_API int zend_hash_get_current_key_type_ex(HashTable *ht, HashPosition *pos)
 }
 
 
-ZEND_API zval *zend_hash_get_current_data_ex(HashTable *ht, HashPosition *pos)
+ZEND_API zval* ZEND_FASTCALL zend_hash_get_current_data_ex(HashTable *ht, HashPosition *pos)
 {
        uint32_t idx = *pos;
        Bucket *p;
@@ -1937,7 +1937,8 @@ ZEND_API zval *zend_hash_get_current_data_ex(HashTable *ht, HashPosition *pos)
        }
 }
 
-ZEND_API void zend_hash_bucket_swap(Bucket *p, Bucket *q) {
+ZEND_API void zend_hash_bucket_swap(Bucket *p, Bucket *q)
+{
        zval val;
        zend_ulong h;
        zend_string *key;
@@ -1955,7 +1956,8 @@ ZEND_API void zend_hash_bucket_swap(Bucket *p, Bucket *q) {
        q->key = key;
 }
 
-ZEND_API void zend_hash_bucket_renum_swap(Bucket *p, Bucket *q) {
+ZEND_API void zend_hash_bucket_renum_swap(Bucket *p, Bucket *q)
+{
        zval val;
 
        ZVAL_COPY_VALUE(&val, &p->val);
@@ -1963,7 +1965,8 @@ ZEND_API void zend_hash_bucket_renum_swap(Bucket *p, Bucket *q) {
        ZVAL_COPY_VALUE(&q->val, &val);
 }
 
-ZEND_API void zend_hash_bucket_packed_swap(Bucket *p, Bucket *q) {
+ZEND_API void zend_hash_bucket_packed_swap(Bucket *p, Bucket *q)
+{
        zval val;
        zend_ulong h;
 
@@ -1977,7 +1980,7 @@ ZEND_API void zend_hash_bucket_packed_swap(Bucket *p, Bucket *q) {
        q->h = h;
 }
 
-ZEND_API int zend_hash_sort_ex(HashTable *ht, sort_func_t sort, compare_func_t compar, zend_bool renumber)
+ZEND_API int ZEND_FASTCALL zend_hash_sort_ex(HashTable *ht, sort_func_t sort, compare_func_t compar, zend_bool renumber)
 {
        Bucket *p;
        uint32_t i, j;
@@ -2155,7 +2158,7 @@ ZEND_API int zend_hash_compare(HashTable *ht1, HashTable *ht2, compare_func_t co
 }
 
 
-ZEND_API zval *zend_hash_minmax(const HashTable *ht, compare_func_t compar, uint32_t flag)
+ZEND_API zval* ZEND_FASTCALL zend_hash_minmax(const HashTable *ht, compare_func_t compar, uint32_t flag)
 {
        uint32_t idx;
        Bucket *p, *res;
@@ -2192,7 +2195,7 @@ ZEND_API zval *zend_hash_minmax(const HashTable *ht, compare_func_t compar, uint
        return &res->val;
 }
 
-ZEND_API int _zend_handle_numeric_str_ex(const char *key, size_t length, zend_ulong *idx)
+ZEND_API int ZEND_FASTCALL _zend_handle_numeric_str_ex(const char *key, size_t length, zend_ulong *idx)
 {
        register const char *tmp = key;
 
index 8767aee45894f911c814e6121751c4431b619cfd..9b7050cfdb6f188bff8408599a98bf6352776fab 100644 (file)
@@ -51,24 +51,24 @@ typedef zend_bool (*merge_checker_func_t)(HashTable *target_ht, zval *source_dat
 BEGIN_EXTERN_C()
 
 /* startup/shutdown */
-ZEND_API void _zend_hash_init(HashTable *ht, uint32_t nSize, dtor_func_t pDestructor, zend_bool persistent ZEND_FILE_LINE_DC);
-ZEND_API void _zend_hash_init_ex(HashTable *ht, uint32_t nSize, dtor_func_t pDestructor, zend_bool persistent, zend_bool bApplyProtection ZEND_FILE_LINE_DC);
-ZEND_API void zend_hash_destroy(HashTable *ht);
-ZEND_API void zend_hash_clean(HashTable *ht);
+ZEND_API void ZEND_FASTCALL _zend_hash_init(HashTable *ht, uint32_t nSize, dtor_func_t pDestructor, zend_bool persistent ZEND_FILE_LINE_DC);
+ZEND_API void ZEND_FASTCALL _zend_hash_init_ex(HashTable *ht, uint32_t nSize, dtor_func_t pDestructor, zend_bool persistent, zend_bool bApplyProtection ZEND_FILE_LINE_DC);
+ZEND_API void ZEND_FASTCALL zend_hash_destroy(HashTable *ht);
+ZEND_API void ZEND_FASTCALL zend_hash_clean(HashTable *ht);
 #define zend_hash_init(ht, nSize, pHashFunction, pDestructor, persistent)                                              _zend_hash_init((ht), (nSize), (pDestructor), (persistent) ZEND_FILE_LINE_CC)
 #define zend_hash_init_ex(ht, nSize, pHashFunction, pDestructor, persistent, bApplyProtection)         _zend_hash_init_ex((ht), (nSize), (pDestructor), (persistent), (bApplyProtection) ZEND_FILE_LINE_CC)
 
-ZEND_API void zend_hash_real_init(HashTable *ht, zend_bool packed);
-ZEND_API void zend_hash_packed_to_hash(HashTable *ht);
-ZEND_API void zend_hash_to_packed(HashTable *ht);
-ZEND_API void zend_hash_extend(HashTable *ht, uint32_t nSize, zend_bool packed);
+ZEND_API void ZEND_FASTCALL zend_hash_real_init(HashTable *ht, zend_bool packed);
+ZEND_API void ZEND_FASTCALL zend_hash_packed_to_hash(HashTable *ht);
+ZEND_API void ZEND_FASTCALL zend_hash_to_packed(HashTable *ht);
+ZEND_API void ZEND_FASTCALL zend_hash_extend(HashTable *ht, uint32_t nSize, zend_bool packed);
 
 /* additions/updates/changes */
-ZEND_API zval *_zend_hash_add_or_update(HashTable *ht, zend_string *key, zval *pData, uint32_t flag ZEND_FILE_LINE_DC);
-ZEND_API zval *_zend_hash_update(HashTable *ht, zend_string *key,zval *pData ZEND_FILE_LINE_DC);
-ZEND_API zval *_zend_hash_update_ind(HashTable *ht, zend_string *key,zval *pData ZEND_FILE_LINE_DC);
-ZEND_API zval *_zend_hash_add(HashTable *ht, zend_string *key,zval *pData ZEND_FILE_LINE_DC);
-ZEND_API zval *_zend_hash_add_new(HashTable *ht, zend_string *key,zval *pData ZEND_FILE_LINE_DC);
+ZEND_API zval* ZEND_FASTCALL _zend_hash_add_or_update(HashTable *ht, zend_string *key, zval *pData, uint32_t flag ZEND_FILE_LINE_DC);
+ZEND_API zval* ZEND_FASTCALL _zend_hash_update(HashTable *ht, zend_string *key,zval *pData ZEND_FILE_LINE_DC);
+ZEND_API zval* ZEND_FASTCALL _zend_hash_update_ind(HashTable *ht, zend_string *key,zval *pData ZEND_FILE_LINE_DC);
+ZEND_API zval* ZEND_FASTCALL _zend_hash_add(HashTable *ht, zend_string *key,zval *pData ZEND_FILE_LINE_DC);
+ZEND_API zval* ZEND_FASTCALL _zend_hash_add_new(HashTable *ht, zend_string *key,zval *pData ZEND_FILE_LINE_DC);
 
 #define zend_hash_update(ht, key, pData) \
                _zend_hash_update(ht, key, pData ZEND_FILE_LINE_CC)
@@ -79,11 +79,11 @@ ZEND_API zval *_zend_hash_add_new(HashTable *ht, zend_string *key,zval *pData ZE
 #define zend_hash_add_new(ht, key, pData) \
                _zend_hash_add_new(ht, key, pData ZEND_FILE_LINE_CC)
 
-ZEND_API zval *_zend_hash_str_add_or_update(HashTable *ht, const char *key, size_t len, zval *pData, uint32_t flag ZEND_FILE_LINE_DC);
-ZEND_API zval *_zend_hash_str_update(HashTable *ht, const char *key, size_t len, zval *pData ZEND_FILE_LINE_DC);
-ZEND_API zval *_zend_hash_str_update_ind(HashTable *ht, const char *key, size_t len, zval *pData ZEND_FILE_LINE_DC);
-ZEND_API zval *_zend_hash_str_add(HashTable *ht, const char *key, size_t len, zval *pData ZEND_FILE_LINE_DC);
-ZEND_API zval *_zend_hash_str_add_new(HashTable *ht, const char *key, size_t len, zval *pData ZEND_FILE_LINE_DC);
+ZEND_API zval* ZEND_FASTCALL _zend_hash_str_add_or_update(HashTable *ht, const char *key, size_t len, zval *pData, uint32_t flag ZEND_FILE_LINE_DC);
+ZEND_API zval* ZEND_FASTCALL _zend_hash_str_update(HashTable *ht, const char *key, size_t len, zval *pData ZEND_FILE_LINE_DC);
+ZEND_API zval* ZEND_FASTCALL _zend_hash_str_update_ind(HashTable *ht, const char *key, size_t len, zval *pData ZEND_FILE_LINE_DC);
+ZEND_API zval* ZEND_FASTCALL _zend_hash_str_add(HashTable *ht, const char *key, size_t len, zval *pData ZEND_FILE_LINE_DC);
+ZEND_API zval* ZEND_FASTCALL _zend_hash_str_add_new(HashTable *ht, const char *key, size_t len, zval *pData ZEND_FILE_LINE_DC);
 
 #define zend_hash_str_update(ht, key, len, pData) \
                _zend_hash_str_update(ht, key, len, pData ZEND_FILE_LINE_CC)
@@ -94,12 +94,12 @@ ZEND_API zval *_zend_hash_str_add_new(HashTable *ht, const char *key, size_t len
 #define zend_hash_str_add_new(ht, key, len, pData) \
                _zend_hash_str_add_new(ht, key, len, pData ZEND_FILE_LINE_CC)
 
-ZEND_API zval *_zend_hash_index_add_or_update(HashTable *ht, zend_ulong h, zval *pData, uint32_t flag ZEND_FILE_LINE_DC);
-ZEND_API zval *_zend_hash_index_add(HashTable *ht, zend_ulong h, zval *pData ZEND_FILE_LINE_DC);
-ZEND_API zval *_zend_hash_index_add_new(HashTable *ht, zend_ulong h, zval *pData ZEND_FILE_LINE_DC);
-ZEND_API zval *_zend_hash_index_update(HashTable *ht, zend_ulong h, zval *pData ZEND_FILE_LINE_DC);
-ZEND_API zval *_zend_hash_next_index_insert(HashTable *ht, zval *pData ZEND_FILE_LINE_DC);
-ZEND_API zval *_zend_hash_next_index_insert_new(HashTable *ht, zval *pData ZEND_FILE_LINE_DC);
+ZEND_API zval* ZEND_FASTCALL _zend_hash_index_add_or_update(HashTable *ht, zend_ulong h, zval *pData, uint32_t flag ZEND_FILE_LINE_DC);
+ZEND_API zval* ZEND_FASTCALL _zend_hash_index_add(HashTable *ht, zend_ulong h, zval *pData ZEND_FILE_LINE_DC);
+ZEND_API zval* ZEND_FASTCALL _zend_hash_index_add_new(HashTable *ht, zend_ulong h, zval *pData ZEND_FILE_LINE_DC);
+ZEND_API zval* ZEND_FASTCALL _zend_hash_index_update(HashTable *ht, zend_ulong h, zval *pData ZEND_FILE_LINE_DC);
+ZEND_API zval* ZEND_FASTCALL _zend_hash_next_index_insert(HashTable *ht, zval *pData ZEND_FILE_LINE_DC);
+ZEND_API zval* ZEND_FASTCALL _zend_hash_next_index_insert_new(HashTable *ht, zval *pData ZEND_FILE_LINE_DC);
 
 #define zend_hash_index_add(ht, h, pData) \
                _zend_hash_index_add(ht, h, pData ZEND_FILE_LINE_CC)
@@ -112,9 +112,9 @@ ZEND_API zval *_zend_hash_next_index_insert_new(HashTable *ht, zval *pData ZEND_
 #define zend_hash_next_index_insert_new(ht, pData) \
                _zend_hash_next_index_insert_new(ht, pData ZEND_FILE_LINE_CC)
 
-ZEND_API zval *zend_hash_index_add_empty_element(HashTable *ht, zend_ulong h);
-ZEND_API zval *zend_hash_add_empty_element(HashTable *ht, zend_string *key);
-ZEND_API zval *zend_hash_str_add_empty_element(HashTable *ht, const char *key, size_t len);
+ZEND_API zval* ZEND_FASTCALL zend_hash_index_add_empty_element(HashTable *ht, zend_ulong h);
+ZEND_API zval* ZEND_FASTCALL zend_hash_add_empty_element(HashTable *ht, zend_string *key);
+ZEND_API zval* ZEND_FASTCALL zend_hash_str_add_empty_element(HashTable *ht, const char *key, size_t len);
 
 #define ZEND_HASH_APPLY_KEEP                           0
 #define ZEND_HASH_APPLY_REMOVE                         1<<0
@@ -124,11 +124,11 @@ typedef int (*apply_func_t)(zval *pDest);
 typedef int (*apply_func_arg_t)(zval *pDest, void *argument);
 typedef int (*apply_func_args_t)(zval *pDest, int num_args, va_list args, zend_hash_key *hash_key);
 
-ZEND_API void zend_hash_graceful_destroy(HashTable *ht);
-ZEND_API void zend_hash_graceful_reverse_destroy(HashTable *ht);
-ZEND_API void zend_hash_apply(HashTable *ht, apply_func_t apply_func);
-ZEND_API void zend_hash_apply_with_argument(HashTable *ht, apply_func_arg_t apply_func, void *);
-ZEND_API void zend_hash_apply_with_arguments(HashTable *ht, apply_func_args_t apply_func, int, ...);
+ZEND_API void ZEND_FASTCALL zend_hash_graceful_destroy(HashTable *ht);
+ZEND_API void ZEND_FASTCALL zend_hash_graceful_reverse_destroy(HashTable *ht);
+ZEND_API void ZEND_FASTCALL zend_hash_apply(HashTable *ht, apply_func_t apply_func);
+ZEND_API void ZEND_FASTCALL zend_hash_apply_with_argument(HashTable *ht, apply_func_arg_t apply_func, void *);
+ZEND_API void ZEND_FASTCALL zend_hash_apply_with_arguments(HashTable *ht, apply_func_args_t apply_func, int, ...);
 
 /* This function should be used with special care (in other words,
  * it should usually not be used).  When used with the ZEND_HASH_APPLY_STOP
@@ -136,37 +136,37 @@ ZEND_API void zend_hash_apply_with_arguments(HashTable *ht, apply_func_args_t ap
  * Also, it does not provide the same kind of reentrancy protection that
  * the standard apply functions do.
  */
-ZEND_API void zend_hash_reverse_apply(HashTable *ht, apply_func_t apply_func);
+ZEND_API void ZEND_FASTCALL zend_hash_reverse_apply(HashTable *ht, apply_func_t apply_func);
 
 
 /* Deletes */
-ZEND_API int zend_hash_del(HashTable *ht, zend_string *key);
-ZEND_API int zend_hash_del_ind(HashTable *ht, zend_string *key);
-ZEND_API int zend_hash_str_del(HashTable *ht, const char *key, size_t len);
-ZEND_API int zend_hash_str_del_ind(HashTable *ht, const char *key, size_t len);
-ZEND_API int zend_hash_index_del(HashTable *ht, zend_ulong h);
+ZEND_API int ZEND_FASTCALL zend_hash_del(HashTable *ht, zend_string *key);
+ZEND_API int ZEND_FASTCALL zend_hash_del_ind(HashTable *ht, zend_string *key);
+ZEND_API int ZEND_FASTCALL zend_hash_str_del(HashTable *ht, const char *key, size_t len);
+ZEND_API int ZEND_FASTCALL zend_hash_str_del_ind(HashTable *ht, const char *key, size_t len);
+ZEND_API int ZEND_FASTCALL zend_hash_index_del(HashTable *ht, zend_ulong h);
 
 /* Data retreival */
-ZEND_API zval *zend_hash_find(const HashTable *ht, zend_string *key);
-ZEND_API zval *zend_hash_str_find(const HashTable *ht, const char *key, size_t len);
-ZEND_API zval *zend_hash_index_find(const HashTable *ht, zend_ulong h);
+ZEND_API zval* ZEND_FASTCALL zend_hash_find(const HashTable *ht, zend_string *key);
+ZEND_API zval* ZEND_FASTCALL zend_hash_str_find(const HashTable *ht, const char *key, size_t len);
+ZEND_API zval* ZEND_FASTCALL zend_hash_index_find(const HashTable *ht, zend_ulong h);
 
 /* Misc */
-ZEND_API zend_bool zend_hash_exists(const HashTable *ht, zend_string *key);
-ZEND_API zend_bool zend_hash_str_exists(const HashTable *ht, const char *str, size_t len);
-ZEND_API zend_bool zend_hash_index_exists(const HashTable *ht, zend_ulong h);
+ZEND_API zend_bool ZEND_FASTCALL zend_hash_exists(const HashTable *ht, zend_string *key);
+ZEND_API zend_bool ZEND_FASTCALL zend_hash_str_exists(const HashTable *ht, const char *str, size_t len);
+ZEND_API zend_bool ZEND_FASTCALL zend_hash_index_exists(const HashTable *ht, zend_ulong h);
 
 /* traversing */
 #define zend_hash_has_more_elements_ex(ht, pos) \
        (zend_hash_get_current_key_type_ex(ht, pos) == HASH_KEY_NON_EXISTENT ? FAILURE : SUCCESS)
-ZEND_API int zend_hash_move_forward_ex(HashTable *ht, HashPosition *pos);
-ZEND_API int zend_hash_move_backwards_ex(HashTable *ht, HashPosition *pos);
-ZEND_API int zend_hash_get_current_key_ex(const HashTable *ht, zend_string **str_index, zend_ulong *num_index, HashPosition *pos);
-ZEND_API void zend_hash_get_current_key_zval_ex(const HashTable *ht, zval *key, HashPosition *pos);
-ZEND_API int zend_hash_get_current_key_type_ex(HashTable *ht, HashPosition *pos);
-ZEND_API zval *zend_hash_get_current_data_ex(HashTable *ht, HashPosition *pos);
-ZEND_API void zend_hash_internal_pointer_reset_ex(HashTable *ht, HashPosition *pos);
-ZEND_API void zend_hash_internal_pointer_end_ex(HashTable *ht, HashPosition *pos);
+ZEND_API int   ZEND_FASTCALL zend_hash_move_forward_ex(HashTable *ht, HashPosition *pos);
+ZEND_API int   ZEND_FASTCALL zend_hash_move_backwards_ex(HashTable *ht, HashPosition *pos);
+ZEND_API int   ZEND_FASTCALL zend_hash_get_current_key_ex(const HashTable *ht, zend_string **str_index, zend_ulong *num_index, HashPosition *pos);
+ZEND_API void  ZEND_FASTCALL zend_hash_get_current_key_zval_ex(const HashTable *ht, zval *key, HashPosition *pos);
+ZEND_API int   ZEND_FASTCALL zend_hash_get_current_key_type_ex(HashTable *ht, HashPosition *pos);
+ZEND_API zval* ZEND_FASTCALL zend_hash_get_current_data_ex(HashTable *ht, HashPosition *pos);
+ZEND_API void  ZEND_FASTCALL zend_hash_internal_pointer_reset_ex(HashTable *ht, HashPosition *pos);
+ZEND_API void  ZEND_FASTCALL zend_hash_internal_pointer_end_ex(HashTable *ht, HashPosition *pos);
 
 #define zend_hash_has_more_elements(ht) \
        zend_hash_has_more_elements_ex(ht, &(ht)->nInternalPointer)
@@ -188,15 +188,15 @@ ZEND_API void zend_hash_internal_pointer_end_ex(HashTable *ht, HashPosition *pos
        zend_hash_internal_pointer_end_ex(ht, &(ht)->nInternalPointer)
 
 /* Copying, merging and sorting */
-ZEND_API void zend_hash_copy(HashTable *target, HashTable *source, copy_ctor_func_t pCopyConstructor);
-ZEND_API void _zend_hash_merge(HashTable *target, HashTable *source, copy_ctor_func_t pCopyConstructor, zend_bool overwrite ZEND_FILE_LINE_DC);
-ZEND_API void zend_hash_merge_ex(HashTable *target, HashTable *source, copy_ctor_func_t pCopyConstructor, merge_checker_func_t pMergeSource, void *pParam);
-ZEND_API void zend_hash_bucket_swap(Bucket *p, Bucket *q);
-ZEND_API void zend_hash_bucket_renum_swap(Bucket *p, Bucket *q);
-ZEND_API void zend_hash_bucket_packed_swap(Bucket *p, Bucket *q);
-ZEND_API int zend_hash_sort_ex(HashTable *ht, sort_func_t sort_func, compare_func_t compare_func, zend_bool renumber);
-ZEND_API int zend_hash_compare(HashTable *ht1, HashTable *ht2, compare_func_t compar, zend_bool ordered);
-ZEND_API zval *zend_hash_minmax(const HashTable *ht, compare_func_t compar, uint32_t flag);
+ZEND_API void  ZEND_FASTCALL zend_hash_copy(HashTable *target, HashTable *source, copy_ctor_func_t pCopyConstructor);
+ZEND_API void  ZEND_FASTCALL _zend_hash_merge(HashTable *target, HashTable *source, copy_ctor_func_t pCopyConstructor, zend_bool overwrite ZEND_FILE_LINE_DC);
+ZEND_API void  ZEND_FASTCALL zend_hash_merge_ex(HashTable *target, HashTable *source, copy_ctor_func_t pCopyConstructor, merge_checker_func_t pMergeSource, void *pParam);
+ZEND_API void  zend_hash_bucket_swap(Bucket *p, Bucket *q);
+ZEND_API void  zend_hash_bucket_renum_swap(Bucket *p, Bucket *q);
+ZEND_API void  zend_hash_bucket_packed_swap(Bucket *p, Bucket *q);
+ZEND_API int   zend_hash_compare(HashTable *ht1, HashTable *ht2, compare_func_t compar, zend_bool ordered);
+ZEND_API int   ZEND_FASTCALL zend_hash_sort_ex(HashTable *ht, sort_func_t sort_func, compare_func_t compare_func, zend_bool renumber);
+ZEND_API zval* ZEND_FASTCALL zend_hash_minmax(const HashTable *ht, compare_func_t compar, uint32_t flag);
 
 #define zend_hash_merge(target, source, pCopyConstructor, overwrite)                                   \
        _zend_hash_merge(target, source, pCopyConstructor, overwrite ZEND_FILE_LINE_CC)
@@ -210,26 +210,19 @@ ZEND_API zval *zend_hash_minmax(const HashTable *ht, compare_func_t compar, uint
 #define zend_hash_next_free_element(ht) \
        (ht)->nNextFreeElement
 
-ZEND_API int zend_hash_rehash(HashTable *ht);
+ZEND_API int ZEND_FASTCALL zend_hash_rehash(HashTable *ht);
 
-ZEND_API HashTable *zend_array_dup(HashTable *source);
-ZEND_API void zend_array_destroy(HashTable *ht);
-ZEND_API void zend_symtable_clean(HashTable *ht);
+ZEND_API HashTable* ZEND_FASTCALL zend_array_dup(HashTable *source);
+ZEND_API void ZEND_FASTCALL zend_array_destroy(HashTable *ht);
+ZEND_API void ZEND_FASTCALL zend_symtable_clean(HashTable *ht);
 
-#if ZEND_DEBUG
-/* debug */
-void zend_hash_display_pListTail(const HashTable *ht);
-void zend_hash_display(const HashTable *ht);
-#endif
+ZEND_API int ZEND_FASTCALL _zend_handle_numeric_str_ex(const char *key, size_t length, zend_ulong *idx);
 
-ZEND_API int _zend_handle_numeric_str_ex(const char *key, size_t length, zend_ulong *idx);
-
-
-ZEND_API uint32_t     zend_hash_iterator_add(HashTable *ht, HashPosition pos);
-ZEND_API HashPosition zend_hash_iterator_pos(uint32_t idx, HashTable *ht);
-ZEND_API void         zend_hash_iterator_del(uint32_t idx);
-ZEND_API HashPosition zend_hash_iterators_lower_pos(HashTable *ht, HashPosition start);
-ZEND_API void        _zend_hash_iterators_update(HashTable *ht, HashPosition from, HashPosition to);
+ZEND_API uint32_t     ZEND_FASTCALL zend_hash_iterator_add(HashTable *ht, HashPosition pos);
+ZEND_API HashPosition ZEND_FASTCALL zend_hash_iterator_pos(uint32_t idx, HashTable *ht);
+ZEND_API void         ZEND_FASTCALL zend_hash_iterator_del(uint32_t idx);
+ZEND_API HashPosition ZEND_FASTCALL zend_hash_iterators_lower_pos(HashTable *ht, HashPosition start);
+ZEND_API void         ZEND_FASTCALL _zend_hash_iterators_update(HashTable *ht, HashPosition from, HashPosition to);
 
 static zend_always_inline void zend_hash_iterators_update(HashTable *ht, HashPosition from, HashPosition to)
 {
index d8be615c162f0587dfeb276b6c64e04ca92a62df..1f0afc21b112d892874a03ec09d9c6e5f86c1282 100644 (file)
@@ -79,7 +79,7 @@ static const unsigned char tolower_map[256] = {
                zend_binary_strncasecmp
  */
 
-ZEND_API int zend_atoi(const char *str, int str_len) /* {{{ */
+ZEND_API int ZEND_FASTCALL zend_atoi(const char *str, int str_len) /* {{{ */
 {
        int retval;
 
@@ -107,7 +107,7 @@ ZEND_API int zend_atoi(const char *str, int str_len) /* {{{ */
 }
 /* }}} */
 
-ZEND_API zend_long zend_atol(const char *str, int str_len) /* {{{ */
+ZEND_API zend_long ZEND_FASTCALL zend_atol(const char *str, int str_len) /* {{{ */
 {
        zend_long retval;
 
@@ -135,7 +135,7 @@ ZEND_API zend_long zend_atol(const char *str, int str_len) /* {{{ */
 }
 /* }}} */
 
-ZEND_API void convert_scalar_to_number(zval *op) /* {{{ */
+ZEND_API void ZEND_FASTCALL convert_scalar_to_number(zval *op) /* {{{ */
 {
 try_again:
        switch (Z_TYPE_P(op)) {
@@ -272,7 +272,7 @@ try_again:
                }                                                                                                                               \
        } while (0);
 
-ZEND_API void convert_to_long(zval *op) /* {{{ */
+ZEND_API void ZEND_FASTCALL convert_to_long(zval *op) /* {{{ */
 {
        if (Z_TYPE_P(op) != IS_LONG) {
                convert_to_long_base(op, 10);
@@ -280,7 +280,7 @@ ZEND_API void convert_to_long(zval *op) /* {{{ */
 }
 /* }}} */
 
-ZEND_API void convert_to_long_base(zval *op, int base) /* {{{ */
+ZEND_API void ZEND_FASTCALL convert_to_long_base(zval *op, int base) /* {{{ */
 {
        zend_long tmp;
 
@@ -336,7 +336,7 @@ ZEND_API void convert_to_long_base(zval *op, int base) /* {{{ */
 }
 /* }}} */
 
-ZEND_API void convert_to_double(zval *op) /* {{{ */
+ZEND_API void ZEND_FASTCALL convert_to_double(zval *op) /* {{{ */
 {
        double tmp;
 
@@ -393,7 +393,7 @@ ZEND_API void convert_to_double(zval *op) /* {{{ */
 }
 /* }}} */
 
-ZEND_API void convert_to_null(zval *op) /* {{{ */
+ZEND_API void ZEND_FASTCALL convert_to_null(zval *op) /* {{{ */
 {
        if (Z_TYPE_P(op) == IS_OBJECT) {
                if (Z_OBJ_HT_P(op)->cast_object) {
@@ -413,7 +413,7 @@ ZEND_API void convert_to_null(zval *op) /* {{{ */
 }
 /* }}} */
 
-ZEND_API void convert_to_boolean(zval *op) /* {{{ */
+ZEND_API void ZEND_FASTCALL convert_to_boolean(zval *op) /* {{{ */
 {
        int tmp;
 
@@ -474,13 +474,13 @@ ZEND_API void convert_to_boolean(zval *op) /* {{{ */
 }
 /* }}} */
 
-ZEND_API void _convert_to_cstring(zval *op ZEND_FILE_LINE_DC) /* {{{ */
+ZEND_API void ZEND_FASTCALL _convert_to_cstring(zval *op ZEND_FILE_LINE_DC) /* {{{ */
 {
        _convert_to_string(op ZEND_FILE_LINE_CC);
 }
 /* }}} */
 
-ZEND_API void _convert_to_string(zval *op ZEND_FILE_LINE_DC) /* {{{ */
+ZEND_API void ZEND_FASTCALL _convert_to_string(zval *op ZEND_FILE_LINE_DC) /* {{{ */
 {
        switch (Z_TYPE_P(op)) {
                case IS_UNDEF:
@@ -551,7 +551,7 @@ static void convert_scalar_to_array(zval *op) /* {{{ */
 }
 /* }}} */
 
-ZEND_API void convert_to_array(zval *op) /* {{{ */
+ZEND_API void ZEND_FASTCALL convert_to_array(zval *op) /* {{{ */
 {
 
        switch (Z_TYPE_P(op)) {
@@ -597,7 +597,7 @@ ZEND_API void convert_to_array(zval *op) /* {{{ */
 }
 /* }}} */
 
-ZEND_API void convert_to_object(zval *op) /* {{{ */
+ZEND_API void ZEND_FASTCALL convert_to_object(zval *op) /* {{{ */
 {
 
        switch (Z_TYPE_P(op)) {
@@ -677,7 +677,7 @@ ZEND_API void multi_convert_to_string_ex(int argc, ...) /* {{{ */
 }
 /* }}} */
 
-ZEND_API zend_long _zval_get_long_func(zval *op) /* {{{ */
+ZEND_API zend_long ZEND_FASTCALL _zval_get_long_func(zval *op) /* {{{ */
 {
 try_again:
        switch (Z_TYPE_P(op)) {
@@ -716,7 +716,7 @@ try_again:
 }
 /* }}} */
 
-ZEND_API double _zval_get_double_func(zval *op) /* {{{ */
+ZEND_API double ZEND_FASTCALL _zval_get_double_func(zval *op) /* {{{ */
 {
 try_again:
        switch (Z_TYPE_P(op)) {
@@ -757,7 +757,7 @@ try_again:
 }
 /* }}} */
 
-ZEND_API zend_string *_zval_get_string_func(zval *op) /* {{{ */
+ZEND_API zend_string* ZEND_FASTCALL _zval_get_string_func(zval *op) /* {{{ */
 {
 try_again:
        switch (Z_TYPE_P(op)) {
@@ -812,7 +812,7 @@ try_again:
 }
 /* }}} */
 
-ZEND_API int add_function(zval *result, zval *op1, zval *op2) /* {{{ */
+ZEND_API int ZEND_FASTCALL add_function(zval *result, zval *op1, zval *op2) /* {{{ */
 {
        zval op1_copy, op2_copy;
        int converted = 0;
@@ -876,7 +876,7 @@ ZEND_API int add_function(zval *result, zval *op1, zval *op2) /* {{{ */
 }
 /* }}} */
 
-ZEND_API int sub_function(zval *result, zval *op1, zval *op2) /* {{{ */
+ZEND_API int ZEND_FASTCALL sub_function(zval *result, zval *op1, zval *op2) /* {{{ */
 {
        zval op1_copy, op2_copy;
        int converted = 0;
@@ -929,7 +929,7 @@ ZEND_API int sub_function(zval *result, zval *op1, zval *op2) /* {{{ */
 }
 /* }}} */
 
-ZEND_API int mul_function(zval *result, zval *op1, zval *op2) /* {{{ */
+ZEND_API int ZEND_FASTCALL mul_function(zval *result, zval *op1, zval *op2) /* {{{ */
 {
        zval op1_copy, op2_copy;
        int converted = 0;
@@ -976,7 +976,7 @@ ZEND_API int mul_function(zval *result, zval *op1, zval *op2) /* {{{ */
 }
 /* }}} */
 
-ZEND_API int pow_function(zval *result, zval *op1, zval *op2) /* {{{ */
+ZEND_API int ZEND_FASTCALL pow_function(zval *result, zval *op1, zval *op2) /* {{{ */
 {
        zval op1_copy, op2_copy;
        int converted = 0;
@@ -1064,7 +1064,7 @@ ZEND_API int pow_function(zval *result, zval *op1, zval *op2) /* {{{ */
 }
 /* }}} */
 
-ZEND_API int div_function(zval *result, zval *op1, zval *op2) /* {{{ */
+ZEND_API int ZEND_FASTCALL div_function(zval *result, zval *op1, zval *op2) /* {{{ */
 {
        zval op1_copy, op2_copy;
        int converted = 0;
@@ -1135,7 +1135,7 @@ ZEND_API int div_function(zval *result, zval *op1, zval *op2) /* {{{ */
 }
 /* }}} */
 
-ZEND_API int mod_function(zval *result, zval *op1, zval *op2) /* {{{ */
+ZEND_API int ZEND_FASTCALL mod_function(zval *result, zval *op1, zval *op2) /* {{{ */
 {
        zend_long op1_lval, op2_lval;
 
@@ -1162,7 +1162,7 @@ ZEND_API int mod_function(zval *result, zval *op1, zval *op2) /* {{{ */
 }
 /* }}} */
 
-ZEND_API int boolean_xor_function(zval *result, zval *op1, zval *op2) /* {{{ */
+ZEND_API int ZEND_FASTCALL boolean_xor_function(zval *result, zval *op1, zval *op2) /* {{{ */
 {
        int op1_val, op2_val;
 
@@ -1212,7 +1212,7 @@ ZEND_API int boolean_xor_function(zval *result, zval *op1, zval *op2) /* {{{ */
 }
 /* }}} */
 
-ZEND_API int boolean_not_function(zval *result, zval *op1) /* {{{ */
+ZEND_API int ZEND_FASTCALL boolean_not_function(zval *result, zval *op1) /* {{{ */
 {
        if (Z_TYPE_P(op1) < IS_TRUE) {
                ZVAL_TRUE(result);
@@ -1237,7 +1237,7 @@ ZEND_API int boolean_not_function(zval *result, zval *op1) /* {{{ */
 }
 /* }}} */
 
-ZEND_API int bitwise_not_function(zval *result, zval *op1) /* {{{ */
+ZEND_API int ZEND_FASTCALL bitwise_not_function(zval *result, zval *op1) /* {{{ */
 {
 try_again:
        switch (Z_TYPE_P(op1)) {
@@ -1269,7 +1269,7 @@ try_again:
 }
 /* }}} */
 
-ZEND_API int bitwise_or_function(zval *result, zval *op1, zval *op2) /* {{{ */
+ZEND_API int ZEND_FASTCALL bitwise_or_function(zval *result, zval *op1, zval *op2) /* {{{ */
 {
        zend_long op1_lval, op2_lval;
 
@@ -1327,7 +1327,7 @@ ZEND_API int bitwise_or_function(zval *result, zval *op1, zval *op2) /* {{{ */
 }
 /* }}} */
 
-ZEND_API int bitwise_and_function(zval *result, zval *op1, zval *op2) /* {{{ */
+ZEND_API int ZEND_FASTCALL bitwise_and_function(zval *result, zval *op1, zval *op2) /* {{{ */
 {
        zend_long op1_lval, op2_lval;
 
@@ -1385,7 +1385,7 @@ ZEND_API int bitwise_and_function(zval *result, zval *op1, zval *op2) /* {{{ */
 }
 /* }}} */
 
-ZEND_API int bitwise_xor_function(zval *result, zval *op1, zval *op2) /* {{{ */
+ZEND_API int ZEND_FASTCALL bitwise_xor_function(zval *result, zval *op1, zval *op2) /* {{{ */
 {
        zend_long op1_lval, op2_lval;
 
@@ -1443,7 +1443,7 @@ ZEND_API int bitwise_xor_function(zval *result, zval *op1, zval *op2) /* {{{ */
 }
 /* }}} */
 
-ZEND_API int shift_left_function(zval *result, zval *op1, zval *op2) /* {{{ */
+ZEND_API int ZEND_FASTCALL shift_left_function(zval *result, zval *op1, zval *op2) /* {{{ */
 {
        zend_long op1_lval, op2_lval;
 
@@ -1470,7 +1470,7 @@ ZEND_API int shift_left_function(zval *result, zval *op1, zval *op2) /* {{{ */
 }
 /* }}} */
 
-ZEND_API int shift_right_function(zval *result, zval *op1, zval *op2) /* {{{ */
+ZEND_API int ZEND_FASTCALL shift_right_function(zval *result, zval *op1, zval *op2) /* {{{ */
 {
        zend_long op1_lval, op2_lval;
 
@@ -1498,7 +1498,7 @@ ZEND_API int shift_right_function(zval *result, zval *op1, zval *op2) /* {{{ */
 /* }}} */
 
 /* must support result==op1 */
-ZEND_API int add_char_to_string(zval *result, const zval *op1, const zval *op2) /* {{{ */
+ZEND_API int ZEND_FASTCALL add_char_to_string(zval *result, const zval *op1, const zval *op2) /* {{{ */
 {
        size_t length = Z_STRLEN_P(op1) + 1;
        zend_string *buf = zend_string_realloc(Z_STR_P(op1), length, 0);
@@ -1511,7 +1511,7 @@ ZEND_API int add_char_to_string(zval *result, const zval *op1, const zval *op2)
 /* }}} */
 
 /* must support result==op1 */
-ZEND_API int add_string_to_string(zval *result, const zval *op1, const zval *op2) /* {{{ */
+ZEND_API int ZEND_FASTCALL add_string_to_string(zval *result, const zval *op1, const zval *op2) /* {{{ */
 {
        size_t op1_len = Z_STRLEN_P(op1);
        size_t length = op1_len + Z_STRLEN_P(op2);
@@ -1524,7 +1524,7 @@ ZEND_API int add_string_to_string(zval *result, const zval *op1, const zval *op2
 }
 /* }}} */
 
-ZEND_API int concat_function(zval *result, zval *op1, zval *op2) /* {{{ */
+ZEND_API int ZEND_FASTCALL concat_function(zval *result, zval *op1, zval *op2) /* {{{ */
 {
        zval op1_copy, op2_copy;
        int use_copy1 = 0, use_copy2 = 0;
@@ -1903,7 +1903,7 @@ static int hash_zval_identical_function(zval *z1, zval *z2) /* {{{ */
 }
 /* }}} */
 
-ZEND_API int is_identical_function(zval *result, zval *op1, zval *op2) /* {{{ */
+ZEND_API int ZEND_FASTCALL is_identical_function(zval *result, zval *op1, zval *op2) /* {{{ */
 {
        if (Z_TYPE_P(op1) != Z_TYPE_P(op2)) {
                ZVAL_FALSE(result);
@@ -1951,7 +1951,7 @@ ZEND_API int is_identical_function(zval *result, zval *op1, zval *op2) /* {{{ */
 }
 /* }}} */
 
-ZEND_API int is_not_identical_function(zval *result, zval *op1, zval *op2) /* {{{ */
+ZEND_API int ZEND_FASTCALL is_not_identical_function(zval *result, zval *op1, zval *op2) /* {{{ */
 {
        if (is_identical_function(result, op1, op2) == FAILURE) {
                return FAILURE;
@@ -1961,7 +1961,7 @@ ZEND_API int is_not_identical_function(zval *result, zval *op1, zval *op2) /* {{
 }
 /* }}} */
 
-ZEND_API int is_equal_function(zval *result, zval *op1, zval *op2) /* {{{ */
+ZEND_API int ZEND_FASTCALL is_equal_function(zval *result, zval *op1, zval *op2) /* {{{ */
 {
        if (compare_function(result, op1, op2) == FAILURE) {
                return FAILURE;
@@ -1971,7 +1971,7 @@ ZEND_API int is_equal_function(zval *result, zval *op1, zval *op2) /* {{{ */
 }
 /* }}} */
 
-ZEND_API int is_not_equal_function(zval *result, zval *op1, zval *op2) /* {{{ */
+ZEND_API int ZEND_FASTCALL is_not_equal_function(zval *result, zval *op1, zval *op2) /* {{{ */
 {
        if (compare_function(result, op1, op2) == FAILURE) {
                return FAILURE;
@@ -1981,7 +1981,7 @@ ZEND_API int is_not_equal_function(zval *result, zval *op1, zval *op2) /* {{{ */
 }
 /* }}} */
 
-ZEND_API int is_smaller_function(zval *result, zval *op1, zval *op2) /* {{{ */
+ZEND_API int ZEND_FASTCALL is_smaller_function(zval *result, zval *op1, zval *op2) /* {{{ */
 {
        if (compare_function(result, op1, op2) == FAILURE) {
                return FAILURE;
@@ -1991,7 +1991,7 @@ ZEND_API int is_smaller_function(zval *result, zval *op1, zval *op2) /* {{{ */
 }
 /* }}} */
 
-ZEND_API int is_smaller_or_equal_function(zval *result, zval *op1, zval *op2) /* {{{ */
+ZEND_API int ZEND_FASTCALL is_smaller_or_equal_function(zval *result, zval *op1, zval *op2) /* {{{ */
 {
        if (compare_function(result, op1, op2) == FAILURE) {
                return FAILURE;
@@ -2001,7 +2001,7 @@ ZEND_API int is_smaller_or_equal_function(zval *result, zval *op1, zval *op2) /*
 }
 /* }}} */
 
-static zend_bool instanceof_interface_only(const zend_class_entry *instance_ce, const zend_class_entry *ce) /* {{{ */
+static zend_bool ZEND_FASTCALL instanceof_interface_only(const zend_class_entry *instance_ce, const zend_class_entry *ce) /* {{{ */
 {
        uint32_t i;
 
@@ -2026,7 +2026,7 @@ static zend_always_inline zend_bool instanceof_class(const zend_class_entry *ins
 }
 /* }}} */
 
-static zend_bool instanceof_interface(const zend_class_entry *instance_ce, const zend_class_entry *ce) /* {{{ */
+static zend_bool ZEND_FASTCALL instanceof_interface(const zend_class_entry *instance_ce, const zend_class_entry *ce) /* {{{ */
 {
        uint32_t i;
 
@@ -2039,7 +2039,7 @@ static zend_bool instanceof_interface(const zend_class_entry *instance_ce, const
 }
 /* }}} */
 
-ZEND_API zend_bool instanceof_function_ex(const zend_class_entry *instance_ce, const zend_class_entry *ce, zend_bool interfaces_only) /* {{{ */
+ZEND_API zend_bool ZEND_FASTCALL instanceof_function_ex(const zend_class_entry *instance_ce, const zend_class_entry *ce, zend_bool interfaces_only) /* {{{ */
 {
        if (ce->ce_flags & ZEND_ACC_INTERFACE) {
                if (!interfaces_only) {
@@ -2057,7 +2057,7 @@ ZEND_API zend_bool instanceof_function_ex(const zend_class_entry *instance_ce, c
 }
 /* }}} */
 
-ZEND_API zend_bool instanceof_function(const zend_class_entry *instance_ce, const zend_class_entry *ce) /* {{{ */
+ZEND_API zend_bool ZEND_FASTCALL instanceof_function(const zend_class_entry *instance_ce, const zend_class_entry *ce) /* {{{ */
 {
        if (ce->ce_flags & ZEND_ACC_INTERFACE) {
                return instanceof_interface(instance_ce, ce);
@@ -2071,7 +2071,7 @@ ZEND_API zend_bool instanceof_function(const zend_class_entry *instance_ce, cons
 #define UPPER_CASE 2
 #define NUMERIC 3
 
-static void increment_string(zval *str) /* {{{ */
+static void ZEND_FASTCALL increment_string(zval *str) /* {{{ */
 {
        int carry=0;
        size_t pos=Z_STRLEN_P(str)-1;
@@ -2157,7 +2157,7 @@ static void increment_string(zval *str) /* {{{ */
 }
 /* }}} */
 
-ZEND_API int increment_function(zval *op1) /* {{{ */
+ZEND_API int ZEND_FASTCALL increment_function(zval *op1) /* {{{ */
 {
 try_again:
        switch (Z_TYPE_P(op1)) {
@@ -2235,7 +2235,7 @@ try_again:
 }
 /* }}} */
 
-ZEND_API int decrement_function(zval *op1) /* {{{ */
+ZEND_API int ZEND_FASTCALL decrement_function(zval *op1) /* {{{ */
 {
        zend_long lval;
        double dval;
@@ -2309,13 +2309,13 @@ try_again:
 }
 /* }}} */
 
-ZEND_API int zend_is_true(zval *op) /* {{{ */
+ZEND_API int ZEND_FASTCALL zend_is_true(zval *op) /* {{{ */
 {
        return i_zend_is_true(op);
 }
 /* }}} */
 
-ZEND_API int zend_object_is_true(zval *op) /* {{{ */
+ZEND_API int ZEND_FASTCALL zend_object_is_true(zval *op) /* {{{ */
 {
        if (Z_OBJ_HT_P(op)->cast_object) {
                zval tmp;
@@ -2340,14 +2340,14 @@ ZEND_API int zend_object_is_true(zval *op) /* {{{ */
 /* }}} */
 
 #ifdef ZEND_USE_TOLOWER_L
-ZEND_API void zend_update_current_locale(void) /* {{{ */
+ZEND_API void ZEND_FASTCALL zend_update_current_locale(void) /* {{{ */
 {
        current_locale = _get_current_locale();
 }
 /* }}} */
 #endif
 
-ZEND_API char *zend_str_tolower_copy(char *dest, const char *source, size_t length) /* {{{ */
+ZEND_API char* ZEND_FASTCALL zend_str_tolower_copy(char *dest, const char *source, size_t length) /* {{{ */
 {
        register unsigned char *str = (unsigned char*)source;
        register unsigned char *result = (unsigned char*)dest;
@@ -2362,13 +2362,13 @@ ZEND_API char *zend_str_tolower_copy(char *dest, const char *source, size_t leng
 }
 /* }}} */
 
-ZEND_API char *zend_str_tolower_dup(const char *source, size_t length) /* {{{ */
+ZEND_API char* ZEND_FASTCALL zend_str_tolower_dup(const char *source, size_t length) /* {{{ */
 {
        return zend_str_tolower_copy((char *)emalloc(length+1), source, length);
 }
 /* }}} */
 
-ZEND_API void zend_str_tolower(char *str, size_t length) /* {{{ */
+ZEND_API void ZEND_FASTCALL zend_str_tolower(char *str, size_t length) /* {{{ */
 {
        register unsigned char *p = (unsigned char*)str;
        register unsigned char *end = p + length;
@@ -2380,7 +2380,7 @@ ZEND_API void zend_str_tolower(char *str, size_t length) /* {{{ */
 }
 /* }}} */
 
-ZEND_API zend_string *zend_string_tolower(zend_string *str) /* {{{ */
+ZEND_API zend_string* ZEND_FASTCALL zend_string_tolower(zend_string *str) /* {{{ */
 {
        register unsigned char *p = (unsigned char*)str->val;
        register unsigned char *end = p + str->len;
@@ -2408,7 +2408,7 @@ ZEND_API zend_string *zend_string_tolower(zend_string *str) /* {{{ */
 }
 /* }}} */
 
-ZEND_API int zend_binary_strcmp(const char *s1, size_t len1, const char *s2, size_t len2) /* {{{ */
+ZEND_API int ZEND_FASTCALL zend_binary_strcmp(const char *s1, size_t len1, const char *s2, size_t len2) /* {{{ */
 {
        int retval;
 
@@ -2424,7 +2424,7 @@ ZEND_API int zend_binary_strcmp(const char *s1, size_t len1, const char *s2, siz
 }
 /* }}} */
 
-ZEND_API int zend_binary_strncmp(const char *s1, size_t len1, const char *s2, size_t len2, size_t length) /* {{{ */
+ZEND_API int ZEND_FASTCALL zend_binary_strncmp(const char *s1, size_t len1, const char *s2, size_t len2, size_t length) /* {{{ */
 {
        int retval;
 
@@ -2440,7 +2440,7 @@ ZEND_API int zend_binary_strncmp(const char *s1, size_t len1, const char *s2, si
 }
 /* }}} */
 
-ZEND_API int zend_binary_strcasecmp(const char *s1, size_t len1, const char *s2, size_t len2) /* {{{ */
+ZEND_API int ZEND_FASTCALL zend_binary_strcasecmp(const char *s1, size_t len1, const char *s2, size_t len2) /* {{{ */
 {
        size_t len;
        int c1, c2;
@@ -2462,7 +2462,7 @@ ZEND_API int zend_binary_strcasecmp(const char *s1, size_t len1, const char *s2,
 }
 /* }}} */
 
-ZEND_API int zend_binary_strncasecmp(const char *s1, size_t len1, const char *s2, size_t len2, size_t length) /* {{{ */
+ZEND_API int ZEND_FASTCALL zend_binary_strncasecmp(const char *s1, size_t len1, const char *s2, size_t len2, size_t length) /* {{{ */
 {
        size_t len;
        int c1, c2;
@@ -2483,7 +2483,7 @@ ZEND_API int zend_binary_strncasecmp(const char *s1, size_t len1, const char *s2
 }
 /* }}} */
 
-ZEND_API int zend_binary_strcasecmp_l(const char *s1, size_t len1, const char *s2, size_t len2) /* {{{ */
+ZEND_API int ZEND_FASTCALL zend_binary_strcasecmp_l(const char *s1, size_t len1, const char *s2, size_t len2) /* {{{ */
 {
        size_t len;
        int c1, c2;
@@ -2505,7 +2505,7 @@ ZEND_API int zend_binary_strcasecmp_l(const char *s1, size_t len1, const char *s
 }
 /* }}} */
 
-ZEND_API int zend_binary_strncasecmp_l(const char *s1, size_t len1, const char *s2, size_t len2, size_t length) /* {{{ */
+ZEND_API int ZEND_FASTCALL zend_binary_strncasecmp_l(const char *s1, size_t len1, const char *s2, size_t len2, size_t length) /* {{{ */
 {
        size_t len;
        int c1, c2;
@@ -2526,31 +2526,31 @@ ZEND_API int zend_binary_strncasecmp_l(const char *s1, size_t len1, const char *
 }
 /* }}} */
 
-ZEND_API int zend_binary_zval_strcmp(zval *s1, zval *s2) /* {{{ */
+ZEND_API int ZEND_FASTCALL zend_binary_zval_strcmp(zval *s1, zval *s2) /* {{{ */
 {
        return zend_binary_strcmp(Z_STRVAL_P(s1), Z_STRLEN_P(s1), Z_STRVAL_P(s2), Z_STRLEN_P(s2));
 }
 /* }}} */
 
-ZEND_API int zend_binary_zval_strncmp(zval *s1, zval *s2, zval *s3) /* {{{ */
+ZEND_API int ZEND_FASTCALL zend_binary_zval_strncmp(zval *s1, zval *s2, zval *s3) /* {{{ */
 {
        return zend_binary_strncmp(Z_STRVAL_P(s1), Z_STRLEN_P(s1), Z_STRVAL_P(s2), Z_STRLEN_P(s2), Z_LVAL_P(s3));
 }
 /* }}} */
 
-ZEND_API int zend_binary_zval_strcasecmp(zval *s1, zval *s2) /* {{{ */
+ZEND_API int ZEND_FASTCALL zend_binary_zval_strcasecmp(zval *s1, zval *s2) /* {{{ */
 {
        return zend_binary_strcasecmp_l(Z_STRVAL_P(s1), Z_STRLEN_P(s1), Z_STRVAL_P(s2), Z_STRLEN_P(s2));
 }
 /* }}} */
 
-ZEND_API int zend_binary_zval_strncasecmp(zval *s1, zval *s2, zval *s3) /* {{{ */
+ZEND_API int ZEND_FASTCALL zend_binary_zval_strncasecmp(zval *s1, zval *s2, zval *s3) /* {{{ */
 {
        return zend_binary_strncasecmp_l(Z_STRVAL_P(s1), Z_STRLEN_P(s1), Z_STRVAL_P(s2), Z_STRLEN_P(s2), Z_LVAL_P(s3));
 }
 /* }}} */
 
-ZEND_API zend_long zendi_smart_strcmp(zval *s1, zval *s2) /* {{{ */
+ZEND_API zend_long ZEND_FASTCALL zendi_smart_strcmp(zval *s1, zval *s2) /* {{{ */
 {
        int ret1, ret2;
        int oflow1, oflow2;
@@ -2612,19 +2612,19 @@ static int hash_zval_compare_function(zval *z1, zval *z2) /* {{{ */
 }
 /* }}} */
 
-ZEND_API int zend_compare_symbol_tables(HashTable *ht1, HashTable *ht2) /* {{{ */
+ZEND_API int ZEND_FASTCALL zend_compare_symbol_tables(HashTable *ht1, HashTable *ht2) /* {{{ */
 {
        return ht1 == ht2 ? 0 : zend_hash_compare(ht1, ht2, (compare_func_t) hash_zval_compare_function, 0);
 }
 /* }}} */
 
-ZEND_API int zend_compare_arrays(zval *a1, zval *a2) /* {{{ */
+ZEND_API int ZEND_FASTCALL zend_compare_arrays(zval *a1, zval *a2) /* {{{ */
 {
        return zend_compare_symbol_tables(Z_ARRVAL_P(a1), Z_ARRVAL_P(a2));
 }
 /* }}} */
 
-ZEND_API int zend_compare_objects(zval *o1, zval *o2) /* {{{ */
+ZEND_API int ZEND_FASTCALL zend_compare_objects(zval *o1, zval *o2) /* {{{ */
 {
        if (Z_OBJ_P(o1) == Z_OBJ_P(o2)) {
                return 0;
@@ -2638,7 +2638,7 @@ ZEND_API int zend_compare_objects(zval *o1, zval *o2) /* {{{ */
 }
 /* }}} */
 
-ZEND_API void zend_locale_sprintf_double(zval *op ZEND_FILE_LINE_DC) /* {{{ */
+ZEND_API void ZEND_FASTCALL zend_locale_sprintf_double(zval *op ZEND_FILE_LINE_DC) /* {{{ */
 {
        zend_string *str;
 
@@ -2647,7 +2647,7 @@ ZEND_API void zend_locale_sprintf_double(zval *op ZEND_FILE_LINE_DC) /* {{{ */
 }
 /* }}} */
 
-ZEND_API zend_string *zend_long_to_str(zend_long num) /* {{{ */
+ZEND_API zend_string* ZEND_FASTCALL zend_long_to_str(zend_long num) /* {{{ */
 {
        char buf[MAX_LENGTH_OF_LONG + 1];
        char *res = zend_print_long_to_buf(buf + sizeof(buf) - 1, num);
@@ -2655,12 +2655,12 @@ ZEND_API zend_string *zend_long_to_str(zend_long num) /* {{{ */
 }
 /* }}} */
 
-ZEND_API zend_uchar is_numeric_str_function(const zend_string *str, zend_long *lval, double *dval) /* {{{ */ {
+ZEND_API zend_uchar ZEND_FASTCALL is_numeric_str_function(const zend_string *str, zend_long *lval, double *dval) /* {{{ */ {
     return is_numeric_string_ex(str->val, str->len, lval, dval, -1, NULL);
 }
 /* }}} */
 
-ZEND_API zend_uchar _is_numeric_string_ex(const char *str, size_t length, zend_long *lval, double *dval, int allow_errors, int *oflow_info) /* {{{ */
+ZEND_API zend_uchar ZEND_FASTCALL _is_numeric_string_ex(const char *str, size_t length, zend_long *lval, double *dval, int allow_errors, int *oflow_info) /* {{{ */
 {
        const char *ptr;
        int digits = 0, dp_or_e = 0;
@@ -2802,7 +2802,7 @@ static zend_always_inline void zend_memnstr_ex_pre(unsigned int td[], const char
 }
 /* }}} */
 
-ZEND_API const char* zend_memnstr_ex(const char *haystack, const char *needle, size_t needle_len, char *end) /* {{{ */
+ZEND_API const char* ZEND_FASTCALL zend_memnstr_ex(const char *haystack, const char *needle, size_t needle_len, char *end) /* {{{ */
 {
        unsigned int td[256];
        register size_t i;
@@ -2833,7 +2833,7 @@ ZEND_API const char* zend_memnstr_ex(const char *haystack, const char *needle, s
 }
 /* }}} */
 
-ZEND_API const char* zend_memnrstr_ex(const char *haystack, const char *needle, size_t needle_len, char *end) /* {{{ */
+ZEND_API const char* ZEND_FASTCALL zend_memnrstr_ex(const char *haystack, const char *needle, size_t needle_len, char *end) /* {{{ */
 {
        unsigned int td[256];
        register size_t i;
@@ -2872,7 +2872,7 @@ ZEND_API const char* zend_memnrstr_ex(const char *haystack, const char *needle,
 
 #if !ZEND_DVAL_TO_LVAL_CAST_OK
 # if SIZEOF_ZEND_LONG == 4
-ZEND_API zend_long zend_dval_to_lval_slow(double d)
+ZEND_API zend_long ZEND_FASTCALL zend_dval_to_lval_slow(double d)
 {
        double  two_pow_32 = pow(2., 32.),
                        dmod;
@@ -2886,7 +2886,7 @@ ZEND_API zend_long zend_dval_to_lval_slow(double d)
        return (zend_long)(zend_ulong)dmod;
 }
 #else
-ZEND_API zend_long zend_dval_to_lval_slow(double d)
+ZEND_API zend_long ZEND_FASTCALL zend_dval_to_lval_slow(double d)
 {
        double  two_pow_64 = pow(2., 64.),
                        dmod;
index 1ee827e908a84f325cb2eb88b6213f6001b86a63..b656e435b2fe6af24fedf9720c2f122b0a7a1ae2 100644 (file)
 #define LONG_SIGN_MASK (((zend_long)1) << (8*sizeof(zend_long)-1))
 
 BEGIN_EXTERN_C()
-ZEND_API int add_function(zval *result, zval *op1, zval *op2);
-ZEND_API int sub_function(zval *result, zval *op1, zval *op2);
-ZEND_API int mul_function(zval *result, zval *op1, zval *op2);
-ZEND_API int pow_function(zval *result, zval *op1, zval *op2);
-ZEND_API int div_function(zval *result, zval *op1, zval *op2);
-ZEND_API int mod_function(zval *result, zval *op1, zval *op2);
-ZEND_API int boolean_xor_function(zval *result, zval *op1, zval *op2);
-ZEND_API int boolean_not_function(zval *result, zval *op1);
-ZEND_API int bitwise_not_function(zval *result, zval *op1);
-ZEND_API int bitwise_or_function(zval *result, zval *op1, zval *op2);
-ZEND_API int bitwise_and_function(zval *result, zval *op1, zval *op2);
-ZEND_API int bitwise_xor_function(zval *result, zval *op1, zval *op2);
-ZEND_API int shift_left_function(zval *result, zval *op1, zval *op2);
-ZEND_API int shift_right_function(zval *result, zval *op1, zval *op2);
-ZEND_API int concat_function(zval *result, zval *op1, zval *op2);
-
-ZEND_API int is_equal_function(zval *result, zval *op1, zval *op2);
-ZEND_API int is_identical_function(zval *result, zval *op1, zval *op2);
-ZEND_API int is_not_identical_function(zval *result, zval *op1, zval *op2);
-ZEND_API int is_not_equal_function(zval *result, zval *op1, zval *op2);
-ZEND_API int is_smaller_function(zval *result, zval *op1, zval *op2);
-ZEND_API int is_smaller_or_equal_function(zval *result, zval *op1, zval *op2);
-
-ZEND_API zend_bool instanceof_function_ex(const zend_class_entry *instance_ce, const zend_class_entry *ce, zend_bool interfaces_only);
-ZEND_API zend_bool instanceof_function(const zend_class_entry *instance_ce, const zend_class_entry *ce);
+ZEND_API int ZEND_FASTCALL add_function(zval *result, zval *op1, zval *op2);
+ZEND_API int ZEND_FASTCALL sub_function(zval *result, zval *op1, zval *op2);
+ZEND_API int ZEND_FASTCALL mul_function(zval *result, zval *op1, zval *op2);
+ZEND_API int ZEND_FASTCALL pow_function(zval *result, zval *op1, zval *op2);
+ZEND_API int ZEND_FASTCALL div_function(zval *result, zval *op1, zval *op2);
+ZEND_API int ZEND_FASTCALL mod_function(zval *result, zval *op1, zval *op2);
+ZEND_API int ZEND_FASTCALL boolean_xor_function(zval *result, zval *op1, zval *op2);
+ZEND_API int ZEND_FASTCALL boolean_not_function(zval *result, zval *op1);
+ZEND_API int ZEND_FASTCALL bitwise_not_function(zval *result, zval *op1);
+ZEND_API int ZEND_FASTCALL bitwise_or_function(zval *result, zval *op1, zval *op2);
+ZEND_API int ZEND_FASTCALL bitwise_and_function(zval *result, zval *op1, zval *op2);
+ZEND_API int ZEND_FASTCALL bitwise_xor_function(zval *result, zval *op1, zval *op2);
+ZEND_API int ZEND_FASTCALL shift_left_function(zval *result, zval *op1, zval *op2);
+ZEND_API int ZEND_FASTCALL shift_right_function(zval *result, zval *op1, zval *op2);
+ZEND_API int ZEND_FASTCALL concat_function(zval *result, zval *op1, zval *op2);
+
+ZEND_API int ZEND_FASTCALL is_equal_function(zval *result, zval *op1, zval *op2);
+ZEND_API int ZEND_FASTCALL is_identical_function(zval *result, zval *op1, zval *op2);
+ZEND_API int ZEND_FASTCALL is_not_identical_function(zval *result, zval *op1, zval *op2);
+ZEND_API int ZEND_FASTCALL is_not_equal_function(zval *result, zval *op1, zval *op2);
+ZEND_API int ZEND_FASTCALL is_smaller_function(zval *result, zval *op1, zval *op2);
+ZEND_API int ZEND_FASTCALL is_smaller_or_equal_function(zval *result, zval *op1, zval *op2);
+
+ZEND_API zend_bool ZEND_FASTCALL instanceof_function_ex(const zend_class_entry *instance_ce, const zend_class_entry *ce, zend_bool interfaces_only);
+ZEND_API zend_bool ZEND_FASTCALL instanceof_function(const zend_class_entry *instance_ce, const zend_class_entry *ce);
 
 /**
  * Checks whether the string "str" with length "length" is numeric. The value
@@ -85,10 +85,10 @@ ZEND_API zend_bool instanceof_function(const zend_class_entry *instance_ce, cons
  * could not be represented as such due to overflow. It writes 1 to oflow_info
  * if the integer is larger than ZEND_LONG_MAX and -1 if it's smaller than ZEND_LONG_MIN.
  */
-ZEND_API zend_uchar _is_numeric_string_ex(const char *str, size_t length, zend_long *lval, double *dval, int allow_errors, int *oflow_info);
+ZEND_API zend_uchar ZEND_FASTCALL _is_numeric_string_ex(const char *str, size_t length, zend_long *lval, double *dval, int allow_errors, int *oflow_info);
 
-ZEND_API const char* zend_memnstr_ex(const char *haystack, const char *needle, size_t needle_len, char *end);
-ZEND_API const char* zend_memnrstr_ex(const char *haystack, const char *needle, size_t needle_len, char *end);
+ZEND_API const char* ZEND_FASTCALL zend_memnstr_ex(const char *haystack, const char *needle, size_t needle_len, char *end);
+ZEND_API const char* ZEND_FASTCALL zend_memnrstr_ex(const char *haystack, const char *needle, size_t needle_len, char *end);
 
 #if SIZEOF_ZEND_LONG == 4
 #      define ZEND_DOUBLE_FITS_LONG(d) (!((d) > ZEND_LONG_MAX || (d) < ZEND_LONG_MIN))
@@ -107,7 +107,7 @@ static zend_always_inline zend_long zend_dval_to_lval(double d)
     }
 }
 #else
-ZEND_API zend_long zend_dval_to_lval_slow(double d);
+ZEND_API zend_long ZEND_FASTCALL zend_dval_to_lval_slow(double d);
 
 static zend_always_inline zend_long zend_dval_to_lval(double d)
 {
@@ -136,7 +136,7 @@ static zend_always_inline zend_uchar is_numeric_string(const char *str, size_t l
     return is_numeric_string_ex(str, length, lval, dval, allow_errors, NULL);
 }
 
-ZEND_API zend_uchar is_numeric_str_function(const zend_string *str, zend_long *lval, double *dval);
+ZEND_API zend_uchar ZEND_FASTCALL is_numeric_str_function(const zend_string *str, zend_long *lval, double *dval);
 
 static zend_always_inline const char *
 zend_memnstr(const char *haystack, const char *needle, size_t needle_len, char *end)
@@ -232,26 +232,26 @@ zend_memnrstr(const char *haystack, const char *needle, size_t needle_len, char
        }
 }
 
-ZEND_API int increment_function(zval *op1);
-ZEND_API int decrement_function(zval *op2);
-
-ZEND_API void convert_scalar_to_number(zval *op);
-ZEND_API void _convert_to_cstring(zval *op ZEND_FILE_LINE_DC);
-ZEND_API void _convert_to_string(zval *op ZEND_FILE_LINE_DC);
-ZEND_API void convert_to_long(zval *op);
-ZEND_API void convert_to_double(zval *op);
-ZEND_API void convert_to_long_base(zval *op, int base);
-ZEND_API void convert_to_null(zval *op);
-ZEND_API void convert_to_boolean(zval *op);
-ZEND_API void convert_to_array(zval *op);
-ZEND_API void convert_to_object(zval *op);
+ZEND_API int ZEND_FASTCALL increment_function(zval *op1);
+ZEND_API int ZEND_FASTCALL decrement_function(zval *op2);
+
+ZEND_API void ZEND_FASTCALL convert_scalar_to_number(zval *op);
+ZEND_API void ZEND_FASTCALL _convert_to_cstring(zval *op ZEND_FILE_LINE_DC);
+ZEND_API void ZEND_FASTCALL _convert_to_string(zval *op ZEND_FILE_LINE_DC);
+ZEND_API void ZEND_FASTCALL convert_to_long(zval *op);
+ZEND_API void ZEND_FASTCALL convert_to_double(zval *op);
+ZEND_API void ZEND_FASTCALL convert_to_long_base(zval *op, int base);
+ZEND_API void ZEND_FASTCALL convert_to_null(zval *op);
+ZEND_API void ZEND_FASTCALL convert_to_boolean(zval *op);
+ZEND_API void ZEND_FASTCALL convert_to_array(zval *op);
+ZEND_API void ZEND_FASTCALL convert_to_object(zval *op);
 ZEND_API void multi_convert_to_long_ex(int argc, ...);
 ZEND_API void multi_convert_to_double_ex(int argc, ...);
 ZEND_API void multi_convert_to_string_ex(int argc, ...);
 
-ZEND_API zend_long _zval_get_long_func(zval *op);
-ZEND_API double _zval_get_double_func(zval *op);
-ZEND_API zend_string *_zval_get_string_func(zval *op);
+ZEND_API zend_long    ZEND_FASTCALL _zval_get_long_func(zval *op);
+ZEND_API double       ZEND_FASTCALL _zval_get_double_func(zval *op);
+ZEND_API zend_string* ZEND_FASTCALL _zval_get_string_func(zval *op);
 
 static zend_always_inline zend_long _zval_get_long(zval *op) {
        return Z_TYPE_P(op) == IS_LONG ? Z_LVAL_P(op) : _zval_get_long_func(op);
@@ -267,14 +267,14 @@ static zend_always_inline zend_string *_zval_get_string(zval *op) {
 #define zval_get_double(op) _zval_get_double((op))
 #define zval_get_string(op) _zval_get_string((op))
 
-ZEND_API int add_char_to_string(zval *result, const zval *op1, const zval *op2);
-ZEND_API int add_string_to_string(zval *result, const zval *op1, const zval *op2);
+ZEND_API int ZEND_FASTCALL add_char_to_string(zval *result, const zval *op1, const zval *op2);
+ZEND_API int ZEND_FASTCALL add_string_to_string(zval *result, const zval *op1, const zval *op2);
 #define convert_to_cstring(op) if (Z_TYPE_P(op) != IS_STRING) { _convert_to_cstring((op) ZEND_FILE_LINE_CC); }
 #define convert_to_string(op) if (Z_TYPE_P(op) != IS_STRING) { _convert_to_string((op) ZEND_FILE_LINE_CC); }
 
 
-ZEND_API int zend_is_true(zval *op);
-ZEND_API int zend_object_is_true(zval *op);
+ZEND_API int ZEND_FASTCALL zend_is_true(zval *op);
+ZEND_API int ZEND_FASTCALL zend_object_is_true(zval *op);
 
 #define zval_is_true(op) \
        zend_is_true(op)
@@ -336,31 +336,31 @@ ZEND_API int string_case_compare_function(zval *result, zval *op1, zval *op2);
 ZEND_API int string_locale_compare_function(zval *result, zval *op1, zval *op2);
 #endif
 
-ZEND_API void zend_str_tolower(char *str, size_t length);
-ZEND_API char *zend_str_tolower_copy(char *dest, const char *source, size_t length);
-ZEND_API char *zend_str_tolower_dup(const char *source, size_t length);
-ZEND_API zend_string *zend_string_tolower(zend_string *str);
+ZEND_API void         ZEND_FASTCALL zend_str_tolower(char *str, size_t length);
+ZEND_API char*        ZEND_FASTCALL zend_str_tolower_copy(char *dest, const char *source, size_t length);
+ZEND_API char*        ZEND_FASTCALL zend_str_tolower_dup(const char *source, size_t length);
+ZEND_API zend_string* ZEND_FASTCALL zend_string_tolower(zend_string *str);
 
-ZEND_API int zend_binary_zval_strcmp(zval *s1, zval *s2);
-ZEND_API int zend_binary_zval_strncmp(zval *s1, zval *s2, zval *s3);
-ZEND_API int zend_binary_zval_strcasecmp(zval *s1, zval *s2);
-ZEND_API int zend_binary_zval_strncasecmp(zval *s1, zval *s2, zval *s3);
-ZEND_API int zend_binary_strcmp(const char *s1, size_t len1, const char *s2, size_t len2);
-ZEND_API int zend_binary_strncmp(const char *s1, size_t len1, const char *s2, size_t len2, size_t length);
-ZEND_API int zend_binary_strcasecmp(const char *s1, size_t len1, const char *s2, size_t len2);
-ZEND_API int zend_binary_strncasecmp(const char *s1, size_t len1, const char *s2, size_t len2, size_t length);
-ZEND_API int zend_binary_strcasecmp_l(const char *s1, size_t len1, const char *s2, size_t len2);
-ZEND_API int zend_binary_strncasecmp_l(const char *s1, size_t len1, const char *s2, size_t len2, size_t length);
+ZEND_API int ZEND_FASTCALL zend_binary_zval_strcmp(zval *s1, zval *s2);
+ZEND_API int ZEND_FASTCALL zend_binary_zval_strncmp(zval *s1, zval *s2, zval *s3);
+ZEND_API int ZEND_FASTCALL zend_binary_zval_strcasecmp(zval *s1, zval *s2);
+ZEND_API int ZEND_FASTCALL zend_binary_zval_strncasecmp(zval *s1, zval *s2, zval *s3);
+ZEND_API int ZEND_FASTCALL zend_binary_strcmp(const char *s1, size_t len1, const char *s2, size_t len2);
+ZEND_API int ZEND_FASTCALL zend_binary_strncmp(const char *s1, size_t len1, const char *s2, size_t len2, size_t length);
+ZEND_API int ZEND_FASTCALL zend_binary_strcasecmp(const char *s1, size_t len1, const char *s2, size_t len2);
+ZEND_API int ZEND_FASTCALL zend_binary_strncasecmp(const char *s1, size_t len1, const char *s2, size_t len2, size_t length);
+ZEND_API int ZEND_FASTCALL zend_binary_strcasecmp_l(const char *s1, size_t len1, const char *s2, size_t len2);
+ZEND_API int ZEND_FASTCALL zend_binary_strncasecmp_l(const char *s1, size_t len1, const char *s2, size_t len2, size_t length);
 
-ZEND_API zend_long zendi_smart_strcmp(zval *s1, zval *s2);
-ZEND_API int zend_compare_symbol_tables(HashTable *ht1, HashTable *ht2);
-ZEND_API int zend_compare_arrays(zval *a1, zval *a2);
-ZEND_API int zend_compare_objects(zval *o1, zval *o2);
+ZEND_API zend_long ZEND_FASTCALL zendi_smart_strcmp(zval *s1, zval *s2);
+ZEND_API int ZEND_FASTCALL zend_compare_symbol_tables(HashTable *ht1, HashTable *ht2);
+ZEND_API int ZEND_FASTCALL zend_compare_arrays(zval *a1, zval *a2);
+ZEND_API int ZEND_FASTCALL zend_compare_objects(zval *o1, zval *o2);
 
-ZEND_API int zend_atoi(const char *str, int str_len);
-ZEND_API zend_long zend_atol(const char *str, int str_len);
+ZEND_API int ZEND_FASTCALL zend_atoi(const char *str, int str_len);
+ZEND_API zend_long ZEND_FASTCALL zend_atol(const char *str, int str_len);
 
-ZEND_API void zend_locale_sprintf_double(zval *op ZEND_FILE_LINE_DC);
+ZEND_API void ZEND_FASTCALL zend_locale_sprintf_double(zval *op ZEND_FILE_LINE_DC);
 
 #define convert_to_ex_master(pzv, lower_type, upper_type)      \
        if (Z_TYPE_P(pzv)!=upper_type) {                                        \
@@ -1164,7 +1164,7 @@ static zend_always_inline char *zend_print_long_to_buf(char *buf, zend_long num)
        }
 }
 
-ZEND_API zend_string *zend_long_to_str(zend_long num);
+ZEND_API zend_string* ZEND_FASTCALL zend_long_to_str(zend_long num);
 
 END_EXTERN_C()
 
index 6baebaa7e453134bf787ab8bb4d68fb8e7a611dd..38c8f42d9fa98aac4c72d52863ab4de571e8c1be 100644 (file)
@@ -27,7 +27,7 @@
 #include "zend_constants.h"
 #include "zend_list.h"
 
-ZEND_API void _zval_dtor_func(zend_refcounted *p ZEND_FILE_LINE_DC)
+ZEND_API void ZEND_FASTCALL _zval_dtor_func(zend_refcounted *p ZEND_FILE_LINE_DC)
 {
        switch (GC_TYPE(p)) {
                case IS_STRING:
@@ -84,7 +84,7 @@ ZEND_API void _zval_dtor_func(zend_refcounted *p ZEND_FILE_LINE_DC)
        }
 }
 
-ZEND_API void _zval_dtor_func_for_ptr(zend_refcounted *p ZEND_FILE_LINE_DC)
+ZEND_API void ZEND_FASTCALL _zval_dtor_func_for_ptr(zend_refcounted *p ZEND_FILE_LINE_DC)
 {
        switch (GC_TYPE(p)) {
                case IS_STRING:
@@ -223,7 +223,7 @@ ZEND_API void zval_add_ref_unref(zval *p)
        }
 }
 
-ZEND_API void _zval_copy_ctor_func(zval *zvalue ZEND_FILE_LINE_DC)
+ZEND_API void ZEND_FASTCALL _zval_copy_ctor_func(zval *zvalue ZEND_FILE_LINE_DC)
 {
        if (EXPECTED(Z_TYPE_P(zvalue) == IS_ARRAY)) {
                ZVAL_ARR(zvalue, zend_array_dup(Z_ARRVAL_P(zvalue)));
@@ -255,12 +255,6 @@ ZEND_API void _zval_dtor_wrapper(zval *zvalue)
 
 
 #if ZEND_DEBUG
-ZEND_API void _zval_copy_ctor_wrapper(zval *zvalue)
-{
-       zval_copy_ctor(zvalue);
-}
-
-
 ZEND_API void _zval_internal_dtor_wrapper(zval *zvalue)
 {
        zval_internal_dtor(zvalue);
index 2dde2e8dd2ccdb17aefa06707fa122e7a05ce1c4..9ca31097c39fcc0e7ae03afb317ba6772f36d3ee 100644 (file)
 
 BEGIN_EXTERN_C()
 
-ZEND_API void _zval_dtor_func(zend_refcounted *p ZEND_FILE_LINE_DC);
-ZEND_API void _zval_dtor_func_for_ptr(zend_refcounted *p ZEND_FILE_LINE_DC);
+ZEND_API void ZEND_FASTCALL _zval_dtor_func(zend_refcounted *p ZEND_FILE_LINE_DC);
+ZEND_API void ZEND_FASTCALL _zval_dtor_func_for_ptr(zend_refcounted *p ZEND_FILE_LINE_DC);
+ZEND_API void ZEND_FASTCALL _zval_copy_ctor_func(zval *zvalue ZEND_FILE_LINE_DC);
+
+#define zval_dtor_func(p)         _zval_dtor_func(zv ZEND_FILE_LINE_CC)
+#define zval_dtor_func_for_ptr(p) _zval_dtor_func_for_ptr(zv ZEND_FILE_LINE_CC)
+#define zval_copy_ctor_func(zv)   _zval_copy_ctor_func(zv ZEND_FILE_LINE_CC)
 
 static zend_always_inline void _zval_dtor(zval *zvalue ZEND_FILE_LINE_DC)
 {
@@ -56,10 +61,6 @@ static zend_always_inline void i_zval_ptr_dtor(zval *zval_ptr ZEND_FILE_LINE_DC)
        }
 }
 
-ZEND_API void _zval_copy_ctor_func(zval *zvalue ZEND_FILE_LINE_DC);
-
-#define zval_copy_ctor_func(zv) _zval_copy_ctor_func(zv ZEND_FILE_LINE_CC)
-
 static zend_always_inline void _zval_copy_ctor(zval *zvalue ZEND_FILE_LINE_DC)
 {
        if (Z_REFCOUNTED_P(zvalue) || Z_IMMUTABLE_P(zvalue)) {
@@ -124,16 +125,13 @@ ZEND_API void _zval_dtor_wrapper(zval *zvalue);
 #define zval_dtor_wrapper _zval_dtor_wrapper
 
 #if ZEND_DEBUG
-ZEND_API void _zval_copy_ctor_wrapper(zval *zvalue);
 ZEND_API void _zval_ptr_dtor_wrapper(zval *zval_ptr);
 ZEND_API void _zval_internal_dtor_wrapper(zval *zvalue);
 ZEND_API void _zval_internal_ptr_dtor_wrapper(zval *zvalue);
-#define zval_copy_ctor_wrapper _zval_copy_ctor_wrapper
 #define zval_ptr_dtor_wrapper _zval_ptr_dtor_wrapper
 #define zval_internal_dtor_wrapper _zval_internal_dtor_wrapper
 #define zval_internal_ptr_dtor_wrapper _zval_internal_ptr_dtor_wrapper
 #else
-#define zval_copy_ctor_wrapper _zval_copy_ctor_func
 #define zval_ptr_dtor_wrapper _zval_ptr_dtor
 #define zval_internal_dtor_wrapper _zval_internal_dtor
 #define zval_internal_ptr_dtor_wrapper _zval_internal_ptr_dtor
@@ -148,7 +146,6 @@ END_EXTERN_C()
 #define ZVAL_PTR_DTOR zval_ptr_dtor_wrapper
 #define ZVAL_INTERNAL_DTOR zval_internal_dtor_wrapper
 #define ZVAL_INTERNAL_PTR_DTOR zval_internal_ptr_dtor_wrapper
-#define ZVAL_COPY_CTOR zval_copy_ctor_wrapper
 
 #endif
 
index e456bf268cb790e939ecf945e1c7fbd663af571b..ba5619f593c7e1bc2f3e33b457c5bdedb66444ae 100644 (file)
@@ -349,7 +349,7 @@ ZEND_VM_HANDLER(13, ZEND_BOOL_NOT, CONST|TMPVAR|CV, ANY)
        ZEND_VM_NEXT_OPCODE();
 }
 
-ZEND_VM_HELPER_EX(zend_binary_assign_op_obj_helper, VAR|UNUSED|CV, CONST|TMPVAR|CV, int (*binary_op)(zval *result, zval *op1, zval *op2))
+ZEND_VM_HELPER_EX(zend_binary_assign_op_obj_helper, VAR|UNUSED|CV, CONST|TMPVAR|CV, binary_op_type binary_op)
 {
        USE_OPLINE
        zend_free_op free_op1, free_op2, free_op_data1;
@@ -439,7 +439,7 @@ ZEND_VM_HELPER_EX(zend_binary_assign_op_obj_helper, VAR|UNUSED|CV, CONST|TMPVAR|
        ZEND_VM_NEXT_OPCODE();
 }
 
-ZEND_VM_HELPER_EX(zend_binary_assign_op_dim_helper, VAR|UNUSED|CV, CONST|TMPVAR|UNUSED|CV, int (*binary_op)(zval *result, zval *op1, zval *op2))
+ZEND_VM_HELPER_EX(zend_binary_assign_op_dim_helper, VAR|UNUSED|CV, CONST|TMPVAR|UNUSED|CV, binary_op_type binary_op)
 {
        USE_OPLINE
        zend_free_op free_op1, free_op2, free_op_data1;
@@ -509,7 +509,7 @@ ZEND_VM_HELPER_EX(zend_binary_assign_op_dim_helper, VAR|UNUSED|CV, CONST|TMPVAR|
        ZEND_VM_NEXT_OPCODE();
 }
 
-ZEND_VM_HELPER_EX(zend_binary_assign_op_helper, VAR|CV, CONST|TMPVAR|CV, int (*binary_op)(zval *result, zval *op1, zval *op2))
+ZEND_VM_HELPER_EX(zend_binary_assign_op_helper, VAR|CV, CONST|TMPVAR|CV, binary_op_type binary_op)
 {
        USE_OPLINE
        zend_free_op free_op1, free_op2;
index c239e2c88607e8811e5c99cf2f2e3450cebdc74a..454e97f4009b91ef869d0f77b1523a9db7b8860d 100644 (file)
@@ -13379,7 +13379,7 @@ static ZEND_OPCODE_HANDLER_RET ZEND_FASTCALL ZEND_IS_NOT_IDENTICAL_SPEC_VAR_CONS
        ZEND_VM_NEXT_OPCODE();
 }
 
-static ZEND_OPCODE_HANDLER_RET ZEND_FASTCALL zend_binary_assign_op_obj_helper_SPEC_VAR_CONST(int (*binary_op)(zval *result, zval *op1, zval *op2) ZEND_OPCODE_HANDLER_ARGS_DC)
+static ZEND_OPCODE_HANDLER_RET ZEND_FASTCALL zend_binary_assign_op_obj_helper_SPEC_VAR_CONST(binary_op_type binary_op ZEND_OPCODE_HANDLER_ARGS_DC)
 {
        USE_OPLINE
        zend_free_op free_op1, free_op_data1;
@@ -13469,7 +13469,7 @@ static ZEND_OPCODE_HANDLER_RET ZEND_FASTCALL zend_binary_assign_op_obj_helper_SP
        ZEND_VM_NEXT_OPCODE();
 }
 
-static ZEND_OPCODE_HANDLER_RET ZEND_FASTCALL zend_binary_assign_op_dim_helper_SPEC_VAR_CONST(int (*binary_op)(zval *result, zval *op1, zval *op2) ZEND_OPCODE_HANDLER_ARGS_DC)
+static ZEND_OPCODE_HANDLER_RET ZEND_FASTCALL zend_binary_assign_op_dim_helper_SPEC_VAR_CONST(binary_op_type binary_op ZEND_OPCODE_HANDLER_ARGS_DC)
 {
        USE_OPLINE
        zend_free_op free_op1, free_op_data1;
@@ -13538,7 +13538,7 @@ static ZEND_OPCODE_HANDLER_RET ZEND_FASTCALL zend_binary_assign_op_dim_helper_SP
        ZEND_VM_NEXT_OPCODE();
 }
 
-static ZEND_OPCODE_HANDLER_RET ZEND_FASTCALL zend_binary_assign_op_helper_SPEC_VAR_CONST(int (*binary_op)(zval *result, zval *op1, zval *op2) ZEND_OPCODE_HANDLER_ARGS_DC)
+static ZEND_OPCODE_HANDLER_RET ZEND_FASTCALL zend_binary_assign_op_helper_SPEC_VAR_CONST(binary_op_type binary_op ZEND_OPCODE_HANDLER_ARGS_DC)
 {
        USE_OPLINE
        zend_free_op free_op1;
@@ -15538,7 +15538,7 @@ static ZEND_OPCODE_HANDLER_RET ZEND_FASTCALL ZEND_YIELD_SPEC_VAR_VAR_HANDLER(ZEN
        ZEND_VM_RETURN();
 }
 
-static ZEND_OPCODE_HANDLER_RET ZEND_FASTCALL zend_binary_assign_op_dim_helper_SPEC_VAR_UNUSED(int (*binary_op)(zval *result, zval *op1, zval *op2) ZEND_OPCODE_HANDLER_ARGS_DC)
+static ZEND_OPCODE_HANDLER_RET ZEND_FASTCALL zend_binary_assign_op_dim_helper_SPEC_VAR_UNUSED(binary_op_type binary_op ZEND_OPCODE_HANDLER_ARGS_DC)
 {
        USE_OPLINE
        zend_free_op free_op1, free_op_data1;
@@ -16481,7 +16481,7 @@ static ZEND_OPCODE_HANDLER_RET ZEND_FASTCALL ZEND_IS_NOT_IDENTICAL_SPEC_VAR_CV_H
        ZEND_VM_NEXT_OPCODE();
 }
 
-static ZEND_OPCODE_HANDLER_RET ZEND_FASTCALL zend_binary_assign_op_obj_helper_SPEC_VAR_CV(int (*binary_op)(zval *result, zval *op1, zval *op2) ZEND_OPCODE_HANDLER_ARGS_DC)
+static ZEND_OPCODE_HANDLER_RET ZEND_FASTCALL zend_binary_assign_op_obj_helper_SPEC_VAR_CV(binary_op_type binary_op ZEND_OPCODE_HANDLER_ARGS_DC)
 {
        USE_OPLINE
        zend_free_op free_op1, free_op_data1;
@@ -16571,7 +16571,7 @@ static ZEND_OPCODE_HANDLER_RET ZEND_FASTCALL zend_binary_assign_op_obj_helper_SP
        ZEND_VM_NEXT_OPCODE();
 }
 
-static ZEND_OPCODE_HANDLER_RET ZEND_FASTCALL zend_binary_assign_op_dim_helper_SPEC_VAR_CV(int (*binary_op)(zval *result, zval *op1, zval *op2) ZEND_OPCODE_HANDLER_ARGS_DC)
+static ZEND_OPCODE_HANDLER_RET ZEND_FASTCALL zend_binary_assign_op_dim_helper_SPEC_VAR_CV(binary_op_type binary_op ZEND_OPCODE_HANDLER_ARGS_DC)
 {
        USE_OPLINE
        zend_free_op free_op1, free_op_data1;
@@ -16640,7 +16640,7 @@ static ZEND_OPCODE_HANDLER_RET ZEND_FASTCALL zend_binary_assign_op_dim_helper_SP
        ZEND_VM_NEXT_OPCODE();
 }
 
-static ZEND_OPCODE_HANDLER_RET ZEND_FASTCALL zend_binary_assign_op_helper_SPEC_VAR_CV(int (*binary_op)(zval *result, zval *op1, zval *op2) ZEND_OPCODE_HANDLER_ARGS_DC)
+static ZEND_OPCODE_HANDLER_RET ZEND_FASTCALL zend_binary_assign_op_helper_SPEC_VAR_CV(binary_op_type binary_op ZEND_OPCODE_HANDLER_ARGS_DC)
 {
        USE_OPLINE
        zend_free_op free_op1;
@@ -18133,7 +18133,7 @@ static ZEND_OPCODE_HANDLER_RET ZEND_FASTCALL ZEND_ASSIGN_POW_SPEC_VAR_CV_HANDLER
        return zend_binary_assign_op_helper_SPEC_VAR_CV(pow_function ZEND_OPCODE_HANDLER_ARGS_PASSTHRU_CC);
 }
 
-static ZEND_OPCODE_HANDLER_RET ZEND_FASTCALL zend_binary_assign_op_obj_helper_SPEC_VAR_TMPVAR(int (*binary_op)(zval *result, zval *op1, zval *op2) ZEND_OPCODE_HANDLER_ARGS_DC)
+static ZEND_OPCODE_HANDLER_RET ZEND_FASTCALL zend_binary_assign_op_obj_helper_SPEC_VAR_TMPVAR(binary_op_type binary_op ZEND_OPCODE_HANDLER_ARGS_DC)
 {
        USE_OPLINE
        zend_free_op free_op1, free_op2, free_op_data1;
@@ -18223,7 +18223,7 @@ static ZEND_OPCODE_HANDLER_RET ZEND_FASTCALL zend_binary_assign_op_obj_helper_SP
        ZEND_VM_NEXT_OPCODE();
 }
 
-static ZEND_OPCODE_HANDLER_RET ZEND_FASTCALL zend_binary_assign_op_dim_helper_SPEC_VAR_TMPVAR(int (*binary_op)(zval *result, zval *op1, zval *op2) ZEND_OPCODE_HANDLER_ARGS_DC)
+static ZEND_OPCODE_HANDLER_RET ZEND_FASTCALL zend_binary_assign_op_dim_helper_SPEC_VAR_TMPVAR(binary_op_type binary_op ZEND_OPCODE_HANDLER_ARGS_DC)
 {
        USE_OPLINE
        zend_free_op free_op1, free_op2, free_op_data1;
@@ -18293,7 +18293,7 @@ static ZEND_OPCODE_HANDLER_RET ZEND_FASTCALL zend_binary_assign_op_dim_helper_SP
        ZEND_VM_NEXT_OPCODE();
 }
 
-static ZEND_OPCODE_HANDLER_RET ZEND_FASTCALL zend_binary_assign_op_helper_SPEC_VAR_TMPVAR(int (*binary_op)(zval *result, zval *op1, zval *op2) ZEND_OPCODE_HANDLER_ARGS_DC)
+static ZEND_OPCODE_HANDLER_RET ZEND_FASTCALL zend_binary_assign_op_helper_SPEC_VAR_TMPVAR(binary_op_type binary_op ZEND_OPCODE_HANDLER_ARGS_DC)
 {
        USE_OPLINE
        zend_free_op free_op1, free_op2;
@@ -19662,7 +19662,7 @@ static ZEND_OPCODE_HANDLER_RET ZEND_FASTCALL ZEND_EXIT_SPEC_UNUSED_HANDLER(ZEND_
        ZEND_VM_NEXT_OPCODE(); /* Never reached */
 }
 
-static ZEND_OPCODE_HANDLER_RET ZEND_FASTCALL zend_binary_assign_op_obj_helper_SPEC_UNUSED_CONST(int (*binary_op)(zval *result, zval *op1, zval *op2) ZEND_OPCODE_HANDLER_ARGS_DC)
+static ZEND_OPCODE_HANDLER_RET ZEND_FASTCALL zend_binary_assign_op_obj_helper_SPEC_UNUSED_CONST(binary_op_type binary_op ZEND_OPCODE_HANDLER_ARGS_DC)
 {
        USE_OPLINE
        zend_free_op free_op_data1;
@@ -19752,7 +19752,7 @@ static ZEND_OPCODE_HANDLER_RET ZEND_FASTCALL zend_binary_assign_op_obj_helper_SP
        ZEND_VM_NEXT_OPCODE();
 }
 
-static ZEND_OPCODE_HANDLER_RET ZEND_FASTCALL zend_binary_assign_op_dim_helper_SPEC_UNUSED_CONST(int (*binary_op)(zval *result, zval *op1, zval *op2) ZEND_OPCODE_HANDLER_ARGS_DC)
+static ZEND_OPCODE_HANDLER_RET ZEND_FASTCALL zend_binary_assign_op_dim_helper_SPEC_UNUSED_CONST(binary_op_type binary_op ZEND_OPCODE_HANDLER_ARGS_DC)
 {
        USE_OPLINE
        zend_free_op free_op_data1;
@@ -21462,7 +21462,7 @@ static ZEND_OPCODE_HANDLER_RET ZEND_FASTCALL ZEND_YIELD_SPEC_UNUSED_VAR_HANDLER(
        ZEND_VM_RETURN();
 }
 
-static ZEND_OPCODE_HANDLER_RET ZEND_FASTCALL zend_binary_assign_op_dim_helper_SPEC_UNUSED_UNUSED(int (*binary_op)(zval *result, zval *op1, zval *op2) ZEND_OPCODE_HANDLER_ARGS_DC)
+static ZEND_OPCODE_HANDLER_RET ZEND_FASTCALL zend_binary_assign_op_dim_helper_SPEC_UNUSED_UNUSED(binary_op_type binary_op ZEND_OPCODE_HANDLER_ARGS_DC)
 {
        USE_OPLINE
        zend_free_op free_op_data1;
@@ -21939,7 +21939,7 @@ static ZEND_OPCODE_HANDLER_RET ZEND_FASTCALL ZEND_YIELD_SPEC_UNUSED_UNUSED_HANDL
        ZEND_VM_RETURN();
 }
 
-static ZEND_OPCODE_HANDLER_RET ZEND_FASTCALL zend_binary_assign_op_obj_helper_SPEC_UNUSED_CV(int (*binary_op)(zval *result, zval *op1, zval *op2) ZEND_OPCODE_HANDLER_ARGS_DC)
+static ZEND_OPCODE_HANDLER_RET ZEND_FASTCALL zend_binary_assign_op_obj_helper_SPEC_UNUSED_CV(binary_op_type binary_op ZEND_OPCODE_HANDLER_ARGS_DC)
 {
        USE_OPLINE
        zend_free_op free_op_data1;
@@ -22029,7 +22029,7 @@ static ZEND_OPCODE_HANDLER_RET ZEND_FASTCALL zend_binary_assign_op_obj_helper_SP
        ZEND_VM_NEXT_OPCODE();
 }
 
-static ZEND_OPCODE_HANDLER_RET ZEND_FASTCALL zend_binary_assign_op_dim_helper_SPEC_UNUSED_CV(int (*binary_op)(zval *result, zval *op1, zval *op2) ZEND_OPCODE_HANDLER_ARGS_DC)
+static ZEND_OPCODE_HANDLER_RET ZEND_FASTCALL zend_binary_assign_op_dim_helper_SPEC_UNUSED_CV(binary_op_type binary_op ZEND_OPCODE_HANDLER_ARGS_DC)
 {
        USE_OPLINE
        zend_free_op free_op_data1;
@@ -23364,7 +23364,7 @@ static ZEND_OPCODE_HANDLER_RET ZEND_FASTCALL ZEND_YIELD_SPEC_UNUSED_CV_HANDLER(Z
        ZEND_VM_RETURN();
 }
 
-static ZEND_OPCODE_HANDLER_RET ZEND_FASTCALL zend_binary_assign_op_obj_helper_SPEC_UNUSED_TMPVAR(int (*binary_op)(zval *result, zval *op1, zval *op2) ZEND_OPCODE_HANDLER_ARGS_DC)
+static ZEND_OPCODE_HANDLER_RET ZEND_FASTCALL zend_binary_assign_op_obj_helper_SPEC_UNUSED_TMPVAR(binary_op_type binary_op ZEND_OPCODE_HANDLER_ARGS_DC)
 {
        USE_OPLINE
        zend_free_op free_op2, free_op_data1;
@@ -23454,7 +23454,7 @@ static ZEND_OPCODE_HANDLER_RET ZEND_FASTCALL zend_binary_assign_op_obj_helper_SP
        ZEND_VM_NEXT_OPCODE();
 }
 
-static ZEND_OPCODE_HANDLER_RET ZEND_FASTCALL zend_binary_assign_op_dim_helper_SPEC_UNUSED_TMPVAR(int (*binary_op)(zval *result, zval *op1, zval *op2) ZEND_OPCODE_HANDLER_ARGS_DC)
+static ZEND_OPCODE_HANDLER_RET ZEND_FASTCALL zend_binary_assign_op_dim_helper_SPEC_UNUSED_TMPVAR(binary_op_type binary_op ZEND_OPCODE_HANDLER_ARGS_DC)
 {
        USE_OPLINE
        zend_free_op free_op2, free_op_data1;
@@ -26480,7 +26480,7 @@ static ZEND_OPCODE_HANDLER_RET ZEND_FASTCALL ZEND_BOOL_XOR_SPEC_CV_CONST_HANDLER
        ZEND_VM_NEXT_OPCODE();
 }
 
-static ZEND_OPCODE_HANDLER_RET ZEND_FASTCALL zend_binary_assign_op_obj_helper_SPEC_CV_CONST(int (*binary_op)(zval *result, zval *op1, zval *op2) ZEND_OPCODE_HANDLER_ARGS_DC)
+static ZEND_OPCODE_HANDLER_RET ZEND_FASTCALL zend_binary_assign_op_obj_helper_SPEC_CV_CONST(binary_op_type binary_op ZEND_OPCODE_HANDLER_ARGS_DC)
 {
        USE_OPLINE
        zend_free_op free_op_data1;
@@ -26570,7 +26570,7 @@ static ZEND_OPCODE_HANDLER_RET ZEND_FASTCALL zend_binary_assign_op_obj_helper_SP
        ZEND_VM_NEXT_OPCODE();
 }
 
-static ZEND_OPCODE_HANDLER_RET ZEND_FASTCALL zend_binary_assign_op_dim_helper_SPEC_CV_CONST(int (*binary_op)(zval *result, zval *op1, zval *op2) ZEND_OPCODE_HANDLER_ARGS_DC)
+static ZEND_OPCODE_HANDLER_RET ZEND_FASTCALL zend_binary_assign_op_dim_helper_SPEC_CV_CONST(binary_op_type binary_op ZEND_OPCODE_HANDLER_ARGS_DC)
 {
        USE_OPLINE
        zend_free_op free_op_data1;
@@ -26639,7 +26639,7 @@ static ZEND_OPCODE_HANDLER_RET ZEND_FASTCALL zend_binary_assign_op_dim_helper_SP
        ZEND_VM_NEXT_OPCODE();
 }
 
-static ZEND_OPCODE_HANDLER_RET ZEND_FASTCALL zend_binary_assign_op_helper_SPEC_CV_CONST(int (*binary_op)(zval *result, zval *op1, zval *op2) ZEND_OPCODE_HANDLER_ARGS_DC)
+static ZEND_OPCODE_HANDLER_RET ZEND_FASTCALL zend_binary_assign_op_helper_SPEC_CV_CONST(binary_op_type binary_op ZEND_OPCODE_HANDLER_ARGS_DC)
 {
        USE_OPLINE
 
@@ -29653,7 +29653,7 @@ static ZEND_OPCODE_HANDLER_RET ZEND_FASTCALL ZEND_YIELD_SPEC_CV_VAR_HANDLER(ZEND
        ZEND_VM_RETURN();
 }
 
-static ZEND_OPCODE_HANDLER_RET ZEND_FASTCALL zend_binary_assign_op_dim_helper_SPEC_CV_UNUSED(int (*binary_op)(zval *result, zval *op1, zval *op2) ZEND_OPCODE_HANDLER_ARGS_DC)
+static ZEND_OPCODE_HANDLER_RET ZEND_FASTCALL zend_binary_assign_op_dim_helper_SPEC_CV_UNUSED(binary_op_type binary_op ZEND_OPCODE_HANDLER_ARGS_DC)
 {
        USE_OPLINE
        zend_free_op free_op_data1;
@@ -31055,7 +31055,7 @@ static ZEND_OPCODE_HANDLER_RET ZEND_FASTCALL ZEND_BOOL_XOR_SPEC_CV_CV_HANDLER(ZE
        ZEND_VM_NEXT_OPCODE();
 }
 
-static ZEND_OPCODE_HANDLER_RET ZEND_FASTCALL zend_binary_assign_op_obj_helper_SPEC_CV_CV(int (*binary_op)(zval *result, zval *op1, zval *op2) ZEND_OPCODE_HANDLER_ARGS_DC)
+static ZEND_OPCODE_HANDLER_RET ZEND_FASTCALL zend_binary_assign_op_obj_helper_SPEC_CV_CV(binary_op_type binary_op ZEND_OPCODE_HANDLER_ARGS_DC)
 {
        USE_OPLINE
        zend_free_op free_op_data1;
@@ -31145,7 +31145,7 @@ static ZEND_OPCODE_HANDLER_RET ZEND_FASTCALL zend_binary_assign_op_obj_helper_SP
        ZEND_VM_NEXT_OPCODE();
 }
 
-static ZEND_OPCODE_HANDLER_RET ZEND_FASTCALL zend_binary_assign_op_dim_helper_SPEC_CV_CV(int (*binary_op)(zval *result, zval *op1, zval *op2) ZEND_OPCODE_HANDLER_ARGS_DC)
+static ZEND_OPCODE_HANDLER_RET ZEND_FASTCALL zend_binary_assign_op_dim_helper_SPEC_CV_CV(binary_op_type binary_op ZEND_OPCODE_HANDLER_ARGS_DC)
 {
        USE_OPLINE
        zend_free_op free_op_data1;
@@ -31214,7 +31214,7 @@ static ZEND_OPCODE_HANDLER_RET ZEND_FASTCALL zend_binary_assign_op_dim_helper_SP
        ZEND_VM_NEXT_OPCODE();
 }
 
-static ZEND_OPCODE_HANDLER_RET ZEND_FASTCALL zend_binary_assign_op_helper_SPEC_CV_CV(int (*binary_op)(zval *result, zval *op1, zval *op2) ZEND_OPCODE_HANDLER_ARGS_DC)
+static ZEND_OPCODE_HANDLER_RET ZEND_FASTCALL zend_binary_assign_op_helper_SPEC_CV_CV(binary_op_type binary_op ZEND_OPCODE_HANDLER_ARGS_DC)
 {
        USE_OPLINE
 
@@ -33206,7 +33206,7 @@ static ZEND_OPCODE_HANDLER_RET ZEND_FASTCALL ZEND_BOOL_XOR_SPEC_CV_TMPVAR_HANDLE
        ZEND_VM_NEXT_OPCODE();
 }
 
-static ZEND_OPCODE_HANDLER_RET ZEND_FASTCALL zend_binary_assign_op_obj_helper_SPEC_CV_TMPVAR(int (*binary_op)(zval *result, zval *op1, zval *op2) ZEND_OPCODE_HANDLER_ARGS_DC)
+static ZEND_OPCODE_HANDLER_RET ZEND_FASTCALL zend_binary_assign_op_obj_helper_SPEC_CV_TMPVAR(binary_op_type binary_op ZEND_OPCODE_HANDLER_ARGS_DC)
 {
        USE_OPLINE
        zend_free_op free_op2, free_op_data1;
@@ -33296,7 +33296,7 @@ static ZEND_OPCODE_HANDLER_RET ZEND_FASTCALL zend_binary_assign_op_obj_helper_SP
        ZEND_VM_NEXT_OPCODE();
 }
 
-static ZEND_OPCODE_HANDLER_RET ZEND_FASTCALL zend_binary_assign_op_dim_helper_SPEC_CV_TMPVAR(int (*binary_op)(zval *result, zval *op1, zval *op2) ZEND_OPCODE_HANDLER_ARGS_DC)
+static ZEND_OPCODE_HANDLER_RET ZEND_FASTCALL zend_binary_assign_op_dim_helper_SPEC_CV_TMPVAR(binary_op_type binary_op ZEND_OPCODE_HANDLER_ARGS_DC)
 {
        USE_OPLINE
        zend_free_op free_op2, free_op_data1;
@@ -33366,7 +33366,7 @@ static ZEND_OPCODE_HANDLER_RET ZEND_FASTCALL zend_binary_assign_op_dim_helper_SP
        ZEND_VM_NEXT_OPCODE();
 }
 
-static ZEND_OPCODE_HANDLER_RET ZEND_FASTCALL zend_binary_assign_op_helper_SPEC_CV_TMPVAR(int (*binary_op)(zval *result, zval *op1, zval *op2) ZEND_OPCODE_HANDLER_ARGS_DC)
+static ZEND_OPCODE_HANDLER_RET ZEND_FASTCALL zend_binary_assign_op_helper_SPEC_CV_TMPVAR(binary_op_type binary_op ZEND_OPCODE_HANDLER_ARGS_DC)
 {
        USE_OPLINE
        zend_free_op free_op2;
index 3e3c16558a3821c5c6d703edcef2018c2e394265..24be4d266afe3ff4f6fa7afa2735c559574bf7a1 100644 (file)
@@ -987,7 +987,7 @@ static void zend_optimize_block(zend_code_block *block, zend_op_array *op_array,
                                        ZEND_OP1_TYPE(opline)==IS_CONST &&
                                        ZEND_OP2_TYPE(opline)==IS_CONST) {
                        /* evaluate constant expressions */
-                       int (*binary_op)(zval *result, zval *op1, zval *op2) = get_binary_op(opline->opcode);
+                       binary_op_type binary_op = get_binary_op(opline->opcode);
                        zval result;
                        int er;
 
index 5bff6ab3a8dfc6b06065e0a1467725ecfe2e5794..f37084ed79c842abebf9b24f50aa7c43ebbf5d1f 100644 (file)
@@ -68,7 +68,7 @@ void zend_optimizer_pass1(zend_op_array *op_array, zend_optimizer_ctx *ctx)
                        if (ZEND_OP1_TYPE(opline) == IS_CONST &&
                                ZEND_OP2_TYPE(opline) == IS_CONST) {
                                /* binary operation with constant operands */
-                               int (*binary_op)(zval *result, zval *op1, zval *op2) = get_binary_op(opline->opcode);
+                               binary_op_type binary_op = get_binary_op(opline->opcode);
                                uint32_t tv = ZEND_RESULT(opline).var;          /* temporary variable */
                                zval result;
                                int er;