1
0
mirror of https://github.com/php/php-src.git synced 2026-04-27 10:16:41 +02:00
Commit Graph

396 Commits

Author SHA1 Message Date
Dmitry Stogov 88a2268d6b Replace "ZEND_CALL_CTOR" hack by additional live-range 2019-04-12 00:49:45 +03:00
Dmitry Stogov c941f1d8c7 Fixed SCCP support for ZEND_ASSIGN_OBJ_REF 2019-04-03 11:22:59 +03:00
Nikita Popov 251f293cb7 Make line numbers for inheritance errors more precise
Use the line of the conflicting child method, rather than either the
first or last line of the class.
2019-03-27 12:42:35 +01:00
Nikita Popov 0122f395c7 Add zend_error_at API that accepts a filename and lineno
Use this for the opcache preloading warnings, as an example usage.
2019-03-26 15:47:00 +01:00
Christoph M. Becker 9ca9394f5b Merge branch 'PHP-7.3' into PHP-7.4
* PHP-7.3:
  Simplfy test case
2019-03-18 14:59:08 +01:00
Xinchen Hui ab8782d1e6 Merge branch 'PHP-7.2' into PHP-7.3
* PHP-7.2:
  Simplfy test case
2019-03-18 19:30:11 +08:00
Xinchen Hui e072537e7f Simplfy test case
(I was working on the same bug while nikic committed the similar fix
2019-03-18 19:28:23 +08:00
Nikita Popov f7abb1e253 Merge branch 'PHP-7.3' into PHP-7.4 2019-03-18 10:51:20 +01:00
Nikita Popov da7add3525 Merge branch 'PHP-7.2' into PHP-7.3 2019-03-18 10:51:00 +01:00
Nikita Popov 54bf8c820f Fixed bug #77743 2019-03-18 10:49:53 +01:00
Fabien Villepinte 26dfce7f36 Replace dirname(__FILE__) by __DIR__ in tests 2019-03-15 22:55:30 +01:00
Nikita Popov ade5474792 Merge branch 'PHP-7.3' into PHP-7.4 2019-03-04 13:16:25 +01:00
Nikita Popov 4c68aaabf1 Merge branch 'PHP-7.2' into PHP-7.3 2019-03-04 13:16:01 +01:00
Nikita Popov 3f00c9367d Fixed bug #77691
We cannot replace an op1_def opcode with an ASSIGN, if it also has
a used res_def. Usually this doesn't happen because the res_def use
can be eliminated first. The example is a case where operand replacement
on the res_def use fails.
2019-03-04 13:11:12 +01:00
Nikita Popov dda2074bf7 Merge branch 'PHP-7.3' into PHP-7.4 2019-02-22 13:42:13 +01:00
Nikita Popov 66fda0cdb1 Remove result def during jmp_set optimization 2019-02-22 13:41:47 +01:00
Nikita Popov ea115a617f Fix removal of unreachable code in SCCP
Due to a wrongly placed check, we were only performing the
unreachable code removal if there were loop vars...
2019-02-22 12:44:36 +01:00
Nikita Popov 4a98f42330 Merge branch 'PHP-7.3' into PHP-7.4 2019-02-22 12:00:35 +01:00
Nikita Popov 33c2b47de3 Merge branch 'PHP-7.2' into PHP-7.3 2019-02-22 12:00:20 +01:00
Nikita Popov 2cfb09caa7 Fix inference warning about missing key type 2019-02-22 11:55:16 +01:00
Nikita Popov 6b110b151d Fixed bug #77643
Resolve property initializers against the correct class, even when
parent slots are reused.
2019-02-21 10:59:30 +01:00
Nikita Popov 0989b70015 Print more precise warning for unresolved constants 2019-02-21 10:35:59 +01:00
Nikita Popov c0e15a3b7f Implement fine-grained conflict handling
Tests can specify conflict keys, either in --CONFLICTS-- or
a per-directory CONFLICTS file. Non-conflicting tests may be run
in parallel.
2019-02-20 11:20:40 +01:00
Dmitry Stogov 12edc453e5 Disable preloading for sensetive opcache tests 2019-02-20 11:47:19 +03:00
Dmitry Stogov 3ef9f23fce Fixed use-after-free during preloading, when q class with unresolved constant uses a preloaded trait. 2019-02-18 13:46:13 +03:00
Nikita Popov e15d657c1a Link anonymous classes during preloading 2019-02-15 17:50:40 +01:00
Nikita Popov 970dcd240f Don't assume that all includes have been executed 2019-02-15 17:36:40 +01:00
Nikita Popov 1b31b45f6f Set filename & lineno information for preload inheritance error 2019-02-15 17:03:57 +01:00
Nikita Popov 92fae00ee0 Handle bailouts during preload linking 2019-02-15 16:56:32 +01:00
Nikita Popov a9497cecf3 Fix preload auto globals handling
We need to compute the auto globals mask before EG(symbol_table)
is cleaned out.
2019-02-15 16:37:12 +01:00
Nikita Popov ade9d5e95b Suppress zend_throw_error during preload constant resolution
Related to bug #77615.
2019-02-15 13:03:46 +01:00
Nikita Popov c15007956d Add preloading support for typed properties
During preloading, try to resolve all property types to CEs. Add a
flag that tracks this. If not all property types can be resolved,
then the class is not eligible for preloading.
2019-02-15 12:41:45 +01:00
Nikita Popov ffc7e953ea properties_info_table may be in arena or shm
For immutable classes it should be shm instead of in arena.

Related to bug #77615.
2019-02-15 10:27:30 +01:00
Dmitry Stogov 2f89baf5c7 Fixed 32/64-bit mismatch 2019-01-14 13:15:52 +03:00
Nikita Popov e219ec144e Implement typed properties
RFC: https://wiki.php.net/rfc/typed_properties_v2

This is a squash of PR #3734, which is a squash of PR #3313.

Co-authored-by: Bob Weinand <bobwei9@hotmail.com>
Co-authored-by: Joe Watkins <krakjoe@php.net>
Co-authored-by: Dmitry Stogov <dmitry@zend.com>
2019-01-11 15:49:06 +01:00
Nikita Popov 61b0122698 Merge branch 'PHP-7.3' 2019-01-10 10:27:57 +01:00
Nikita Popov ade702a0d2 Fixed bug #77434
Mark arrays containing partial arrays as partial. This was already
done for the ADD_ARRAY_ELEMENT case, but not for ASSIGN_DIM.
2019-01-10 10:25:55 +01:00
Xinchen Hui dd61845cf8 Merge branch 'PHP-7.3'
* PHP-7.3:
  Fixed bug #77266 (Assertion failed in dce_live_ranges)
2019-01-08 19:19:44 +08:00
Xinchen Hui cd49db9d47 Fixed bug #77266 (Assertion failed in dce_live_ranges) 2019-01-08 19:19:01 +08:00
Nikita Popov 767cbd93c9 Merge branch 'PHP-7.3' 2019-01-07 10:05:33 +01:00
Nikita Popov 6f75890e7b Fix one issue reported in bug #77310
SCCP did not handle array ASSIGN_* with a BOT operand correctly.
2019-01-07 10:05:23 +01:00
Nikita Popov 685307b081 Merge branch 'PHP-7.3' 2019-01-02 09:32:59 +01:00
Nikita Popov 91888cc372 Fixed bug #77257
Correctly handle the case of duplicate predecessors, by removing the
duplicate predecessor and corresponding phi node operands.

For the future, it would be better to instead allow duplicate
predecessors and avoid this kind of fragile code...
2019-01-02 09:31:50 +01:00
Nikita Popov 6debea2fd8 Merge branch 'PHP-7.3' 2018-12-10 13:36:54 +01:00
Nikita Popov 93aabf1533 Fixed bug #77275
Instead of juggling with this problem during literal compaction,
make sure that we always initialize Z_EXTRA for literals, which
seems like the more robust solution.
2018-12-10 13:36:23 +01:00
Nikita Popov 745e250a21 Merge branch 'PHP-7.3' 2018-11-28 20:10:32 +01:00
Nikita Popov f4eec70260 Merge branch 'PHP-7.2' into PHP-7.3 2018-11-28 20:10:17 +01:00
Nikita Popov 17f8b9fb36 Fixed bug #77215
Remove invalid assertion: A block can have multiple switch frees,
so if we don't do live range block splitting, it is not necessarily
true that the free is located at the start of a block.
2018-11-28 20:08:39 +01:00
Mizunashi Mana 10ae8b685f Fix opcache blacklist test on macOS 2018-11-20 21:11:56 +01:00
Dmitry Stogov d5955d9587 typo 2018-11-15 00:10:17 +03:00