Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
66 changes: 36 additions & 30 deletions docs/bootstrap-inventory.md
Original file line number Diff line number Diff line change
Expand Up @@ -8,11 +8,11 @@ Regenerate: `php script/bootstrap-inventory.php`

| Metric | Count |
|--------|------:|
| PHP files on vm.php path | 7021 |
| Phase A inventory files (M2 ratio SSOT) | 7021 |
| PHP files on vm.php path | 7022 |
| Phase A inventory files (M2 ratio SSOT) | 7022 |
| Phase A ratio-deferred paths | 0 |
| Source constructs flagged (blockers) | 0 |
| Source constructs flagged (warnings) | 22575 |
| Source constructs flagged (warnings) | 22576 |

## Compiler CFG gaps (`lib/Compiler.php`)

Expand Down Expand Up @@ -2982,6 +2982,7 @@ Rank live CFG gaps across inventory files: `php script/bootstrap-inventory-triag
| `ext/standard/JitStreamLibcHandleKernel.php` | 0 | 1 |
| `ext/standard/JitStreamLifecycleKernel.php` | 0 | 1 |
| `ext/standard/JitStreamMetaKernel.php` | 0 | 1 |
| `ext/standard/JitStreamMetaThinAot.php` | 0 | 1 |
| `ext/standard/JitStreamModeKernel.php` | 0 | 1 |
| `ext/standard/JitStreamNotificationCallback.php` | 0 | 2 |
| `ext/standard/JitStreamPath.php` | 0 | 1 |
Expand Down Expand Up @@ -29778,7 +29779,12 @@ Rank live CFG gaps across inventory files: `php script/bootstrap-inventory-triag
### `ext/standard/JitStreamMetaKernel.php`

**Warnings** (review for bootstrap subset):
- 9 class method(s)
- 10 class method(s)

### `ext/standard/JitStreamMetaThinAot.php`

**Warnings** (review for bootstrap subset):
- 14 class method(s)

### `ext/standard/JitStreamModeKernel.php`

Expand Down Expand Up @@ -32842,18 +32848,18 @@ Rank live CFG gaps across inventory files: `php script/bootstrap-inventory-triag
### `ext/standard/VmErrorHandler.php`

**Warnings** (review for bootstrap subset):
- new Variable (line 78)
- new Variable (line 87)
- new Variable (line 93)
- new Variable (line 99)
- new Variable (line 105)
- new Variable (line 118)
- new Variable (line 166)
- new Variable (line 168)
- new Variable (line 209)
- new Variable (line 217)
- new Variable (line 225)
- new Variable (line 237)
- new Variable (line 79)
- new Variable (line 88)
- new Variable (line 94)
- new Variable (line 100)
- new Variable (line 106)
- new Variable (line 119)
- new Variable (line 167)
- new Variable (line 169)
- new Variable (line 210)
- new Variable (line 218)
- new Variable (line 226)
- new Variable (line 238)
- 13 class method(s)

### `ext/standard/VmErrorLog.php`
Expand Down Expand Up @@ -52075,16 +52081,16 @@ Rank live CFG gaps across inventory files: `php script/bootstrap-inventory-triag
- new Variable (line 20719)
- new Variable (line 20737)
- new NoDiscardMetadata (line 20985)
- new Variable (line 21182)
- new Variable (line 21184)
- new CompileError (line 21212)
- new CompileError (line 21243)
- new CompileError (line 21282)
- new CompileError (line 21427)
- new CompileError (line 21456)
- new CompileError (line 21489)
- new CompileError (line 21496)
- new Variable (line 21734)
- new Variable (line 21181)
- new Variable (line 21183)
- new CompileError (line 21211)
- new CompileError (line 21242)
- new CompileError (line 21281)
- new CompileError (line 21426)
- new CompileError (line 21455)
- new CompileError (line 21488)
- new CompileError (line 21495)
- new Variable (line 21733)
- 591 class method(s)
- 31 closure(s)

Expand Down Expand Up @@ -55742,10 +55748,10 @@ Rank live CFG gaps across inventory files: `php script/bootstrap-inventory-triag
### `lib/VM/ErrorReporter.php`

**Warnings** (review for bootstrap subset):
- new Variable (line 148)
- new ScriptExit (line 534)
- new Variable (line 706)
- 53 class method(s)
- new Variable (line 174)
- new ScriptExit (line 560)
- new Variable (line 732)
- 54 class method(s)

### `lib/VM/ExceptionHandlerStack.php`

Expand Down
25 changes: 25 additions & 0 deletions ext/standard/JitStreamMetaKernel.php
Original file line number Diff line number Diff line change
Expand Up @@ -48,6 +48,13 @@ final class JitStreamMetaKernel

public static function implement(Context $context): void
{
// Thin AOT: LLVM meta from StreamGlobalsJit paths — NestedJIT VmFs misses those slots (#27659).
if ($context->isThinStandaloneAotMain()) {
self::implementThinStandalone($context);

return;
}

$probe = $context->module->getNamedFunction('__compiler_stream_get_meta_data');
if (null !== $probe && $probe->countBasicBlocks() > 0) {
self::registerLinkedRuntime($context);
Expand All @@ -71,6 +78,24 @@ public static function implement(Context $context): void
}
}

/** Thin user-script AOT: path-table meta + NestedJIT set_blocking/enable_crypto (#27659). */
private static function implementThinStandalone(Context $context): void
{
$savedBlock = BasicBlockHelper::tryGetInsertBlock($context);

JitStreamMetaThinAot::implementGetMetaData($context);
self::ensureJitHelperCompiled($context);
self::implementIfMissing($context, '__compiler_stream_set_blocking', self::implementSetBlockingBridge(...));
self::implementIfMissing($context, '__compiler_stream_enable_crypto', self::implementEnableCryptoBridge(...));
self::registerLinkedRuntime($context);

if (null !== $savedBlock) {
BasicBlockHelper::restoreInsertBlock($context, $savedBlock);
} else {
$context->builder->clearInsertionPosition();
}
}

/**
* @param callable(Context, LlvmFunction): void $emit
*/
Expand Down
Loading
Loading