1
0
mirror of https://github.com/php/php-src.git synced 2026-04-21 15:08:16 +02:00
Commit Graph

5169 Commits

Author SHA1 Message Date
Dmitry Stogov ccef2bc435 Merge branch 'PHP-8.1'
* PHP-8.1:
  Tracing JIT: Fixed incorrect assumption about stack slot type
2022-04-11 11:45:32 +03:00
Dmitry Stogov 69bcd93190 Merge branch 'PHP-8.0' into PHP-8.1
* PHP-8.0:
  Tracing JIT: Fixed incorrect assumption about stack slot type
2022-04-11 11:42:56 +03:00
Dmitry Stogov 5b048dd05c Tracing JIT: Fixed incorrect assumption about stack slot type
Fixes oss-fuzz #46404
2022-04-11 11:42:01 +03:00
Nikita Popov 414f7fc2bb Merge branch 'PHP-8.1'
* PHP-8.1:
  Improve type narrowing fix
2022-04-10 11:22:52 +02:00
Nikita Popov c72e9621ce Improve type narrowing fix
We need to explicitly model the null return type for property
accesses on non-objects.
2022-04-10 11:22:36 +02:00
Dmitry Stogov df0c8aaee9 JIT: Fix array clobbering by user error handler
Fixes oss-fuzz #46336
2022-04-04 16:47:47 +03:00
Dmitry Stogov 4f18dbeb97 Merge branch 'PHP-8.0' into PHP-8.1
* PHP-8.0:
  JIT: Fix array clobbering by user error handler
2022-04-04 16:37:17 +03:00
Dmitry Stogov c489e360a6 JIT: Fix array clobbering by user error handler
Fixes oss-fuzz #46336
2022-04-04 16:36:25 +03:00
Dmitry Stogov d260e063a8 Merge branch 'PHP-8.1'
* PHP-8.1:
  Fixed reference counting inference
2022-04-04 15:34:57 +03:00
Dmitry Stogov e721a42211 Merge branch 'PHP-8.0' into PHP-8.1
* PHP-8.0:
  Fixed reference counting inference
2022-04-04 15:34:46 +03:00
Dmitry Stogov c0bb238483 Fixed reference counting inference
Fixes oss-fuzz #46084
2022-04-04 15:34:02 +03:00
Dmitry Stogov db34e2a68e Merge branch 'PHP-8.1'
* PHP-8.1:
  Trcing JIT: remove unchecked type guards om ROPE_* instructions
2022-04-04 15:08:01 +03:00
Dmitry Stogov 33704be5f2 Trcing JIT: remove unchecked type guards om ROPE_* instructions
Fixes oss-fuzz #46209
2022-04-04 15:06:35 +03:00
Dmitry Stogov 6156505697 Merge branch 'PHP-8.1'
* PHP-8.1:
  JIT: Fixed incorrect code generation
2022-04-04 14:24:32 +03:00
Dmitry Stogov 24bb178310 Merge branch 'PHP-8.0' into PHP-8.1
* PHP-8.0:
  JIT: Fixed incorrect code generation
