/opt/alt/php72/usr/include/php/Zend
NameSizeModeActions
zend.h128750644editdlrm
zend_alloc.h192960644editdlrm
zend_alloc_sizes.h27790644editdlrm
zend_API.h604960644editdlrm
zend_arena.h37960644editdlrm
zend_ast.h84630644editdlrm
zend_bitset.h70970644editdlrm
zend_build.h17760644editdlrm
zend_builtin_functions.h16670644editdlrm
zend_closures.h21360644editdlrm
zend_compile.h335070644editdlrm
zend_config.h1070644editdlrm
zend_config.nw.h25540644editdlrm
zend_config.w32.h28360644editdlrm
zend_constants.h60400644editdlrm
zend_dtrace.h21010644editdlrm
zend_errors.h22120644editdlrm
zend_exceptions.h39580644editdlrm
zend_execute.h145130644editdlrm
zend_extensions.h61230644editdlrm
zend_float.h157020644editdlrm
zend_gc.h51400644editdlrm
zend_generators.h75640644editdlrm
zend_globals.h73540644editdlrm
zend_globals_macros.h28290644editdlrm
zend_hash.h345600644editdlrm
zend_highlight.h24300644editdlrm
zend_inheritance.h20080644editdlrm
zend_ini.h97100644editdlrm
zend_ini_parser.h27520644editdlrm
zend_ini_scanner.h20350644editdlrm
zend_ini_scanner_defs.h2240644editdlrm
zend_interfaces.h44280644editdlrm
zend_istdiostream.h16990644editdlrm
zend_iterators.h36390644editdlrm
zend_language_parser.h81480644editdlrm
zend_language_scanner.h28400644editdlrm
zend_language_scanner_defs.h2970644editdlrm
zend_list.h32950644editdlrm
zend_llist.h39520644editdlrm
zend_long.h44610644editdlrm
zend_modules.h49520644editdlrm
zend_multibyte.h50010644editdlrm
zend_multiply.h96510644editdlrm
zend_objects.h19260644editdlrm
zend_objects_API.h35620644editdlrm
zend_object_handlers.h94440644editdlrm
zend_operators.h314970644editdlrm
zend_portability.h153320644editdlrm
zend_ptr_stack.h43790644editdlrm
zend_range_check.h31500644editdlrm
zend_signal.h41520644editdlrm
zend_smart_str.h52550644editdlrm
zend_smart_string.h50090644editdlrm
zend_smart_string_public.h15540644editdlrm
zend_smart_str_public.h14290644editdlrm
zend_sort.h17980644editdlrm
zend_stack.h25220644editdlrm
zend_stream.h34580644editdlrm
zend_string.h151720644editdlrm
zend_strtod.h20160644editdlrm
zend_strtod_int.h36490644editdlrm
zend_ts_hash.h67200644editdlrm
zend_types.h338370644editdlrm
zend_type_info.h32530644editdlrm
zend_variables.h47820644editdlrm
zend_virtual_cwd.h126650644editdlrm
zend_vm.h20250644editdlrm
zend_vm_def.h2594650644editdlrm
zend_vm_execute.h23124490644editdlrm
zend_vm_opcodes.h129480644editdlrm
Edit: /opt/alt/php72/usr/include/php/Zend/zend_bitset.h (7097B)
/* +----------------------------------------------------------------------+ | Zend OPcache JIT | +----------------------------------------------------------------------+ | Copyright (c) 1998-2018 The PHP Group | +----------------------------------------------------------------------+ | This source file is subject to version 3.01 of the PHP license, | | that is bundled with this package in the file LICENSE, and is | | available through the world-wide-web at the following url: | | http://www.php.net/license/3_01.txt | | If you did not receive a copy of the PHP license and are unable to | | obtain it through the world-wide-web, please send a note to | | license@php.net so we can mail you a copy immediately. | +----------------------------------------------------------------------+ | Authors: Dmitry Stogov | +----------------------------------------------------------------------+ */ /* $Id:$ */ #ifndef _ZEND_BITSET_H_ #define _ZEND_BITSET_H_ typedef zend_ulong *zend_bitset; #define ZEND_BITSET_ELM_SIZE sizeof(zend_ulong) #if SIZEOF_ZEND_LONG == 4 # define ZEND_BITSET_ELM_NUM(n) ((n) >> 5) # define ZEND_BITSET_BIT_NUM(n) ((zend_ulong)(n) & Z_UL(0x1f)) #elif SIZEOF_ZEND_LONG == 8 # define ZEND_BITSET_ELM_NUM(n) ((n) >> 6) # define ZEND_BITSET_BIT_NUM(n) ((zend_ulong)(n) & Z_UL(0x3f)) #else # define ZEND_BITSET_ELM_NUM(n) ((n) / (sizeof(zend_long) * 8)) # define ZEND_BITSET_BIT_NUM(n) ((n) % (sizeof(zend_long) * 8)) #endif #define ZEND_BITSET_ALLOCA(n, use_heap) \ (zend_bitset)do_alloca((n) * ZEND_BITSET_ELM_SIZE, use_heap) /* Number of trailing zero bits (0x01 -> 0; 0x40 -> 6; 0x00 -> LEN) */ static zend_always_inline int zend_ulong_ntz(zend_ulong num) { #if (defined(__GNUC__) || __has_builtin(__builtin_ctzl)) \ && SIZEOF_ZEND_LONG == SIZEOF_LONG && defined(PHP_HAVE_BUILTIN_CTZL) return __builtin_ctzl(num); #elif (defined(__GNUC__) || __has_builtin(__builtin_ctzll)) && defined(PHP_HAVE_BUILTIN_CTZLL) return __builtin_ctzll(num); #elif defined(_WIN32) unsigned long index; #if defined(_WIN64) if (!BitScanForward64(&index, num)) { #else if (!BitScanForward(&index, num)) { #endif /* undefined behavior */ return SIZEOF_ZEND_LONG * 8; } return (int) index; #else int n; if (num == Z_UL(0)) return SIZEOF_ZEND_LONG * 8; n = 1; #if SIZEOF_ZEND_LONG == 8 if ((num & 0xffffffff) == 0) {n += 32; num = num >> Z_UL(32);} #endif if ((num & 0x0000ffff) == 0) {n += 16; num = num >> 16;} if ((num & 0x000000ff) == 0) {n += 8; num = num >> 8;} if ((num & 0x0000000f) == 0) {n += 4; num = num >> 4;} if ((num & 0x00000003) == 0) {n += 2; num = num >> 2;} return n - (num & 1); #endif } /* Returns the number of zend_ulong words needed to store a bitset that is N bits long. */ static inline uint32_t zend_bitset_len(uint32_t n) { return (n + ((sizeof(zend_long) * 8) - 1)) / (sizeof(zend_long) * 8); } static inline zend_bool zend_bitset_in(zend_bitset set, uint32_t n) { return (set[ZEND_BITSET_ELM_NUM(n)] & (Z_UL(1) << ZEND_BITSET_BIT_NUM(n))) != Z_UL(0); } static inline void zend_bitset_incl(zend_bitset set, uint32_t n) { set[ZEND_BITSET_ELM_NUM(n)] |= Z_UL(1) << ZEND_BITSET_BIT_NUM(n); } static inline void zend_bitset_excl(zend_bitset set, uint32_t n) { set[ZEND_BITSET_ELM_NUM(n)] &= ~(Z_UL(1) << ZEND_BITSET_BIT_NUM(n)); } static inline void zend_bitset_clear(zend_bitset set, uint32_t len) { memset(set, 0, len * ZEND_BITSET_ELM_SIZE); } static inline int zend_bitset_empty(zend_bitset set, uint32_t len) { uint32_t i; for (i = 0; i < len; i++) { if (set[i]) { return 0; } } return 1; } static inline void zend_bitset_fill(zend_bitset set, uint32_t len) { memset(set, 0xff, len * ZEND_BITSET_ELM_SIZE); } static inline zend_bool zend_bitset_equal(zend_bitset set1, zend_bitset set2, uint32_t len) { return memcmp(set1, set2, len * ZEND_BITSET_ELM_SIZE) == 0; } static inline void zend_bitset_copy(zend_bitset set1, zend_bitset set2, uint32_t len) { memcpy(set1, set2, len * ZEND_BITSET_ELM_SIZE); } static inline void zend_bitset_intersection(zend_bitset set1, zend_bitset set2, uint32_t len) { uint32_t i; for (i = 0; i < len; i++) { set1[i] &= set2[i]; } } static inline void zend_bitset_union(zend_bitset set1, zend_bitset set2, uint32_t len) { uint32_t i; for (i = 0; i < len; i++) { set1[i] |= set2[i]; } } static inline void zend_bitset_difference(zend_bitset set1, zend_bitset set2, uint32_t len) { uint32_t i; for (i = 0; i < len; i++) { set1[i] = set1[i] & ~set2[i]; } } static inline void zend_bitset_union_with_intersection(zend_bitset set1, zend_bitset set2, zend_bitset set3, zend_bitset set4, uint32_t len) { uint32_t i; for (i = 0; i < len; i++) { set1[i] = set2[i] | (set3[i] & set4[i]); } } static inline void zend_bitset_union_with_difference(zend_bitset set1, zend_bitset set2, zend_bitset set3, zend_bitset set4, uint32_t len) { uint32_t i; for (i = 0; i < len; i++) { set1[i] = set2[i] | (set3[i] & ~set4[i]); } } static inline zend_bool zend_bitset_subset(zend_bitset set1, zend_bitset set2, uint32_t len) { uint32_t i; for (i = 0; i < len; i++) { if (set1[i] & ~set2[i]) { return 0; } } return 1; } static inline int zend_bitset_first(zend_bitset set, uint32_t len) { uint32_t i; for (i = 0; i < len; i++) { if (set[i]) { return ZEND_BITSET_ELM_SIZE * 8 * i + zend_ulong_ntz(set[i]); } } return -1; /* empty set */ } static inline int zend_bitset_last(zend_bitset set, uint32_t len) { uint32_t i = len; while (i > 0) { i--; if (set[i]) { int j = ZEND_BITSET_ELM_SIZE * 8 * i - 1; zend_ulong x = set[i]; while (x != Z_UL(0)) { x = x >> Z_UL(1); j++; } return j; } } return -1; /* empty set */ } #define ZEND_BITSET_FOREACH(set, len, bit) do { \ zend_bitset _set = (set); \ uint32_t _i, _len = (len); \ for (_i = 0; _i < _len; _i++) { \ zend_ulong _x = _set[_i]; \ if (_x) { \ (bit) = ZEND_BITSET_ELM_SIZE * 8 * _i; \ for (; _x != 0; _x >>= Z_UL(1), (bit)++) { \ if (!(_x & Z_UL(1))) continue; #define ZEND_BITSET_REVERSE_FOREACH(set, len, bit) do { \ zend_bitset _set = (set); \ uint32_t _i = (len); \ zend_ulong _test = Z_UL(1) << (ZEND_BITSET_ELM_SIZE * 8 - 1); \ while (_i-- > 0) { \ zend_ulong _x = _set[_i]; \ if (_x) { \ (bit) = ZEND_BITSET_ELM_SIZE * 8 * (_i + 1) - 1; \ for (; _x != 0; _x <<= Z_UL(1), (bit)--) { \ if (!(_x & _test)) continue; \ #define ZEND_BITSET_FOREACH_END() \ } \ } \ } \ } while (0) static inline int zend_bitset_pop_first(zend_bitset set, uint32_t len) { int i = zend_bitset_first(set, len); if (i >= 0) { zend_bitset_excl(set, i); } return i; } #endif /* _ZEND_BITSET_H_ */ /* * Local variables: * tab-width: 4 * c-basic-offset: 4 * indent-tabs-mode: t * End: * vim600: sw=4 ts=4 fdm=marker * vim<600: sw=4 ts=4 */