Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Sign up
Appearance settings

Commit f6fc0fd

Browse files
committed
Add missing type guard
1 parent 6c8ef1d commit f6fc0fd

File tree

1 file changed

+10
-0
lines changed

1 file changed

+10
-0
lines changed

‎ext/opcache/jit/zend_jit_trace.c‎

Lines changed: 10 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -6557,6 +6557,16 @@ static const void *zend_jit_trace(zend_jit_trace_rec *trace_buffer, uint32_t par
65576557

65586558
for (i = 0; i < op_array->last_var; i++,j++) {
65596559
if (ra[j] && (ra[j]->flags & ZREG_LOAD) != 0) {
6560+
if ((ssa->var_info[j].type & MAY_BE_GUARD) != 0) {
6561+
uint8_t op_type;
6562+
6563+
ssa->var_info[j].type &= ~MAY_BE_GUARD;
6564+
op_type = concrete_type(ssa->var_info[j].type);
6565+
if (!zend_jit_type_guard(&dasm_state, opline, EX_NUM_TO_VAR(i), op_type)) {
6566+
goto jit_failure;
6567+
}
6568+
SET_STACK_TYPE(stack, i, op_type, 1);
6569+
}
65606570
SET_STACK_REG_EX(stack, i, ra[j]->reg, ZREG_LOAD);
65616571
if (!zend_jit_load_var(&dasm_state, ssa->var_info[j].type, i, ra[j]->reg)) {
65626572
goto jit_failure;

0 commit comments

Comments
(0)

AltStyle によって変換されたページ (->オリジナル) /