diff options
author | Dmitry Stogov <dmitry@zend.com> | 2017-10-04 16:53:01 +0300 |
---|---|---|
committer | Dmitry Stogov <dmitry@zend.com> | 2017-10-04 16:53:01 +0300 |
commit | e70618aff6f447a298605d07648f2ce9e5a284f5 (patch) | |
tree | fb72291c9346d131c7d787411e5ce4161010f987 /UPGRADING.INTERNALS | |
parent | 2cbc75ec63dbe9aed6b8480444b4f73693da1bd1 (diff) | |
download | php-git-e70618aff6f447a298605d07648f2ce9e5a284f5.tar.gz |
Changed the way VM accesses constant operands in 64-bit builds.
Diffstat (limited to 'UPGRADING.INTERNALS')
-rw-r--r-- | UPGRADING.INTERNALS | 19 |
1 files changed, 19 insertions, 0 deletions
diff --git a/UPGRADING.INTERNALS b/UPGRADING.INTERNALS index f505483562..efb9920bfb 100644 --- a/UPGRADING.INTERNALS +++ b/UPGRADING.INTERNALS @@ -10,6 +10,7 @@ PHP 7.2 INTERNALS UPGRADE NOTES g. ZEND_BEGIN_ARG_WITH_RETURN_TYPE_INFO_EX changed h. valid_symbol_table removed i. array_init() and array_init_size() + j. Run-time constant operand addressing 2. Build system changes a. Unix build system changes @@ -52,6 +53,24 @@ PHP 7.2 INTERNALS UPGRADE NOTES i. array_init() and array_init_size() are not functions anymore. They don't return any values. + j. In 64-bit builds PHP-7.2 and below used relative run-time constant operand + addressing. E.g. opline->op1.constant kept an offset from start of literals + table - op_array->literals. To speedup access op_array->literals was cached + in execute_data->literals. So the resulting address calculated as + EX(literals) + opline->op1.constant. + + Now at run-time literals allocated close to opcodes, and addressed + relatively from current opline. This eliminates load of EX(literals) on + each constant access as well as EX(literals) initialization on each call. + + As result some related macros were removed (ZEND_EX_USE_LITERALS, + EX_LOAD_LITERALS, EX_LITERALS, RT_CONSTANT_EX, EX_CONSTANT) or changed + (RT_CONSTANT, ZEND_PASS_TWO_UPDATE_CONSTANT, ZEND_PASS_TWO_UNDO_CONSTANT). + This change way affect only some "system" extensions. EX_LITERALS, + RT_CONSTANT_EX, EX_CONSTANT should be substituted by RT_CONSTANT than now + use "opline" (instead of "op_array") as first argument. + + ======================== 2. Build system changes ======================== |