From: Dmitry Stogov Date: Thu, 5 Sep 2019 12:35:19 +0000 (+0300) Subject: Revert "Microoptimization (avoid code duplication)" X-Git-Tag: php-7.4.0RC2~85 X-Git-Url: https://granicus.if.org/sourcecode?a=commitdiff_plain;h=4ecdff2da829a60ddb01ecb260d688acca7339d4;p=php Revert "Microoptimization (avoid code duplication)" This reverts commit 25d97f5eeeaf2eca760139f04fe2711e71791d0f. --- diff --git a/Zend/zend_vm_def.h b/Zend/zend_vm_def.h index 8dbcfe850a..f8e7cad985 100644 --- a/Zend/zend_vm_def.h +++ b/Zend/zend_vm_def.h @@ -4016,9 +4016,10 @@ ZEND_VM_HOT_HANDLER(129, ZEND_DO_ICALL, ANY, ANY, SPEC(RETVAL)) if (UNEXPECTED(EG(exception) != NULL)) { zend_rethrow_exception(execute_data); - } else { - ZEND_VM_SET_OPCODE(opline + 1); + HANDLE_EXCEPTION(); } + + ZEND_VM_SET_OPCODE(opline + 1); ZEND_VM_CONTINUE(); } @@ -4123,9 +4124,9 @@ ZEND_VM_C_LABEL(fcall_end): if (UNEXPECTED(EG(exception) != NULL)) { zend_rethrow_exception(execute_data); - } else { - ZEND_VM_SET_OPCODE(opline + 1); + HANDLE_EXCEPTION(); } + ZEND_VM_SET_OPCODE(opline + 1); ZEND_VM_CONTINUE(); } @@ -4234,9 +4235,10 @@ ZEND_VM_C_LABEL(fcall_end): zend_vm_stack_free_call_frame(call); if (UNEXPECTED(EG(exception) != NULL)) { zend_rethrow_exception(execute_data); - } else { - ZEND_VM_SET_OPCODE(opline + 1); + HANDLE_EXCEPTION(); } + + ZEND_VM_SET_OPCODE(opline + 1); ZEND_VM_CONTINUE(); } diff --git a/Zend/zend_vm_execute.h b/Zend/zend_vm_execute.h index 34e290093d..8882f18d14 100644 --- a/Zend/zend_vm_execute.h +++ b/Zend/zend_vm_execute.h @@ -1286,9 +1286,10 @@ static ZEND_VM_HOT ZEND_OPCODE_HANDLER_RET ZEND_FASTCALL ZEND_DO_ICALL_SPEC_RETV if (UNEXPECTED(EG(exception) != NULL)) { zend_rethrow_exception(execute_data); - } else { - ZEND_VM_SET_OPCODE(opline + 1); + HANDLE_EXCEPTION(); } + + ZEND_VM_SET_OPCODE(opline + 1); ZEND_VM_CONTINUE(); } @@ -1330,9 +1331,10 @@ static ZEND_VM_HOT ZEND_OPCODE_HANDLER_RET ZEND_FASTCALL ZEND_DO_ICALL_SPEC_RETV if (UNEXPECTED(EG(exception) != NULL)) { zend_rethrow_exception(execute_data); - } else { - ZEND_VM_SET_OPCODE(opline + 1); + HANDLE_EXCEPTION(); } + + ZEND_VM_SET_OPCODE(opline + 1); ZEND_VM_CONTINUE(); } @@ -1460,9 +1462,9 @@ fcall_end: if (UNEXPECTED(EG(exception) != NULL)) { zend_rethrow_exception(execute_data); - } else { - ZEND_VM_SET_OPCODE(opline + 1); + HANDLE_EXCEPTION(); } + ZEND_VM_SET_OPCODE(opline + 1); ZEND_VM_CONTINUE(); } @@ -1544,9 +1546,9 @@ fcall_end: if (UNEXPECTED(EG(exception) != NULL)) { zend_rethrow_exception(execute_data); - } else { - ZEND_VM_SET_OPCODE(opline + 1); + HANDLE_EXCEPTION(); } + ZEND_VM_SET_OPCODE(opline + 1); ZEND_VM_CONTINUE(); } @@ -1655,9 +1657,10 @@ fcall_end: zend_vm_stack_free_call_frame(call); if (UNEXPECTED(EG(exception) != NULL)) { zend_rethrow_exception(execute_data); - } else { - ZEND_VM_SET_OPCODE(opline + 1); + HANDLE_EXCEPTION(); } + + ZEND_VM_SET_OPCODE(opline + 1); ZEND_VM_CONTINUE(); } @@ -1766,9 +1769,10 @@ fcall_end: zend_vm_stack_free_call_frame(call); if (UNEXPECTED(EG(exception) != NULL)) { zend_rethrow_exception(execute_data); - } else { - ZEND_VM_SET_OPCODE(opline + 1); + HANDLE_EXCEPTION(); } + + ZEND_VM_SET_OPCODE(opline + 1); ZEND_VM_CONTINUE(); }