ext/opcache/zend_jit: call TSRM dtor before unloading opcache.so#10533
Merged
dstogov merged 1 commit intophp:PHP-8.1from Feb 7, 2023
Merged
ext/opcache/zend_jit: call TSRM dtor before unloading opcache.so#10533dstogov merged 1 commit intophp:PHP-8.1from
dstogov merged 1 commit intophp:PHP-8.1from
Conversation
Commit a211956 added a TSRM destructor, but that destructor will get called by tsrm_shutdown(), which is after opcache.so has already been unloaded, resulting in a shutdown crash, e.g.: #0 0x00007fad01737500 in ?? () php#1 0x000055ac54e723c4 in tsrm_shutdown () at TSRM/TSRM.c:194 php#2 0x000055ac54c42180 in main (argc=80, argv=0x55ac57bc14d0) at sapi/cli/php_cli.c:1388 By calling ts_free_id() before opcache.so gets unloaded, we can easily fix this crash bug.
dstogov
reviewed
Feb 7, 2023
Member
dstogov
left a comment
There was a problem hiding this comment.
This looks right. I'll merge this when tests passed.
Contributor
Author
|
All green, this worked. (Only AppVeyor is still queued.) |
dstogov
added a commit
that referenced
this pull request
Feb 7, 2023
* PHP-8.1: ext/opcache/zend_jit: call TSRM dtor before unloading opcache.so (#10533)
dstogov
added a commit
that referenced
this pull request
Feb 7, 2023
* PHP-8.2: ext/opcache/zend_jit: call TSRM dtor before unloading opcache.so (#10533)
Member
|
Thanks again. |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Commit a211956 added a TSRM destructor, but that destructor will get called by tsrm_shutdown(), which is after opcache.so has already been unloaded, resulting in a shutdown crash, e.g.:
By calling ts_free_id() before opcache.so gets unloaded, we can easily fix this crash bug.
(@dstogov, this should fix the CI failures after your JIT dtor change.)