We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent c57dd7c commit 9a2f500Copy full SHA for 9a2f500
ext/opcache/Optimizer/sccp.c
@@ -1217,7 +1217,7 @@ static void replace_constant_operands(sccp_ctx *ctx) {
1217
1218
/* We iterate the variables backwards, so we can eliminate sequences like INIT_ROPE
1219
* and INIT_ARRAY. */
1220
- for (i = ssa->vars_count - 1; i >= 0; i--) {
+ for (i = ssa->vars_count - 1; i >= op_array->last_var; i--) {
1221
zend_ssa_var *var = &ssa->vars[i];
1222
zval *value;
1223
int use;
@@ -1364,7 +1364,7 @@ static void sccp_context_init(sccp_ctx *ctx,
1364
1365
static void sccp_context_free(sccp_ctx *ctx) {
1366
int i;
1367
- for (i = 0; i < ctx->ssa->vars_count; ++i) {
+ for (i = ctx->op_array->last_var; i < ctx->ssa->vars_count; ++i) {
1368
zval_ptr_dtor_nogc(&ctx->values[i]);
1369
}
1370
efree(ctx->values);
0 commit comments