Dmitry Stogov
a111dfae0b
Removed dead condition
2018-12-25 19:23:40 +03:00
Dmitry Stogov
2954a309de
Avoid code duplication
2018-12-25 17:48:29 +03:00
Dmitry Stogov
868c1b7377
Reduce executor size
2018-12-18 17:34:18 +03:00
Dmitry Stogov
1f3a535324
Delay exceptional case check
2018-11-20 13:06:23 +03:00
Dmitry Stogov
a5a3d507d2
Optimization
2018-11-20 11:55:16 +03:00
Levi Morrison
74d15b535a
Remove do_bind_inherited_class; use do_bind_class
...
Pass NULL as the second parameter. I don't know if in the past these
differed more, but there isn't any point to having both of them
anymore.
2018-11-07 18:54:00 +01:00
Zeev Suraski
9afce019e0
Future-proof email addresses
2018-11-01 18:35:32 +02:00
Zeev Suraski
54dc07f3dc
Update email addresses. We're still @Zend, but future proofing it...
2018-11-01 17:20:07 +02:00
Dmitry Stogov
e3688c2180
Refetetch function name on exceptional path to allow better code on fast code path.
2018-10-23 17:12:49 +03:00
Nikita Popov
149e6aaa99
Fix accessibility checks for dynamic properties
...
A dynamic property may be shadowed by a private/protected property.
Make sure we check property accessibility for non-indirect
properties as well.
Closes #3626 .
2018-10-22 16:46:33 +02:00
Dmitry Stogov
d57cd36e47
Immutable clases and op_arrays.
...
Squashed commit of the following:
commit cd0c36c3f9
Merge: 4740dabb84
ad6738e886
Author: Dmitry Stogov <dmitry@zend.com>
Date: Wed Oct 17 14:43:38 2018 +0300
Merge branch 'master' into immutable
* master:
Remove the "auto" encoding
Fixed bug #77025
Add vtbls for EUC-TW encoding
commit 4740dabb84
Author: Dmitry Stogov <dmitry@zend.com>
Date: Wed Oct 17 14:12:28 2018 +0300
Reverted back ce->iterator_funcs_ptr. Initialize ce->iterator_funcs_ptr fields in immutable classes.
commit ad7a78b253
Author: Dmitry Stogov <dmitry@zend.com>
Date: Wed Oct 17 11:46:30 2018 +0300
Added comment
commit 0276ea5187
Author: Dmitry Stogov <dmitry@zend.com>
Date: Wed Oct 17 11:42:43 2018 +0300
Added type cast
commit c63fc5d5f1
Author: Dmitry Stogov <dmitry@zend.com>
Date: Wed Oct 17 11:36:51 2018 +0300
Moved static class members initialization into the proper place.
commit b945548e93
Author: Dmitry Stogov <dmitry@zend.com>
Date: Wed Oct 17 11:21:03 2018 +0300
Removed redundand assertion
commit d5a4108840
Author: Dmitry Stogov <dmitry@zend.com>
Date: Wed Oct 17 11:19:13 2018 +0300
Removed duplicate code
commit 8dadca8864
Author: Dmitry Stogov <dmitry@zend.com>
Date: Wed Oct 17 11:05:43 2018 +0300
Hide offset encoding magic in ZEND_MAP_PTR_IS_OFFSET(), ZEND_MAP_PTR_OFFSET2PTR() and ZEND_MAP_PTR_PTR2OFFSET() macros.
commit 9ef07c88bd
Author: Dmitry Stogov <dmitry@zend.com>
Date: Wed Oct 17 10:48:29 2018 +0300
typo
commit a06f0f3d3a
Merge: 94099586ec
3412345ffe
Author: Dmitry Stogov <dmitry@zend.com>
Date: Wed Oct 17 10:47:07 2018 +0300
Merge branch 'master' into immutable
* master:
Remove unused variable makefile_am_files
Classify object handlers are required/optional
Add support for getting SKIP_TAGSTART and SKIP_WHITE options
Remove some obsolete config_vars.mk occurrences
Remove bsd_converted from .gitignore
Remove configuration parser and scanners ignores
Remove obsolete buildconf.stamp from .gitignore
[ci skip] Add magicdata.patch exception to .gitignore
Remove outdated ext/spl/examples items from .gitignore
Remove unused test.inc in ext/iconv/tests
commit 94099586ec
Author: Dmitry Stogov <dmitry@zend.com>
Date: Mon Oct 15 23:34:01 2018 +0300
Immutable clases and op_arrays
2018-10-17 15:52:50 +03:00
Nikita Popov
1cfbb21790
Classify object handlers are required/optional
2018-10-16 20:53:59 +02:00
Peter Kokot
902d39a3a7
Trim trailing whitespace in source code files
2018-10-13 14:14:50 +02:00
Nikita Popov
7ec8087f80
Introduce get_properties_for() handler
...
This handler allows getting the object properties for a particular
purpose, such as array casting, serialization, etc.
2018-10-10 10:39:10 +02:00
Dmitry Stogov
6beaa9fa5b
Use zend_hash_find() instead of zend_hash_exists()
2018-09-19 13:55:27 +03:00
Dmitry Stogov
689c6fb188
Replace ZEND_ACC_ANON_BOUND, ZEND_ACC_UNRESOLVED_PARENT and ZEND_ACC_UNRESOLVED_INTERFACES with single ZEND_ACC_LINKED.
2018-09-18 11:41:40 +03:00
Dmitry Stogov
bc288c4723
Simplify __clone() visibility check (magic methods still don't respect ZEND_ACC_CHANGED).
2018-09-13 13:36:09 +03:00
Dmitry Stogov
2fbfdde1b6
Cleanup class linking
2018-08-27 16:40:25 +03:00
Dmitry Stogov
6136a20544
ZEND_DECLARE_CLASS, ZEND_DECLARE_INHERITED_CLASS and ZEND_DECLARE_INHERITED_CLASS_DELAYED don't need return value anymore.
2018-08-24 15:40:53 +03:00
Dmitry Stogov
d140df58e6
Keep information about unresolved interfaces in zend_class_entry->interface_names.
...
Move interface implementation code into ZEND_DECLARE_*CLASS opcodes.
Remove ZEND_ADD_INTERFACE and ZEND_VERIFY_ABSTRACT_CLASS opcodes.
2018-08-23 17:16:28 +03:00
Dmitry Stogov
67397970b2
Replace zend_class_entry->traits by persistent zend_class_entry->trait_names.
...
Move trait binding code into ZEND_DECLARE_*CLASS opcodes.
Remove ZEND_ADD_TRIAIT and ZEND_BIND_TRAITS opcodes.
2018-08-23 02:02:26 +03:00
Dmitry Stogov
92fdf9d629
Change zend_lookup_class_ex() and zend_fetch_class_by_name() prototypes to accept optional lower-case class name as zend_string*, instead of zval*.
2018-08-22 17:07:31 +03:00
Dmitry Stogov
1321aa5080
Merge branch 'PHP-7.3'
...
* PHP-7.3:
Stop using zend_function->reserved[] space.
2018-08-22 10:44:34 +03:00
Dmitry Stogov
8d95f561e4
Stop using zend_function->reserved[] space.
2018-08-22 10:43:51 +03:00
Dmitry Stogov
6d88e1ccd6
Don't use second operand of BIND_STATIC instruction.
2018-08-21 12:22:04 +03:00
Dmitry Stogov
7a52864ad0
Merge branch 'PHP-7.3'
...
* PHP-7.3:
Removed dead code
2018-08-21 09:02:22 +03:00
Dmitry Stogov
5e5311e0ba
Removed dead code
2018-08-21 09:01:54 +03:00
Dmitry Stogov
64f8b0185f
Merge branch 'PHP-7.3'
...
* PHP-7.3:
Avoid hash lookups in BIND_STATIC and BIND_LEXICAL opcode handlers. Encode static variable offset into opline->extended_value.
2018-08-20 16:11:40 +03:00
Dmitry Stogov
b8828926f2
Avoid hash lookups in BIND_STATIC and BIND_LEXICAL opcode handlers.
...
Encode static variable offset into opline->extended_value.
2018-08-20 16:10:09 +03:00
Xinchen Hui
4ab25235e5
Added a note
2018-08-17 12:22:46 +08:00
Xinchen Hui
fd463a9a60
Fixed bug #76752 (Crash in ZEND_COALESCE_SPEC_TMP_HANDLER - assertion in _get_zval_ptr_tmp failed).
2018-08-17 12:19:31 +08:00
Dmitry Stogov
3ced766da9
Removed duplicate code. zend_fetch_dimension_address_LIST_w() was a copy of zend_fetch_dimension_address_W(), ZEND_FETCH_LIST_W_SPEC_CV_... a copy of ZEND_FETCH_DIM_W_SPEC_CV_...
2018-07-30 10:53:39 +03:00
Dmitry Stogov
a588b825d6
Improved assignment to "next" element of array ($a[] = ...)
2018-07-27 13:15:22 +03:00
Dmitry Stogov
f374e93762
Use better check
2018-07-26 14:13:33 +03:00
Dmitry Stogov
ab8094c666
Pack zend_constant.flags and zend_constant.module_number into reserved space inside zend_constant.value.
2018-07-26 12:58:07 +03:00
Dmitry Stogov
f950128cd6
Encode parent class name as IS_CONST operand in DECLARE_INHERITED_CLASS and DECLARE_ANON_INHERITED_CLASS opcodes (eliminate FETCH_CLAS
...
S opcode).
2018-07-25 13:40:47 +03:00
Peter Kokot
8d3f8ca12a
Remove unused Git attributes ident
...
The $Id$ keywords were used in Subversion where they can be substituted
with filename, last revision number change, last changed date, and last
user who changed it.
In Git this functionality is different and can be done with Git attribute
ident. These need to be defined manually for each file in the
.gitattributes file and are afterwards replaced with 40-character
hexadecimal blob object name which is based only on the particular file
contents.
This patch simplifies handling of $Id$ keywords by removing them since
they are not used anymore.
2018-07-25 00:53:25 +02:00
Dmitry Stogov
afc82e243c
Micro-optimization
2018-07-23 10:52:00 +03:00
Dmitry Stogov
df60566671
Inline FETCH_CONST and DEFINED handlers into "hybrid" executor.
2018-07-17 13:30:55 +03:00
Dmitry Stogov
88dd38ee81
Reduce overhead of case-insensitive constants deprecation for "fast path"
2018-07-17 12:58:58 +03:00
Nikita Popov
3588d8af12
Deprecate case-insensitive constants
...
RFC: https://wiki.php.net/rfc/case_insensitive_constant_deprecation
2018-07-16 19:16:55 +02:00
Dmitry Stogov
40551e0255
Eliminated reference-counting and EG(exception) check
2018-07-09 13:20:46 +03:00
Dmitry Stogov
67b4c3379a
Uze ZVAL_COPY_DEREF() instead of ZVAL_DEREF() and ZVAL_COPY()
2018-07-09 12:46:46 +03:00
Xinchen Hui
9d1e9b73c5
rename ref_dtor_func to rc_dtor_func
2018-07-06 19:15:26 +08:00
Xinchen Hui
f9297387f4
Rename zval_dtor_func and ref_dotr_func
2018-07-06 18:47:30 +08:00
Xinchen Hui
e3355ac5ec
Revert "Rename _zval_dtor_func to _ref_dtor_func"
...
This reverts commit a362ae6b12
.
2018-07-06 18:37:45 +08:00
Xinchen Hui
a362ae6b12
Rename _zval_dtor_func to _ref_dtor_func
2018-07-06 18:32:27 +08:00
Dmitry Stogov
dcf7592076
Optimize array to object casting
2018-07-06 03:10:05 +03:00
Dmitry Stogov
85b2bc38e1
Optimize object to array casting
2018-07-06 01:25:24 +03:00
Dmitry Stogov
3a8f26060c
Argument unpacking with Traversables and non-integer keys.
...
Changed error message, added UPGRADING note and test.
2018-07-04 22:34:36 +03:00
Dmitry Stogov
af341213f7
se zval_ptr_dtor_str() instead of zend_string_release_ex(Z_STR(*), 0)
2018-07-04 12:08:07 +03:00
Dmitry Stogov
d84ef96742
SEND_UNPACK should throw exception on Traversable with non-integer keys
2018-07-04 09:35:12 +03:00
Dmitry Stogov
7eb045d31a
API cleanup. Removed unused functions (kept compatibility macros).
2018-07-04 00:50:57 +03:00
Dmitry Stogov
004a0568f4
Eliminated REFCOUNTED checks on persistent constant operands in SEND_VAL[_EX] and QM_ASSIGN.
2018-07-03 13:10:22 +03:00
Dmitry Stogov
177c7e3a72
Merge branch 'bug63217'
...
* bug63217:
Another fix for bug #63217
Partial revert of 30156d588c
2018-07-03 12:58:50 +03:00
Dmitry Stogov
3fd97a5b1f
Better hot/cold code splitting
2018-07-03 11:07:39 +03:00
Dmitry Stogov
28b03f9605
Another fix for bug #63217
2018-07-03 01:09:58 +03:00
Dmitry Stogov
57af94c8b9
Partial revert of 30156d588c
2018-07-02 20:54:44 +03:00
Rudi Theunissen
30156d588c
Fixed bug #63217
...
Don't automatically convert literal string keys to integers on
array access, as we may be dealing with an ArrayAccess object,
rather than a plain array.
2018-07-02 16:41:59 +02:00
Dmitry Stogov
d6ab163be8
cleanup
2018-06-29 12:35:14 +03:00
Dmitry Stogov
56450c6e65
Moved very rare exception check into a single place.
2018-06-27 13:34:15 +03:00
Xinchen Hui
3d8c82c353
Merge branch 'PHP-7.2'
...
* PHP-7.2:
Update NEWS
Fixed bug #76534 (PHP hangs on 'illegal string offset on string references with an error handler)
Conflicts:
Zend/zend_vm_execute.h
2018-06-27 13:08:47 +08:00
Xinchen Hui
3521661bd1
Merge branch 'PHP-7.1' into PHP-7.2
...
* PHP-7.1:
Fixed bug #76534 (PHP hangs on 'illegal string offset on string references with an error handler)
Conflicts:
Zend/zend_execute.c
Zend/zend_vm_def.h
Zend/zend_vm_execute.h
2018-06-27 13:07:36 +08:00
Xinchen Hui
d1b1866a3a
Fixed bug #76534 (PHP hangs on 'illegal string offset on string references with an error handler)
2018-06-27 13:05:11 +08:00
Dmitry Stogov
7f67513ca3
Lazy function copying from op_cache SHM into process memory
2018-06-25 19:53:58 +03:00
Nikita Popov
61d00a6cf3
Use COPY_DEREF instead of COPY_UNREF
...
This fixes the behavior when the storage location of the fetch is
modified before the operand is dereferenced by the using VM opcode.
Furthermore it elimiates references as a possible return value from
*_R opcodes, which will give us more opportunities for inferences,
in particular in regard to typed properties.
2018-06-25 11:23:59 +02:00
Dmitry Stogov
4418d61ca3
Avoid reusing zend_function.common.prototype for magic things (use reserved fields instead).
2018-06-21 13:09:25 +03:00
Nikita Popov
0b04938c87
Fix unspecialized executor
...
If we conditionally fetch a value, we also need to conditionally
free it.
2018-06-14 23:26:27 +02:00
Nikita Popov
95a0709935
Fix handling of ERROR zval in op1 of ASSIGN_REF
...
If op1 is ERROR the behavior is to not perform any assignment and
return NULL. However, if the RHS was a by-value returning function,
we'd instead emit a notice and return the RHS as the return value
(even though the value was not assigned to anything -- the temporary
is immediately destroyed).
This normalized the behavior to always check for an ERROR in op1
first.
2018-06-09 21:31:30 +02:00
Nikita Popov
d877d18676
Error on by-ref assign to overloaded prop returning ref
...
This error was already thrown if __get() was used -- however not
if it returned by reference. This is incorrect, because the
reference return makes no difference to a by-reference assignment,
which has reference-breaking semantics. The result was that the
assignment was accepted silently, even though it didn't do anything
(not even the value was assigned, let alone the reference).
2018-06-09 18:42:22 +02:00
Dmitry Stogov
1597b56619
Inline few small opcode handlers into hybrid executor
2018-06-07 16:30:53 +03:00
Dmitry Stogov
59c2ff2543
Embed zend_leave_helper() into hybrid executor to avoid call overhead.
2018-06-05 11:33:19 +03:00
Dmitry Stogov
b6a2ae3a5b
Cleanup
2018-06-05 11:26:15 +03:00
Dmitry Stogov
9e0f131d2b
Fixed ISSET/ISEMPTY bit meaning to simplify run-time checks
2018-05-31 19:02:51 +03:00
Dmitry Stogov
84aab1d4e1
Marked rarely used opcodes as "cold" (e.g. ADD_CONST_CONST ususaly optimized out).
2018-05-30 01:50:44 +03:00
Dmitry Stogov
da5a44c1c0
Revert "Avoid reference-counting"
...
This reverts commit ea26ab3393
.
2018-05-29 18:04:16 +03:00
Anatol Belski
6f4a01da21
Fix build without global registers
2018-05-28 20:44:58 +02:00
Dmitry Stogov
c27dda709c
Removed dead code
2018-05-28 18:29:43 +03:00
Dmitry Stogov
c9df8ac6c5
Separate common code into helper function
2018-05-28 18:11:43 +03:00
Dmitry Stogov
ea26ab3393
Avoid reference-counting
2018-05-28 17:10:58 +03:00
Dmitry Stogov
5eb1f92f31
Use zend_string_release_ex() instread of zend_string_release() in places, where we sure about string persistence.
2018-05-28 16:27:12 +03:00
Dmitry Stogov
1a63fa6ec9
Implemented Request #76178 (Class constants are slow: they should be inlined at runtime)
...
Run-time cache is used to eliminate recalculation of constant expression in RECV_INIT opcode (only non reference countable values are cached).
2018-05-03 14:40:18 +03:00
Dmitry Stogov
c88be6aee1
Bit check micro-optimization
2018-04-28 14:13:12 +03:00
Dmitry Stogov
d4aba32d8c
Cache negative defined() results
2018-03-30 16:41:02 +03:00
Dmitry Stogov
4aa9505b6e
Merge identical handlers
2018-03-29 11:13:17 +03:00
Dmitry Stogov
91ba1f2085
Remove "hot" mark from JMP(Z|NZ|ZNZ) with IS_CONST operand
2018-03-23 16:11:27 +03:00
Dmitry Stogov
295b233bfd
Mark few more opcode handlers as "hot".
2018-03-23 13:59:47 +03:00
Dmitry Stogov
a795bd8265
Optimize zend_hash_real_init()
2018-03-23 00:13:45 +03:00
Dmitry Stogov
e791e93b55
Make ZEND_ISSET_ISEMPTY_CV specialised across ISSET/ISEMPTY and HOT (the handler is really small, so inlining affects executor size insignificantly)
2018-03-22 13:03:45 +03:00
Dmitry Stogov
d7f2dc4ec6
Improve HashTable iterators handling:
...
- Avoid iterators check/update on each HashTable update opration
- Keep position equal (or above) nNumUsed instead of HT_INVALID_IDX
- Fixed iterators handling in array_unshift()
2018-03-22 02:41:49 +03:00
Dmitry Stogov
a2d1f2df46
Eliminate conditional branches
2018-03-07 00:03:13 +03:00
Dmitry Stogov
bd908f6145
Fixed build without global register variables
2018-02-22 11:00:29 +03:00
Dmitry Stogov
927748b271
Reorganize make_real_object() related code
2018-02-21 18:43:38 +03:00
Dmitry Stogov
ecb52b8b3b
Move exceprional code into helper & zend_fetch_var_address_helper() micro-optimization.
2018-02-21 17:09:42 +03:00
Dmitry Stogov
7559b1c50c
Move result address calculation from specialized handlers to less specialized helpers
2018-02-21 16:06:29 +03:00
Dmitry Stogov
9c0427cada
Mark exceptional helpers as "cold"
2018-02-21 12:07:29 +03:00
Dmitry Stogov
e1b1cff48d
Move exceptional code into helpers
2018-02-21 10:10:04 +03:00
Dmitry Stogov
41eb70a493
Added expectation
2018-02-21 02:49:40 +03:00
Dmitry Stogov
b53f5cc92d
Move exceptional code into helpers
2018-02-21 01:27:39 +03:00
Dmitry Stogov
a00286921e
Move cold code, duplicated by specializer, into helper functions
2018-02-20 23:44:25 +03:00
Dmitry Stogov
b46f10b43f
Fixed build without global register variables
2018-02-20 20:39:02 +03:00
Dmitry Stogov
8b7cdbaa49
Separate slow path with make_real_object() and related code into "cold" function.
2018-02-20 17:22:11 +03:00
Dmitry Stogov
cbf2d91911
Separate cold paths of ISSET_ISEMPTY_DIM_OBJ
2018-02-20 14:42:53 +03:00
Nikita Popov
b0af9ac733
Avoid live range references in opcodes
...
Don't store the live range of the freed variable for FREE_ON_RETURN
frees, instead look it up at runtime. As this is an extremely
unlikely codepath (in particular, it requires a loop variable with
a throwing destructor), saving the runtime lookup of the live range
is not worth the extra complexity this adds everywhere else.
2018-02-16 21:30:48 +01:00
Nikita Popov
f61c01eeb1
Fix unused variable warning
2018-02-16 15:31:54 +01:00
Dmitry Stogov
b4112ea288
Don't make expectations about non-constant zval refcauntability
2018-02-16 15:37:04 +03:00
Dmitry Stogov
6fadb72c0b
Move exceptional code into "cold" helpers
2018-02-16 02:45:31 +03:00
Dmitry Stogov
02aea893fb
Use Z_TYPE_INFO_REFCOUNTED() macro
2018-02-15 21:54:49 +03:00
Dmitry Stogov
27d7671603
Avoid generation of rarely used specialized handler
2018-02-15 14:50:42 +03:00
Dmitry Stogov
23da83c8ca
Avoid inlining of rarely used handlers
2018-02-15 13:48:04 +03:00
Nikita Popov
db2475cec2
Fix unused variable compiler warnings
2018-02-05 20:58:15 +01:00
Nikita Popov
ef20d2990f
Remove unnecessary CE_STATIC_MEMBERS() checks
...
CE_STATIC_MEMBERS(ce) is destroyed after EG(active)=0 is set, so we
should never run into a situation where it is NULL inside the VM.
2018-02-05 18:54:17 +01:00
Dmitry Stogov
752d684971
Removed "dead" code
2018-02-05 20:43:08 +03:00
Dmitry Stogov
ca035f26aa
Moved "zval.u2.cache_slot" into free room of "zend_op"
2018-02-05 19:41:47 +03:00
Dmitry Stogov
3a794d39f0
Avoid repeatable ARG_SHOULD_BE_SENT_BY_REF() checks in FETCH_*FUNC_ARG and following SEND_VAR_EX. Perform the check once in a new CHECK_FUNC_ARG opcode and reuse in the following FETCH_*FUNC_ARG and SEND_FUNC_ARG (SEND_VAR_EX replacement).
2018-02-05 19:40:06 +03:00
Nikita Popov
e0171ed9d0
Avoid another unused opline warning
...
The unconditional opline load here used to be necessary for freeing
the return value in case of exception. However, this is no longer
the case, so using LOAD_OPLINE() should be sufficient now.
2018-02-03 17:43:41 +01:00
Nikita Popov
24e744d8a2
Avoid VM warning if building without global regs
2018-02-03 17:43:41 +01:00
Dmitry Stogov
ba298725d1
Changed CATCH instruction format (extended_value moved into op2, op2 into result, result into extended_value)
2018-01-31 22:39:30 +03:00
Dmitry Stogov
9c7fb529ce
Changed FETCH_CONSTANT instruction format (extended_value moved into op1)
2018-01-31 18:15:25 +03:00
Dmitry Stogov
f67f455ef7
Changed FETCH_CLASS instruction format (extended_value moved into op1)
2018-01-31 18:14:43 +03:00
Dmitry Stogov
59ede4c82b
Avoid redundand mask extraction
2018-01-31 13:47:43 +03:00
Dmitry Stogov
1d7eab12e6
Avoid redundand mask extraction
2018-01-31 13:34:34 +03:00
Dmitry Stogov
7141631cc8
Change FETCH/ISSET instruction modifiers:
...
- Get rid of ZEND_ISEMPTY and ZEND_ISSET_ISEMPTY_MASK. Use just single ZEND_ISSET bit to make distinct between isset() and empty()
- Use ZEND_FETCH_GLOBAL, ZEND_FETCH_LOCAL and ZEND_FETCH_GLOBAL_LOCK as bitmask
- Removed unused ZEND_FETCH_STANDARD
- Extended ZEND_FETCH_ARG_MASK
2018-01-30 22:06:05 +03:00
Dmitry Stogov
5e8aa036f2
Access extra data stored in zval through macros
2018-01-23 12:56:22 +03:00
Dmitry Stogov
a87a2f464b
Send by reference without duplication
2018-01-17 18:50:18 +03:00
Dmitry Stogov
dd51cb1e34
More effecient array duplication
2018-01-17 17:56:04 +03:00
Dmitry Stogov
0bfc4f34ca
Avoid EG(vm_interrupt) check on forward JMP
2018-01-16 13:50:36 +03:00
Dmitry Stogov
12c386f5b9
Use ZEND_CLOSURE_OBJECT() macro to resolve closure op_array to closure object through address calculation, instead of op_array->prototype reuse. (reapply 781e1573af
, now it should be OK).
2018-01-11 22:15:45 +03:00
Dmitry Stogov
6ba10a03e7
Revert "Use ZEND_CLOSURE_OBJECT() macro to resolve closure op_array to closure object through address calculation, instead of op_array->prototype reuse." (this patch is incomplete or wrong)
...
This reverts commit 781e1573af
.
2018-01-11 17:27:26 +03:00
Dmitry Stogov
781e1573af
Use ZEND_CLOSURE_OBJECT() macro to resolve closure op_array to closure object through address calculation, instead of op_array->prototype reuse.
2018-01-11 16:25:28 +03:00
Dmitry Stogov
f09c012ebe
Mark FETCH_OBJ_R and INIT_METHOD_CALL as HOT_OBJ for (UNUSED+CONST and CV+CONST)
2018-01-10 19:14:52 +03:00
Dmitry Stogov
94508cdc3f
Fixed whitespaces
2018-01-10 02:22:07 +03:00
Nikita Popov
d9c706f28d
Merge branch 'PHP-7.2'
2018-01-09 20:25:19 +01:00
Nikita Popov
2dd80a0782
Merge branch 'PHP-7.1' into PHP-7.2
2018-01-09 20:24:48 +01:00
Nikita Popov
fd30c59e04
Fixed bug #75786
...
SEND_UNPACK on iterators was duplicating references in-place,
which effectively leaks the original value and causes an off-by-one
refcount on the duplicated value.
Replace this with a deref, as an actual duplication is not even
needed in this case.
2018-01-09 20:20:31 +01:00
Gabriel Caruso
6687e8db15
Trailing whitespaces on Zend
...
Signed-off-by: Gabriel Caruso <carusogabriel34@gmail.com>
2018-01-04 02:41:57 -02:00
Xinchen Hui
a6519d0514
year++
2018-01-02 12:57:58 +08:00
Xinchen Hui
7a7ec01a49
year++
2018-01-02 12:55:14 +08:00
Xinchen Hui
ccd4716ec7
year++
2018-01-02 12:53:31 +08:00
Dmitry Stogov
5c8f8f8fce
Use ZEND_FAST_CONCAT instead of ZEND_CONCAT for CONST operands.
2017-12-29 13:54:18 +03:00
Dmitry Stogov
f010423335
Use IS_EQUAL instead of CASE when first operand is CV or CONST. Removed CASE handlers that duplicated IS_EQUAL.
2017-12-29 12:57:58 +03:00
Dmitry Stogov
27206f9cc5
Removed useless specialization
2017-12-29 12:02:50 +03:00
Dmitry Stogov
6e4d18924b
Combine READY_TO_DESTROY, EXTRACT_ZVAL_PTR and FREE_OP_VAR_PTR into single, better optimized, macro.
2017-12-26 16:50:34 +03:00
Dmitry Stogov
6e23e84332
Use zval constructors instead ZVAL_COPY if we know the types
2017-12-26 16:49:34 +03:00
Dmitry Stogov
efcbea4345
Cheaper reference construction
2017-12-26 13:30:25 +03:00
Dmitry Stogov
35b3fdfd0a
Separate exceptional code into cold functions.
2017-12-22 16:35:52 +03:00
Dmitry Stogov
66a604171c
Array addition is not commutative
2017-12-15 14:40:19 +03:00
Dmitry Stogov
588f1df7a2
Remove duplicate handlers for commutative operations
2017-12-15 13:42:54 +03:00
David Walker
6d4de4cf05
Implement list() reference assignments
...
Support list() reference assignments of the form:
list(&$a, list(&$b, $c)) = $d;
RFC: https://wiki.php.net/rfc/list_reference_assignment
2017-12-09 13:39:52 +01:00
Dmitry Stogov
2d8f238318
Avoid duplication
2017-12-07 14:59:42 +03:00