mirror of
https://github.com/php/php-src.git
synced 2024-11-23 18:04:36 +08:00
Improve dependencies
This commit is contained in:
parent
a753430fb9
commit
485412ecb1
@ -251,6 +251,10 @@ SOURCE=.\zend_execute.h
|
||||
# End Source File
|
||||
# Begin Source File
|
||||
|
||||
SOURCE=.\zend_execute_locks.h
|
||||
# End Source File
|
||||
# Begin Source File
|
||||
|
||||
SOURCE=.\zend_extensions.h
|
||||
# End Source File
|
||||
# Begin Source File
|
||||
|
@ -580,25 +580,6 @@ int zendlex(znode *zendlval CLS_DC);
|
||||
|
||||
#define PZVAL_IS_REF(z) ((z)->is_ref)
|
||||
|
||||
#define PZVAL_LOCK(z) ((z)->refcount++)
|
||||
#define PZVAL_UNLOCK(z) { ((z)->refcount--); \
|
||||
if (!(z)->refcount) { \
|
||||
(z)->refcount = 1; \
|
||||
(z)->is_ref = 0; \
|
||||
EG(garbage)[EG(garbage_ptr)++] = (z); \
|
||||
if (EG(garbage_ptr) == 4) { \
|
||||
zval_ptr_dtor(&EG(garbage)[0]); \
|
||||
zval_ptr_dtor(&EG(garbage)[1]); \
|
||||
EG(garbage)[0] = EG(garbage)[2]; \
|
||||
EG(garbage)[1] = EG(garbage)[3]; \
|
||||
EG(garbage_ptr) -= 2; \
|
||||
} \
|
||||
} \
|
||||
}
|
||||
|
||||
#define SELECTIVE_PZVAL_LOCK(pzv, pzn) if (!((pzn)->u.EA.type & EXT_TYPE_UNUSED)) { PZVAL_LOCK(pzv); }
|
||||
|
||||
|
||||
/* Lost In Stupid Parentheses */
|
||||
#define ARG_SHOULD_BE_SENT_BY_REF(offset, conduct_check, arg_types) \
|
||||
( \
|
||||
|
@ -31,6 +31,7 @@
|
||||
#include "zend_constants.h"
|
||||
#include "zend_extensions.h"
|
||||
#include "zend_fast_cache.h"
|
||||
#include "zend_execute_locks.h"
|
||||
|
||||
#if defined(HAVE_ALLOCA) && defined(HAVE_ALLOCA_H)
|
||||
# include <alloca.h>
|
||||
|
@ -30,6 +30,7 @@
|
||||
#include "zend_operators.h"
|
||||
#include "zend_constants.h"
|
||||
#include "zend_extensions.h"
|
||||
#include "zend_execute_locks.h"
|
||||
|
||||
|
||||
ZEND_API void (*zend_execute)(zend_op_array *op_array ELS_DC);
|
||||
|
22
Zend/zend_execute_locks.h
Normal file
22
Zend/zend_execute_locks.h
Normal file
@ -0,0 +1,22 @@
|
||||
#ifndef _ZEND_EXECUTE_LOCKS_H
|
||||
#define _ZEND_EXECUTE_LOCKS_H
|
||||
|
||||
#define PZVAL_LOCK(z) ((z)->refcount++)
|
||||
#define PZVAL_UNLOCK(z) { ((z)->refcount--); \
|
||||
if (!(z)->refcount) { \
|
||||
(z)->refcount = 1; \
|
||||
(z)->is_ref = 0; \
|
||||
EG(garbage)[EG(garbage_ptr)++] = (z); \
|
||||
if (EG(garbage_ptr) == 4) { \
|
||||
zval_ptr_dtor(&EG(garbage)[0]); \
|
||||
zval_ptr_dtor(&EG(garbage)[1]); \
|
||||
EG(garbage)[0] = EG(garbage)[2]; \
|
||||
EG(garbage)[1] = EG(garbage)[3]; \
|
||||
EG(garbage_ptr) -= 2; \
|
||||
} \
|
||||
} \
|
||||
}
|
||||
|
||||
#define SELECTIVE_PZVAL_LOCK(pzv, pzn) if (!((pzn)->u.EA.type & EXT_TYPE_UNUSED)) { PZVAL_LOCK(pzv); }
|
||||
|
||||
#endif /* _ZEND_EXECUTE_LOCKS_H */
|
Loading…
Reference in New Issue
Block a user