History log of /PHP_TRUNK/ext/opcache/Optimizer/block_pass.c
Revision Date Author Comments (<<< Hide modified files) (Show modified files >>>)
35e7573 04-May-2016 Nikita Popov <nikic@php.net> Merge branch 'PHP-7.0'

Conflicts:
ext/opcache/Optimizer/block_pass.c
0691e7a 04-May-2016 Nikita Popov <nikic@php.net> Fix JMPZ, JMPZNZ_EX chain optimization

The result_type was not copied, resulting in a corrupted JMPZ_EX.
Fix can be verified by inspecting the opcodes of the following
function (it should not contain any _EX opcodes):

function test() {
if ($a && $b) {
echo "a";
}

if ($b || $c || $d) {
echo "b";
}
}

Conflicts:
ext/opcache/Optimizer/block_pass.c
/php-src/ext/opcache/Optimizer/block_pass.c
4a568dd 16-Apr-2016 Nikita Popov <nikic@php.net> Drop left-over debugging statement in block pass
/php-src/ext/opcache/Optimizer/block_pass.c
1e82ad8 30-Mar-2016 Andrea Faulds <ajf@ajf.me> Warn about invalid strings in arithmetic

Squashed commit of the following:

commit e05d3b67325d4521418483ed924ac9211a188919
Author: Andrea Faulds <ajf@ajf.me>
Date: Wed Mar 30 01:43:35 2016 +0100

UPGRADING and NEWS

commit 6caf1d4585207d1b02fb06a216cd7da1a1f5e12d
Author: Andrea Faulds <ajf@ajf.me>
Date: Sun Mar 20 21:18:33 2016 +0000

Fixes

commit 6dadb1b0efe5e2ed071e95a55c806519e61377ac
Author: Andrea Faulds <ajf@ajf.me>
Date: Sun Feb 14 02:15:01 2016 +0000

Add test for numeric string errors in assignment

commit bd5f04e8dd576f92a48d25546f4f9a0f57f374de
Author: Andrea Faulds <ajf@ajf.me>
Date: Sat Feb 13 23:53:05 2016 +0000

Add test for numeric string errors

commit c72e92f16d512bcae30cc9639c89bcb08d971742
Author: Andrea Faulds <ajf@ajf.me>
Date: Tue Jan 26 23:28:33 2016 +0000

Add test for scientific notation in integer operations

commit d94c08852d405b3a7ef6c84d24bf7915c890ce78
Author: Andrea Faulds <ajf@ajf.me>
Date: Sun Feb 14 01:25:57 2016 +0000

Disable optimiser evaluation for numeric string errors

commit 30ee954ed13d933e766c68605d683c8ebae3d8ee
Author: Andrea Faulds <ajf@ajf.me>
Date: Sun Feb 14 01:46:25 2016 +0000

fixup

commit a6403b79e054c95e2b7345d787f3092b261eed27
Author: Andrea Faulds <ajf@ajf.me>
Date: Sat Feb 13 22:00:27 2016 +0000

Do not convert error-causing numeric strings ahead-of-time

commit f9dc35401471ef3035954cb6f171826769297548
Author: Andrea Faulds <ajf@ajf.me>
Date: Sat Feb 13 19:15:38 2016 +0000

Disable compile-time evaluation for numeric string errors

commit e05b0cc8496ea082c6db27efd8b8277ef1f785b5
Author: Andrea Faulds <ajf@ajf.me>
Date: Fri Feb 5 11:42:26 2016 +0000

Make _zval_get_long_func_noisy function for inlining

commit 84d66321a57e579759109650c8bb7e3d5002854a
Author: Andrea Faulds <ajf@ajf.me>
Date: Tue Jan 26 23:10:00 2016 +0000

Update tests

commit 5ac4a0cc4bff282e3a15eaa8ab44b67391881a6d
Author: Andrea Faulds <ajf@ajf.me>
Date: Tue Jan 26 22:08:19 2016 +0000

Use is_numeric_string_ex for zval_get_long etc.

commit c21f08848533723331012a62a153de3577731d6a
Author: Andrea Faulds <ajf@ajf.me>
Date: Thu Jan 7 21:13:04 2016 +0000

Update tests

commit 63e214cf8160420bfc51c6a2b4ae32f09ad8e8af
Author: Andrea Faulds <ajf@ajf.me>
Date: Wed Jan 6 00:28:01 2016 +0000

Warn on non-/bad numeric strings in arithmetic
/php-src/ext/opcache/Optimizer/block_pass.c
8e5b139 12-Mar-2016 Nikita Popov <nikic@php.net> Evaluate arguments of new for classes without ctor

ML: http://markmail.org/message/4b3mk7jid64zvz34
/php-src/ext/opcache/Optimizer/block_pass.c
adb8251 17-Mar-2016 Xinchen Hui <laruence@gmail.com> Merge branch 'PHP-7.0'

* PHP-7.0:
Remove unnecessary pattern
Fixed for PHP7
Fixed bug #71843 (null ptr deref ZEND_RETURN_SPEC_CONST_HANDLER)

Conflicts:
ext/opcache/Optimizer/block_pass.c
aef22ac 17-Mar-2016 Xinchen Hui <laruence@gmail.com> Remove unnecessary pattern
/php-src/ext/opcache/Optimizer/block_pass.c
041a01f 17-Mar-2016 Xinchen Hui <laruence@gmail.com> Fixed for PHP7
/php-src/ext/opcache/Optimizer/block_pass.c
820b0aa 17-Mar-2016 Xinchen Hui <laruence@gmail.com> Merge branch 'PHP-5.6' into PHP-7.0

* PHP-5.6:
Fixed bug #71843 (null ptr deref ZEND_RETURN_SPEC_CONST_HANDLER)
8e2f658 17-Mar-2016 Xinchen Hui <laruence@gmail.com> Fixed bug #71843 (null ptr deref ZEND_RETURN_SPEC_CONST_HANDLER)
/php-src/ext/opcache/Optimizer/block_pass.c
791b8f0 18-Feb-2016 Dmitry Stogov <dmitry@zend.com> Merge branch 'PHP-7.0'

* PHP-7.0:
Set proper type flags (REFCOUNTED and COPYABLE) according to interned or regular string
796e162 18-Feb-2016 Dmitry Stogov <dmitry@zend.com> Set proper type flags (REFCOUNTED and COPYABLE) according to interned or regular string
/php-src/ext/opcache/Optimizer/block_pass.c
ab58694 15-Feb-2016 Xinchen Hui <laruence@gmail.com> Fixed another assertion fails due to live_range cleaned (ext/phar/tests/003a.phpt)
/php-src/ext/opcache/Optimizer/block_pass.c
44ed1cb 11-Feb-2016 Nikita Popov <nikic@php.net> Remove ZEND_CALL_CTOR_RESULT_UNUSED

Instead emit a FREE on the result of NEW.
/php-src/ext/opcache/Optimizer/block_pass.c
8c2d559 11-Feb-2016 Dmitry Stogov <dmitry@zend.com> Combine conditions
/php-src/ext/opcache/Optimizer/block_pass.c
5faedf5 05-Feb-2016 Nikita Popov <nikic@php.net> Remove EXT_TYPE_UNUSED in favor of IS_UNUSED

This means we no longer allocate an unused VAR for the retval of
instructions that support unused results.

Nearly all instructions already used the result variable only if
it was used. The only exception to this was the return value
variable for internal function call results. I've adjusted the code
to use a stack zval for the unused return case now. As we have
retval specialization now, we know that it doesn't matter.
/php-src/ext/opcache/Optimizer/block_pass.c
7174af4 08-Feb-2016 Nikita Popov <nikic@php.net> Support CFG construction without live range splitting

We must not split at live range boundaries for SSA constructions,
otherwise an OP_DATA instruction may be separated into new block
and not picked up during renaming.

It's also unnecessary for this use case and only blows up the CFG.
/php-src/ext/opcache/Optimizer/block_pass.c
63fb2b7 25-Jan-2016 Xinchen Hui <laruence@gmail.com> Improve the names
/php-src/ext/opcache/Optimizer/block_pass.c
3d5438b 01-Jan-2016 Lior Kaplan <kaplanlior@gmail.com> Merge branch 'PHP-7.0'

* PHP-7.0:
Update header to PHP Version 7
Happy new year (Update copyright to 2016)
Happy new year (Update copyright to 2016)
2eb1f38 01-Jan-2016 Lior Kaplan <kaplanlior@gmail.com> Happy new year (Update copyright to 2016)
/php-src/ext/opcache/Optimizer/block_pass.c
e82a735 23-Dec-2015 Dmitry Stogov <dmitry@zend.com> Remove live-range if the corresponding definition is deleted
/php-src/ext/opcache/Optimizer/block_pass.c
88eae43 20-Dec-2015 Nikita Popov <nikic@php.net> Remove uses of VARs in extended_value

The DECLARE_(ANON_)INHERITED_CLASS(_DELAYED) opcodes were
referencing the parent ce VAR through extended_value. This is
hacky and we can't track the def-use chain in SSA.

