Home
last modified time | relevance | path

Searched refs:stack (Results 1 – 25 of 96) sorted by relevance

1234

/PHP-7.4/Zend/
H A Dzend_stack.c23 #define ZEND_STACK_ELEMENT(stack, n) ((void *)((char *) (stack)->elements + (stack)->size * (n))) argument
27 stack->size = size; in zend_stack_init()
28 stack->top = 0; in zend_stack_init()
29 stack->max = 0; in zend_stack_init()
37 if (stack->top >= stack->max) { in zend_stack_push()
39 stack->elements = safe_erealloc(stack->elements, stack->size, stack->max, 0); in zend_stack_push()
41 memcpy(ZEND_STACK_ELEMENT(stack, stack->top), element, stack->size); in zend_stack_push()
49 return ZEND_STACK_ELEMENT(stack, stack->top - 1); in zend_stack_top()
58 --stack->top; in zend_stack_del_top()
99 return stack->top; in zend_stack_count()
[all …]
H A Dzend_ptr_stack.h46 if (stack->top+count > stack->max) { \ in END_EXTERN_C()
50 } while (stack->top+count > stack->max); \ in END_EXTERN_C()
51stack->elements = (void **) perealloc(stack->elements, (sizeof(void *) * (stack->max)), stack->per… in END_EXTERN_C()
52 stack->top_element = stack->elements+stack->top; \ in END_EXTERN_C()
64 *(stack->top_element++) = a;
65 *(stack->top_element++) = b;
89 stack->top -= 3; in zend_ptr_stack_3_pop()
96 stack->top -= 2; in zend_ptr_stack_2_pop()
103 stack->top++; in zend_ptr_stack_push()
109 stack->top--; in zend_ptr_stack_pop()
[all …]
H A Dzend_ptr_stack.c26 stack->top_element = stack->elements = NULL; in zend_ptr_stack_init_ex()
27 stack->top = stack->max = 0; in zend_ptr_stack_init_ex()
47 stack->top++; in zend_ptr_stack_n_push()
64 stack->top--; in zend_ptr_stack_n_pop()
75 pefree(stack->elements, stack->persistent); in zend_ptr_stack_destroy()
82 int i = stack->top; in zend_ptr_stack_apply()
103 int i = stack->top; in zend_ptr_stack_clean()
106 pefree(stack->elements[i], stack->persistent); in zend_ptr_stack_clean()
109 stack->top = 0; in zend_ptr_stack_clean()
110 stack->top_element = stack->elements; in zend_ptr_stack_clean()
[all …]
H A Dzend_stack.h32 ZEND_API int zend_stack_init(zend_stack *stack, int size);
33 ZEND_API int zend_stack_push(zend_stack *stack, const void *element);
34 ZEND_API void *zend_stack_top(const zend_stack *stack);
35 ZEND_API int zend_stack_del_top(zend_stack *stack);
36 ZEND_API int zend_stack_int_top(const zend_stack *stack);
37 ZEND_API int zend_stack_is_empty(const zend_stack *stack);
38 ZEND_API int zend_stack_destroy(zend_stack *stack);
39 ZEND_API void *zend_stack_base(const zend_stack *stack);
40 ZEND_API int zend_stack_count(const zend_stack *stack);
41 ZEND_API void zend_stack_apply(zend_stack *stack, int type, int (*apply_function)(void *element));
[all …]
H A Dzend_gc.c288 return stack->next; in gc_stack_next()
294 (*stack) = gc_stack_next(*stack); in gc_stack_push()
306 (*stack) = (*stack)->prev; in gc_stack_pop()
320 stack = p->next; in gc_stack_free()
322 p = stack; in gc_stack_free()
696 GC_STACK_DCL(stack); in gc_scan_black()
814 GC_STACK_DCL(stack); in gc_mark_grey()
989 GC_STACK_DCL(stack); in gc_scan()
1438 gc_stack stack; in zend_gc_collect_cycles() local
1440 stack.prev = NULL; in zend_gc_collect_cycles()
[all …]
H A Dzend_execute.h160 #define ZEND_VM_STACK_ELEMENTS(stack) \ argument
161 (((zval*)(stack)) + ZEND_VM_STACK_HEADER_SLOTS)
171 …fine ZEND_ASSERT_VM_STACK(stack) ZEND_ASSERT(stack->top > (zval *) stack && stack->end > (zval *) argument
174 # define ZEND_ASSERT_VM_STACK(stack) argument
/PHP-7.4/ext/opcache/Optimizer/
H A Dzend_worklist.h44 stack->buf = (int*)zend_arena_calloc(arena, sizeof(*stack->buf), len); in zend_worklist_stack_prepare()
45 stack->len = 0; in zend_worklist_stack_prepare()
46 stack->capacity = len; in zend_worklist_stack_prepare()
53 ZEND_ASSERT(stack->len < stack->capacity); in zend_worklist_stack_push()
54 stack->buf[stack->len++] = i; in zend_worklist_stack_push()
59 ZEND_ASSERT(stack->len); in zend_worklist_stack_peek()
60 return stack->buf[stack->len - 1]; in zend_worklist_stack_peek()
65 ZEND_ASSERT(stack->len); in zend_worklist_stack_pop()
66 return stack->buf[--stack->len]; in zend_worklist_stack_pop()
71 zend_worklist_stack stack; member
[all …]
/PHP-7.4/ext/pcre/pcre2lib/sljit/
H A DsljitUtils.c242 stack->end = stack->min_start + max_size; in sljit_allocate_stack()
243 stack->start = stack->end - start_size; in sljit_allocate_stack()
244 stack->top = stack->end; in sljit_allocate_stack()
245 return stack; in sljit_allocate_stack()
301 munmap((void*)stack->min_start, stack->end - stack->min_start); in sljit_free_stack()
334 stack->end = stack->min_start + max_size; in sljit_allocate_stack()
335 stack->start = stack->end; in sljit_allocate_stack()
358 stack->end = stack->min_start + max_size; in sljit_allocate_stack()
359 stack->start = stack->end - start_size; in sljit_allocate_stack()
362 stack->top = stack->end; in sljit_allocate_stack()
[all …]
/PHP-7.4/ext/spl/tests/
H A Ddllist_004.phpt5 $stack = new SplStack();
8 $stack->pop();
13 $stack->shift();
20 $stack->push($a);
21 echo $stack->pop()."\n";
24 $stack->push(1);
25 $stack->push(2);
26 echo $stack->top()."\n";
34 $stack->push(NULL);
35 $stack->push(NULL);
[all …]
H A Dbug75673.phpt5 $stack = new SplStack();
6 $stack->push("one");
7 $stack->push("two");
9 $serialized = $stack->serialize();
10 var_dump($stack->count());
11 $stack->unserialize($serialized);
12 var_dump($stack->count());
13 $stack->unserialize($serialized);
14 var_dump($stack->count());
H A DSplStack_setIteratorMode.phpt7 $stack = new SplStack();
9 $stack->setIteratorMode(SplDoublyLinkedList::IT_MODE_FIFO);
/PHP-7.4/ext/com_dotnet/tests/
H A Dbug73679.phpt11 $stack = new DOTNET("mscorlib", "System.Collections.Stack", -2200000000);
12 $stack->Push(".Net");
13 $stack->Push("Hello ");
14 echo $stack->Pop() . $stack->Pop();
/PHP-7.4/ext/standard/tests/array/
H A Darray_shift_variation7.phpt5 /* Prototype : mixed array_shift(array &$stack)
16 $stack = array ('one' => 'un', 'two' => 'deux');
19 var_dump($result = array_shift($stack));
22 echo key($stack) . " => " . current ($stack) . "\n";
H A Darray_push_variation5.phpt5 /* Prototype : int array_push(array $stack, mixed $var [, mixed $...])
16 $stack = array ('one' => 'un', 'two' => 'deux');
20 var_dump($result = array_push($stack, $var0));
23 echo key($stack) . " => " . current ($stack) . "\n";
H A Darray_shift_variation5.phpt5 /* Prototype : mixed array_shift(array &$stack)
12 * as the $stack argument of another call to array_shift()
18 $stack = array ( array ( array ('zero', 'one', 'two'), 'un', 'deux'), 'eins', 'zwei');
22 var_dump(array_shift(array_shift(array_shift($stack))));
24 $stack = array (array( array('zero', 'one', 'two'), 'un', 'deux'), 'eins', 'zwei');
27 $result1 = array_shift($stack);
H A Darray_push_variation3.phpt5 /* Prototype : int array_push(array $stack, mixed $var [, mixed $...])
13 * 2. as sub-array as $stack arg
24 echo "\n-- Pass sub-array as \$stack argument --\n";
51 -- Pass sub-array as $stack argument --
/PHP-7.4/tests/lang/
H A DpassByReference_012.phpt8 $stack = array ( array ( 'two' ));
9 var_dump(array_shift(array_shift($stack)));
13 $stack = $original;
14 var_dump(array_shift(array_shift($stack)));
/PHP-7.4/sapi/phpdbg/
H A Dphpdbg_cmd.c376 if (stack && stack->next) { in phpdbg_stack_free()
430 stack->next = NULL; in phpdbg_stack_free()
446 stack->top = next; in phpdbg_stack_push()
448 stack->next = next; in phpdbg_stack_push()
451 next->top = stack->top; in phpdbg_stack_push()
452 stack->top = next; in phpdbg_stack_push()
455 stack->len++; in phpdbg_stack_push()
464 param->next = stack; in phpdbg_stack_separate()
465 stack->top = param->top; in phpdbg_stack_separate()
471 const phpdbg_param_t *top = (stack != NULL) ? *stack : NULL; in phpdbg_stack_verify()
[all …]
H A Dphpdbg_cmd.h141 PHPDBG_API void phpdbg_stack_push(phpdbg_param_t *stack, phpdbg_param_t *param);
144 PHPDBG_API int phpdbg_stack_verify(const phpdbg_command_t *command, phpdbg_param_t **stack);
145 PHPDBG_API int phpdbg_stack_execute(phpdbg_param_t *stack, zend_bool allow_async_unsafe);
146 PHPDBG_API void phpdbg_stack_free(phpdbg_param_t *stack);
H A Dphpdbg_lexer.l31 void phpdbg_init_lexer (phpdbg_param_t *stack, char *input) { in ZEND_EXTERN_MODULE_GLOBALS()
32 PHPDBG_G(parser_stack) = stack; in ZEND_EXTERN_MODULE_GLOBALS()
/PHP-7.4/Zend/tests/
H A Dbug36214.phpt6 public $stack = array();
9 $this->stack[$name] = $var;return;
13 return $this->stack[$name];
/PHP-7.4/ext/pdo_mysql/tests/
H A Dpdo_mysql_subclass.phpt38 $stack = debug_backtrace();
39 if (!isset($stack[1]))
42 printf("%s(", $stack[1]['function']);
44 foreach ($stack[1]['args'] as $k => $v)
/PHP-7.4/ext/pcre/pcre2lib/
H A Dpcre2_jit_misc.c147 jit_stack->stack = sljit_allocate_stack(startsize, maxsize, &jit_stack->memctl); in pcre2_jit_stack_create()
148 if (jit_stack->stack == NULL) in pcre2_jit_stack_create()
193 sljit_free_stack((struct sljit_stack *)(jit_stack->stack), &jit_stack->memctl); in pcre2_jit_stack_free()
/PHP-7.4/ext/mbstring/tests/
H A Dmbregex_stack_limit2.phpt2 Test oniguruma stack limit
30 Warning: mb_ereg_replace(): mbregex search failure in php_mbereg_replace_exec(): match-stack limit …
/PHP-7.4/sapi/cli/
H A Dconfig.w3214 ADD_FLAG("LDFLAGS_CLI", "/stack:67108864");
24 ADD_FLAG("LDFLAGS_CLI_WIN32", "/stack:67108864");

Completed in 53 milliseconds

1234