com php-src: Removed too strict register allocation constraint.: ext/opcache/jit/zend_jit_x86.dasc
| From: | Dmitry Stogov | Date: | Tue, 09 Apr 2019 23:06:51 +0000 |
| Subject: | com php-src: Removed too strict register allocation constraint.: ext/opcache/jit/zend_jit_x86.dasc | ||
| Groups: | php.cvs | ||
| Request: | Send a blank email to php-cvs+get-105602@lists.php.net to get a copy of this message | ||
Commit: 20548ab506d9e4285706709d364ebaed23895da8
Author: Dmitry Stogov <dmitry@zend.com> Wed, 10 Apr 2019 02:06:51 +0300
Parents: 2980de29f0bf060f9e3f49f4fd101c7a80bffdba
Branches: master
Link: http://git.php.net/?p=php-src.git;a=commitdiff;h=20548ab506d9e4285706709d364ebaed23895da8
Log:
Removed too strict register allocation constraint.
Changed paths:
M ext/opcache/jit/zend_jit_x86.dasc
Diff:
diff --git a/ext/opcache/jit/zend_jit_x86.dasc b/ext/opcache/jit/zend_jit_x86.dasc
index 0df4ae8..a988ea2 100644
--- a/ext/opcache/jit/zend_jit_x86.dasc
+++ b/ext/opcache/jit/zend_jit_x86.dasc
@@ -10000,9 +10000,10 @@ static zend_bool zend_jit_opline_supports_reg(zend_op_array *op_array,
zend_ssa
case ZEND_MUL:
op1_info = OP1_INFO();
op2_info = OP2_INFO();
- return
- !(op1_info & ((MAY_BE_ANY|MAY_BE_REF|MAY_BE_UNDEF)-(MAY_BE_LONG|MAY_BE_DOUBLE)))
&&
- !(op2_info & ((MAY_BE_ANY|MAY_BE_REF|MAY_BE_UNDEF)-(MAY_BE_LONG|MAY_BE_DOUBLE)));
+ if ((op1_info | op2_info) & MAY_BE_UNDEF) {
+ return 0;
+ }
+ return (op1_info & op2_info & (MAY_BE_LONG|MAY_BE_DOUBLE)) != 0;
case ZEND_BW_OR:
case ZEND_BW_AND:
case ZEND_BW_XOR:
@@ -10011,9 +10012,10 @@ static zend_bool zend_jit_opline_supports_reg(zend_op_array *op_array,
zend_ssa
case ZEND_MOD:
op1_info = OP1_INFO();
op2_info = OP2_INFO();
- return
- !(op1_info & ((MAY_BE_ANY|MAY_BE_REF|MAY_BE_UNDEF)-MAY_BE_LONG)) &&
- !(op2_info & ((MAY_BE_ANY|MAY_BE_REF|MAY_BE_UNDEF)-MAY_BE_LONG));
+ if ((op1_info | op2_info) & MAY_BE_UNDEF) {
+ return 0;
+ }
+ return (op1_info & op2_info & MAY_BE_LONG) != 0;
case ZEND_PRE_INC:
case ZEND_PRE_DEC:
case ZEND_POST_INC:
@@ -10021,8 +10023,7 @@ static zend_bool zend_jit_opline_supports_reg(zend_op_array *op_array,
zend_ssa
op1_info = OP1_INFO();
return
opline->op1_type == IS_CV &&
- (op1_info & MAY_BE_LONG) &&
- !(op1_info & ((MAY_BE_ANY|MAY_BE_REF|MAY_BE_UNDEF)-(MAY_BE_LONG|MAY_BE_DOUBLE)));
+ (op1_info & MAY_BE_LONG);
case ZEND_BOOL:
case ZEND_BOOL_NOT:
case ZEND_JMPZ:
@@ -10030,9 +10031,7 @@ static zend_bool zend_jit_opline_supports_reg(zend_op_array *op_array,
zend_ssa
case ZEND_JMPZNZ:
case ZEND_JMPZ_EX:
case ZEND_JMPNZ_EX:
- op1_info = OP1_INFO();
- return
- !(op1_info &
((MAY_BE_ANY|MAY_BE_REF|MAY_BE_UNDEF)-(MAY_BE_NULL|MAY_BE_FALSE|MAY_BE_TRUE|MAY_BE_LONG|MAY_BE_DOUBLE)));
+ return 1;
}
return 0;
}