Skip to content

Commit 520bb05

Browse files
committed
Remove jit_LOAD_IP()
1 parent 978a379 commit 520bb05

File tree

1 file changed

+9
-14
lines changed

1 file changed

+9
-14
lines changed

ext/opcache/jit/zend_jit_ir.c

Lines changed: 9 additions & 14 deletions
Original file line numberDiff line numberDiff line change
@@ -911,14 +911,9 @@ static ir_ref jit_IP32(zend_jit_ctx *jit)
911911
return ir_RLOAD_U32(ZREG_IP);
912912
}
913913

914-
static void jit_LOAD_IP(zend_jit_ctx *jit, ir_ref ref)
915-
{
916-
jit_STORE_IP(jit, ref);
917-
}
918-
919914
static void jit_LOAD_IP_ADDR(zend_jit_ctx *jit, const zend_op *target)
920915
{
921-
jit_LOAD_IP(jit, ir_CONST_ADDR(target));
916+
jit_STORE_IP(jit, ir_CONST_ADDR(target));
922917
}
923918

924919
static void zend_jit_track_last_valid_opline(zend_jit_ctx *jit)
@@ -2203,7 +2198,7 @@ static int zend_jit_leave_throw_stub(zend_jit_ctx *jit)
22032198
ir_MERGE_WITH_EMPTY_TRUE(if_set);
22042199

22052200
// JIT: opline = EG(exception_op);
2206-
jit_LOAD_IP(jit, jit_EG(exception_op));
2201+
jit_STORE_IP(jit, jit_EG(exception_op));
22072202

22082203
if (GCC_GLOBAL_REGS) {
22092204
ir_STORE(jit_EX(opline), jit_IP(jit));
@@ -4163,7 +4158,7 @@ static int zend_jit_handler(zend_jit_ctx *jit, const zend_op *opline, int may_th
41634158
ir_CALL(IR_VOID, ir_CONST_FUNC(handler));
41644159
} else {
41654160
ir_ref ip = ir_CALL_2(IR_ADDR, ir_CONST_FC_FUNC(handler), jit_FP(jit), jit_IP(jit));
4166-
jit_LOAD_IP(jit, ip);
4161+
jit_STORE_IP(jit, ip);
41674162
}
41684163
if (may_throw) {
41694164
zend_jit_check_exception(jit);
@@ -10282,7 +10277,7 @@ static int zend_jit_do_fcall(zend_jit_ctx *jit, const zend_op *opline, const zen
1028210277
if (num_args) {
1028310278
ip = ir_ADD_OFFSET(ip, num_args * sizeof(zend_op));
1028410279
}
10285-
jit_LOAD_IP(jit, ip);
10280+
jit_STORE_IP(jit, ip);
1028610281
}
1028710282

1028810283
if (!trace && op_array == &func->op_array && call_num_args >= op_array->required_num_args) {
@@ -10304,7 +10299,7 @@ static int zend_jit_do_fcall(zend_jit_ctx *jit, const zend_op *opline, const zen
1030410299
}
1030510300
ip = ir_LOAD_A(ir_ADD_OFFSET(func_ref, offsetof(zend_op_array, opcodes)));
1030610301
}
10307-
jit_LOAD_IP(jit, ip);
10302+
jit_STORE_IP(jit, ip);
1030810303
helper = ir_CONST_FC_FUNC(zend_jit_copy_extra_args_helper);
1030910304
} else {
1031010305
helper = ir_CONST_FC_FUNC(zend_jit_copy_extra_args_helper_no_skip_recv);
@@ -10328,7 +10323,7 @@ static int zend_jit_do_fcall(zend_jit_ctx *jit, const zend_op *opline, const zen
1032810323
}
1032910324
ip = ir_LOAD_A(ir_ADD_OFFSET(func_ref, offsetof(zend_op_array, opcodes)));
1033010325
}
10331-
jit_LOAD_IP(jit, ip);
10326+
jit_STORE_IP(jit, ip);
1033210327

1033310328
// JIT: num_args = EX_NUM_ARGS();
1033410329
ir_ref num_args, first_extra_arg;
@@ -11103,7 +11098,7 @@ static int zend_jit_leave_func(zend_jit_ctx *jit,
1110311098
ir_GUARD(jit_IP(jit), jit_STUB_ADDR(jit, jit_stub_trace_halt));
1110411099
} else {
1110511100
ir_GUARD(ir_NE(ref, ir_CONST_ADDR(ZEND_VM_RETURN_VAL)), jit_STUB_ADDR(jit, jit_stub_trace_halt));
11106-
jit_LOAD_IP(jit, ref);
11101+
jit_STORE_IP(jit, ref);
1110711102
}
1110811103
}
1110911104

@@ -17078,9 +17073,9 @@ static int zend_jit_trace_handler(zend_jit_ctx *jit, const zend_op_array *op_arr
1707817073
opline->opcode == ZEND_DO_FCALL ||
1707917074
opline->opcode == ZEND_GENERATOR_CREATE) {
1708017075

17081-
jit_LOAD_IP(jit, ir_AND_A(ref, ir_CONST_ADDR(~ZEND_VM_ENTER_BIT)));
17076+
jit_STORE_IP(jit, ir_AND_A(ref, ir_CONST_ADDR(~ZEND_VM_ENTER_BIT)));
1708217077
} else {
17083-
jit_LOAD_IP(jit, ref);
17078+
jit_STORE_IP(jit, ref);
1708417079
}
1708517080
}
1708617081
if (may_throw

0 commit comments

Comments
 (0)