mirror of
https://github.com/php/php-src.git
synced 2026-03-24 00:02:20 +01:00
Update IR
IR commit: 4cb5282c895908cfd4547ab460de86d189d15177 Fixes GH-15662: Segmentation fault in ext/opcache/jit/ir/ir_cfg.c
This commit is contained in:
@@ -97,7 +97,7 @@ int ir_build_cfg(ir_ctx *ctx)
|
||||
/* Some successors of IF and SWITCH nodes may be inaccessible by backward DFS */
|
||||
use_list = &ctx->use_lists[end];
|
||||
n = use_list->count;
|
||||
if (n > 1) {
|
||||
if (n > 1 || (n == 1 && (ir_op_flags[insn->op] & IR_OP_FLAG_TERMINATOR) != 0)) {
|
||||
for (p = &ctx->use_edges[use_list->refs]; n > 0; p++, n--) {
|
||||
/* Remember possible inaccessible successors */
|
||||
ir_bitset_incl(bb_leaks, *p);
|
||||
@@ -245,6 +245,7 @@ int ir_build_cfg(ir_ctx *ctx)
|
||||
IR_ASSERT(ref);
|
||||
ir_ref pred_b = _blocks[ref];
|
||||
ir_block *pred_bb = &blocks[pred_b];
|
||||
IR_ASSERT(pred_b > 0);
|
||||
*q = pred_b;
|
||||
edges[pred_bb->successors + pred_bb->successors_count++] = b;
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user