Commit Graph

115800 Commits

Author SHA1 Message Date
Nikita Popov
fec0ff8cb0 Merge branch 'PHP-7.4' 2019-10-04 12:42:58 +02:00
Nikita Popov
ca652aafa8 Fixed bug #78632
I'm going for a very conservative fix here, where the previous
logic is restored for the case where an object is passed to
method_exists(). We might want to check against EG(scope) instead,
but this seems like a safer choice.

This means that behavior in PHP 7.4 changes only for
method_exists('C', 'privateMethodNotOnC'), which should be sensible.
2019-10-04 12:41:49 +02:00
Dmitry Stogov
dc3c8c75da Prefer optimization without JMPZNZ instruction 2019-10-04 12:52:46 +03:00
Nikita Popov
d44cf9b539 Replace "unexpected character" warning with ParseError
Closes GH-4767.
2019-10-04 11:28:58 +02:00
Nikita Popov
11d139625f Merge branch 'PHP-7.4' 2019-10-04 10:39:32 +02:00
Nikita Popov
9659562cb5 Fix use-after-free with delayed interned memoized const operand
We should addref CONST operands during memoization, as they might
be destroyed by later compilation, e.g. through interning.
2019-10-04 10:38:11 +02:00
Nikita Popov
c10cd739a7 Merge branch 'PHP-7.4' 2019-10-04 10:12:16 +02:00
Nikita Popov
f26b60a583 Fix crash when unpacking into array literal with string keys 2019-10-04 10:11:30 +02:00
Christoph M. Becker
0edcd105f3 Merge branch 'PHP-7.4'
* PHP-7.4:
  Fix #78620: Out of memory error
2019-10-04 09:14:36 +02:00
Christoph M. Becker
6627f782d6 Merge branch 'PHP-7.3' into PHP-7.4
* PHP-7.3:
  Fix #78620: Out of memory error
2019-10-04 09:11:18 +02:00
Dmitry Stogov
3f069b19a0 Merge branch 'PHP-7.4'
* PHP-7.4:
  Fixed bug #78614 (Does not compile with DTRACE anymore)
2019-10-04 10:10:53 +03:00
Dmitry Stogov
3ded328bea Fixed bug #78614 (Does not compile with DTRACE anymore) 2019-10-04 10:10:22 +03:00
Christoph M. Becker
cf183a5e2c Merge branch 'PHP-7.2' into PHP-7.3
* PHP-7.2:
  Fix #78620: Out of memory error
2019-10-04 09:09:39 +02:00
Christoph M. Becker
abaf9a76dc Fix #78620: Out of memory error
The integer addition in `ZEND_MM_ALIGNED_SIZE_EX` can overflow, what we
have to catch early.
2019-10-04 09:08:01 +02:00
Joe Watkins
26baf5454b
Merge branch 'PHP-7.4'
* PHP-7.4:
  fix #78624: session_gc return value for user defined session handlers
2019-10-04 06:16:41 +02:00
Joe Watkins
74ca3a5cad
Merge branch 'PHP-7.3' into PHP-7.4
* PHP-7.3:
  fix #78624: session_gc return value for user defined session handlers
2019-10-04 06:16:18 +02:00
Joe Watkins
f45eb353d1
Merge branch 'PHP-7.2' into PHP-7.3
* PHP-7.2:
  fix #78624: session_gc return value for user defined session handlers
2019-10-04 06:12:29 +02:00
Brent Shaffer
a6d219630c
fix #78624: session_gc return value for user defined session handlers 2019-10-04 06:12:02 +02:00
Joe Watkins
4731f57882
Merge branch 'PHP-7.4'
* PHP-7.4:
  Fix typo in CODING_STANDARDS.md [ci skip]
2019-10-04 05:42:44 +02:00
tpfast
8069e1522d
Fix typo in CODING_STANDARDS.md [ci skip] 2019-10-04 05:42:27 +02:00
Dmitry Stogov
bf56daa8c8 Remove "finally" restriction. 2019-10-04 02:53:24 +03:00
Dmitry Stogov
204660fd9a Simplify protection from infinity loops 2019-10-04 02:04:00 +03:00
Dmitry Stogov
3a78c3aaf5 Moved non-constant JMP optimizations from pass1 to pass3.
Removed useless "break"s, that stopped optimization too early.
2019-10-04 00:27:49 +03:00
Dmitry Stogov
39d1e50b2d Avoid "$a = $a + ..." to "$a += ..." conversion (compound assignments work slower).
Added DFA optimization patters (e.g. "$a = $a + 1" to "++$a"), that previously worked only for compound assignments.
2019-10-03 16:33:17 +03:00
Dmitry Stogov
de3c1eb85e Move obvious optimization patterns from pass1 directly to compiler 2019-10-03 14:57:20 +03:00
Dmitry Stogov
a5465728c2 Added missing rules 2019-10-03 14:56:02 +03:00
Dmitry Stogov
c1de93efbe Fixed comments 2019-10-03 13:55:58 +03:00
Dmitry Stogov
59c828a8c4 Added missing rules 2019-10-03 13:54:08 +03:00
Joe Watkins
114060e2f2
Merge branch 'PHP-7.4'
* PHP-7.4:
  Fix bug #76809 (SSL settings aren't respected when persistent connection is reused)
