1
0
mirror of https://github.com/php/php-src.git synced 2026-04-21 15:08:16 +02:00
Commit Graph

3929 Commits

Author SHA1 Message Date
Dmitry Stogov 7b629afe4e Fixed incorrect DCE of a constructor call
Fixez oss-fuzz #42049
2021-12-06 15:59:30 +03:00
Dmitry Stogov c29f6baaee JIT: Fix incorrect elimination of type store
Fixes oss-fuzz #41995
2021-12-06 14:22:07 +03:00
Dmitry Stogov aa7280264e Fix refcount inferemce ($a += $a returns old array with RCN)
Fixes oss-fuzz #41670
2021-12-06 11:30:03 +03:00
Dmitry Stogov c9901aa594 Add missing "return" 2021-12-03 13:52:10 +03:00
Dmitry Stogov 4a5c05a49d ws 2021-12-03 13:40:01 +03:00
Dmitry Stogov 1d054b3fa7 Fix array object clobbering by user error handler
Fixes oss-fuss #41605 and #41610
2021-12-03 13:35:28 +03:00
Dmitry Stogov 2515e788bc JIT: Fix register clobbering
Fixes oss-fuzz #41621
2021-12-03 11:13:50 +03:00
Dmitry Stogov c4ee66856e Tracing JIT: Fixed Zend/tests/str_offset_008.phpt failure 2021-12-02 23:47:36 +03:00
Dmitry Stogov 2fde308fc6 JIT: Fix ASSIGN_DIM_OP with undefined variable and index and user error handler, throwing an exception
Fixes oss-fuzz #39422
2021-12-02 22:19:48 +03:00
Dmitry Stogov 94286cd596 Fix yet another indirect string modification by error handler problem 2021-12-02 16:16:54 +03:00
Dmitry Stogov 37ac707cac Add missing zend_string_release_ex(tmp, 0) and cleanup
- use GC_DELREF() instead of zend_string_release_ex()
- add expectations for exceptional cases
- replace IS_ARRAY_IMMUTABLE by IS_STR_INTERNED
2021-12-02 11:18:08 +03:00
Dmitry Stogov df16da3697 Fixed ext/bz2/tests/005.phpt test failure introduesed by 09547c64c2 2021-12-02 10:32:45 +03:00
Dmitry Stogov 4595a57e99 Fix clobering of operand by error handler in assignment to string offset (optimization and JIT support) 2021-12-02 01:20:17 +03:00
Dmitry Stogov e7b31f57ec JIT: Fix incorrect code produced for BOOL_NOT and [double, undef] operand
Fixes oss-fuzz #41531
2021-11-30 20:36:52 +03:00
Dmitry Stogov c1036194d6 JIT: Fix incorrect reference counting inference
Fixes oss-fuzz #40747
2021-11-30 12:58:54 +03:00
Dmitry Stogov 6e1fe96962 JIT: Fix uninitialized result of ASSIGN_DIM[_OP] after clobbering array by user error handler
Fixes oss-fuzz #41208
2021-11-30 11:40:18 +03:00
Dmitry Stogov 86430e8e01 Fixed type inference (it's safe to ignore reference counting narrowing) 2021-11-29 23:32:52 +03:00
Dmitry Stogov aff115547f JIT: Fix exception handling when next array element is already occupied
Fixes oss-fuzz #41408
2021-11-29 21:44:00 +03:00
Dmitry Stogov d955415114 JIT: Fix named arguments handling
Fixes oss-fuzz #41486
2021-11-29 18:39:50 +03:00
Dmitry Stogov 8f4cfe04eb JIT: Fix named arguments handling
Fixes oss-fuzz #41486
2021-11-29 18:37:49 +03:00
Dmitry Stogov 297117bbc5 Disable type narrowing optimization when we contruct SSA for JIT
This also revets incorrect fix introduced in f9518c3850
2021-11-29 15:51:54 +03:00
Dmitry Stogov 49f44e7ffc JIT: Fixed use-after-free caused by shift by negative number
Fixes oss-fuzz #41192
2021-11-25 22:21:44 +03:00
Dmitry Stogov f9518c3850 Fixed incorrect narrowing to double
Fixes oss-fuzz #41223
2021-11-25 15:14:04 +03:00
Dmitry Stogov 3c53a9fd73 Fixed incorrect refcountion inference for BW_NOT
BW_NOT for emtpy string returns empty string

Fixes oss-fuzz #41280
2021-11-25 13:51:56 +03:00
Dmitry Stogov f302430c72 Fixed incorrect DCE for ADD_ARRAY_ELEMENT instruction
DCE might remove INIT_ARRAY instruction but then keep the related
ADD_ARRAY_ELEMENT, becuse its both operands need to be freed.

Fixes oss-fuzz #41309
2021-11-25 13:33:26 +03:00
Nikita Popov be271f277e Fix bug #81652
We need to check not only for defs but also for uses of the
variable.
2021-11-24 15:18:31 +01:00
Dmitry Stogov 9dd3e8be8a JIT: Fixed memory leak in Zend/tests/concat_002.phpt introduced by fac78ee760 2021-11-17 18:43:39 +03:00
Dmitry Stogov fac78ee760 JIT: Fixed memory leak 2021-11-17 13:59:35 +03:00
Dmitry Stogov 48a65fef6f JIT: Fixed memory lieak 2021-11-17 12:48:56 +03:00
David Carlier fb3e646f6b OpenBSD ZTS build fix
Closes GH-7661.
2021-11-17 10:20:05 +01:00
Dmitry Stogov fc35a6b93c Tracing JIT: Fixed abstract stack consistency for [QM_]ASSIGN of CV to itself 2021-11-15 23:25:16 +03:00
Dmitry Stogov 85066fd88e Tracing JIT: Fixed failure on non-optimized op_arrays (op_array->T may be above ssa->vars_count) 2021-11-15 14:44:01 +03:00
Dmitry Stogov 292d76d8a4 JIT: Fixed reference-counting inference 2021-11-15 10:39:58 +03:00
Dmitry Stogov 64fde17042 Fixed test 2021-11-12 22:48:50 +03:00
Dmitry Stogov 12d02e6227 Fixed incorrect guard elimination 2021-11-12 21:00:08 +03:00
Dmitry Stogov 5380b415a2 JIT: Partially fix handling of exceptions thrown in interrupt handlers 2021-11-11 21:14:17 +03:00
Dmitry Stogov 64915775a7 JIT: Fixed incorrect MOD into BW_AND optimization 2021-11-10 21:14:41 +03:00
Dmitry Stogov 3081423706 Tracing JIT: Fixed register allocation
In case of side exit on ADD/SUB/MUL overflow source registers must be kept unchanged
2021-11-10 20:04:25 +03:00
Dmitry Stogov 3dba5566ce Tracing JIT: Fixed incorrect assumption about in-memeory zval type 2021-11-10 16:46:09 +03:00
Dmitry Stogov 45683703f1 JIT: Fixed memory leak 2021-11-10 12:49:20 +03:00
Dmitry Stogov 203c1b807e Tracing JIT: Fixed incorrect tracing type inference
There are some cases when IS_VAR/IS_TMP_VAR variables are set to IS_UNDEF.
TODO: It would be better to switch to IS_NULL in master.
2021-11-10 11:10:44 +03:00
Dmitry Stogov 535a0553e8 Fixed incorrect reference counter inference 2021-11-08 20:54:17 +03:00
Dmitry Stogov 8fe808207f JIT: Fixed incorrect guard elimination 2021-11-08 20:08:39 +03:00
Nikita Popov 53df29bc29 Drop pi nodes for both old/new pred in replace_predecessor
We also need to drop pi nodes for new_pred here, as the pi node
restriction for new_pred is not necessarily true for control
coming from old_pred as well.

Fixes oss-fuzz #40782.
2021-11-08 14:56:42 +01:00
Dmitry Stogov e868ded6ef Don't call _zend_hash_index_find() for packed arrays 2021-11-08 13:13:23 +03:00
Dmitry Stogov 7bf63243e1 JIT: Fixed incorrect guard elimination 2021-11-08 12:28:36 +03:00
Dmitry Stogov 34d22acc7e Tracing JIT: Fixed incorrect guard elimination 2021-11-03 23:37:00 +03:00
Dmitry Stogov 66d93c63ff Fixed type inference for FETCH_DIM_W without use 2021-11-03 19:44:38 +03:00
Dmitry Stogov 2605911272 Tracing JIT: Fixed reference counting when escape because of IS_UNDEF element (test) 2021-11-01 22:19:10 +03:00
Dmitry Stogov d7ac39b02d Tracing JIT: Fixed reference counting when escape because of IS_UNDEF element 2021-11-01 22:14:12 +03:00