Commit Graph

439 Commits

Author SHA1 Message Date
Peter Kokot
3748d8070f Implement #64517: Add AC_ARG_PROGRAM macro
The AC_ARG_PROGRAM Autoconf macro provides program name transformations
when installing. This patch implements #64517 and prepares the
implementation for the request #60518.

In ./configure --help it additionally outputs --program-prefix=PREFIX,
--program-suffix=SUFFIX and the upcoming --program-transform-name=PROGRAM
option.

Macro AC_ARG_PROGRAM is available since Autoconf 2.0 and needs to be
called after the AC_CANONICAL_TARGET macro.

Refs:
- https://www.gnu.org/software/autoconf/manual/autoconf-2.69/html_node/Transforming-Names.html
2018-08-29 02:04:48 +02: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
Christoph M. Becker
c9861bd7a9 Create and expose php_sys_symlink() and php_sys_link()
These macros are supposed to behave like POSIX's symlink() and link(),
respectively, on POSIX compliant systems and on Windows.

Future scope: merge link.c and link_win32.c
2018-08-02 14:08:30 +02:00
Christoph M. Becker
bccf0dfba1 Prepare UPGRADING(.INTERNALS) for PHP 7.4
We also add this as task to README.RELEASE_PROCESS, so that it's not
overlooked next time.
2018-07-31 15:54:03 +02:00
Peter Kokot
7c1e0930c4 Remove TSRM_CHECK_GCC_ARG and LIBZEND_CPLUSPLUS_CHECKS
This removes two old Autoconf macro definitions since they are not used
anymore.
2018-07-31 05:59:05 +02:00
Peter Kokot
72551dd89e [ci skip] Document RETSIGTYPE 2018-07-29 21:32:35 +02:00
Peter Kokot
209f05a878 [ci skip] Note HAVE_ST_BLKSIZE and HAVE_ST_RDEV 2018-07-29 14:44:56 +02:00
Peter Kokot
d7ad4babe0 [ci skip] Note removal of PHP_PROG_LEX 2018-07-29 13:37:48 +02: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
57c4ae393c typo 2018-07-25 23:00:33 +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
Remi Collet
0c3561892b add info about zend_class_entry.iterator_funcs 2018-07-18 11:17:53 +02:00
Christoph M. Becker
0896a3abd1 [ci skip] Fix typos 2018-07-10 17:03:48 +02:00
Christoph M. Becker
091c0a8a59 [ci skip] Document changes to php_add[c]slashes 2018-07-10 16:04:14 +02:00
Tyson Andre
5bbe6080b4 [ci skip] Fix a typo. RANGE_RANGE should be RAND_RANGE 2018-07-05 12:11:56 +02:00
Christoph M. Becker
d798fd491b [ci skip] Document GC_C() → zend_gc_get_status() 2018-07-04 12:19:29 +02:00
Christoph M. Becker
2ff26bdf73 [ci skip] Document new typedef zif_handler 2018-06-28 12:52:36 +02:00
Markus Staab
a0a4232ae3 [ci skip] fixed typos 2018-06-25 13:14:55 +02:00
Dmitry Stogov
ecce21169e Added note about zend_function.reserved[] fields usage 2018-06-25 13:35:14 +03:00
Remi Collet
3b9ecb2d65 add note about php_url struct changes 2018-06-22 14:58:30 +02:00
Robert Lu
ecc1a7c582 Fix bug #44217: Output after stdout/stderr closed cause immediate exit with status 0
We exit with status 255 instead.
2018-06-19 12:15:33 +02:00
Anatol Belski
acda5e084e Document new configurue options 2018-03-08 12:14:48 +01:00
Xinchen Hui
cf0fae5e97 Optimized base64_encode/decode with SIMD instructions 2018-02-12 20:53:14 +08:00
Dmitry Stogov
1208acfe5f Added note about changed VM instructions 2018-02-02 17:35:23 +03:00
Dmitry Stogov
17a3b48454 Make IS_UNUSED to be zero. 2018-01-31 11:18:41 +03:00
Dmitry Stogov
742d5a01ed Get rid of IS_TYPE_COPYABLE. 2018-01-19 17:47:26 +03:00
Dmitry Stogov
1ee94f56c4 Removed IS_TYPE_COPYABLE flag from IS_STRING zvals. 2018-01-18 12:41:27 +03:00
Xinchen Hui
3a3e0493d0 Added ZEND_API zend_cpu_supports 2018-01-16 14:53:00 +08:00
Anatol Belski
83497327e7 Implement high resolution monotonic timer function hrtime() 2018-01-07 16:03:52 +01:00
Dmitry Stogov
d9f5ea691f zend_fcall_info_cache.initialized is removed (zend_fcall_info_cache is initialized if zend_fcall_info_cache.function_handler is set). 2017-12-27 15:15:03 +03:00
Nikita Popov
b2b2b437af Add _IS_NUMBER as cast_object() target type
convert_scalar_to_number() will now call cast_object() with an
_IS_NUMBER argument, in which case the cast handler should return
either an integer or floating point number, whichever is more
appropriate.

