Repository navigation
Conversation
henderkes
commented
Nov 7, 2026
Comment on lines
54
to
+60
| - The ZTS symbols compiler_globals_offset and executor_globals_offset have been | ||
| removed: CG()/EG() now reach the globals through a __thread struct. | ||
| - PG(), SG(), CWDG(), SIGG(), ZCG(), JIT_G() and INI_SCNG() use native TLS. | ||
| The core_globals_offset, sapi_globals_offset, cwd_globals_offset, | ||
| zend_signal_globals_offset, accel_globals_offset, jit_globals_offset and | ||
| ini_scanner_globals_offset symbols have been removed. | ||
| - php_reserve_tsrm_memory() has been removed. |
Contributor
Author
There was a problem hiding this comment.
What are the conventions here, could I just amend the initial upgrading entry?
|
|
||
| #ifdef ZTS | ||
| /* {{{ php_reserve_tsrm_memory */ | ||
| PHPAPI void php_reserve_tsrm_memory(void) |
Contributor
Author
There was a problem hiding this comment.
I assume it's fine to remove this in one go?
arnaud-lb
reviewed
Nov 11, 2026
Comment on lines
+50
to
+51
| ZEND_API int jit_globals_id; | ||
| ZEND_TLS_API TSRM_TLS TSRM_TLS_MODEL_ATTR zend_jit_globals jit_globals; |
Member
There was a problem hiding this comment.
I think it's fine removing the ZEND_API / ZEND_TLS_API here, as JIT_G() is not supposed to be used outside of ext/opcache and zend_jit.h is not installed.
In zend_jit.h, we can assume ZEND_TLS_DIRECT as these globals are not accessed by other modules.
Ditto for ext/opcache/ZendAccelerator.c / ext/opcache/ZendAccelerator.h.
| size_t cwd_globals_offset; | ||
| CWD_API ts_rsrc_id cwd_globals_id; | ||
| ZEND_TLS_API TSRM_TLS TSRM_TLS_MODEL_ATTR virtual_cwd_globals cwd_globals; | ||
| static void *cwd_globals_tls_addr(void) { return &cwd_globals; } |
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.
@arnaud-lb forgive me for the PR so soon again, but thanks to the prior PRs it's purely mechanical this time around.
Next up, kind of hoping to get rid of TLS_DIRECT macro and the resource id indirection access machinery which only still exist because of Windows, but I don't know if it's feasible.