Skip to content

Commit cd58662

Browse files
committed
Merge branch 'PHP-8.4'
* PHP-8.4: Fix function JIT for Wordpress unit tests
2 parents 972d6b6 + 5885b94 commit cd58662

File tree

1 file changed

+5
-0
lines changed

1 file changed

+5
-0
lines changed

ext/opcache/jit/zend_jit_ir.c

+5
Original file line numberDiff line numberDiff line change
@@ -3562,6 +3562,8 @@ static void jit_IF_TRUE_FALSE_ex(zend_jit_ctx *jit, ir_ref if_ref, ir_ref true_b
35623562
}
35633563
}
35643564

3565+
static void zend_jit_case_start(zend_jit_ctx *jit, int switch_b, int case_b, ir_ref switch_ref);
3566+
35653567
static void _zend_jit_add_predecessor_ref(zend_jit_ctx *jit, int b, int pred, ir_ref ref)
35663568
{
35673569
int i, *p;
@@ -3584,6 +3586,9 @@ static void _zend_jit_add_predecessor_ref(zend_jit_ctx *jit, int b, int pred, ir
35843586
} else if (jit->ctx.ir_base[ref].op == IR_IF) {
35853587
jit_IF_TRUE_FALSE_ex(jit, ref, b);
35863588
ref = ir_LOOP_END();
3589+
} else if (jit->ctx.ir_base[ref].op == IR_SWITCH) {
3590+
zend_jit_case_start(jit, pred, b, ref);
3591+
ref = ir_LOOP_END();
35873592
} else if (jit->ctx.ir_base[ref].op == IR_UNREACHABLE) {
35883593
ir_BEGIN(ref);
35893594
ref = ir_LOOP_END();

0 commit comments

Comments
 (0)