To avoid this, the layout of declaration opcodes is changed
as follows: op1 points to the lcname and rtd_key literals, in
that order. (For anon/lambda declarations only one of lcname or
rtd_key is present.) This frees up op2, which is now used to
reference the parent ce VAR in inheriting declarations. The
jmp offset for anon class declarations is moved frop op2 to
extended_value.

The changes were applied both to class and function declarations
to keep everything symmetric.
/php-src/ext/opcache/Optimizer/block_pass.c
c88ffa9 15-Dec-2015 Dmitry Stogov <dmitry@zend.com> Added e-SSA based DFA optimisation framework (incomplete)
/php-src/ext/opcache/Optimizer/block_pass.c
29a2c64 15-Dec-2015 Sebastian Bergmann <sebastian@php.net> Fugbix typo
/php-src/ext/opcache/Optimizer/block_pass.c
6694ecd 14-Dec-2015 Bob Weinand <bobwei9@hotmail.com> Fix live_range updates on ZEND(_FE)_FREE opcodes in block_pass
/php-src/ext/opcache/Optimizer/block_pass.c
f243aaf 11-Dec-2015 Dmitry Stogov <dmitry@zend.com> Added e-SSA based DFA optimisation framework (incomplete)
/php-src/ext/opcache/Optimizer/block_pass.c
3b5c844 10-Dec-2015 Dmitry Stogov <dmitry@zend.com> Initialize bitset before processing the seconf BB (we skip the first one)
/php-src/ext/opcache/Optimizer/block_pass.c
fd20e6c 09-Dec-2015 Dmitry Stogov <dmitry@zend.com> Apply local optimizatons to extended bacic block (this allows some optimizarions across few following BBs).
/php-src/ext/opcache/Optimizer/block_pass.c
4fd30c9 09-Dec-2015 Dmitry Stogov <dmitry@zend.com> Improve debugging of non-local variables
/php-src/ext/opcache/Optimizer/block_pass.c
d2597ad 09-Dec-2015 Dmitry Stogov <dmitry@zend.com> Improved optimizer dubugging facility
/php-src/ext/opcache/Optimizer/block_pass.c
44c5fbb 09-Dec-2015 Dmitry Stogov <dmitry@zend.com> Fixed other issues with empty block handling
/php-src/ext/opcache/Optimizer/block_pass.c
245a8c3 08-Dec-2015 Xinchen Hui <laruence@gmail.com> end is unsigned, this was broken if start == end == 0
/php-src/ext/opcache/Optimizer/block_pass.c
404e003 09-Dec-2015 Dmitry Stogov <dmitry@zend.com> Delete empty live-ranges
/php-src/ext/opcache/Optimizer/block_pass.c
2cc2396 08-Dec-2015 Dmitry Stogov <dmitry@zend.com> Fixed compilation with enabled internal debuging
/php-src/ext/opcache/Optimizer/block_pass.c
3d8fdd5 07-Dec-2015 Dmitry Stogov <dmitry@zend.com> Fixed potential memory leaks
/php-src/ext/opcache/Optimizer/block_pass.c
1e9fcb4 20-Nov-2015 Xinchen Hui <laruence@gmail.com> conflicts variable name
/php-src/ext/opcache/Optimizer/block_pass.c
b3393ba 20-Nov-2015 Dmitry Stogov <dmitry@zend.com> Refactored CFG based optimization using new CFG representation.

Squashed commit of the following:

commit 907533390678f58eac738040ef62a40788048bef
Author: Dmitry Stogov <dmitry@zend.com>
Date: Fri Nov 20 21:25:28 2015 +0300

cleanup

commit 82f7e6f5bb434f12e9fdf45f597be351527f383c
Author: Dmitry Stogov <dmitry@zend.com>
Date: Fri Nov 20 21:22:01 2015 +0300

Update build system

commit 8fd83d843fde3f486692de4e2c6b7d64d4192704
Author: Dmitry Stogov <dmitry@zend.com>
Date: Fri Nov 20 20:50:32 2015 +0300

Reachable blocks can't be empty

commit 5822a36269833930a35cb3547222357118b11310
Author: Dmitry Stogov <dmitry@zend.com>
Date: Fri Nov 20 19:11:02 2015 +0300

added missing constraints

commit 2d0c00b243479924de0260ae8d80d624c36994a3
Author: Dmitry Stogov <dmitry@zend.com>
Date: Fri Nov 20 19:03:12 2015 +0300

optimization

commit 29d1e5eb210c51b052cac4d6c232aaa2c724dbbb
Author: Dmitry Stogov <dmitry@zend.com>
Date: Fri Nov 20 18:34:11 2015 +0300

Added missing optimization patterns

commit 38dd3b3f2459f5193c742633213f41d78326ea28
Author: Dmitry Stogov <dmitry@zend.com>
Date: Fri Nov 20 17:47:06 2015 +0300

zend_optimize_block() refactoring

commit 3dc97bd1f6d433dff0617338382347b6d0c08f84
Author: Dmitry Stogov <dmitry@zend.com>
Date: Fri Nov 20 14:30:32 2015 +0300

We don't use CFG back-references anymore

commit 2242c9e0aa741d287146ad43179650796f199f2d
Author: Dmitry Stogov <dmitry@zend.com>
Date: Fri Nov 20 14:16:03 2015 +0300

Consistent naming

commit 64f2856716069390ed7703ac88905cebf5e04023
Author: Dmitry Stogov <dmitry@zend.com>
Date: Fri Nov 20 13:29:32 2015 +0300

Optimization and separate building of direct CFG from predecessrs calculation

commit 9389be4869b13ec45df5dbd443015d2ac539a347
Author: Dmitry Stogov <dmitry@zend.com>
Date: Fri Nov 20 10:44:19 2015 +0300

Use CFG without back references (incomplete, but works)

commit 3d3ecd4b883959cf7b86c33622183295f913924e
Author: Dmitry Stogov <dmitry@zend.com>
Date: Fri Nov 20 00:50:09 2015 +0300

Fixed iteration in reverse order

commit 52f7fde0c3dfa4b4591519828ebdb238c2377936
Author: Dmitry Stogov <dmitry@zend.com>
Date: Thu Nov 19 18:35:09 2015 +0300

Separate debugging code into zend_dump.c

commit 4193a039ea96bae41baf97c6e458f419e8dbf9c5
Author: Dmitry Stogov <dmitry@zend.com>
Date: Thu Nov 19 17:22:04 2015 +0300

Remove unused code

commit 4228fdc57d8d120e1dad4e4d44045fa1a6f06fe0
Author: Dmitry Stogov <dmitry@zend.com>
Date: Thu Nov 19 17:21:20 2015 +0300

Remove dead live-ranges only on assembling basic blocks

commit 9a4a7966edf19b92678876f85565700694205598
Author: Dmitry Stogov <dmitry@zend.com>
Date: Thu Nov 19 15:26:29 2015 +0300

New CFG representation (incomplete)
/php-src/ext/opcache/Optimizer/block_pass.c
d6308af 19-Nov-2015 Dmitry Stogov <dmitry@zend.com> Proper optmisation of "goto" into the middle of "try" block.
/php-src/ext/opcache/Optimizer/block_pass.c
df63ec5 18-Nov-2015 Dmitry Stogov <dmitry@zend.com> minor fixes
/php-src/ext/opcache/Optimizer/block_pass.c
104a597 18-Nov-2015 Dmitry Stogov <dmitry@zend.com> Eliminate unreachable live ranges
/php-src/ext/opcache/Optimizer/block_pass.c
66b953e 18-Nov-2015 Dmitry Stogov <dmitry@zend.com> Eliminate unreachable catch blocks
/php-src/ext/opcache/Optimizer/block_pass.c
af47326 18-Nov-2015 Dmitry Stogov <dmitry@zend.com> Extended Debug info with live-ranges and excepton-table.
/php-src/ext/opcache/Optimizer/block_pass.c
a6cc322 17-Nov-2015 Dmitry Stogov <dmitry@zend.com> Added internal debug log for block pass.
/php-src/ext/opcache/Optimizer/block_pass.c
030fab6 17-Nov-2015 Dmitry Stogov <dmitry@zend.com> Two step optimization for JMPZNZ L,L; L: JMPZ L+1; L: JMPNZ L+1.
/php-src/ext/opcache/Optimizer/block_pass.c
854e8eb 17-Nov-2015 Dmitry Stogov <dmitry@zend.com> Move JMPZNZ L,L; L: JMPZ L+1; L: JMPNZ L+1 optimization patterns from zend_jmp_optimization() into zend_optimize_block() because the value of Tsource in zend_jmp_optimization() is inconsistent.
Fixed compilation warnings.
/php-src/ext/opcache/Optimizer/block_pass.c
6cb3d90 17-Nov-2015 Dmitry Stogov <dmitry@zend.com> Skip first basic block (we skiped it before)
/php-src/ext/opcache/Optimizer/block_pass.c
7de1908 17-Nov-2015 Dmitry Stogov <dmitry@zend.com> cleanup
/php-src/ext/opcache/Optimizer/block_pass.c
8112e34 17-Nov-2015 Dmitry Stogov <dmitry@zend.com> cleanup
/php-src/ext/opcache/Optimizer/block_pass.c
843c165 17-Nov-2015 Dmitry Stogov <dmitry@zend.com> Don't undo/redo "pass two" for jump targets in opcache optimizer.
/php-src/ext/opcache/Optimizer/block_pass.c
09aa68b 11-Nov-2015 Dmitry Stogov <dmitry@zend.com> Break dependency between opcache and optimizer. Remove copatibility macros.
/php-src/ext/opcache/Optimizer/block_pass.c
baf97b1 10-Nov-2015 Dmitry Stogov <dmitry@zend.com> We don't nees zend_op_array->brk_cont_array at run-time anymore.
Move zend_op_array->brk_cont_array into CG(context).brk_cont_array.
Use more compact zend_op_array->live_range instead of zend_op_array->brk_cont_array.
Semantic is kept unchanged.
/php-src/ext/opcache/Optimizer/block_pass.c
86a96f2 10-Nov-2015 Dmitry Stogov <dmitry@zend.com> Changed meaning of "op2" for ZEND_FREE, ZEND_FE_FREE, ZEND_FAST_CALL, ZEND_FAST_RET.
Previously it was an instruction number.
Now it's an index in op_array->try_cacth_array[].
/php-src/ext/opcache/Optimizer/block_pass.c
603c172 06-Nov-2015 Nikita Popov <nikic@php.net> Merge branch 'PHP-7.0'

