File tree Expand file tree Collapse file tree 3 files changed +5
-7
lines changed Expand file tree Collapse file tree 3 files changed +5
-7
lines changed Original file line number Diff line number Diff line change @@ -180,7 +180,7 @@ static ZEND_INI_MH(OnUpdateFiberStackSize) /* {{{ */
180
180
if (new_value ) {
181
181
EG (fiber_stack_size ) = zend_atol (ZSTR_VAL (new_value ), ZSTR_LEN (new_value ));
182
182
} else {
183
- EG (fiber_stack_size ) = zend_fiber_page_size () * ZEND_FIBER_DEFAULT_PAGE_COUNT ;
183
+ EG (fiber_stack_size ) = ZEND_FIBER_DEFAULT_C_STACK_SIZE ;
184
184
}
185
185
return SUCCESS ;
186
186
}
Original file line number Diff line number Diff line change @@ -106,7 +106,7 @@ static zend_always_inline void zend_observer_fiber_switch_notify(zend_fiber *fro
106
106
}
107
107
/* }}} */
108
108
109
- size_t zend_fiber_page_size ()
109
+ static size_t zend_fiber_page_size ()
110
110
{
111
111
#if _POSIX_MAPPED_FILES
112
112
static size_t page_size ;
Original file line number Diff line number Diff line change @@ -52,10 +52,6 @@ typedef struct _zend_fiber_context {
52
52
zend_fiber_stack stack ;
53
53
} zend_fiber_context ;
54
54
55
- #define ZEND_FIBER_GUARD_PAGES 1
56
-
57
- #define ZEND_FIBER_DEFAULT_PAGE_COUNT (((sizeof(void *)) < 8) ? 512 : 2048)
58
-
59
55
typedef struct _zend_fiber {
60
56
/* Fiber PHP object handle. */
61
57
zend_object std ;
@@ -111,7 +107,9 @@ ZEND_COLD ZEND_NORETURN void zend_error_suspend_fiber(
111
107
ZEND_API void zend_fiber_switch_context (zend_fiber_context * to );
112
108
ZEND_API void zend_fiber_suspend_context (zend_fiber_context * current );
113
109
114
- size_t zend_fiber_page_size ();
110
+ #define ZEND_FIBER_GUARD_PAGES 1
111
+
112
+ #define ZEND_FIBER_DEFAULT_C_STACK_SIZE (4096 * (((sizeof(void *)) < 8) ? 256 : 512))
115
113
116
114
#define ZEND_FIBER_VM_STACK_SIZE (1024 * sizeof(zval))
117
115
You can’t perform that action at this time.
0 commit comments