Conversation
There was a problem hiding this comment.
This naming is confusing... maybe static_var_names and static_vars?
There was a problem hiding this comment.
I agree, just meant to be similar with op_array->vars.
There was a problem hiding this comment.
Do we really need to keep an array of static variable names?
There was a problem hiding this comment.
We might use indirect addressing into vars array by using u2 inside static_variables?
|
A general comment: Previously the static variables table could be shared between multiple functions based on refcount. At least until the first static variable is bound by executing the function. Was this sharing important for performance? Will it be a problem if it's no longer present? |
|
yeah, we need duplicated the static_variables when op_array is copied from shared memory out to php proceses, I was thinking of introduce IS_TYPE_IMMUTABLE which is marked in static_variables[0].u2 . however , if the function is executed enough times, it will be faster (if the hash lookup time beat memroy duplication time). |
b918cb3 to
2028829
Compare
cfab746 to
1d183a8
Compare
There was a problem hiding this comment.
In general, "val" may be a part of "var" and destroying "var" before incrementing "val", may cause problems. (may be I'm wrong).
There was a problem hiding this comment.
val always should have a minimum refcount of 1 as long as it is referenced in static_variables array. So it shouldn't be an issue.
|
part of this has been committed as 6579e48 , close this |
No description provided.