Conflicts:
ext/opcache/Optimizer/zend_optimizer.c
99d818f 07-Nov-2015 Nikita Popov <nikic@php.net> Don't propagate into ops that error on non-string

To properly support this make update_opN_const fallible -- they
are not always called through replace_with_const.
/php-src/ext/opcache/Optimizer/block_pass.c
eb7be53 27-Oct-2015 Dmitry Stogov <dmitry@zend.com> Speed up fetching of class entries for self:: parent:: and static::

This is generalized solution for Bob's idea of speed up self::method() calls without ZEND_FETCH_CLASS.

At first, it adds few new opcodes to separate class related behaviour:
FETCH_STATIC_PROP_R
FETCH_STATIC_PROP_W
FETCH_STATIC_PROP_RW
FETCH_STATIC_PROP_FUNC_ARG
FETCH_STATIC_PROP_UNSET
FETCH_STATIC_PROP_IS
UNSET_STATIC_PROP
ISSET_ISEMPTY_STATIC_PROP
FETCH_CLASS_CONSTANT

At seconds, it enables IS_UNUSED operand to fetch (self, parent or static without separate FETCH_CLASS) for new opcodes and the following ones:
INIT_STATIC_METHOD_CALL
NEW
END_INSTANCEOF

Finaly, opcache optimizer had to be fixed to support new opcodes.
/php-src/ext/opcache/Optimizer/block_pass.c
fe08b93 12-Sep-2015 Bob Weinand <bobwei9@hotmail.com> Add support for **= in opcache optimizer
/php-src/ext/opcache/Optimizer/block_pass.c
79cd9a1 11-Aug-2015 Xinchen Hui <laruence@php.net> Fixed bug #70237 (Empty while and do-while segmentation fault with opcode on CLI enabled).
/php-src/ext/opcache/Optimizer/block_pass.c
6e894f8 11-Aug-2015 Xinchen Hui <laruence@php.net> Merge branch 'PHP-5.6'
90cb3bb 06-Aug-2015 Dmitry Stogov <dmitry@zend.com> Reduce memory usage by using bitsets instead of array of bytes.
/php-src/ext/opcache/Optimizer/block_pass.c
ef1b588 10-Jul-2015 Dmitry Stogov <dmitry@zend.com> Resolve GOTO at compile time and replace it with sequnce of FREE/FE_FREE and JMP.
/php-src/ext/opcache/Optimizer/block_pass.c
549e8c4 10-Jul-2015 Dmitry Stogov <dmitry@zend.com> Squashed commit of the following:

commit 03cf871f1576f08b2348c141b209894a7bf17a86
Author: Dmitry Stogov <dmitry@zend.com>
Date: Fri Jul 10 02:45:31 2015 +0300

Revert "Fixed bug #62210 (Exceptions can leak temporary variables. As a part of the fix serious refactoring was done. op_array->brk_cont_array was removed, and replaced with more general and speed efficient op_array->T_liveliness. ZEND_GOTO opcode is always replaced by ZEND_JMP at compile time). (Bob, Dmitry, Laruence)"

This reverts commit 5ee841325901a4b040cfea56292a24702fe224d9.

commit 285a68227ce3d380e821a24fa389aa5239bd3fe1
Author: Dmitry Stogov <dmitry@zend.com>
Date: Fri Jul 10 02:45:26 2015 +0300

Revert "Tuned off dubugging of live ranges"

This reverts commit 404dc93d35f7061fc4b1b41ad6cb0721b9b52bcc.

commit 93d9d11157301ee2ec99afb6f5744b126d17f637
Author: Dmitry Stogov <dmitry@zend.com>
Date: Fri Jul 10 02:45:17 2015 +0300

Revert "Remove loop_var_stack"

This reverts commit b3a4c05071c3786e27e1326fa1b4d5acad62fccd.

commit ede68ebbc284aec79e3f719f2c8dbf9da6907752
Author: Dmitry Stogov <dmitry@zend.com>
Date: Fri Jul 10 02:45:12 2015 +0300

Revert "ZEND_SEPARATE reuses temporaries"

This reverts commit 1852f538b9f8d5e7d67fe5a4f6080396d8b10034.

commit 96d8995dc1f517fb01b481736273767509f76c47
Author: Dmitry Stogov <dmitry@zend.com>
Date: Fri Jul 10 02:45:10 2015 +0300

Revert "Add assertion in liveliness computation"

This reverts commit ed14019e8c0c852480eebc6fc552d8c3d939dce1.

commit 0649d7bfef152e6cc8e67b922534e9946c634d9c
Author: Dmitry Stogov <dmitry@zend.com>
Date: Fri Jul 10 02:45:07 2015 +0300

Revert "Fixed invalid live-range detection"

This reverts commit 54f367ee2a2e4cb7c952b17915c226fdc56038ab.

commit dfe8f3851f6b04595eb089323e3492115a59363e
Author: Dmitry Stogov <dmitry@zend.com>
Date: Fri Jul 10 02:45:04 2015 +0300

Revert "Add test guaranteeing that loop vars are only freed after potential return type exceptions"

This reverts commit f5db5a558d550bf441373febebbb02f3884209d1.

commit 52a94aad6f48a199358cc07f7e4f56bb73050504
Author: Dmitry Stogov <dmitry@zend.com>
Date: Fri Jul 10 02:45:01 2015 +0300

Revert "Fixed exception habdling on "return" statement."

This reverts commit 17c5315bdf8f8087979aeb55f6d3a512ba197cf5.

commit 6e90ad7331901711e89c2ceb2bcab5023e5cee60
Author: Dmitry Stogov <dmitry@zend.com>
Date: Fri Jul 10 02:44:58 2015 +0300

Revert "Fix too early terminated temporary range with break/cont/goto"

This reverts commit cc876c04b420589cb1f62b650d0c0e24975dd4af.

commit 7b766e44b1970e4031f75109c302c07ead2c05cb
Author: Dmitry Stogov <dmitry@zend.com>
Date: Fri Jul 10 02:44:55 2015 +0300

Revert "Fixed exception catching on break/continue"

This reverts commit 8c3f701eebfa92d761bb368cfa8c2d1ccf821b9d.
/php-src/ext/opcache/Optimizer/block_pass.c
5ee8413 07-Jul-2015 Dmitry Stogov <dmitry@zend.com> Fixed bug #62210 (Exceptions can leak temporary variables. As a part of the fix serious refactoring was done. op_array->brk_cont_array was removed, and replaced with more general and speed efficient op_array->T_liveliness. ZEND_GOTO opcode is always replaced by ZEND_JMP at compile time). (Bob, Dmitry, Laruence)

Squashed commit of the following:

commit 38e22106d4bdcc829dd2b64be1d3c6cdc089f3ed
Author: Dmitry Stogov <dmitry@zend.com>
Date: Tue Jul 7 15:12:19 2015 +0300

Added NEWS entry

commit 0a355935bfb10b5a4c893f4db9496ea8abbcf71b
Author: Dmitry Stogov <dmitry@zend.com>
Date: Tue Jul 7 15:06:32 2015 +0300

Inline function, to eliminate repeatable checks

commit d937584f3aef0baae6001377b61fd700b6f36e14
Merge: 0341626 32677f5
Author: Dmitry Stogov <dmitry@zend.com>
Date: Tue Jul 7 14:35:49 2015 +0300

Merge branch 'master' into temporary_cleaning

* master:
Fixed bug #70006 (cli - function with default arg = STDOUT crash output).
Fix x86 build
Fixed use after free on closure_call_leak_with_exception.phpt
Fixed test

commit 0341626ea94a5e474c660732d33884460847d5e7
Merge: 74869fa dec35de
Author: Dmitry Stogov <dmitry@zend.com>
Date: Tue Jul 7 12:00:53 2015 +0300

