diff options
author | Dmitry Stogov <dmitry@zend.com> | 2018-05-08 11:58:17 +0300 |
---|---|---|
committer | Dmitry Stogov <dmitry@zend.com> | 2018-05-08 11:58:17 +0300 |
commit | 4ad9cf460595efd1151faec0780b6ae5a4e0bc57 (patch) | |
tree | 21ce3f1d510267c812e54470a5addcb689de300f /Zend/zend_alloc.c | |
parent | dc796b04c1193e0ca5def1239c5bd2bd93d5af09 (diff) | |
download | php-git-4ad9cf460595efd1151faec0780b6ae5a4e0bc57.tar.gz |
Bit test optimization
Diffstat (limited to 'Zend/zend_alloc.c')
-rw-r--r-- | Zend/zend_alloc.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/Zend/zend_alloc.c b/Zend/zend_alloc.c index b5c705610d..30f98ff50c 100644 --- a/Zend/zend_alloc.c +++ b/Zend/zend_alloc.c @@ -587,7 +587,7 @@ static zend_always_inline int zend_mm_bitset_find_zero_and_set(zend_mm_bitset *b static zend_always_inline int zend_mm_bitset_is_set(zend_mm_bitset *bitset, int bit) { - return (bitset[bit / ZEND_MM_BITSET_LEN] & (Z_L(1) << (bit & (ZEND_MM_BITSET_LEN-1)))) != 0; + return ZEND_BIT_TEST(bitset, bit); } static zend_always_inline void zend_mm_bitset_set_bit(zend_mm_bitset *bitset, int bit) |