1
0
mirror of https://github.com/php/php-src.git synced 2026-04-11 18:13:00 +02:00
Commit Graph

1487 Commits

Author SHA1 Message Date
Dmitry Stogov
c5364b851a Fix crashes after opcache restart 2022-10-11 14:23:12 +03:00
Dmitry Stogov
e81b6bf018 Merge branch 'PHP-8.0' into PHP-8.1
* PHP-8.0:
  Fix typo
2022-10-05 21:39:37 +03:00
Dmitry Stogov
072dc3c857 Fix typo 2022-10-05 21:39:16 +03:00
Dmitry Stogov
5877b84056 Merge branch 'PHP-8.0' into PHP-8.1
* PHP-8.0:
  Fix register allocation (missing store)
2022-10-03 17:09:01 +03:00
Dmitry Stogov
ed652a514f Fix register allocation (missing store)
This fixes oss-fuzz #52022
2022-10-03 17:08:11 +03:00
Dmitry Stogov
da28a6b497 Merge branch 'PHP-8.0' into PHP-8.1
* PHP-8.0:
  Fix abstract trace consisency for FE_FETCH instruction
2022-10-03 14:51:21 +03:00
Dmitry Stogov
5ca4113386 Fix abstract trace consisency for FE_FETCH instruction 2022-10-03 14:48:03 +03:00
Dmitry Stogov
aa179bf3dd Force exit to VM 2022-09-29 15:27:38 +03:00
Ilija Tovilo
0aa5adb143 Fix invalid label before }
Will be fixed in C23 :)

Closes GH-9624
2022-09-27 23:27:17 +02:00
Dmitry Stogov
2568db287d Wrap JIT compiler with zend_try to recover in case of memory overflow 2022-09-27 22:28:16 +03:00
wxue1
52f4ed16e0 Indirect call reduction for Jit code
Changing indirect call to direct call for Jit code
benefits the branch prediction, which gets 1% performance
gain in our workload.
Similarly, we change indirect jump to direct jump.