Merge branch 'temporary_cleaning' of https://github.com/laruence/php-src into temporary_cleaning

* 'temporary_cleaning' of https://github.com/laruence/php-src:
Fixed checkpoint get
Fixed crash of invalid pointer derefer
cleanup

commit 74869fa67375b8daf772ac30b6b936fd2a2132c6
Author: Dmitry Stogov <dmitry@zend.com>
Date: Tue Jul 7 11:45:34 2015 +0300

Fixed wrong GOTO resolution

commit dec35ded3294e3022e88a623188c3d1d71381675
Author: Xinchen Hui <laruence@gmail.com>
Date: Tue Jul 7 15:58:49 2015 +0800

Fixed checkpoint get

commit b0f419540ad24c44810c9b05da046965618ffc65
Author: Dmitry Stogov <dmitry@zend.com>
Date: Tue Jul 7 10:47:11 2015 +0300

Fixed crash of invalid pointer derefer (laruence)

commit 7a428d98ca2899c5933914caa0cd17b4126e952c
Author: Dmitry Stogov <dmitry@zend.com>
Date: Tue Jul 7 10:35:47 2015 +0300

Fixed identation

commit 9c3a4dce9ce02034d19d28182aa9c1298d528daf
Author: Dmitry Stogov <dmitry@zend.com>
Date: Tue Jul 7 10:33:52 2015 +0300

Fixed invalid size

commit 653abc670b2a1f453b0fc3fc4a9eca919ee870cc
Author: Xinchen Hui <laruence@gmail.com>
Date: Tue Jul 7 11:29:14 2015 +0800

Fixed crash of invalid pointer derefer

commit e04500ceda606ac4f364d03bcd562327bdc74eee
Author: Xinchen Hui <laruence@gmail.com>
Date: Tue Jul 7 11:28:26 2015 +0800

cleanup

commit 34183e1687681038e77b650078927b35ee84e933
Author: Dmitry Stogov <dmitry@zend.com>
Date: Tue Jul 7 04:49:46 2015 +0300

op_array->T_liveliness compression

commit 2f6ad845795a08c3d7ac219e9c42950565b20394
Author: Dmitry Stogov <dmitry@zend.com>
Date: Tue Jul 7 04:44:44 2015 +0300

White spaces

commit be83f115a3f82a548c8d377c66574de5e5187410
Author: Dmitry Stogov <dmitry@zend.com>
Date: Tue Jul 7 04:42:26 2015 +0300

Identation

commit 1f5084b99038c374ac012b017c4d1652bb5d4222
Merge: 91b620d 1adf3df
Author: Dmitry Stogov <dmitry@zend.com>
Date: Tue Jul 7 04:41:54 2015 +0300

Merge branch 'master' into temporary_cleaning

* master:
Throw TypeError for invalid callback
Fix crash when exception occurs during nested rope
Fix crash when exception is thrown during ROPE_END
Small cleanup in ternary compilation
move the define to the right place
fix ext/ldap build
Rectify information about invalid shift warning being now ArithmeticError

commit 91b620d684c5a2296774432d5d0ff8f5d14397d6
Author: Dmitry Stogov <dmitry@zend.com>
Date: Tue Jul 7 04:32:04 2015 +0300

Replace GOTO by FREE/FE_FREE and JMP at compile time

commit 7052e5697918fab83d2975977c3392f7188fbc87
Author: Dmitry Stogov <dmitry@zend.com>
Date: Tue Jul 7 02:25:08 2015 +0300

Use zend_regenerate_var_liveliness_info() to regenerate information after pass two.

commit ae72b0dc6797815a846b8f95abccb36367422d27
Merge: a81c4bb a919fe8
Author: Dmitry Stogov <dmitry@zend.com>
Date: Mon Jul 6 21:02:34 2015 +0300

Merge branch 'master' into temporary_cleaning

* master:
Do not display EXT_TYPE_UNUSED in phpdbg opcodes
Run debug build with opcache on travis

commit a81c4bb8c6f1ba8124a5a7636694480ff0f1328c
Author: Dmitry Stogov <dmitry@zend.com>
Date: Mon Jul 6 20:59:34 2015 +0300

Improved algorithm. It's actually the same algorithm with second loop removed and simpler temporary data structures. The only difference may be in "re-defined" vatriable handling. Now live-range in that case started from the seconnd definition (this must be more safe).

commit 9a16810f7a7c10373603c5250d985616acf45e97
Merge: bbfbe47 001ecd3
Author: Dmitry Stogov <dmitry@zend.com>
Date: Mon Jul 6 17:57:45 2015 +0300

Merge branch 'master' into temporary_cleaning

* master:
Simplify TMP var number decoding (without HashTable)

commit bbfbe470c865cb8b3cae8bf6518e6d06af525522
Merge: 0bda4ab 436b01e
Author: Dmitry Stogov <dmitry@zend.com>
Date: Mon Jul 6 17:02:01 2015 +0300

Merge branch 'master' into temporary_cleaning

* master:
Avoid dangerous optimization
Fixed JMPZNZ instruction printing
Attempt at falling back on ldap_find_control for Mac OS

commit 0bda4abea7ba0a51c2ec125edb547645d0329792
Author: Dmitry Stogov <dmitry@zend.com>
Date: Mon Jul 6 16:05:33 2015 +0300

Fixed live-range construction for OP_DATA opcode
Added comments about algorithm assumtions

commit 521ad9df98fdf1dd8b7c212799ddeb1a84483e6f
Merge: 4398dab a09dcb0
Author: Bob Weinand <bobwei9@hotmail.com>
Date: Mon Jul 6 14:54:15 2015 +0200

Merge branch 'master' of https://github.com/php/php-src into temporary_cleaning

commit 4398dab82f9a5ce64df55b24988ce7d31e24074f
Author: Bob Weinand <bobwei9@hotmail.com>
Date: Mon Jul 6 13:51:27 2015 +0200

Add a few phpt tests related to temporary cleaning

commit 739656f83ff5b570bb311d2c7cb2d72380a3c759
Author: Dmitry Stogov <dmitry@zend.com>
Date: Mon Jul 6 14:28:49 2015 +0300