2019-10-03 07:13:49 +02:00
Joe Watkins
5a8e7b95a1
Merge branch 'PHP-7.3' into PHP-7.4
* PHP-7.3:
  Fix bug #76809 (SSL settings aren't respected when persistent connection is reused)
2019-10-03 07:13:15 +02:00
Joe Watkins
f4d078b1c7
Merge branch 'PHP-7.2' into PHP-7.3
* PHP-7.2:
  Fix bug #76809 (SSL settings aren't respected when persistent connection is reused)
2019-10-03 06:57:05 +02:00
Fábio Souto
9a2b42a5c1
Fix bug #76809 (SSL settings aren't respected when persistent connection is reused) 2019-10-03 06:56:21 +02:00
Joe Watkins
733a1e9df0
Merge branch 'PHP-7.4'
* PHP-7.4:
  Fix #76859 stream_get_line skips data if used with data-generating filter
2019-10-03 06:52:25 +02:00
Joe Watkins
de83036f13
Merge branch 'PHP-7.3' into PHP-7.4
* PHP-7.3:
  Fix #76859 stream_get_line skips data if used with data-generating filter
2019-10-03 06:51:56 +02:00
Joe Watkins
5b1bb23edf
Merge branch 'PHP-7.2' into PHP-7.3
* PHP-7.2:
  Fix #76859 stream_get_line skips data if used with data-generating filter
2019-10-03 06:51:10 +02:00
Konstantin Kopachev
05560b67bc
Fix #76859 stream_get_line skips data if used with data-generating filter
stream_get-line repeatedly calls php_stream_fill_read_buffer until
enough data is accumulated in buffer. However, when stream contains
filters attached to it, then each call to fill buffer essentially
resets buffer read/write pointers and new data is written over old.
This causes stream_get_line to skip parts of data from stream
This patch fixes such behavior, so fill buffer call will append.
2019-10-03 06:50:43 +02:00
Dmitry Stogov
1e4c553e0d Cleanup JMP optimization rules 2019-10-03 04:26:40 +03:00
Dmitry Stogov
6cac8d5b3b Optimizer cleanup
- all rules from pass2 moved to pass1
- all JMP unrelated rules from pass3 moved to pass1
- pass3 keeps only JMP optimization rules
- pass2.c is removed
- pass1_5.c remaned to pass1.c ("_5" was related to PHP 5)
2019-10-03 02:18:16 +03:00
Derick Rethans
a0eef7067b Updated to version 2019.3 (2019c) 2019-10-02 23:39:12 +01:00
Derick Rethans
bf0a39a1c6 Empty merge 2019-10-02 23:39:12 +01:00
Derick Rethans
a46bdcb631 Updated to version 2019.3 (2019c) 2019-10-02 23:39:11 +01:00
Derick Rethans
3f7da44209 Empty merge 2019-10-02 23:39:11 +01:00
Derick Rethans
0505fbf2e5 Updated to version 2019.3 (2019c) 2019-10-02 23:39:09 +01:00
Christoph M. Becker
f6c685a750 Merge branch 'PHP-7.4'
* PHP-7.4:
  Revert "Fix #78620: Out of memory error"
2019-10-02 19:03:48 +02:00
Christoph M. Becker
2508131588 Merge branch 'PHP-7.3' into PHP-7.4
* PHP-7.3:
  Revert "Fix #78620: Out of memory error"
2019-10-02 19:03:25 +02:00
Christoph M. Becker
d295e1dce2 Merge branch 'PHP-7.2' into PHP-7.3
* PHP-7.2:
  Revert "Fix #78620: Out of memory error"
2019-10-02 19:02:28 +02:00
Christoph M. Becker
f2fb37a772 Revert "Fix #78620: Out of memory error"
This reverts commit 8ce04df7e0.

Cf. <https://github.com/php/php-src/pull/4766#discussion_r330658679>.
2019-10-02 19:01:35 +02:00
Christoph M. Becker
d0672fc005 Merge branch 'PHP-7.4'
* PHP-7.4:
  Fix #78620: Out of memory error
2019-10-02 18:22:11 +02:00
Christoph M. Becker
b262b24beb Merge branch 'PHP-7.3' into PHP-7.4
* PHP-7.3:
  Fix #78620: Out of memory error
2019-10-02 18:21:50 +02:00
Christoph M. Becker
752a34fb2c Merge branch 'PHP-7.2' into PHP-7.3
* PHP-7.2:
  Fix #78620: Out of memory error
2019-10-02 18:20:09 +02:00