Dmitry Stogov
cffba945e5
Merge branch 'PHP-8.0' into PHP-8.1
...
* PHP-8.0:
Fixed type inference
2021-09-22 15:32:16 +03:00
Dmitry Stogov
e588f24276
Fixed type inference
2021-09-22 15:30:30 +03:00
Dmitry Stogov
5860a390d5
Merge branch 'PHP-8.0' into PHP-8.1
...
* PHP-8.0:
JIT: Fixed JIT for FETCH_OBJ when op1 is a reference of non-object
2021-09-22 14:55:02 +03:00
Dmitry Stogov
7a93a8a6fd
JIT: Fixed JIT for FETCH_OBJ when op1 is a reference of non-object
2021-09-22 14:52:25 +03:00
Dmitry Stogov
f2ceb639b8
Tracing JIT: Record information about types of defined object properties and use it to optimize code for ASSIGN_OBJ_OP, PRE/POST_INC/DEC_OBJ and FETCH_OBJ_R/IS
2021-09-22 14:08:31 +03:00
Dmitry Stogov
4d4a175dc0
Tracing JIT: Fixed FETCH_DIM_R with packed array and negative key
2021-09-22 02:05:05 +03:00
Dmitry Stogov
a86ed2df4f
Merge branch 'PHP-8.0' into PHP-8.1
...
* PHP-8.0:
Tracing JIT: Fixed bug in register allocator.
2021-09-22 00:46:45 +03:00
Dmitry Stogov
19854371ed
Tracing JIT: Fixed bug in register allocator.
...
Type of variable might need to be checked (using type guard) before loading to register.
2021-09-22 00:43:56 +03:00
Nikita Popov
a846547ed4
Fix range() return type inference for undef operand
...
This results in a long range.
2021-09-21 17:03:18 +02:00
Nikita Popov
37337507ec
Merge branch 'PHP-8.0' into PHP-8.1
...
* PHP-8.0:
Don't unconditionally add array value type for undef
2021-09-21 14:54:34 +02:00
Nikita Popov
61445248cb
Don't unconditionally add array value type for undef
...
We have an invariant that an array value type is set if and only
if an array key type is set, which is violated for the case of
undef values for always invalid keys.
2021-09-21 14:54:16 +02:00
Dmitry Stogov
6d04d165b6
JIT: Disable recursive call optimization for VM without global register variables (ARM64 part)
2021-09-21 15:16:06 +03:00
Nikita Popov
4c31edb44e
Merge branch 'PHP-8.0' into PHP-8.1
...
* PHP-8.0:
Check for undef var in typed property assignment
2021-09-21 14:11:56 +02:00
Nikita Popov
f4bcf8c393
Check for undef var in typed property assignment
...
Without this check the assignment would actually silently succeed,
not just skip the warning.
2021-09-21 14:09:26 +02:00
Dmitry Stogov
2d8ce2f993
Merge branch 'PHP-8.0' into PHP-8.1
...
* PHP-8.0:
JIT: Disable recursive call optimization for VM without global register variables
2021-09-21 14:33:09 +03:00
Dmitry Stogov
48d050ef72
JIT: Disable recursive call optimization for VM without global register variables
...
A tail-call to VM handler from recursively called function may lead to
pass control to incorrect stack frame.
2021-09-21 14:30:56 +03:00
Nikita Popov
0ad2444513
Merge branch 'PHP-8.0' into PHP-8.1
...
* PHP-8.0:
Fix missing undef checks for comparisons
2021-09-21 12:09:18 +02:00
Nikita Popov
95e0cc06a2
Fix missing undef checks for comparisons
2021-09-21 12:06:32 +02:00
Dmitry Stogov
c9f348805f
Merge branch 'PHP-8.0' into PHP-8.1
...
* PHP-8.0:
JIT x86: Fixed incorrect EX(func) initialization for recursive calls
2021-09-21 13:02:31 +03:00
Dmitry Stogov
0e0f50b413
JIT x86: Fixed incorrect EX(func) initialization for recursive calls
2021-09-21 13:01:27 +03:00
Dmitry Stogov
443b196033
Merge branch 'PHP-8.0' into PHP-8.1
...
* PHP-8.0:
JIT x86: Fixed register clobbering in code produced for "$x[$y] %= $z".
Fix #81420 : ZipArchive::extractTo extracts outside of destination
2021-09-21 10:48:59 +03:00
Dmitry Stogov
f0f774a129
JIT x86: Fixed register clobbering in code produced for "$x[$y] %= $z".
2021-09-21 10:42:53 +03:00
Dmitry Stogov
ac1dd73048
JIT: Move unusual checks for IS_REFERENCE to cold paths.
2021-09-20 21:14:26 +03:00
Nikita Popov
55582a2527
Merge branch 'PHP-8.0' into PHP-8.1
...
* PHP-8.0:
Don't replace values in unreachable code in sccp
2021-09-20 13:12:43 +02:00
Nikita Popov
1b33da5dd2
Don't replace values in unreachable code in sccp
...
While technically legal, this may cause unexpected situations
(in this example, setting an FE_FREE operand to constant null)
and is suboptimal anyway. It's better to preserve the vacuous type
and drop it later (though we currently don't implement this).
2021-09-20 13:12:26 +02:00
Dmitry Stogov
939b91ad93
Merge branch 'PHP-8.0' into PHP-8.1
...
* PHP-8.0:
JIT: Fixed incorrect assignment of undefined variable
2021-09-17 18:43:13 +03:00
Dmitry Stogov
01cfd5e4f9
JIT: Fixed incorrect assignment of undefined variable
2021-09-17 18:35:55 +03:00
Nikita Popov
bda1ee9511
Merge branch 'PHP-8.0' into PHP-8.1
...
* PHP-8.0:
Fix FETCH_OBJ_IS type inference
2021-09-17 17:05:42 +02:00
Nikita Popov
a49a309386
Fix FETCH_OBJ_IS type inference
...
Even if the property is typed, null is still a valid return
value in the BP_VAR_IS case. Other cases will throw instead.
2021-09-17 17:05:25 +02:00
Dmitry Stogov
703bd89f8f
Merge branch 'PHP-8.0' into PHP-8.1
...
* PHP-8.0:
JIT: keep register value across call
2021-09-17 18:00:42 +03:00
Dmitry Stogov
015cafa38c
JIT: keep register value across call
2021-09-17 17:58:24 +03:00
Nikita Popov
e0e5b59d2e
Try harder to clean up unreachable loop free block
...
While we can't drop the loop free, we can drop other instructions
in the same block. We should also indicate that it no longer has
predecessors.
2021-09-17 16:32:29 +02:00
Dmitry Stogov
fc0cfd1223
Merge branch 'PHP-8.0' into PHP-8.1
...
* PHP-8.0:
JIT: Fixed warning when assign undefined variable to property
2021-09-17 16:30:26 +03:00
Dmitry Stogov
04209de93c
JIT: Fixed warning when assign undefined variable to property
2021-09-17 16:22:06 +03:00
Dmitry Stogov
e5541c943a
Tracing JIT: Use packed array guards for ASSIGN_DIM_OP and allow to move them out of loops.
2021-09-17 14:33:04 +03:00
Dmitry Stogov
beba96dd99
JIT: Fixed jump to undefined label
2021-09-17 13:23:58 +03:00
Nikita Popov
8ffce434f5
Merge branch 'PHP-8.0' into PHP-8.1
...
* PHP-8.0:
Don't jit FE_RESET_R with undef operand
2021-09-17 12:04:43 +02:00
Nikita Popov
d46b10296e
Don't jit FE_RESET_R with undef operand
...
The implementation currently assumes that the operand is always
an array, but this did not account for a possibly undef operand.
2021-09-17 12:04:21 +02:00
Dmitry Stogov
5a1ab2c9b3
JIT: Removed wrong branch
2021-09-17 11:32:57 +03:00
Nikita Popov
28f2b727c7
Replace SKIPIF with EXTENSIONS
2021-09-16 17:01:55 +02:00
Dmitry Stogov
255ce1f60d
Merge branch 'PHP-8.0' into PHP-8.1
...
* PHP-8.0:
JIT: Fixed memory leak in BOOL_NOT when opearnd ia a reference to bool
2021-09-16 17:21:02 +03:00
Dmitry Stogov
5e3eaf14fe
JIT: Fixed memory leak in BOOL_NOT when opearnd ia a reference to bool
2021-09-16 17:18:51 +03:00
Nikita Popov
56210a5117
Merge branch 'PHP-8.0' into PHP-8.1
...
* PHP-8.0:
Undef result on throwing typed reference assignment
2021-09-16 15:49:33 +02:00
Nikita Popov
83f283f5ea
Undef result on throwing typed reference assignment
2021-09-16 15:48:10 +02:00
Dmitry Stogov
2172142346
Tracing JIT: Use recorded information about elements of arrays to generate better code for ASSIGN_DIM_OP.
2021-09-16 15:50:16 +03:00
Nikita Popov
3191f83146
Merge branch 'PHP-8.0' into PHP-8.1
...
* PHP-8.0:
Don't const evaluate increment of array in SCCP
2021-09-16 14:43:28 +02:00
Nikita Popov
4c8093a9f1
Don't const evaluate increment of array in SCCP
2021-09-16 14:43:08 +02:00
Nikita Popov
91aa78f9b4
Merge branch 'PHP-8.0' into PHP-8.1
...
* PHP-8.0:
Fix may_throw for ASSIGN_OBJ
2021-09-16 12:47:04 +02:00
Nikita Popov
1548418461
Fix may_throw for ASSIGN_OBJ
...
The code did not account for a number of possible exceptions.
2021-09-16 12:46:53 +02:00
Dmitry Stogov
6f54b17485
Fixed condition
2021-09-16 12:34:21 +03:00