Lines Matching refs:EG

78 				active_opline-EG(active_op_array)->opcodes,
135 ZVAL_NULL(&EG(uninitialized_zval)); in init_executor()
136 ZVAL_ERROR(&EG(error_zval)); in init_executor()
142 EG(symtable_cache_ptr) = EG(symtable_cache); in init_executor()
143 EG(symtable_cache_limit) = EG(symtable_cache) + SYMTABLE_CACHE_SIZE; in init_executor()
144 EG(no_extensions) = 0; in init_executor()
146 EG(function_table) = CG(function_table); in init_executor()
147 EG(class_table) = CG(class_table); in init_executor()
149 EG(in_autoload) = NULL; in init_executor()
150 EG(error_handling) = EH_NORMAL; in init_executor()
151 EG(flags) = EG_FLAGS_INITIAL; in init_executor()
155 zend_hash_init(&EG(symbol_table), 64, NULL, ZVAL_PTR_DTOR, 0); in init_executor()
159 zend_hash_init(&EG(included_files), 8, NULL, NULL, 0); in init_executor()
161 EG(ticks_count) = 0; in init_executor()
163 ZVAL_UNDEF(&EG(user_error_handler)); in init_executor()
164 ZVAL_UNDEF(&EG(user_exception_handler)); in init_executor()
166 EG(current_execute_data) = NULL; in init_executor()
168 zend_stack_init(&EG(user_error_handlers_error_reporting), sizeof(int)); in init_executor()
169 zend_stack_init(&EG(user_error_handlers), sizeof(zval)); in init_executor()
170 zend_stack_init(&EG(user_exception_handlers), sizeof(zval)); in init_executor()
172 zend_objects_store_init(&EG(objects_store), 1024); in init_executor()
174 EG(full_tables_cleanup) = 0; in init_executor()
175 ZEND_ATOMIC_BOOL_INIT(&EG(vm_interrupt), false); in init_executor()
176 ZEND_ATOMIC_BOOL_INIT(&EG(timed_out), false); in init_executor()
178 EG(exception) = NULL; in init_executor()
179 EG(prev_exception) = NULL; in init_executor()
181 EG(fake_scope) = NULL; in init_executor()
182 EG(trampoline).common.function_name = NULL; in init_executor()
184 EG(ht_iterators_count) = sizeof(EG(ht_iterators_slots)) / sizeof(HashTableIterator); in init_executor()
185 EG(ht_iterators_used) = 0; in init_executor()
186 EG(ht_iterators) = EG(ht_iterators_slots); in init_executor()
187 memset(EG(ht_iterators), 0, sizeof(EG(ht_iterators_slots))); in init_executor()
189 EG(persistent_constants_count) = EG(zend_constants)->nNumUsed; in init_executor()
190 EG(persistent_functions_count) = EG(function_table)->nNumUsed; in init_executor()
191 EG(persistent_classes_count) = EG(class_table)->nNumUsed; in init_executor()
193 EG(get_gc_buffer).start = EG(get_gc_buffer).end = EG(get_gc_buffer).cur = NULL; in init_executor()
195 EG(record_errors) = false; in init_executor()
196 EG(num_errors) = 0; in init_executor()
197 EG(errors) = NULL; in init_executor()
199 EG(filename_override) = NULL; in init_executor()
200 EG(lineno_override) = -1; in init_executor()
206 EG(active) = 1; in init_executor()
254 EG(symbol_table).pDestructor = zend_unclean_zval_ptr_dtor; in shutdown_destructors()
259 symbols = zend_hash_num_elements(&EG(symbol_table)); in shutdown_destructors()
260 zend_hash_reverse_apply(&EG(symbol_table), (apply_func_t) zval_call_destructor); in shutdown_destructors()
261 } while (symbols != zend_hash_num_elements(&EG(symbol_table))); in shutdown_destructors()
262 zend_objects_store_call_destructors(&EG(objects_store)); in shutdown_destructors()
265 zend_objects_store_mark_destructed(&EG(objects_store)); in shutdown_destructors()
276 EG(flags) |= EG_FLAGS_IN_RESOURCE_SHUTDOWN; in zend_shutdown_executor_values()
278 zend_close_rsrc_list(&EG(regular_list)); in zend_shutdown_executor_values()
282 EG(active) = 0; in zend_shutdown_executor_values()
285 zend_hash_graceful_reverse_destroy(&EG(symbol_table)); in zend_shutdown_executor_values()
288 if (EG(full_tables_cleanup)) { in zend_shutdown_executor_values()
289 zend_hash_reverse_apply(EG(zend_constants), clean_non_persistent_constant_full); in zend_shutdown_executor_values()
291 ZEND_HASH_MAP_REVERSE_FOREACH_STR_KEY_VAL(EG(zend_constants), key, zv) { in zend_shutdown_executor_values()
293 if (_idx == EG(persistent_constants_count)) { in zend_shutdown_executor_values()
307 ZEND_HASH_MAP_REVERSE_FOREACH_VAL(EG(function_table), zv) { in zend_shutdown_executor_values()
320 ZEND_HASH_MAP_REVERSE_FOREACH_VAL(EG(class_table), zv) { in zend_shutdown_executor_values()
377 if (Z_TYPE(EG(user_error_handler)) != IS_UNDEF) { in zend_shutdown_executor_values()
378 zval_ptr_dtor(&EG(user_error_handler)); in zend_shutdown_executor_values()
379 ZVAL_UNDEF(&EG(user_error_handler)); in zend_shutdown_executor_values()
382 if (Z_TYPE(EG(user_exception_handler)) != IS_UNDEF) { in zend_shutdown_executor_values()
383 zval_ptr_dtor(&EG(user_exception_handler)); in zend_shutdown_executor_values()
384 ZVAL_UNDEF(&EG(user_exception_handler)); in zend_shutdown_executor_values()
387 zend_stack_clean(&EG(user_error_handlers_error_reporting), NULL, 1); in zend_shutdown_executor_values()
388 zend_stack_clean(&EG(user_error_handlers), (void (*)(void *))ZVAL_PTR_DTOR, 1); in zend_shutdown_executor_values()
389 zend_stack_clean(&EG(user_exception_handlers), (void (*)(void *))ZVAL_PTR_DTOR, 1); in zend_shutdown_executor_values()
397 zend_hash_discard(EG(zend_constants), EG(persistent_constants_count)); in zend_shutdown_executor_values()
400 zend_objects_store_free_object_storage(&EG(objects_store), fast_shutdown); in zend_shutdown_executor_values()
410 bool fast_shutdown = is_zend_mm() && !EG(full_tables_cleanup); in shutdown_executor()
433 zend_hash_discard(EG(function_table), EG(persistent_functions_count)); in shutdown_executor()
434 zend_hash_discard(EG(class_table), EG(persistent_classes_count)); in shutdown_executor()
438 if (EG(full_tables_cleanup)) { in shutdown_executor()
439 zend_hash_reverse_apply(EG(function_table), clean_non_persistent_function_full); in shutdown_executor()
440 zend_hash_reverse_apply(EG(class_table), clean_non_persistent_class_full); in shutdown_executor()
442 ZEND_HASH_MAP_REVERSE_FOREACH_STR_KEY_VAL(EG(function_table), key, zv) { in shutdown_executor()
444 if (_idx == EG(persistent_functions_count)) { in shutdown_executor()
451 ZEND_HASH_MAP_REVERSE_FOREACH_STR_KEY_VAL(EG(class_table), key, zv) { in shutdown_executor()
452 if (_idx == EG(persistent_classes_count)) { in shutdown_executor()
460 while (EG(symtable_cache_ptr) > EG(symtable_cache)) { in shutdown_executor()
461 EG(symtable_cache_ptr)--; in shutdown_executor()
462 zend_hash_destroy(*EG(symtable_cache_ptr)); in shutdown_executor()
463 FREE_HASHTABLE(*EG(symtable_cache_ptr)); in shutdown_executor()
466 zend_hash_destroy(&EG(included_files)); in shutdown_executor()
468 zend_stack_destroy(&EG(user_error_handlers_error_reporting)); in shutdown_executor()
469 zend_stack_destroy(&EG(user_error_handlers)); in shutdown_executor()
470 zend_stack_destroy(&EG(user_exception_handlers)); in shutdown_executor()
471 zend_objects_store_destroy(&EG(objects_store)); in shutdown_executor()
472 if (EG(in_autoload)) { in shutdown_executor()
473 zend_hash_destroy(EG(in_autoload)); in shutdown_executor()
474 FREE_HASHTABLE(EG(in_autoload)); in shutdown_executor()
477 if (EG(ht_iterators) != EG(ht_iterators_slots)) { in shutdown_executor()
478 efree(EG(ht_iterators)); in shutdown_executor()
483 if (EG(ht_iterators_used) && !CG(unclean_shutdown)) { in shutdown_executor()
484 zend_error(E_WARNING, "Leaked %" PRIu32 " hashtable iterators", EG(ht_iterators_used)); in shutdown_executor()
489 ZEND_ASSERT(EG(trampoline).common.function_name == NULL || CG(unclean_shutdown)); in shutdown_executor()
491 EG(ht_iterators_used) = 0; in shutdown_executor()
509 func = EG(current_execute_data)->func; in get_active_class_name()
539 func = EG(current_execute_data)->func; in get_active_function_name()
565 return get_function_or_method_name(EG(current_execute_data)->func); in get_active_function_or_method_name()
587 func = EG(current_execute_data)->func; in get_active_function_arg_name()
616 zend_string *filename_override = EG(filename_override); in zend_get_executed_filename_ex()
621 zend_execute_data *ex = EG(current_execute_data); in zend_get_executed_filename_ex()
636 zend_long lineno_override = EG(lineno_override); in zend_get_executed_lineno()
641 zend_execute_data *ex = EG(current_execute_data); in zend_get_executed_lineno()
651 if (EG(exception) && ex->opline->opcode == ZEND_HANDLE_EXCEPTION && in zend_get_executed_lineno()
652 ex->opline->lineno == 0 && EG(opline_before_exception)) { in zend_get_executed_lineno()
653 return EG(opline_before_exception)->lineno; in zend_get_executed_lineno()
664 zend_execute_data *ex = EG(current_execute_data); in zend_get_executed_scope()
679 return EG(current_execute_data) != 0; in zend_is_executing()
732 …return zval_update_constant_ex(pp, EG(current_execute_data) ? zend_get_executed_scope() : CG(activ… in zval_update_constant()
769 if (!EG(active)) { in zend_call_function()
773 if (EG(exception)) { in zend_call_function()
817 if (UNEXPECTED(EG(exception))) { in zend_call_function()
841 if (UNEXPECTED(EG(exception))) { in zend_call_function()
899 if (UNEXPECTED(EG(exception))) { in zend_call_function()
950 orig_fake_scope = EG(fake_scope); in zend_call_function()
951 EG(fake_scope) = NULL; in zend_call_function()
953 uint32_t orig_jit_trace_num = EG(jit_trace_num); in zend_call_function()
958 EG(jit_trace_num) = orig_jit_trace_num; in zend_call_function()
962 call->prev_execute_data = EG(current_execute_data); in zend_call_function()
963 EG(current_execute_data) = call; in zend_call_function()
976 if (!EG(exception) && call->func) { in zend_call_function()
987 EG(current_execute_data) = call->prev_execute_data; in zend_call_function()
993 if (EG(exception)) { in zend_call_function()
1000 if (zend_atomic_bool_exchange_ex(&EG(vm_interrupt), false)) { in zend_call_function()
1001 if (zend_atomic_bool_load_ex(&EG(timed_out))) { in zend_call_function()
1004 zend_interrupt_function(EG(current_execute_data)); in zend_call_function()
1012 EG(fake_scope) = orig_fake_scope; in zend_call_function()
1016 if (UNEXPECTED(EG(exception))) { in zend_call_function()
1017 if (UNEXPECTED(!EG(current_execute_data))) { in zend_call_function()
1019 } else if (EG(current_execute_data)->func && in zend_call_function()
1020 ZEND_USER_CODE(EG(current_execute_data)->func->common.type)) { in zend_call_function()
1021 zend_rethrow_exception(EG(current_execute_data)); in zend_call_function()
1053 if (!EG(exception)) { in zend_call_known_function()
1149 zv = zend_hash_find(EG(class_table), lc_name); in zend_lookup_class_ex()
1198 if (EG(in_autoload) == NULL) { in zend_lookup_class_ex()
1199 ALLOC_HASHTABLE(EG(in_autoload)); in zend_lookup_class_ex()
1200 zend_hash_init(EG(in_autoload), 8, NULL, NULL, 0); in zend_lookup_class_ex()
1203 if (zend_hash_add_empty_element(EG(in_autoload), lc_name) == NULL) { in zend_lookup_class_ex()
1216 zend_string *previous_filename = EG(filename_override); in zend_lookup_class_ex()
1217 zend_long previous_lineno = EG(lineno_override); in zend_lookup_class_ex()
1218 EG(filename_override) = NULL; in zend_lookup_class_ex()
1219 EG(lineno_override) = -1; in zend_lookup_class_ex()
1223 EG(filename_override) = previous_filename; in zend_lookup_class_ex()
1224 EG(lineno_override) = previous_lineno; in zend_lookup_class_ex()
1227 zend_hash_del(EG(in_autoload), lc_name); in zend_lookup_class_ex()
1306 EG(no_extensions)=1; in zend_eval_stringl()
1331 EG(no_extensions)=0; in zend_eval_stringl()
1355 if (handle_exceptions && EG(exception)) { in zend_eval_stringl_ex()
1356 result = zend_exception_error(EG(exception), E_ERROR); in zend_eval_stringl_ex()
1378 if (EG(hard_timeout) > 0) { in zend_timeout()
1379 zend_atomic_bool_store_ex(&EG(timed_out), false); in zend_timeout()
1380 zend_set_timeout_ex(EG(hard_timeout), 1); in zend_timeout()
1382 EG(hard_timeout) = 0; in zend_timeout()
1386 zend_atomic_bool_store_ex(&EG(timed_out), false); in zend_timeout()
1390 …"Maximum execution time of " ZEND_LONG_FMT " second%s exceeded", EG(timeout_seconds), EG(timeout_s… in zend_timeout()
1406 if (si->si_value.sival_ptr != &EG(max_execution_timer_timer)) { in zend_timeout_handler()
1411 if (EG(oldact).sa_sigaction) { in zend_timeout_handler()
1412 EG(oldact).sa_sigaction(dummy, si, uc); in zend_timeout_handler()
1416 if (EG(oldact).sa_handler) EG(oldact).sa_handler(dummy); in zend_timeout_handler()
1431 if (zend_atomic_bool_load_ex(&EG(timed_out))) { in zend_timeout_handler()
1454 …ND_LONG_FMT " seconds exceeded (terminated) in %s on line %d\n", EG(timeout_seconds), EG(hard_time… in zend_timeout_handler()
1463 zend_on_timeout(EG(timeout_seconds)); in zend_timeout_handler()
1466 zend_atomic_bool_store_ex(&EG(timed_out), true); in zend_timeout_handler()
1467 zend_atomic_bool_store_ex(&EG(vm_interrupt), true); in zend_timeout_handler()
1470 if (EG(hard_timeout) > 0) { in zend_timeout_handler()
1472 zend_set_timeout_ex(EG(hard_timeout), 1); in zend_timeout_handler()
1598 EG(timeout_seconds) = seconds; in zend_set_timeout()
1600 zend_atomic_bool_store_ex(&EG(timed_out), false); in zend_set_timeout()
1609 zend_atomic_bool_store_ex(&EG(timed_out), false); in zend_unset_timeout()
1619 if (EG(timeout_seconds)) { in zend_unset_timeout()
1631 zend_atomic_bool_store_ex(&EG(timed_out), false); in zend_unset_timeout()
1641 if (EG(exception)) { in report_class_fetch_error()
1681 ce = zend_get_called_scope(EG(current_execute_data)); in zend_fetch_class()
1751 return zend_hash_del_ind(&EG(symbol_table), name); in zend_delete_global_variable()
1761 ex = EG(current_execute_data); in zend_rebuild_symbol_table()
1773 if (EG(symtable_cache_ptr) > EG(symtable_cache)) { in zend_rebuild_symbol_table()
1774 symbol_table = ex->symbol_table = *(--EG(symtable_cache_ptr)); in zend_rebuild_symbol_table()
1864 zend_execute_data *execute_data = EG(current_execute_data); in zend_set_local_var()
1907 zend_execute_data *execute_data = EG(current_execute_data); in zend_set_local_var_str()