Fixed Zend/tests/foreach_004.phpt failure (FE_FETCH shouldn't be included into TMP vatriablr live range)

commit 3df462a2bcf5fa8f9244ea299178152a5d436277
Author: Dmitry Stogov <dmitry@zend.com>
Date: Mon Jul 6 13:41:02 2015 +0300

Improve data layout (reduce the op_array structure size on 64-bit systems)

commit 883b73c56e6dab6489ae4cda2c1331b53a995586
Author: Dmitry Stogov <dmitry@zend.com>
Date: Mon Jul 6 13:28:45 2015 +0300

Removed op_array->brk_cont_array

commit ae5e58b59843513505e84e396c1446ac35cb1b94
Author: Bob Weinand <bobwei9@hotmail.com>
Date: Mon Jul 6 04:22:58 2015 +0200

Fix bug with brk_cont variable free / free loop vars via temporary liveliness info

commit b4223ca62771e1003c9ab778a09a177ad71e6d57
Author: Bob Weinand <bobwei9@hotmail.com>
Date: Mon Jul 6 04:07:07 2015 +0200

Fix bugs / cleanup fixes

commit ea33189d220c7fc0884848571635abe3cddd2f4d
Author: Xinchen Hui <laruence@gmail.com>
Date: Sun Jul 5 20:58:38 2015 +0800

Removed useless TsTop

commit 1dbb007e4addba9ac3bfc227db27a651cbcf5ede
Merge: 550bbf8 3a8af24
Author: Xinchen Hui <laruence@gmail.com>
Date: Sat Jul 4 15:06:44 2015 +0800

Merge branch 'temporary_cleaning' of https://github.com/dstogov/php-src into temporary_cleaning

commit 3a8af245290ceb507108340831254672f24022fa
Author: Dmitry Stogov <dmitry@zend.com>
Date: Fri Jul 3 16:15:36 2015 +0300

More exceptions from regular liveliness analyses (with explanation in comments).
Mark old "unexplained" exceptions with ???.

commit ba721efa2cbd2136668fec956ef3b034ac1a29d6
Author: Dmitry Stogov <dmitry@zend.com>
Date: Fri Jul 3 14:16:09 2015 +0300

Print list of live temp variables (at least for internal debugging)

commit 8d1f88fe91e62b4333703c58b871d85b66fb7b70
Author: Dmitry Stogov <dmitry@zend.com>
Date: Fri Jul 3 13:31:56 2015 +0300

Use op_array->T_liveliness to free incomplete ropes and restore error_reporting level on exception

commit 80c1d0d779e6e9609a211907838f3727aa7b301a
Author: Dmitry Stogov <dmitry@zend.com>
Date: Fri Jul 3 11:05:39 2015 +0300

Don't keep empty T_liveliness

commit 501ae8aaac0a92368b50e9f342b04d7334d263f6
Author: Dmitry Stogov <dmitry@zend.com>
Date: Thu Jul 2 22:31:48 2015 +0300

Reverted changes to Zend/zend_arena.h.
Reuse CG(arena) instead of creating a new one.

commit a4fce36907147df5ac1af78b44135e3f07c1844c
Merge: 6ff7246 fd0fcce
Author: Dmitry Stogov <dmitry@zend.com>
Date: Thu Jul 2 22:01:42 2015 +0300

Merge branch 'temporary_cleaning' of github.com:bwoebi/php-src into temporary_cleaning

* 'temporary_cleaning' of github.com:bwoebi/php-src:
Fix remaining issues with compacted temporaries
Fix regression from last commit (+1 ?!)
Fix off-by-one (opcache may remove last ZEND_RETURN)
Speed algorithm up, more fail safety when reusing temporaries
Dumb bug in opcode.c (forgot to update Ts[i])
Fix opcache support
Exempt ROPE temporaries from freeing
Hmm, we need temporary info for all the opcodes
Add opcache support for cleaning in optimization step (Opcache seems to have a few unrelated issues which blow up together with that patch)
Add proper temporary cleaning upon frame abortion
Fix arena on small sizes (size < sizeof(zend_arena))

commit fd0fcce81177717f3a05ac87192b5ed05eead0a1
Author: Bob Weinand <bobwei9@hotmail.com>
Date: Thu Jul 2 20:00:33 2015 +0200

Fix remaining issues with compacted temporaries

commit 427dc58bbb93022d1c2077f874afcdb9dd82d5c5
Author: Bob Weinand <bobwei9@hotmail.com>
Date: Wed Jul 1 22:49:12 2015 +0200

Fix regression from last commit (+1 ?!)

commit 1adcf56a6e9f09e7ad06331d4d6280035b17a7d1
Author: Bob Weinand <bobwei9@hotmail.com>
Date: Wed Jul 1 22:17:07 2015 +0200

Fix off-by-one (opcache may remove last ZEND_RETURN)

commit 25b231b7841fa4078c65976cabdd843845a6cbe6
Author: Bob Weinand <bobwei9@hotmail.com>
Date: Wed Jul 1 20:59:24 2015 +0200

Speed algorithm up, more fail safety when reusing temporaries

commit 22d9d05350e35d180018d0bccbad6f173cb4797d
Author: Bob Weinand <bobwei9@hotmail.com>
Date: Wed Jul 1 16:48:46 2015 +0200

Dumb bug in opcode.c (forgot to update Ts[i])

commit 6538269bfa5bcbad34fc2f051b0fd5e4ebf2ff00
Author: Bob Weinand <bobwei9@hotmail.com>
Date: Wed Jul 1 13:05:52 2015 +0200

Fix opcache support

commit 333a7c4a8813a45dc79ce55b8e9c0a0b98671e13
Author: Bob Weinand <bobwei9@hotmail.com>
Date: Sat Jun 27 22:40:21 2015 +0200

Exempt ROPE temporaries from freeing

commit 02585f77085427baea48448c134a96c542af3337
Author: Bob Weinand <bobwei9@hotmail.com>
Date: Fri Jun 26 16:20:55 2015 +0200

Hmm, we need temporary info for all the opcodes

commit cbcaedbd78199897e5cacffd700b706f21590abf
Author: Bob Weinand <bobwei9@hotmail.com>
Date: Fri Jun 26 01:04:09 2015 +0200

Add opcache support for cleaning in optimization step
(Opcache seems to have a few unrelated issues which blow up together with that patch)

commit fef649f4067823a1f96f85340cf715e5877310bc
Author: Bob Weinand <bobwei9@hotmail.com>
Date: Fri Jun 26 01:02:27 2015 +0200

Add proper temporary cleaning upon frame abortion

commit 1cec2e7271b789b84601f8acf385950af1bb0c7c
Author: Bob Weinand <bobwei9@hotmail.com>
Date: Thu Jun 25 23:33:21 2015 +0200

Fix arena on small sizes (size < sizeof(zend_arena))
/php-src/ext/opcache/Optimizer/block_pass.c
436b01e 06-Jul-2015 Dmitry Stogov <dmitry@zend.com> Avoid dangerous optimization
/php-src/ext/opcache/Optimizer/block_pass.c
fa1abb5 01-Jul-2015 Dmitry Stogov <dmitry@zend.com> Fixed memory leak because of incorrect 'if ();' optimization
/php-src/ext/opcache/Optimizer/block_pass.c
a0b55e6 01-Jul-2015 Dmitry Stogov <dmitry@zend.com> Cleanup (updated comments about optimization of comparison with IS_NULL)
/php-src/ext/opcache/Optimizer/block_pass.c
4a2e40b 30-Jun-2015 Dmitry Stogov <dmitry@zend.com> Use ZSTR_ API to access zend_string elements (this is just renaming without semantick changes).
/php-src/ext/opcache/Optimizer/block_pass.c
625dba0 29-Jun-2015 Dmitry Stogov <dmitry@zend.com> Don't evaluate invalid constant expressions.
/php-src/ext/opcache/Optimizer/block_pass.c
4a4529a 28-Jun-2015 Bob Weinand <bobwei9@hotmail.com> Fix rope memory leaks upon exception
/php-src/ext/opcache/Optimizer/block_pass.c
8542bef 22-May-2015 Nikita Popov <nikic@php.net> Remove ZEND_BRK/ZEND_CONT from VM

These are no longer used at run-time now, only temporarily during
compilation.
/php-src/ext/opcache/Optimizer/block_pass.c
d72a944 12-May-2015 Dmitry Stogov <dmitry@zend.com> Merged FE_FETCH_R[W] with the following ASSIGN[_REF] when assigne to CV.
/php-src/ext/opcache/Optimizer/block_pass.c
7e5aa6b 13-May-2015 Dmitry Stogov <dmitry@zend.com> Removed deprecated conditions
/php-src/ext/opcache/Optimizer/block_pass.c
e6976e9 06-May-2015 Dmitry Stogov <dmitry@zend.com> Merge branch 'PHP-5.6'

* PHP-5.6:
Fixed bug #69549 (Memory leak with opcache.optimization_level=0xFFFFFFFF)
329513c 06-May-2015 Dmitry Stogov <dmitry@zend.com> Merge branch 'PHP-5.5' into PHP-5.6

* PHP-5.5:
Fixed bug #69549 (Memory leak with opcache.optimization_level=0xFFFFFFFF)

Conflicts:
NEWS
8026001 06-May-2015 Dmitry Stogov <dmitry@zend.com> Fixed bug #69549 (Memory leak with opcache.optimization_level=0xFFFFFFFF)
/php-src/ext/opcache/Optimizer/block_pass.c
94245bc 26-Apr-2015 Dmitry Stogov <dmitry@zend.com> Refactored using specialized opcodes
/php-src/ext/opcache/Optimizer/block_pass.c
ca76a86 21-Apr-2015 Dmitry Stogov <dmitry@zend.com> Removed deprecated code
/php-src/ext/opcache/Optimizer/block_pass.c
e37e9d2 24-Mar-2015 Dmitry Stogov <dmitry@zend.com> Reverted part committed by mistake
/php-src/ext/opcache/Optimizer/block_pass.c
23c33b1 24-Mar-2015 Dmitry Stogov <dmitry@zend.com> Optimized strings concatenation.
ZEND_ADD_STRING/VAR/CHAR are replaced with ZEND_ROPE_INTI, ZEND_ROPE_ADD, ZEND_ROPE_END.
Instead of reallocation and copying string on each ZEND_ADD_STRING/VAR/CAHR, collect all the strings and then allocate and construct the resulting string once.
/php-src/ext/opcache/Optimizer/block_pass.c
0a6bb2d 20-Mar-2015 Dmitry Stogov <dmitry@zend.com> Fixed optimization patterns
/php-src/ext/opcache/Optimizer/block_pass.c
d146d15 19-Mar-2015 Dmitry Stogov <dmitry@zend.com> Optimize zend_string_realloc() add more specialized versions zend_string_extend() and zend_string_truncate()
/php-src/ext/opcache/Optimizer/block_pass.c
db10b72 13-Mar-2015 Dmitry Stogov <dmitry@zend.com> Use fastcall calling convention for most critical ZE subsystems.
/php-src/ext/opcache/Optimizer/block_pass.c
9a20323 01-Mar-2015 Dmitry Stogov <dmitry@zend.com> Improved assert() according to expectations RFC.

See https://wiki.php.net/rfc/expectations

Squashed commit of the following:

commit 3f3651a7870738e35ec541e53b53069152135b24
Author: Dmitry Stogov <dmitry@zend.com>
Date: Mon Mar 2 11:56:33 2015 +0300

opcode 137 is used for ZEND_OP_DATA and con't be reused for ZEND_ASSERT_CHECK

commit ca8ecabf2a5f97f9116839c33396c9a7037e4368
Merge: 24328ac 9dac923
Author: Dmitry Stogov <dmitry@zend.com>
Date: Mon Mar 2 10:49:23 2015 +0300

Merge branch 'master' into assert

* master:
Update NEWS
Fixed bug #69139 (Crash in gc_zval_possible_root on unserialize)
windows only test
Align entries format
Align entries format for 5.6.7
Align entries format for 5.5.23
Bump header year
Fixed bug #69144 (strtr not replacing with partly matching replace pairs)
Fixed test?
Revert mktime()/gmmktime()'s arginfo
Update NEWS
Fixed bug #69141 Missing arguments in reflection info for some builtin functions
Add NEWS entry
Remove useless date warning
Fix ARG_INFO for levenshtein
Fix ARG_INFO for levenshtein
fix dir separator in tests
Update NEWS
Fixed bug #69085 (SoapClient's __call() type confusion through unserialize()).

commit 24328ac03f79a0f3b19be7411bf9e173f392abda
Merge: 021fd94 1cdee9a
Author: Dmitry Stogov <dmitry@zend.com>
Date: Fri Feb 27 15:57:13 2015 +0300

Merge branch 'master' into assert

* master:
Fixed C++ support
Fixed bug #69115 crash in mail
Reorder
Update NEWs
Fixed bug #69121 (Segfault in get_current_user when script owner is not in passwd with ZTS build)
Update News
Fixed bug #69125 (Array numeric string as key)
fix bug#68942's patch
Fixed ability to build unspecialized executor
Fixed bug #69124 (method name could not be used when by ref)
Fixed a bug that header value is not terminated by '\0' when accessed through getenv().
Fixed a bug that header value is not terminated by '\0' when accessed through getenv().

commit 021fd94ed1d692d212e6e30c6c1a9767c3f16f7f
Merge: 49963eb ace1f82
Author: Dmitry Stogov <dmitry@zend.com>
Date: Thu Feb 26 11:26:03 2015 +0300

Merge branch 'master' into assert

* master: (59 commits)
Improved ASSIGN_DIM handler
Don't inline slow path
Revert a part committted by mistake
Fixed compilation warnings
Fixed a bug that header value is not terminated by '\0' when accessed through getenv().
better name
Improve fix for #69038
Update NEWs
Fixed bug #69108 ("Segmentation fault" when (de)serializing SplObjectStorage)
Added specialized versions of DO_FCALL handler: DO_ICALL - for internal functions DO_UCALL - for user functions DO_FCALL_BY_NAME - plain, most probably user, funcstions (not methods)
Use cache_slot offsets instead of indexes (simplify run-time instructions)
Split INIT_FCALL_BY_NAME inti INIT_FCALL_BY_NAME(CONST+STRING) and INIT_DYNAMIC_CALL(CONST-STRING|TMPVAR|CV)
Support list($a, $b) = $a
Avoid unnecassary check
Make zend_array_destroy() to free the corresponding zend_array
Eliminate check on the fast path
Make current() and key() receive argument by value.
Use Firebird default home folder, replace Interbase with Firebird
Updated NEWS
updated NEWS
...

Conflicts:
Zend/zend_vm_execute.h
Zend/zend_vm_opcodes.c
Zend/zend_vm_opcodes.h

commit 49963ebf9d2bcd6d2670203dd72884f6ba6c8a4b
Merge: 07b1f92 6b77959
Author: Dmitry Stogov <dmitry@zend.com>
Date: Thu Feb 19 11:13:08 2015 +0300

Merge branch 'master' into assert

* master:
Implemented AST pretty-printer
update NEWS to match the actual stuff in 5.6.6
update NEWS to match the actual stuff in 5.5.22
update NEWS(add missing entry for the enchant fix, and reorder the entries a bit)
fix typo in bug#
update NEWS
fix email format
update NEWS
update 5.6.6 release date in NEWS
Fix bug #69033 (Request may get env. variables from previous requests if PHP works as FastCGI)
BFN
fix test
fix test
fix test
Fixed bug #65593 (Segfault when calling ob_start from output buffering callback)
Updated NEWS
add CVE
5.4.39 next
Fix associativity to match Perl
Blast off to space.

Conflicts:
Zend/zend_ast.c

commit 07b1f92ed662f6fa9309e679b83aff328362c98b
Author: Dmitry Stogov <dmitry@zend.com>
Date: Wed Feb 18 23:06:32 2015 +0300

fixed pretty-printer (support for "elseif")

commit 5a976c8d85078502b48379996ab066e57533a0c3
Author: Dmitry Stogov <dmitry@zend.com>
Date: Wed Feb 18 19:50:08 2015 +0300

Fixed vaeious ptetty-printer issues

commit 69491e8e8e692030b0585aab485146906c0fedaf
Merge: 8473157 3ddc246
Author: Dmitry Stogov <dmitry@zend.com>
Date: Wed Feb 18 10:18:32 2015 +0300

Merge branch 'master' into assert

* master:
Set PHP_JSON_VERSION to 1.4.0
Remove unnecessary resource checks in openssl ext
JSON is now maintained

commit 8473157fbb12d03fff8d5b602865a4b667522a4d
Author: Dmitry Stogov <dmitry@zend.com>
Date: Wed Feb 18 10:17:26 2015 +0300

Fixed typo and white spaces

commit 96de5ffc8d604df9797d0141ae5ad9c15e1d6c32
Author: Dmitry Stogov <dmitry@zend.com>
Date: Wed Feb 18 00:28:39 2015 +0300

Fixed assert() in namesapaces

commit 5eba069c28e7b6590618707e0b21cdb2dd62a192
Merge: 4a2d9c0 d428bf2
Author: Dmitry Stogov <dmitry@zend.com>
Date: Tue Feb 17 22:45:55 2015 +0300

Merge branch 'master' into assert

* master: (25 commits)
improve debugability in TS debug builds
More UPGRADING, in particular on foreach
Fixed bug #69038 (switch(SOMECONSTANT) misbehaves) for master
Replace var is introduced
abstain from using xmlCleanupParser
fix TS build
Fix bug #68942 (Use after free vulnerability in unserialize() with DateTimeZone)
update news
Fix bug #68942 (Use after free vulnerability in unserialize() with DateTimeZone)
Port for for bug #68552
Fix bug #68942 (Use after free vulnerability in unserialize() with DateTimeZone)
Update NEWS
Fixed bug #69038 (switch(SOMECONSTANT) misbehaves)
- BFN
Don't read the local php.ini when Generating Phar When building phar shared, you can end up loading a previous phar.so that isn't compatible with the php cli being used to generate Phar here.
- Fixed bug #67827 (broken detection of system crypt sha256/sha512 support)
Delete json outdated package.xml
made ZEND_TSRMLS_CACHE_* macros look like function calls
- Fix merge
- Fixed bug #67427 (SoapServer cannot handle large messages) patch by: brandt at docoloc dot de
...

commit 4a2d9c0953dccd9e78ebee9291e1213419eb9136
Author: Dmitry Stogov <dmitry@zend.com>
Date: Tue Feb 17 22:45:10 2015 +0300

Implemented AST pretty-printer to capture expression passed to assert()

commit 7a059b66d51a65159801bd826346721325b89fec
Merge: 9973df7 3892eba
Author: Dmitry Stogov <dmitry@zend.com>
Date: Mon Feb 16 18:42:28 2015 +0300

Merge branch 'expect' of github.com:krakjoe/php-src into assert

* 'expect' of github.com:krakjoe/php-src:
import expect

Conflicts:
Zend/zend_compile.c
Zend/zend_execute_API.c
Zend/zend_globals.h
Zend/zend_vm_def.h
Zend/zend_vm_execute.h
Zend/zend_vm_opcodes.c
Zend/zend_vm_opcodes.h
ext/opcache/Optimizer/block_pass.c
ext/opcache/Optimizer/pass1_5.c
ext/standard/assert.c
ext/standard/tests/assert/assert_error3.phpt

commit 3892eba2bf56a7699453855c995404106322718d
Author: krakjoe <joe.watkins@live.co.uk>
Date: Sun Feb 2 12:49:35 2014 +0000

import expect
/php-src/ext/opcache/Optimizer/block_pass.c
c2c78dc 25-Feb-2015 Dmitry Stogov <dmitry@zend.com> Added specialized versions of DO_FCALL handler:
DO_ICALL - for internal functions
DO_UCALL - for user functions
DO_FCALL_BY_NAME - plain, most probably user, funcstions (not methods)
/php-src/ext/opcache/Optimizer/block_pass.c
97fe15d 12-Feb-2015 Dmitry Stogov <dmitry@zend.com> Fix "forech" statemt behaviour according to https://wiki.php.net/rfc/php7_foreach

Squashed commit of the following:

commit 1e41295097576dbce6c197ddb7507c07ccae3cbe
Author: Dmitry Stogov <dmitry@zend.com>
Date: Sat Jan 31 07:28:58 2015 +0300

Generalize HashTableIterator API to allows its usage without involvement of HashTable.nInternalPonter

commit 5406f21b11e563069d64045e599693b51c444b63
Author: Dmitry Stogov <dmitry@zend.com>
Date: Fri Jan 30 18:08:43 2015 +0300

Reduced alghorithms complexity

commit b37f1d58d2a141b6e1d980a461ccb588d4317d2e
Author: Dmitry Stogov <dmitry@zend.com>
Date: Fri Jan 30 18:08:30 2015 +0300

Fixed test name

commit fb2d079645829b12ed4e55a461034df6400bc430
Author: Dmitry Stogov <dmitry@zend.com>
Date: Fri Jan 30 18:08:05 2015 +0300

API cleanup

commit 08302c0d6d1cab279b9f2129df03a057baddf2ff
Author: Dmitry Stogov <dmitry@zend.com>
Date: Fri Jan 30 14:20:46 2015 +0300

Make array_splice() to preserve foreach hash position

commit cc4b7be41e2e2b9b0d7a3c8e98466b8886692e6e
Author: Dmitry Stogov <dmitry@zend.com>
Date: Fri Jan 30 12:24:31 2015 +0300

Make internal function, operation on array passed by reference, to preserve foreach hash position

commit 5aa9712b0a30303aadfe3bdd8ae1f072ca3e6ba1
Author: Dmitry Stogov <dmitry@zend.com>
Date: Fri Jan 30 09:49:35 2015 +0300

Implement consistent behavior for foreach by value over plain object

commit 4c5b385ff53ae9f0b52572e98c4db801f56603b0
Author: Dmitry Stogov <dmitry@zend.com>
Date: Fri Jan 30 07:56:37 2015 +0300

More careful iterators update.

commit 721fc9e80d2ee8f2cd79c8c3cdceffae2c72de92
Author: Dmitry Stogov <dmitry@zend.com>
Date: Thu Jan 29 21:43:28 2015 +0300

Added new test

commit 15a23b1218b3e38630d677751a975907daa2cd54
Author: Dmitry Stogov <dmitry@zend.com>
Date: Thu Jan 29 21:05:02 2015 +0300

Reimplement iteration magic with HashTableIterators (see https://wiki.php.net/rfc/php7_foreach#implementation_details)

commit 10a3260b1f16b6075fd8140f673dfef4d5efea91
Author: Dmitry Stogov <dmitry@zend.com>
Date: Thu Jan 29 21:04:44 2015 +0300

New test

commit eef80c583762d1e98d177cdbb27e3a8a6b0c4539
Author: Dmitry Stogov <dmitry@zend.com>
Date: Wed Jan 28 16:52:21 2015 +0300

Fixed foreach by reference iteration over constant array

commit 61e739187391661e2d541947bec25d7dcc4479f3
Author: Dmitry Stogov <dmitry@zend.com>
Date: Wed Jan 28 14:59:54 2015 +0300

Fixed temporary variable re-allocation pass

commit 92e90c09f085c22707ff4a59201f016f56e0ef8b
Author: Dmitry Stogov <dmitry@zend.com>
Date: Wed Jan 28 12:44:57 2015 +0300

Fixed operand destruction in case of exceptions in iterator

commit dd2a36a2074bbb0cb31de00b66dcf2812d6d753f
Author: Dmitry Stogov <dmitry@zend.com>
Date: Wed Jan 28 10:02:34 2015 +0300

Use GET_OP1_ZVAL_PTR_DEREF() (IS_TMP_VAR and IS_CONST can't be IS_REFERENCE)

commit 4638f7b91407c48710007af82a68da0007c820f2
Author: Dmitry Stogov <dmitry@zend.com>
Date: Wed Jan 28 07:43:28 2015 +0300

Change "foreach" statement behavior (this is just a PoC yet)

- "foreach by value" don't relay on internal array/object pointer and doesnt perform array duplication. It just locks it incrementing reference counter. If the original array is modified by some code, the copy on write is performed and "foreach" still work with the old copy.

- it makes no difference if array given to "foreach by value" is reference itself

- "foreach by reference" still use internal array/object pointer and should work similar to PHP-5. (This id not completely implemented)
/php-src/ext/opcache/Optimizer/block_pass.c
d0e75bd 22-Jan-2015 Anatol Belski <ab@php.net> Merge branch 'PHP-5.5' into PHP-5.6

* PHP-5.5:
Fixed bug #68827 Double free with disabled ZMM
Fixed segfault while running with moodle
201f660 22-Jan-2015 Xinchen Hui <laruence@php.net> Merge branch 'PHP-5.6'
d0928b7 22-Jan-2015 Xinchen Hui <laruence@php.net> Merge branch 'PHP-5.5' into PHP-5.6
251745c 22-Jan-2015 Xinchen Hui <laruence@php.net> Fixed segfault while running with moodle
/php-src/ext/opcache/Optimizer/block_pass.c
22ac15e 19-Jan-2015 Dmitry Stogov <dmitry@zend.com> Improve optimization of CONCAT/ADD_STRING/ADD_CJAR sequences
/php-src/ext/opcache/Optimizer/block_pass.c
fc33f52 15-Jan-2015 Xinchen Hui <laruence@php.net> bump year
/php-src/ext/opcache/Optimizer/block_pass.c
b7a7b1a 03-Jan-2015 Stanislav Malyshev <stas@php.net> trailing whitespace removal
/php-src/ext/opcache/Optimizer/block_pass.c
aa5b3b0 09-Jan-2015 Xinchen Hui <laruence@php.net> Merge branch 'PHP-5.6'
0547edb 09-Jan-2015 Xinchen Hui <laruence@php.net> Fixed bug (try block removed while combined with xdebug)
/php-src/ext/opcache/Optimizer/block_pass.c
0f81564 05-Dec-2014 Nikita Popov <nikic@php.net> Drop ZEND_PRINT opcode in favor of ZEND_ECHO

The return value long(1) is an IS_CONST operand now.
/php-src/ext/opcache/Optimizer/block_pass.c
e112f6a 14-Dec-2014 Anatol Belski <ab@php.net> second shot on removing TSRMLS_*
/php-src/ext/opcache/Optimizer/block_pass.c
bdeb220 13-Dec-2014 Anatol Belski <ab@php.net> first shot remove TSRMLS_* things
/php-src/ext/opcache/Optimizer/block_pass.c
303d73e 26-Nov-2014 Dmitry Stogov <dmitry@zend.com> Reimplemented silence operator (@) handling on exceptions. Now each silence region is stored in op_array->brk_cont_array. On exception ZEND_HANDLE_EXCEPTION handler traverse this array and restore original EG(error_reporting) if exception occured inside a "silence" region.
/php-src/ext/opcache/Optimizer/block_pass.c
ab539e1 20-Oct-2014 Dmitry Stogov <dmitry@zend.com> Removed old irrelevant comment
/php-src/ext/opcache/Optimizer/block_pass.c
7c7b918 05-Oct-2014 Dmitry Stogov <dmitry@zend.com> Fixed list() behavior inconsistency (string handling is disabled for all cases, ArrayAccess objects handling is enabled for all cases, ZEND_FETCH_DIM_TMP_VAR opcode is renamed into ZEND_FETCH_LIST, ZEND_FETCH_ADD_LOCK flag is removed).
/php-src/ext/opcache/Optimizer/block_pass.c
67a11b6 29-Sep-2014 Nikita Popov <nikic@php.net> Drop unused INIT_STRING opcode

INIT_STRING has been implemented as an UNUSED op1 to ADD_* for
some time now.
/php-src/ext/opcache/Optimizer/block_pass.c
5bd34be 27-Sep-2014 Nikita Popov <nikic@php.net> Opcache compatibility for coalesce operator
/php-src/ext/opcache/Optimizer/block_pass.c
06103d6 23-Sep-2014 Dmitry Stogov <dmitry@zend.com> Use zval_ptr_dtor_nogc() to free IS_TMP_VAR operands.
Removed ZEND_SWITCH_FREE opcode (ZEND_FREE used instead).
/php-src/ext/opcache/Optimizer/block_pass.c
d244d3b 22-Sep-2014 Dmitry Stogov <dmitry@zend.com> Fixed typo
/php-src/ext/opcache/Optimizer/block_pass.c
3bc8a95 19-Sep-2014 Dmitry Stogov <dmitry@zend.com> Fixed useless or duplicated IS_INTERNED() checks
/php-src/ext/opcache/Optimizer/block_pass.c
82096dc 10-Sep-2014 Dmitry Stogov <dmitry@zend.com> Removed ZEND_QM_ASSIGN_VAR and ZEND_JMP_SET_VAR opcodes (in PHPNG they did exacly the same as ZEND_QM_ASSIGN and ZEND_JMP_SET)
/php-src/ext/opcache/Optimizer/block_pass.c
234af84 28-Aug-2014 Dmitry Stogov <dmitry@zend.com> Refactored optimizer (compile different opimizer passes separately, instead of including *.c file)
/php-src/ext/opcache/Optimizer/block_pass.c
ee552b6 27-Aug-2014 Dmitry Stogov <dmitry@zend.com> Reorder fields for better nenory consumtion and data locality on 64-bit systems
/php-src/ext/opcache/Optimizer/block_pass.c
6f9f0bf 25-Aug-2014 Anatol Belski <ab@php.net> master renames phase 2
/php-src/ext/opcache/Optimizer/block_pass.c
c3e3c98 25-Aug-2014 Anatol Belski <ab@php.net> master renames phase 1
/php-src/ext/opcache/Optimizer/block_pass.c
63d3f0b 19-Aug-2014 Anatol Belski <ab@php.net> basic macro replacements, all at once
/php-src/ext/opcache/Optimizer/block_pass.c
101c055 15-Aug-2014 Xinchen Hui <laruence@php.net> Add copyright header
/php-src/ext/opcache/Optimizer/block_pass.c
e2522b4 15-Aug-2014 Xinchen Hui <laruence@php.net> Remove old version PHP supports
/php-src/ext/opcache/Optimizer/block_pass.c
b7715c7 30-Jun-2014 Dmitry Stogov <dmitry@zend.com> Refactored parameter passing mechanism.

In PHP-5.6 and below each argument passed to user function was copies on VM stack twice.
Now we always have ZEND_INIT_FCALL (or simular) opcode that pushes "call frame" on top of VM stack.
"Call frame" is actually the same zend_execute_data structure.
All the following ZEND_SEND instructions push arguments on top of the stack in a way that they directly comes into corresponding CV variables of the called frame. Extra arguments are copied at the end of stack frame (after all CV and TMP variables) on function enterance.

There are two minor incompatibilities:
1) It's not allowed to decalre functions redefining arguments e.g. "function foo($a,$a) {}".
2) func_get_arg() and func_get args() return the current value of argument and not the original value that was sent.
/php-src/ext/opcache/Optimizer/block_pass.c
87b6672 20-Jun-2014 Dmitry Stogov <dmitry@zend.com> Code cleanup
/php-src/ext/opcache/Optimizer/block_pass.c
a4f3819 18-Jun-2014 Dmitry Stogov <dmitry@zend.com> Use arena allocator for optimizer temporary data structures
/php-src/ext/opcache/Optimizer/block_pass.c
eb5c613 17-May-2014 Xinchen Hui <laruence@gmail.com> Fixed Zend Hash API usage (although it's in comments)
/php-src/ext/opcache/Optimizer/block_pass.c
feeebc2 17-May-2014 Dmitry Stogov <dmitry@zend.com> Fixed new hash API usage
/php-src/ext/opcache/Optimizer/block_pass.c
17d027e 30-Apr-2014 Dmitry Stogov <dmitry@zend.com> Split IS_BOOL into IS_FALSE and IS_TRUE
/php-src/ext/opcache/Optimizer/block_pass.c
afe66d8 21-Apr-2014 Dmitry Stogov <dmitry@zend.com> Cleanup
/php-src/ext/opcache/Optimizer/block_pass.c
3434d3f 17-Apr-2014 Dmitry Stogov <dmitry@zend.com> Optimize CASE(TRUE, X) into BOOL(X) (this pattern affects wordpress)
/php-src/ext/opcache/Optimizer/block_pass.c
c92dd8e 17-Apr-2014 Dmitry Stogov <dmitry@zend.com> Fixed ZEND_CAST related optimizations (now it returns IS_VAR instead of IS_TMP_VAR)
/php-src/ext/opcache/Optimizer/block_pass.c
76cc99f 03-Apr-2014 Dmitry Stogov <dmitry@zend.com> Refactored ZVAL flags usage to simplify various checks (e.g. Z_REFCOUNTED(), candidate for GC, etc)
/php-src/ext/opcache/Optimizer/block_pass.c
fd4d11e 31-Mar-2014 Dmitry Stogov <dmitry@zend.com> fixes
/php-src/ext/opcache/Optimizer/block_pass.c
7465be4 31-Mar-2014 Dmitry Stogov <dmitry@zend.com> Optimizer related fixes (incomplete)
/php-src/ext/opcache/Optimizer/block_pass.c
5324f22 28-Mar-2014 Dmitry Stogov <dmitry@zend.com> ext/opcache refactoring (incomplete)
/php-src/ext/opcache/Optimizer/block_pass.c
3458dac 13-Jan-2014 Dmitry Stogov <dmitry@zend.com> Merge branch 'PHP-5.6'

* PHP-5.6:
Fixed bug #66471 (Keep backward compatibility)
ca55024 13-Jan-2014 Dmitry Stogov <dmitry@zend.com> Fixed bug #66471 (Keep backward compatibility)
/php-src/ext/opcache/Optimizer/block_pass.c
aab2e8e 12-Jan-2014 Dmitry Stogov <dmitry@zend.com> Merge branch 'PHP-5.6'

* PHP-5.6:
Fixed bug #66474 (Optimizer bug in constant string to boolean conversion)
d09d64c 12-Jan-2014 Dmitry Stogov <dmitry@zend.com> Merge branch 'PHP-5.5' into PHP-5.6

* PHP-5.5:
Fixed bug #66474 (Optimizer bug in constant string to boolean conversion)

Conflicts:
NEWS
fcd7569 12-Jan-2014 Dmitry Stogov <dmitry@zend.com> Fixed bug #66474 (Optimizer bug in constant string to boolean conversion)
/php-src/ext/opcache/Optimizer/block_pass.c
b11b3d2 18-Dec-2013 Bob Weinand <bobwei9@hotmail.com> Fixed ZTS build. Needed to bump API version number.
/php-src/ext/opcache/Optimizer/block_pass.c
d14670c 18-Dec-2013 Kalle Sommer Nielsen <kalle@php.net> Eliminate another TSRMLS_FETCH() in i_zend_is_true()

# Affected extensions have all been updated, ext/opcache and ext/zip
# both have macros for cross version compatibility
/php-src/ext/opcache/Optimizer/block_pass.c
e713259 26-Nov-2013 Dmitry Stogov <dmitry@zend.com> Merge branch 'PHP-5.5' into PHP-5.6

* PHP-5.5:
Fixed bug #66176 (Invalid constant substitution)
Fixed bug #66176 (Invalid constant substitution)
d79dd9c 26-Nov-2013 Dmitry Stogov <dmitry@zend.com> Fixed bug #66176 (Invalid constant substitution)
/php-src/ext/opcache/Optimizer/block_pass.c
27524b5 26-Nov-2013 Dmitry Stogov <dmitry@zend.com> Fixed bug #66176 (Invalid constant substitution)
/php-src/ext/opcache/Optimizer/block_pass.c
0999d85 26-Nov-2013 Dmitry Stogov <dmitry@zend.com> Merge branch 'PHP-5.5' into PHP-5.6

* PHP-5.5:
Fixed bug #66176 (Invalid constant substitution)

Conflicts:
NEWS
d85ac7f 26-Nov-2013 Dmitry Stogov <dmitry@zend.com> Fixed bug #66176 (Invalid constant substitution)
/php-src/ext/opcache/Optimizer/block_pass.c
0d7a638 26-Sep-2013 Nikita Popov <nikic@php.net> Implement variadic function syntax

As per RFC: https://wiki.php.net/rfc/variadics
/php-src/ext/opcache/Optimizer/block_pass.c
46f18cc 16-Sep-2013 Xinchen Hui <laruence@php.net> Fixed bug #65665 (Exception not properly caught when opcache enabled)
/php-src/ext/opcache/Optimizer/block_pass.c
1c67a99 26-Aug-2013 Dmitry Stogov <dmitry@zend.com> Fixed compilation warning
/php-src/ext/opcache/Optimizer/block_pass.c
cb17c99 30-Jul-2013 Dmitry Stogov <dmitry@zend.com> Improved implementation of NOP removal pass from O(n^2) to O(n) (hnw)
/php-src/ext/opcache/Optimizer/block_pass.c
4b83f4a 29-Apr-2013 Dmitry Stogov <dmitry@zend.com> Avoid possible conditional jump depended on uninitialised value
/php-src/ext/opcache/Optimizer/block_pass.c
e270396 10-Apr-2013 Dmitry Stogov <dmitry@zend.com> Fixed support for PHP-5.3
/php-src/ext/opcache/Optimizer/block_pass.c
7845f49 10-Apr-2013 Dmitry Stogov <dmitry@zend.com> Numeric string constants used as array indeces have to be converted to long at compile time
/php-src/ext/opcache/Optimizer/block_pass.c
2b28f29 09-Apr-2013 Dmitry Stogov <dmitry@zend.com> Fixed CFG construction bugs
/php-src/ext/opcache/Optimizer/block_pass.c
23b44e7 01-Apr-2013 Dmitry Stogov <dmitry@zend.com> Fixed ZTS build
/php-src/ext/opcache/Optimizer/block_pass.c
74f158f 01-Apr-2013 Dmitry Stogov <dmitry@zend.com> Fixed issue #79 (Optimization Problem/Bug)
/php-src/ext/opcache/Optimizer/block_pass.c
987dee9 24-Mar-2013 Dmitry Stogov <dmitry@zend.com> Fixed PHP-5.2 ZTS compatibility
/php-src/ext/opcache/Optimizer/block_pass.c
e00b04a 16-Mar-2013 Dmitry Stogov <dmitry@zend.com> Fixed memory leaks
/php-src/ext/opcache/Optimizer/block_pass.c
34d3202 15-Mar-2013 Dmitry Stogov <dmitry@zend.com> Merge Zend Optimizer+

git-subtree-dir: ext/opcache
git-subtree-mainline: b1dbfb73571b051fef055dc371e05163cf73eb8b
git-subtree-split: 8d35170c5fe9b9c0c864b7a6c4dc6b0149809569