Signed-off-by: Su, Tao <tao.su@intel.com>
Signed-off-by: Wang, Xue <xue1.wang@intel.com>
2022-09-22 11:22:27 +01:00
Arnaud Le Blanc
466e4dc2a2 Check return value of zend_jit_trace_get_exit_addr() (#9097) 2022-09-09 10:50:03 +02:00
Dmitry Stogov
a516e2992d Merge branch 'PHP-8.0' into PHP-8.1
* PHP-8.0:
  Fix ext/opcache/tests/jit/inc_obj_004.phpt failure introduced by fd74ee7e90
2022-08-29 12:35:46 +03:00
Dmitry Stogov
ce42dcf483 Fix ext/opcache/tests/jit/inc_obj_004.phpt failure introduced by fd74ee7e90
This should fix GH-9445
2022-08-29 12:30:14 +03:00
Dmitry Stogov
2a33280ceb Merge branch 'PHP-8.0' into PHP-8.1
* PHP-8.0:
  JIT: Make code generation to be consistent with register allocation
2022-08-22 19:55:10 +03:00
Dmitry Stogov
fd74ee7e90 JIT: Make code generation to be consistent with register allocation
Fixes ext/opcache/tests/jit/add_014.phpt with opcache.jit=1205
2022-08-22 19:53:33 +03:00
Dmitry Stogov
5762fc52c6 Merge branch 'PHP-8.0' into PHP-8.1
* PHP-8.0:
  Tracing JIT: Fix incorrect guard elimination
2022-08-22 15:39:47 +03:00
Dmitry Stogov
c9c51eb1f1 Tracing JIT: Fix incorrect guard elimination
Fixes oss-fuzz #49917
2022-08-22 15:38:41 +03:00
David Carlier
9360cd6add Merge branch 'PHP-8.0' into PHP-8.1 2022-08-19 16:40:54 +01:00
David Carlier
52e312afb8 opcache jit fix message format for OpenBSD.
like macOs it requires `ll`.
Closes #9380.
2022-08-19 16:40:29 +01:00
Dmitry Stogov
7ff71a0a55 Merge branch 'PHP-8.0' into PHP-8.1
* PHP-8.0:
  Tracing: Prevent recording types of variables used to pass zend_class_entry
2022-08-01 17:03:56 +03:00
Dmitry Stogov
2758ff2a77 Tracing: Prevent recording types of variables used to pass zend_class_entry 2022-08-01 17:02:53 +03:00
Dmitry Stogov
69c10aed58 Fix incorrect guard motion out of the loop
Fixes oss-fuzz #49579
2022-08-01 15:32:49 +03:00
Dmitry Stogov
e70d282077 JIT: Fix missing type stote
Fixes oss-fuzz #49402
2022-07-25 15:24:26 +03:00
Dmitry Stogov
cc465ba0bb Merge branch 'PHP-8.0' into PHP-8.1
* PHP-8.0:
  Fix memory leak
2022-07-25 12:08:00 +03:00
Dmitry Stogov
44b86aee31 Fix memory leak
Fixes oss-fuzz #49272
2022-07-25 12:04:46 +03:00
Arnaud Le Blanc
f2381ae4ba Fix JIT crash with large number of match/switch arms (#8961)
Switch statements may generate a large number of exit points. Once the max
number of exit points is reached, get_exit_addr() returns NULL. This was not
checked, and this resulted in a jump table with some 0 addresses.
2022-07-18 12:34:20 +02:00
Dmitry Stogov
af75eab0ef Merge branch 'PHP-8.0' into PHP-8.1
* PHP-8.0:
  Fix incorrect condition introdused in 7cf6f17383
2022-06-29 13:09:14 +03:00
Dmitry Stogov
d66d477d6f Fix incorrect condition introdused in 7cf6f17383 2022-06-29 13:08:18 +03:00
Dmitry Stogov
b7693360cb Merge branch 'PHP-8.0' into PHP-8.1
* PHP-8.0:
  Fixed bug GH-8847 (PHP hanging infinitly at 100% cpu when check php syntaxe of a valid file)
2022-06-29 12:13:03 +03:00
Dmitry Stogov
7cf6f17383 Fixed bug GH-8847 (PHP hanging infinitly at 100% cpu when check php syntaxe of a valid file) 2022-06-29 12:10:46 +03:00
Dmitry Stogov
7e23c838e2 Fixed Bug GH-8863: RW operation on readonly property doesn't throw with JIT 2022-06-27 16:41:53 +03:00
Dmitry Stogov
971b07ea60 JIT: Fix incorrect reference-counting
This fixes oss-fuzz #47937
2022-06-14 15:03:50 +03:00
Dmitry Stogov
70e0e1ada6 Merge branch 'PHP-8.0' into PHP-8.1
* PHP-8.0:
  JIT: Fix missing register store
2022-06-14 13:59:47 +03:00
Dmitry Stogov
1cd8074743 JIT: Fix missing register store
This fixes oss-fuzz #48023
2022-06-14 13:57:44 +03:00
Dmitry Stogov
7ebda198ea Merge branch 'PHP-8.0' into PHP-8.1
* PHP-8.0:
  Fix memory leak
2022-05-30 11:39:10 +03:00
Dmitry Stogov
3a8912fb7c Fix memory leak
This fixes oss-fuzz #47648
2022-05-30 11:32:17 +03:00
Arnaud Le Blanc
69d263e2a1 Add JIT guards for INIT_METHOD_CALL when the method may be modified (#8600)
Non-polymorphic methods can be modified from one request to an other due to recompilation or conditional declaration.

Fixes GH-8591

Co-authored-by: Oleg Stepanischev <Oleg.Stepanischev@tatar.ru>
2022-05-27 13:15:15 +02:00
Dmitry Stogov
6c25413183 Add JIT guards for INIT_FCALL instructions and functions that may be modified
For methods we reuse mechanism of polymorphic calls.
For regular function we invalidate the whole root trace.

This fixes https://github.com/php/php-src/issues/8461
2022-05-12 18:44:12 +03:00
Dmitry Stogov
c3a30544ad JIT: Fixed incorrect guard
Fixes oss-fuzz #46704
2022-04-18 11:34:18 +03:00
Dmitry Stogov
8633893330 Merge branch 'PHP-8.0' into PHP-8.1
* PHP-8.0:
  JIT: Fix memory lek
2022-04-11 12:21:02 +03:00
Dmitry Stogov
3aaf2f6f89 JIT: Fix memory lek
Fixes oss-fuzz #46462
2022-04-11 12:17:05 +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
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
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
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
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