2022-04-04 14:24:10 +03:00
Dmitry Stogov 0d44bbd212 JIT: Fixed incorrect code generation
Fixes oss-fuzz #46328
2022-04-04 14:20:45 +03:00
George Peter Banyard 2c2ecba063 Determine value of ZEND_MM_* during config and fix sign conversion (#6981)
Also add a new ZEND_MM_NEED_EIGHT_BYTE_REALIGNMENT definition.

This fixes many [-Wsign-conversion] warnings.

Co-authored-by: Guillaume Charifi <guillaume.charifi@sfr.fr>
Co-authored-by: Bob Weinand <bobwei9@hotmail.com>
2022-04-01 15:43:42 +01:00
Max Kellermann b9e895bca0 Replace memcmp() with zend_string functions (#8216)
* ext/oci8: use zend_string_equals()

Eliminate duplicate code.

* main/php_variables: use zend_string_equals_literal()

Eliminate duplicate code.

* Zend/zend_string: add zend_string_equals_cstr()

Allows eliminating duplicate code.

* Zend, ext/{opcache,standard}, main/output: use zend_string_equals_cstr()

Eliminate duplicate code.

* Zend/zend_string: add zend_string_starts_with()

* ext/{opcache,phar,spl,standard}: use zend_string_starts_with()

This adds missing length checks to several callers, e.g. in
cache_script_in_shared_memory().  This is important when the
zend_string is shorter than the string parameter, when memcmp()
happens to check backwards; this can result in an out-of-bounds memory
access.
2022-03-31 16:27:58 +02:00
Dmitry Stogov 2d3415a74a Merge branch 'PHP-8.1'
* PHP-8.1:
  JIT: Fixed memory leak
2022-03-25 16:56:08 +03:00
Dmitry Stogov 7aac1c11ee Merge branch 'PHP-8.0' into PHP-8.1
* PHP-8.0:
  JIT: Fixed memory leak
2022-03-25 16:55:37 +03:00
Dmitry Stogov aa352c2c54 JIT: Fixed memory leak
Fixes oss-fuzz #45981
2022-03-25 16:54:50 +03:00
Max Kellermann 04a4864b65 ext/opcache: merge redundant code and "bool" refactoring (#8237)
* ext/opcache/ZendAccelerator: make check_persistent_script_access() static

* ext/opcache/ZendAccelerator: convert "int" to "bool"

* ext/opcache/zend_file_cache: convert "int" to "bool"

* ext/opcache: use true/false for zend_persistent_script.corrupted

* ext/opcache/ZendAccelerator: move duplicate code to zend_accel_discard_script()

* ext/opcache/ZendAccelerator: convert accel_deactivate_now() to function

Simplify the #iddef ZEND_WIN32.

* ext/opcache/zend_file_cache: simplify iovec initializer

* ext/opcache/zend_file_cache: add local zend_string* variables

Eliminates lots of redundant casts and avoids reloading the variable
from RAM into registers.

* ext/opcache/zend_file_cache: use ZSTR_VAL()

* ext/opcache/zend_file_cache: move code to zend_file_cache_script_write()

This eliminates duplicate error handling code.
2022-03-24 15:03:53 +01:00
Dmitry Stogov 0ba92163a0 Merge branch 'PHP-8.1'
* PHP-8.1:
  JIT: Fix register clobbering
2022-03-21 16:13:13 +03:00
Dmitry Stogov 62a1c068fe Merge branch 'PHP-8.0' into PHP-8.1
* PHP-8.0:
  JIT: Fix register clobbering
2022-03-21 16:13:04 +03:00
Dmitry Stogov cf83bdd925 JIT: Fix register clobbering
Fixes oss-fuzz #45590
2022-03-21 16:08:52 +03:00
Dmitry Stogov 159a89b87d Merge branch 'PHP-8.1'
* PHP-8.1:
  JIT: Fix missing type store
2022-03-21 14:07:47 +03:00
Dmitry Stogov 21b0da8cdf Merge branch 'PHP-8.0' into PHP-8.1
* PHP-8.0:
  JIT: Fix missing type store
2022-03-21 14:07:34 +03:00
Dmitry Stogov e9fc81a2f8 JIT: Fix missing type store
Fixes oss-fuzz #45604
2022-03-21 13:34:46 +03:00
Dmitry Stogov 7947095b64 Merge branch 'PHP-8.1'
* PHP-8.1:
  JIT: Fix memory leak
2022-03-21 12:54:18 +03:00
Dmitry Stogov 2198493f12 Merge branch 'PHP-8.0' into PHP-8.1
* PHP-8.0:
  JIT: Fix memory leak
2022-03-21 12:51:10 +03:00
Dmitry Stogov 7051dc3372 JIT: Fix memory leak
Fixes oss-fuzz #45658
2022-03-21 12:50:30 +03:00
Max Kellermann b9b134de5c ext/opcache/ZendAccelerator: move duplicate code into bzero_aligned() 2022-03-20 20:42:14 +01:00
Max Kellermann 63281763bf ext/opcache/zend_shared_alloc: add zend_shared_alloc_aligned()
Eliminate some duplicate code.
2022-03-20 20:42:14 +01:00
Max Kellermann 373f236673 ext/opcache: C++ compatibility 2022-03-20 20:38:23 +01:00
Max Kellermann 82de4fcfe6 ext/opcache/ZendAccelerator: remove redundant check (#8222)
The "accelerator_enabled" flag has been checked already in the
previous "if".
2022-03-19 13:51:40 +00:00
Dmitry Stogov e85f812378 Merge branch 'PHP-8.1'
* PHP-8.1:
  JIT: Fix missing exception handling
2022-03-18 18:56:58 +03:00
Dmitry Stogov 83ab9cf871 Merge branch 'PHP-8.0' into PHP-8.1
* PHP-8.0:
  JIT: Fix missing exception handling
2022-03-18 18:56:02 +03:00
Dmitry Stogov 3d6a7e2bd5 JIT: Fix missing exception handling
Fixes oss-fuzz #45649
2022-03-18 18:54:47 +03:00
Dmitry Stogov d06422670c Merge branch 'PHP-8.1'
* PHP-8.1:
  Fix memory leak
2022-03-14 12:59:13 +03:00
Dmitry Stogov 156d3aedc1 Merge branch 'PHP-8.0' into PHP-8.1
* PHP-8.0:
  Fix memory leak
2022-03-14 12:58:11 +03:00
Dmitry Stogov 2b7431cf5b Fix memory leak
Fixed oss-fuzz #45535
2022-03-14 12:57:37 +03:00
Dmitry Stogov 981ae10bf9 Merge branch 'PHP-8.1'
* PHP-8.1:
  JIT: Fix register allocation
2022-03-14 11:48:11 +03:00
Dmitry Stogov 2bed115336 Merge branch 'PHP-8.0' into PHP-8.1
* PHP-8.0:
  JIT: Fix register allocation
2022-03-14 11:47:27 +03:00
Dmitry Stogov e20f955e44 JIT: Fix register allocation
Fixes oss-fuzz #45487
2022-03-14 11:46:45 +03:00
Dmitry Stogov 0d80bc2abd Merge branch 'PHP-8.1'
* PHP-8.1:
  JIT: Fix type store
2022-03-14 09:51:58 +03:00
Dmitry Stogov 2862553de7 Merge branch 'PHP-8.0' into PHP-8.1
* PHP-8.0:
  JIT: Fix type store
2022-03-14 09:51:49 +03:00
Dmitry Stogov 9792f0db76 JIT: Fix type store
Fixes oss-fuzz #45190
2022-03-14 09:48:58 +03:00
Christoph M. Becker 6b2187bc79 Merge branch 'PHP-8.1'
* PHP-8.1:
  Fix GH-8160: ZTS support on Alpine is broken
2022-03-11 14:42:49 +01:00
Christoph M. Becker 0b1bca6b9c Merge branch 'PHP-8.0' into PHP-8.1
* PHP-8.0:
  Fix GH-8160: ZTS support on Alpine is broken
2022-03-11 14:41:46 +01:00
Michael Voříšek 2b2aeb989e Fix GH-8160: ZTS support on Alpine is broken
We need to export `__MUSL__` so that phpize builds can see the proper
macro, and also need to fix "_tsrm_ls_cache" usage for musl.

Closes GH-8180.
2022-03-11 14:39:39 +01:00