rfc:direct-execution-opcode
Differences
This shows you the differences between two versions of the page.
Both sides previous revisionPrevious revisionNext revision | Previous revisionNext revisionBoth sides next revision | ||
rfc:direct-execution-opcode [2020/12/10 11:56] – chopins | rfc:direct-execution-opcode [2020/12/10 12:33] – chopins | ||
---|---|---|---|
Line 13: | Line 13: | ||
When executing, judge whether the loaded PHP file is an opcode file based on the flag. if no flag, will run as it is now.If is opcode file will direct execution without check php source file. | When executing, judge whether the loaded PHP file is an opcode file based on the flag. if no flag, will run as it is now.If is opcode file will direct execution without check php source file. | ||
+ | |||
+ | The **includes()** **includes_once()** and **require()** **require_one()** can load opcode file. So if you include opcode files, the source code must use the compiled file path instead of the source file path. | ||
Change function to: | Change function to: | ||
Line 30: | Line 32: | ||
php---> | php---> | ||
+ | |||
+ | new opcode file format like below: | ||
+ | |||
+ | <PHP> | ||
+ | <? | ||
+ | </ | ||
**opcache exec process:** | **opcache exec process:** | ||
Line 46: | Line 54: | ||
</ | </ | ||
===== Backward Incompatible Changes ===== | ===== Backward Incompatible Changes ===== | ||
- | This change causes | + | Magic constant |
The file path obtained by **error reporting**, | The file path obtained by **error reporting**, | ||
Line 75: | Line 84: | ||
* set 1, default value, different version opcode file exec are prohibited | * set 1, default value, different version opcode file exec are prohibited | ||
* set 0, different version opcode file will report **E_WARNING** message | * set 0, different version opcode file will report **E_WARNING** message | ||
- | |||
- | ===== Future Scope ===== | ||
- | support opcode file in phar. | ||
===== Patches and Tests ===== | ===== Patches and Tests ===== |
rfc/direct-execution-opcode.txt · Last modified: 2021/04/23 18:07 by imsop