php-in-php: lazy StringTriggerError from Type::register (#35392) - #35394
Merged
Conversation
Drop Type::register always-on declare+ensureLinked; HashTable::implement and JitScalarEnumCoerce ensure before lookup. SilenceRuntime/JitTriggerErrorKernel early-returns still link StreamLifecycle so HELPER_RUNTIME_O=0 NestedJIT cannot skip fflush after a prior in-NestedJIT ensureLinked (#32122 .1 mint class). Co-authored-by: Cursor <cursoragent@cursor.com>
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.
Summary
Type::registeralways-onStringTriggerError::declareUndefinedArrayKeyAbis+ensureLinkedso AOT init cannot NestedJITtrigger_error/ undef-key ABIs during every register (Release v1.1.0: fix cold-build-check compile_failed on hello world (LLVM Module.php line 180; re-#24302) #32122.1mint class).HashTable::implementdeclares/ensures at entry;JitScalarEnumCoerce::emitObjectScalarWarningensures before lookup (WeakRef NestedJIT viaRefcount::implementcan run before HashTable).JitTriggerErrorKernel/SilenceRuntimeearly-returns still linkSilenceRuntime→StreamLifecycleso a prior in-NestedJITensureLinkedcannot leave__compiler_fflushunregistered (HELPER_RUNTIME_O=0/ Regression: HELPER_RUNTIME_O=0 AOT compile fails looking up __compiler_trigger_error after #33234 (lib/JIT/Builtin/Type.php) #33248).php-src: Zend/zend_execute_API.c, main/php_errors.c, ext/standard/basic_functions.c (
trigger_error)Closes #35392
Test plan
./script/phpunit.sh --filter 'TypeRegisterLazyStringTriggerError|TypeDeadTriggerErrorAbi|TypeDeadUndefinedArrayKeyAbi|TypeDeadTypeInitializeLazyTimeEnvTriggerPending|TriggerErrorHelperRuntimeO033248|ContextMinimalStandaloneLazyStringTriggerError'→ OK (23 tests, 156 assertions)./script/aot-smoke.sh→ 8 passed, 0 failedruntime/*.c/lib/AOT/runtime/*.cMade with Cursor