Previously convert_scalar_to_number() unconditionally converted
objects to integers instead.

Fixes bug #53033.
Fixes bug #54973.
Fixes bug #73108.
2017-12-26 12:39:06 +01:00
Tom Van Looy
e4e26f2428 Remove RAND_RANGE() macro
The behavior of RANGE_RANGE() is 7.1 changed completely, from
rescaling an already generated number to generating a number
itself. Because of this str_shuffle() ended up generating two
random numbers on every iteration.

To avoid further misuse the function is dropped entirely. Extensions
for PHP >= 7.1 should directly call php_mt_rand_range().
2017-12-09 17:24:17 +01:00
Anatol Belski
6c8b441f87 [ci skip] Update UPGRADING.INTERNALS 2017-11-06 14:20:04 +01:00
Anatol Belski
7d14dcc084 [ci skip] Fix UPGRADING.INTERNALS, seems it was not reset after 7.2
branch off
2017-11-06 14:12:02 +01:00
Dmitry Stogov
67d5f39a47 Persistent resources are "thread-local".
Register persistent resources through new functions zend_register_persistent_resource()/zend_register_persistent_resource_ex().
2017-11-01 15:19:31 +03:00
Nikita Popov
cb2884679c Remove zend_get_parameters(_ex) APIs
zend_get_parameters_ex() has been marked as deprecated for a long
time already. What zend_get_paramers() does is even more
questionable under PHP7. Both functions are obsoleted by the ZPP
mechanism, so I'm dropping them.
2017-10-30 22:00:42 +01:00
Dmitry Stogov
5d88ea5c75 Update UPGRADING.INTERNALS 2017-10-30 12:47:22 +03:00
Dmitry Stogov
ef5ea48741 Always use IS_CONSTANT_AST (IS_CONSTANT is removed). 2017-10-10 10:11:05 +03:00
Dmitry Stogov
39ded1d5f8 Changed zend_ast_ref structure to use only one allocation, removing dichotomy between heap/arena ASTs. 2017-10-09 16:57:51 +03:00
Dmitry Stogov
254b74b85f HASH_FLAG_PERSISTENT renamed into IS_ARRAY_PERSISTENT and moved into GC_FLAGS (to be consistent with IS_STR_PERSISTENT). 2017-10-06 02:54:14 +03:00
Dmitry Stogov
cb9d81ef4f Refactored recursion pretection 2017-10-06 01:34:50 +03:00
Dmitry Stogov
e70618aff6 Changed the way VM accesses constant operands in 64-bit builds. 2017-10-04 16:53:01 +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
Remi Collet
8d1ae4e1c5 valid_symbol_table removed 2017-07-05 06:33:34 +02:00
Remi Collet
b6ee9dd490 upgrading: doc about ZEND_BEGIN_ARG_WITH_RETURN_TYPE_INFO_EX 2017-06-26 17:26:07 +02:00
Remi Collet
4ed8ff5090 not about zend_arg_info.class_name 2017-06-25 08:41:11 +02:00
Remi Collet
b3b8627106 note about IS_TYPE_IMMUTABLE 2017-06-25 08:32:03 +02:00
Remi Collet
59c30c01b3 note about php_pcre_replace* 2017-06-25 08:27:52 +02:00
Remi Collet
754e1c463d ZEND_ACC_CLONE is removed 2017-06-25 08:23:30 +02:00
Remi Collet
8e98a44eb2 fix version 2017-06-25 08:22:29 +02:00
Anatol Belski
e9dd511ec6 [ci skip] more upgrading notes 2017-04-24 18:15:15 +02:00
Anatol Belski
0e1b2ae4f3 [ci skip] move item to right section 2017-04-24 18:15:14 +02:00
Anatol Belski
46df51132a fix typo 2017-02-15 16:15:16 +01:00
Anatol Belski
8164e024cd update UPGRADING.INTERNALS 2017-02-13 08:35:01 +01:00
Anatol Belski
758af77e9d Path handling related refactorings
Primarily related to the path handling datatypes, to avoid unnecessary
casts, where possible. Also some rework to avoid code dup. Probably
more places are to go, even not path related, primarily to have less
casts and unsigned integers where possible. That way, we've not only
less warnings and casts, but are also safer with regard to the
integer overflows. OFC it's not a panacea, but still significantly
reduces the vulnerability potential.
2016-12-22 14:56:47 +01:00
Anatol Belski
5e6faf2306 add UPGRADING and NEWS items 2016-12-21 16:10:38 +01:00
Yasuo Ohgaki
7f196e321f Fix bug #71038 - session_start() returns true even when it failed
PR #2167
2016-11-17 11:09:07 +09:00
Kalle Sommer Nielsen
64945e9387 Implemented proc_nice() for Windows (FR #49806)
The core implementation details are described in win32/nice.c for values sent to proc_nice(), these can however be discussed to maybe comply with those of wmic, Anatol, thoughts?

The test supplied uses wmic for testing the functionality, it could potentially fail on systems where either wmic is not available or the system language is not english (as Microsoft tends to translate even CLI programs).
2016-10-16 04:17:35 +02:00
Nikita Popov
0374a98e14 Scrub UPGRADING and UPGRADING.INTERNALS
There were already some master-only entries in there -- I hope I
didn't remove anything that was supposed to be there.

[skip ci]
2016-08-15 23:01:19 +02:00
Anatol Belski
6442aac72f move the internal only info into UPGRADING.INTERNALS 2016-07-11 11:22:00 +02:00
Anatol Belski
5e66b8f232 notes to UPGRADING.INTERNALS 2016-06-20 18:03:19 +02:00
Anatol Belski
0f71d006e8 make room for next UPGRADING notes 2015-09-17 13:19:30 +02:00
Christoph M. Becker
1b5e87a579 Fix #70289: Different sort in php7 (and hhvm) compared to php5
We add a respective note to UPGRADING. Furthermore, as renaming of zend_qsort()
and the new zend_insert_sort() are irrelevant for user-land, we move this
info to UPGRADING.INTERNALS.
2015-08-18 13:44:14 +02:00
Adam Harvey
d6db83816c We don't need CVS/SVN keywords in UPGRADING. 2015-08-13 12:40:46 -07:00
Anatol Belski
a7587135e3 more info for UPGRADING.INTERNALS 2015-08-02 17:49:06 +02:00
Anatol Belski
9249890acf fix wrong info 2015-07-29 19:30:36 +02:00
Anatol Belski
f6d196a38f document globals accesor macro and tls specifiers 2015-07-29 17:26:53 +02:00
Anatol Belski
02df0cb02b improve info about the applink 2015-07-03 12:45:59 +02:00
Anatol Belski
9d9f372df6 added openssl applink shim note to UPGRADING.INTERNALS 2015-07-03 12:40:54 +02:00
Anatol Belski
274edb4c6f add missing item in the content table 2015-07-03 12:40:53 +02:00
Anatol Belski
d0787534c0 add missing items to the table of contents 2015-07-02 16:34:42 +02:00
Anatol Belski
79ca2b06b6 update UPGRADING infos 2015-07-02 16:32:57 +02:00
Hannes Magnusson
ce01d7361e space 2015-06-23 19:29:10 -07:00
Anatol Belski
29a91e52ad a bit more clearness fir --with-mp 2015-06-02 15:56:30 +02:00
Andrew Murray
00790467b7 Fixed typos in UPGRADING.INTERNALS 2015-06-01 11:13:09 +10:00
Hannes Magnusson
8eea193470 Fix typos and add link to the phpng upgrading wiki page 2015-05-29 19:07:14 +00:00
Xinchen Hui
45c3112726 Add some missed entry 2015-04-11 09:48:09 +08:00
Anatol Belski
e1f706e3f4 fix typo 2015-03-24 22:02:26 +01:00
Anatol Belski
4dc69709e2 some more UPGRADING INTERNALS notes 2015-03-23 15:50:13 +01:00
Anatol Belski
429c8715b2 some UPGRADING.INTERNALS notes 2015-03-23 15:27:26 +01:00
Reeze Xia
ff2cccbfdd TSRMLS_* macros have been removed, user don't have to care about the change anymore 2015-02-06 11:46:38 +01:00
Xinchen Hui
118ed493e1 Update UPGRADING 2015-02-04 14:25:06 +08:00
Xinchen Hui
77b164edfd Update UPGRADING 2015-02-04 11:42:19 +08:00
Yasuo Ohgaki
6230493005 Update UPGRADING.INTERNALS Session section 2015-02-04 11:54:16 +09:00
Yasuo Ohgaki
f90f6108c8 Merge branch 'master' into master-rfc-session-lock4
Conflicts:
	UPGRADING
2015-01-29 09:55:36 +09:00
Stanislav Malyshev
dfe6aea9ca size_t cleanup for PDO 2015-01-26 16:16:02 -08:00
Yasuo Ohgaki
7b17980875 Update UPGRADING and UPGRADING.INTERNALS 2015-01-26 06:14:40 +09:00
Adam Harvey
eb6dc9db29 Make gc_collect_cycles hookable. 2015-01-23 19:23:58 +00:00
Anatol Belski
dec8eb431a noted the TSRM changes to UPGRADING.INTERNALS 2014-12-18 09:09:02 +01:00
Julien Pauli
0adfa03397 Merged PR #911. 2014-12-12 18:00:13 +01:00
Andrea Faulds
8efe343352 Note macro removal in UPGRADING.INTERNALS 2014-12-05 19:46:31 +00:00
Anatol Belski
583c3dc9e7 added info about some other macro changes 2014-11-20 14:23:15 +01:00
Anatol Belski
f030cd8bda added note about toolset and phpize 2014-11-20 14:23:14 +01:00
Anatol Belski
799057c6be added note about the response files 2014-11-20 14:23:13 +01:00
Anatol Belski
5eb65a71a7 update UPGRADING.INTERNALS 2014-11-10 14:25:14 +01:00
Nikita Popov
3efc331701 Add notes about get_class_entry/get_class_name to UPGRADING 2014-10-10 12:28:55 +02:00
Anatol Belski
bdc4f23517 updated UPGRADING.INTERNALS 2014-08-27 20:49:34 +02:00
Anatol Belski
316705c7ed add note about 'l' and zend_long 2014-08-27 09:26:25 +02:00
Ferenc Kovacs
a18714d8ed better heading for UPGRADING.INTERNALS 2014-08-26 00:35:40 +02:00
Anatol Belski
1cda5e196c updated UPGRADING.INTERNALS 2014-08-26 00:13:37 +02:00
Anatol Belski
b2d123f985 fix a phrase 2014-08-24 02:57:19 +02:00
Anatol Belski
3c17ce9e0f note on %pd format 2014-08-24 02:36:17 +02:00
Anatol Belski
4ff697b6b1 adedd note on portable numeric macros 2014-08-22 13:48:20 +02:00
Anatol Belski
4c56e68b7f note on LFS macros 2014-08-22 13:40:45 +02:00
Anatol Belski
24cf50d2df note on hash table and sprintf 2014-08-22 13:22:49 +02:00
Anatol Belski
c893552a9a note on zpp specs 2014-08-22 10:31:48 +02:00
Anatol Belski
612e459041 updated UPGRADING.INTERNALS with new data types 2014-08-22 10:24:51 +02:00
Kalle Sommer Nielsen
9e3551ba1f Eliminated the TSRMLS_FETCH() in zend_set_memory_limit() 2013-11-18 01:36:17 +01:00
Ferenc Kovacs
d17b684b91 bump version, empty NEWS, UPGRADING and UPGRADING.INTERNALS 2013-11-06 14:03:24 +01:00
Nikita Popov
0d7a638866 Implement variadic function syntax
As per RFC: https://wiki.php.net/rfc/variadics
2013-09-26 18:39:17 +02:00
Michael Wallner
4a3936ef4a NEWS/UPGRADING{,.INTERNALS} notes about temp POST stream 2013-09-17 11:08:23 +02:00
Nikita Popov
0856714576 Always pass return_value_ptr to internal functions
Previous some places passed return_value_ptr only if the function
returned by reference. Now return_value_ptr is always set, even
for functions returning by-value.

This allows you to return zvals without copying their contents. For
this purpose two new macros RETVAL_ZVAL_FAST and RETURN_ZVAL_FAST
are added:

    RETVAL_ZVAL_FAST(zv); /* Analog to RETVAL_ZVAL(zv, 1, 0) */
    RETURN_ZVAL_FAST(zv); /* Analog to RETURN_ZVAL(zv, 1, 0) */

These macros behave similarly to the non-FAST versions with
copy=1 and dtor=0, with the difference that the FAST versions
will try return the zval without copying by utilizing return_value_ptr.
2013-08-31 13:16:41 +02:00
Michael Wallner
3419ee9547 bison upgrading notes 2013-08-09 22:23:35 +02:00
Nikita Popov
ca660c2f77 Update NEWS, UPGRADING and UPGRADING.INTERNALS 2013-06-17 18:27:22 +02:00
Nikita Popov
1713d9ad30 Merge branch 'PHP-5.5'
Conflicts:
	UPGRADING
	UPGRADING.INTERNALS
2013-03-23 18:09:05 +01:00
Nikita Popov
0cb868c042 Move some internal changes from UPGRADING to UPGRADING.INTERNALS 2013-03-23 18:06:25 +01:00
Nikita Popov
fcc6611de9 Add support for non-scalar Iterator keys in foreach
RFC: https://wiki.php.net/rfc/foreach-non-scalar-keys
2013-03-12 17:27:31 +01:00
Gustavo Lopes
70b25e9c61 UPGRADING.INTERNALS: document zend_qsort_r 2013-01-14 17:27:20 +01:00
Stanislav Malyshev
bd340b7296 add NEWS/UPGRADING 2012-07-14 15:03:51 -07:00
Gustavo André dos Santos Lopes
e391abb1d9 - Cleanup UPGRADING and UPGRADING.INTERNALS from 5.4 changes.
- Added information about removal of streams pooling API.
2012-02-22 10:08:37 +00:00
Pierre Joye
090bfcdfe1 - add expand_filepath_with_mode (not used anywhere yet but will be used for file ops (fopen&co) to avoid extra links resolution and other non required ops on open 2011-07-25 16:50:07 +00:00
Jani Taskinen
6791197b31 - Added section for build system changes in UPGRADING.INTERNALS 2010-11-18 10:43:01 +00:00
Gustavo André dos Santos Lopes
dc8bc65fe6 - Fixed incorrection in UPGRADING.INTERNALS. 2010-11-15 03:22:26 +00:00
Gustavo André dos Santos Lopes
3a02cfb675 - Added leak_variable() function.
- Added mechanism to force outer streams to be closed before their inner ones.
- Fixed temp:// streams only handling correctly (through an ad hoc mechanism)  reverse closing order
  when the  inner stream is of type memory.
2010-11-15 03:05:32 +00:00
Gustavo André dos Santos Lopes
3f804701b5 - Added to UPGRADING(.INTERNALS) information about the changes on html.c.
- Added to UPGRADING information about the new class Transliteral, the new
  parameter in dns_get_record and the fact that call_user_func_array no longer
  allows call-time pass-by-reference.
2010-10-24 16:21:15 +00:00
Kalle Sommer Nielsen
a3161aa091 Removed a TSRMLS_FETCH() call in php_idate() in favor of the TSRMLS macros 2010-09-27 01:19:57 +00:00
Kalle Sommer Nielsen
1ac15b2f8e Added TSRMLS macros into php_get_current_user() 2010-09-23 04:13:36 +00:00
Pierre Joye
b154864cc9 - drop tsrmls_fetch in popen_ex 2010-09-17 10:00:01 +00:00
Pierre Joye
83527d16a3 - drop tsrmls_fetch in tsrm_win32_access 2010-09-17 09:27:19 +00:00
Pierre Joye
79ee513903 - drop TSRMLS_FETCH in sapi_register_* (won't bring much at runtime :) ) and cleanup/group the upgrade guide, no need of twenty titles for the same change 2010-09-17 08:42:12 +00:00
Pierre Joye
ed58636f00 - use TSRMLS_D/C with php_stream_context_alloc 2010-09-16 09:33:42 +00:00
Pierre Joye
aa0ed267a2 - use TSRMLS_*C instead of TSRMLS_FETCH in zend_list_insert 2010-09-16 09:13:19 +00:00
Pierre Joye
4420a91bbd - macros--; ZEND_FAST_* are now gone 2010-09-15 17:27:43 +00:00
Pierre Joye
c93631a137 - update and restore TOC 2010-09-15 17:04:22 +00:00
Dmitry Stogov
f2df6a4a3e - Improved memory usage
. zend_function.pass_rest_by_reference is replaced by
    ZEND_ACC_PASS_REST_BY_REFERENCE in zend_function.fn_flags
  . zend_function.return_reference is replaced by ZEND_ACC_RETURN_REFERENCE
    in zend_function.fn_flags
  . zend_arg_info.required_num_args removed. it was needed only for internal
    functions. Now the first arg_info for internal function (which has special
    meaning) is represented by zend_internal_function_info structure.
  . zend_op_array.size, size_var, size_literal, current_brk_cont,
    backpatch_count moved into CG(context), because they are used only during
    compilation.
  . zend_op_array.start_op is moved into EG(start_op), because it's used
    only for 'interactive' execution of single top-level op-array.
  . zend_op_array.done_pass_two is replaced by ZEND_ACC_DONE_PASS_TWO in
    zend_op_array.fn_flags.
  . op_array.vars array is trimmed (reallocated) during pass_two.
  . zend_class_entry.constants_updated is replaced by
     ZEND_ACC_CONSTANTS_UPDATED in zend_class_entry.ce_flags
  . the size of zend_class_entry is reduced by sharing the same memory space
    by different information for internal and user classes.
    See zend_class_inttry.info union.
2010-09-15 07:38:52 +00:00
Pierre Joye
bf0a5ea745 - add php_sys_readlink 2010-09-10 14:01:44 +00:00
Pierre Joye
9b6d0f222e - typo/clarity 2010-09-02 10:30:34 +00:00
Pierre Joye
6d6645b3f8 - upgrading addition about stat/lstat 2010-09-01 09:54:45 +00:00
Pierre Joye
b01d74f7f9 - initial import, internals upgrade guide 2010-08-30 10:26:31 +00:00