1
0
mirror of https://github.com/php/php-src.git synced 2026-04-24 16:38:25 +02:00
Commit Graph

150 Commits

Author SHA1 Message Date
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 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 34e58a6447 Reduced overhead of magic method calls (__get/__set/__unset/__isset/__dectructor/__clone). 2018-06-22 14:29:54 +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 a795bd8265 Optimize zend_hash_real_init() 2018-03-23 00:13:45 +03:00
Dmitry Stogov 58880e3fc1 Get rid of IS_OBJ_USE_GUARDS and IS_OBJ_HAS_GUARDS flags 2018-02-27 17:38:56 +03:00
Dmitry Stogov b3e22da745 Use OBJ_FLAGS() macro to access object flags (even if they are currently stored together with GC_FLAGS) 2018-01-22 15:57:00 +03:00
Dmitry Stogov 6634d5e313 Use HT_FLAGS() macro 2018-01-22 14:58:16 +03:00
Xinchen Hui a6519d0514 year++ 2018-01-02 12:57:58 +08:00
Dmitry Stogov 175e461369 Use fastcall calling convention for objects and resources API 2017-12-14 13:50:39 +03:00
Dmitry Stogov 49ea143bbd Encapsulate reference-counting primitives.
Prohibit direct update of GC_REFCOUNT(), GC_SET_REFCOUNT(), GC_ADDREF() and GC_DELREF() shoukf be instead.
Added mactros to validate reference-counting (disabled for now).
These macros are going to be used to eliminate race-condintions during reference-counting on data shared between threads.
2017-10-27 01:28:58 +03:00
Dmitry Stogov 44e0b79ac6 Refactored array creation API. array_init() and array_init_size() are converted into macros calling zend_new_array(). They are not functions anymore and don't return any values. 2017-09-20 02:25:56 +03:00
Anatol Belski bc5811f361 further sync for vim mode lines 2017-07-04 18:12:45 +02:00
Dmitry Stogov 908ce66f73 Cleanup. Removed unused functions and unimplemented prototype. Avoid useless "dtor_obj" calls. 2017-06-27 12:03:06 +03:00
Xinchen Hui 705bd6df78 Unused var 2017-05-08 10:56:21 +08:00
Nikita Popov 3abef9c960 Don't double initialize object properties 2017-05-04 20:57:21 +02:00
Sammy Kaye Powers 9e29f841ce Update copyright headers to 2017 2017-01-02 09:30:12 -06:00
Dmitry Stogov d6c332eb51 Turn IS_TYPE_COLLECTABLE zval flag into GC_COLLECTABLE zend_refcounted flag.
This simplifies checks and allows reset this flag for "acyclic" arrays and objects.
2016-10-21 17:47:30 +03:00
Xinchen Hui ae3be78ce8 EG(fake_scope) was always set to NULL wrongly 2016-06-12 15:32:04 +08:00
Dmitry Stogov e9c3f9fcde Fixed bug #72177 (Scope issue in __destruct after ReflectionProperty::setValue()) 2016-05-13 11:55:09 +03:00
Dmitry Stogov 6499162ff0 - get rid of EG(scope). zend_get_executed_scope() should be used instead.
- ichanged zval_update_constant_ex(). Use IS_TYPE_IMMUTABLE flag on shared constants and AST, instead of "inline_change" parameter.
2016-04-28 04:13:34 +03:00
Dmitry Stogov e88c71d356 Optimize property guards for the most usual case with only one acive guard. 2016-04-27 00:24:20 +03:00
Dmitry Stogov a186ac0e47 IS_CONST operands don't have to be separated. Use reference-counting instead of duplication.
- with opcache all IS_CONST operands are not refcounted (scalars, interned strings or immutable arrays)
- without opcache IS_CONST operands are not shared between processes or threads and may use common reference counters
2016-04-05 20:09:14 +03:00
Xinchen Hui 97a9470d97 bump year which is missed in rev 49493a2 2016-01-02 17:56:11 +08:00
Dmitry Stogov 37f0c6b5cb Add myself into list of authors of the most refactored files. 2015-08-31 11:38:16 +03:00
Dmitry Stogov 25f9e25526 Fixed bug #70187 (Notice: unserialize(): Unexpected end of serialized data) 2015-08-26 03:27:05 +03:00
Aaron Piotrowski 5df893ce3c Use NULL where possible for exception class
Matches usage of zend_throw_exception()/zend_throw_exception_ex().
2015-07-07 12:10:55 -05:00
Aaron Piotrowski 22c38b2ef5 Remove need to pass error level 2015-07-03 17:53:41 -05:00
Aaron Piotrowski 5a99c07ecc Enable throwing custom exceptions from errors 2015-07-03 17:53:40 -05:00
Xinchen Hui 72b0627315 Fixed bug #69521 (Segfault in gc_collect_cycles()). 2015-07-02 18:43:06 +08:00
Dmitry Stogov 7aa7627172 Use ZSTR_ API to access zend_string elements (this is just renaming without semantick changes). 2015-06-30 13:59:27 +03:00
Xinchen Hui 4cc0096e00 Fixed memroy errors with valgrind 2015-06-29 15:36:02 +08:00
Dmitry Stogov 4a6e1345e2 Use COW to prevent unnecessary duplication of dynamic propertyes of stdClass (and other classes without predefined properties). 2015-06-17 12:50:16 +03:00
Dmitry Stogov eebab8282b Improved hash table copying 2015-05-19 13:23:13 +03:00
Dmitry Stogov 388c2cbdbc Micro optimizations 2015-04-28 19:11:45 +03:00
Dmitry Stogov 1800bed104 Micro optimizations 2015-04-27 18:30:33 +03:00
Dmitry Stogov ad863c1740 Convert fatal errors into EngineException 2015-04-02 14:19:52 +03:00
Dmitry Stogov ec760d8fff Convert fatal errors into EngineExceptions 2015-04-01 20:01:57 +03:00
Dmitry Stogov acfc31c0f8 Use zend_error_noreturn() for fatal errors 2015-04-01 13:32:23 +03:00
Dmitry Stogov e97ae4fee8 Make zend_array_destroy() to free the corresponding zend_array 2015-02-24 18:34:37 +03:00
Dmitry Stogov 9e70d7672d Move zend_object->guards into additional slot of zend_object->properties_table[]. As result size of objects without __get/__set/__unset/__isset magic methods is reduced. 2015-02-04 15:24:13 +03:00
Xinchen Hui fc33f52d8c bump year 2015-01-15 23:27:30 +08:00
Anatol Belski f62ad3bc57 Merge remote-tracking branch 'origin/master' into native-tls
* origin/master:
  made the apache ini holders to be zend_bool
  Removed useless local variable
  Use simpler functions
  Fixed test
  small fixes to UPGRADING
  Reorder to save alignment size (of course, only for common used structs)
2014-12-15 13:57:43 +01:00
Dmitry Stogov dd01ade999 Use simpler functions 2014-12-15 14:43:16 +03:00
Anatol Belski bdeb220f48 first shot remove TSRMLS_* things 2014-12-13 23:06:14 +01:00
Dmitry Stogov ab7b38e336 Added new optimized zend_array_destroy() function 2014-11-25 12:58:29 +03:00
Dmitry Stogov 99818a576f Use inline version of the function in the loop 2014-11-24 17:20:49 +03:00
Nikita Popov 4b892439e6 Fix bug #68262: Broken reference across cloned objects 2014-10-19 13:22:44 +02:00
Dmitry Stogov 5c897aa7da Preallocate hash tables of required size 2014-09-03 18:21:36 +04:00
Anatol Belski c3e3c98ec6 master renames phase 1 2014-08-25 19:24:55 +02:00