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
2 changes: 1 addition & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -44,7 +44,7 @@ Presenter script and troubleshooting: [`docs/GETTING-STARTED.md`](docs/GETTING-S
| Self-host **M2** spine | ✅ **726/726** link (literal `src/cli_driver.php`) ([#1492](https://github.com/PurHur/php-compiler/issues/1492), [#2868](https://github.com/PurHur/php-compiler/issues/2868), [#2201](https://github.com/PurHur/php-compiler/issues/2201), [#2543](https://github.com/PurHur/php-compiler/issues/2543), [#2652](https://github.com/PurHur/php-compiler/issues/2652)) |
| Self-host **M3** emit | 🚧 smoke strict **native** ✅ ([#2610](https://github.com/PurHur/php-compiler/issues/2610)); full `Compiler` CFG 🚧 ([#1937](https://github.com/PurHur/php-compiler/issues/1937)) |
| Self-host **M4** loop | 🚧 gen-2→gen-3 spine **726/726** ✅ ([#2697](https://github.com/PurHur/php-compiler/pull/2697)); full revision argv probe flakey/segfault 139 ([#2880](https://github.com/PurHur/php-compiler/issues/2880), [#2967](https://github.com/PurHur/php-compiler/issues/2967)); changed-tree rebuild ⬜ ([#1498](https://github.com/PurHur/php-compiler/issues/1498)) · [bootstrap-generations.md](docs/bootstrap-generations.md) |
| Self-host **M5** vendor prelink | 🚧 `php-types` **object_ok** ([#1416](https://github.com/PurHur/php-compiler/issues/1416)); `make north-star5-verify` |
| Self-host **M5** vendor prelink | 🚧 `north-star5-verify` green — **3/3** vendor `object_ok` (cold-boot step 5b) via native→Zend rebuild fallback ([#2967](https://github.com/PurHur/php-compiler/issues/2967)); native vendor-bundle emit still 🚧 ([#3028](https://github.com/PurHur/php-compiler/issues/3028), [#3030](https://github.com/PurHur/php-compiler/issues/3030), [#3031](https://github.com/PurHur/php-compiler/issues/3031)); `make north-star5-verify` |
| Full Zend PHP compatibility | ❌ — subset only (matrices in `docs/`, not on status site) |

MiniWebApp gates: [docs/miniwebapp-gates.md](docs/miniwebapp-gates.md) ([#472](https://github.com/PurHur/php-compiler/issues/472)). Presenter verify: `make north-star1-verify` ([#1845](https://github.com/PurHur/php-compiler/issues/1845)). Docker image: `php-compiler:22.04-dev`.
Expand Down
142 changes: 72 additions & 70 deletions docs/bootstrap-inventory.md
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,7 @@ Regenerate: `php script/bootstrap-inventory.php`
| Phase A inventory files (M2 ratio SSOT) | 726 |
| Phase A ratio-deferred paths | 0 |
| Source constructs flagged (blockers) | 0 |
| Source constructs flagged (warnings) | 1878 |
| Source constructs flagged (warnings) | 1880 |

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

Expand Down Expand Up @@ -529,13 +529,13 @@ Rank live CFG gaps across inventory files: `php script/bootstrap-inventory-triag
| `lib/Func/JIT.php` | 0 | 2 |
| `lib/Func/PHP.php` | 0 | 1 |
| `lib/Handler.php` | 0 | 1 |
| `lib/JIT.php` | 0 | 56 |
| `lib/JIT.php` | 0 | 57 |
| `lib/JIT/Analyzer.php` | 0 | 1 |
| `lib/JIT/ArrayBuiltinHelper.php` | 0 | 47 |
| `lib/JIT/ArrayMapCallbackPolicy.php` | 0 | 1 |
| `lib/JIT/ArrayReduceCallbackPolicy.php` | 0 | 1 |
| `lib/JIT/BasicBlockHelper.php` | 0 | 1 |
| `lib/JIT/BootstrapCompileSmokeM3Emit.php` | 0 | 2 |
| `lib/JIT/BootstrapCompileSmokeM3Emit.php` | 0 | 3 |
| `lib/JIT/Builtin.php` | 0 | 1 |
| `lib/JIT/Builtin/AttributeRegistry.php` | 0 | 1 |
| `lib/JIT/Builtin/CallArgv.php` | 0 | 1 |
Expand Down Expand Up @@ -3964,62 +3964,63 @@ Rank live CFG gaps across inventory files: `php script/bootstrap-inventory-triag
### `lib/JIT.php`

**Warnings** (review for bootstrap subset):
- new JIT\Call\ExternalMethod (line 146)
- new JIT\Scope (line 172)
- new Operand\Literal (line 223)
- new Operand\Literal (line 239)
- new Variable (line 925)
- new JIT\Call\Vararg (line 935)
- new JIT\Call\Native (line 945)
- new JIT\Call\Native (line 1089)
- new JIT\Variable (line 1279)
- new JIT\Call\Native (line 1296)
- new JIT\Call\Native (line 1355)
- new JIT\Call\Native (line 1397)
- new JIT\Call\Native (line 1443)
- new JIT\Call\Native (line 2461)
- new JIT\Call\Native (line 2492)
- new JIT\Call\Native (line 2539)
- new JIT\Call\Native (line 2586)
- new JIT\Call\Native (line 2648)
- new JIT\Call\Native (line 3252)
- new JIT\Call\Native (line 3290)
- new JIT\Call\Native (line 3324)
- new JIT\Call\Native (line 3368)
- new JIT\Call\Native (line 3725)
- new JIT\Call\Native (line 3791)
- new ext\standard\boolval (line 4156)
- new Operand\Literal (line 4236)
- new JIT\Variable (line 4270)
- new Operand\Literal (line 4345)
- new ext\standard\intval (line 4449)
- new Variable (line 4478)
- new Variable (line 4589)
- new OpCode (line 4672)
- new Variable (line 4921)
- new JIT\Call\RuntimeVariableFunction (line 4960)
- new Variable (line 5017)
- new Variable (line 5146)
- new Variable (line 5165)
- new Variable (line 5946)
- new Variable (line 5986)
- new Variable (line 6005)
- new Variable (line 6538)
- new Variable (line 6558)
- new Variable (line 6628)
- new Variable (line 6834)
- new Variable (line 6873)
- new Operand\Literal (line 6882)
- new Variable (line 6897)
- new Operand\Literal (line 7236)
- new Operand\Literal (line 7240)
- new Operand\Literal (line 7244)
- new Variable (line 7248)
- new Variable (line 7272)
- new Variable (line 7284)
- new Variable (line 7497)
- new Variable (line 7513)
- 189 class method(s) — PHPCfg Op\Stmt\ClassMethod not lowered in Compiler
- new JIT\Call\ExternalMethod (line 152)
- new JIT\Scope (line 178)
- new JIT\TryCatchState (line 186)
- new Operand\Literal (line 231)
- new Operand\Literal (line 247)
- new Variable (line 960)
- new JIT\Call\Vararg (line 970)
- new JIT\Call\Native (line 980)
- new JIT\Call\Native (line 1124)
- new JIT\Variable (line 1313)
- new JIT\Call\Native (line 1330)
- new JIT\Call\Native (line 1389)
- new JIT\Call\Native (line 1431)
- new JIT\Call\Native (line 1477)
- new JIT\Call\Native (line 2495)
- new JIT\Call\Native (line 2526)
- new JIT\Call\Native (line 2573)
- new JIT\Call\Native (line 2620)
- new JIT\Call\Native (line 2682)
- new JIT\Call\Native (line 3403)
- new JIT\Call\Native (line 3441)
- new JIT\Call\Native (line 3475)
- new JIT\Call\Native (line 3519)
- new JIT\Call\Native (line 3947)
- new JIT\Call\Native (line 4013)
- new ext\standard\boolval (line 4378)
- new Operand\Literal (line 4458)
- new JIT\Variable (line 4492)
- new Operand\Literal (line 4567)
- new ext\standard\intval (line 4671)
- new Variable (line 4700)
- new Variable (line 4811)
- new OpCode (line 4894)
- new Variable (line 5143)
- new JIT\Call\RuntimeVariableFunction (line 5182)
- new Variable (line 5239)
- new Variable (line 5368)
- new Variable (line 5387)
- new Variable (line 6168)
- new Variable (line 6208)
- new Variable (line 6227)
- new Variable (line 6760)
- new Variable (line 6780)
- new Variable (line 6850)
- new Variable (line 7056)
- new Variable (line 7095)
- new Operand\Literal (line 7104)
- new Variable (line 7119)
- new Operand\Literal (line 7458)
- new Operand\Literal (line 7462)
- new Operand\Literal (line 7466)
- new Variable (line 7470)
- new Variable (line 7494)
- new Variable (line 7506)
- new Variable (line 7719)
- new Variable (line 7735)
- 193 class method(s) — PHPCfg Op\Stmt\ClassMethod not lowered in Compiler

### `lib/JIT/Analyzer.php`

Expand Down Expand Up @@ -4095,8 +4096,9 @@ Rank live CFG gaps across inventory files: `php script/bootstrap-inventory-triag
### `lib/JIT/BootstrapCompileSmokeM3Emit.php`

**Warnings** (review for bootstrap subset):
- new Call\Native (line 424)
- 16 class method(s) — PHPCfg Op\Stmt\ClassMethod not lowered in Compiler
- new Call\Native (line 476)
- new Call\Native (line 531)
- 19 class method(s) — PHPCfg Op\Stmt\ClassMethod not lowered in Compiler

### `lib/JIT/Builtin.php`

Expand Down Expand Up @@ -4701,11 +4703,11 @@ Rank live CFG gaps across inventory files: `php script/bootstrap-inventory-triag
**Warnings** (review for bootstrap subset):
- new Temporary (line 111)
- new Variable (line 115)
- new Variable (line 146)
- new Variable (line 300)
- new Variable (line 327)
- new Literal (line 488)
- new Variable (line 738)
- new Variable (line 155)
- new Variable (line 309)
- new Variable (line 336)
- new Literal (line 497)
- new Variable (line 747)
- 21 class method(s) — PHPCfg Op\Stmt\ClassMethod not lowered in Compiler

### `lib/JIT/IssetHelper.php`
Expand Down Expand Up @@ -4886,9 +4888,9 @@ Rank live CFG gaps across inventory files: `php script/bootstrap-inventory-triag

**Warnings** (review for bootstrap subset):
- new TryCatchHandler (line 76)
- new Variable (line 220)
- new Variable (line 240)
- 6 class method(s) — PHPCfg Op\Stmt\ClassMethod not lowered in Compiler
- new Variable (line 237)
- new Variable (line 257)
- 9 class method(s) — PHPCfg Op\Stmt\ClassMethod not lowered in Compiler

### `lib/JIT/TypeCheck.php`

Expand Down Expand Up @@ -5068,7 +5070,7 @@ Rank live CFG gaps across inventory files: `php script/bootstrap-inventory-triag
- new JIT (line 148)
- new JITContext (line 162)
- new State (line 188)
- new LintCompiler (line 432)
- new LintCompiler (line 436)
- 33 class method(s) — PHPCfg Op\Stmt\ClassMethod not lowered in Compiler

### `lib/VM.php`
Expand Down
4 changes: 4 additions & 0 deletions docs/bootstrap-m5-fast-path.md
Original file line number Diff line number Diff line change
Expand Up @@ -147,6 +147,10 @@ php script/bootstrap-vendor-objects.php --compile # reuses committed .o when ve

Rebuild of vendor `.o` uses literal `vendor/{package}` sources (bundle `require_once` paths) via Zend or a gen-0 native driver under `build/` ([#2842](https://github.com/PurHur/php-compiler/issues/2842), [#2849](https://github.com/PurHur/php-compiler/issues/2849)). With `vendor/` absent, `--compile` reuses committed `prelinked/bootstrap-vendor/*.o` when present ([#2841](https://github.com/PurHur/php-compiler/issues/2841)); missing `.o` rebuild from `prelinked/bootstrap-vendor/sources/` + symlinked `vendor/ircmaxell/*` (no autoload — [#2881](https://github.com/PurHur/php-compiler/issues/2881)).

**Cold-boot native→Zend fallback (#2967):** the gen-0 native driver (`build/selfhost-native-compile-driver`) currently returns `parseAndCompile returned null (parser/CFG spine)` for the three vendor bundles ([#3028](https://github.com/PurHur/php-compiler/issues/3028) php-cfg, [#3030](https://github.com/PurHur/php-compiler/issues/3030) php-types, [#3031](https://github.com/PurHur/php-compiler/issues/3031) php-llvm). When `bootstrapVendorPrelinkColdBootCompile()` detects that **all** rebuild failures are this native parse-spine null (`bootstrapVendorPrelinkFailuresAreNativeParseSpine()`), it retries the rebuild once with the Zend `bin/compile.php` invoker (`BOOTSTRAP_M5_VENDOR_ALLOW_ZEND=1`). This keeps `north-star5-verify` **step 5b** green (3/3 `object_ok`) while the native vendor-bundle emit gap is closed — i.e. the M5 ladder no longer regresses on the native parser/CFG spine, but cold boot is still **Zend-assisted** until [#3028](https://github.com/PurHur/php-compiler/issues/3028)/[#3030](https://github.com/PurHur/php-compiler/issues/3030)/[#3031](https://github.com/PurHur/php-compiler/issues/3031) land native rebuild.

**Fresh-clone prerequisite:** `script/apply-patches.sh` must apply cleanly. The `php-types-magic-script-const` and `php-types-first-class-callable` overlay anchors include the `case 'Expr_YieldFrom':` line inserted by `php-types-yield-from.patch`; the overlays run after yield-from, so their anchors must match the post-yield-from `TypeReconstructor.php` (otherwise `set -e` aborts the whole patch run on a fresh `composer install`).

Presenter: `make north-star5-verify` / `./script/north-star5-verify.sh` ([#1416](https://github.com/PurHur/php-compiler/issues/1416)).

`lib/AOT/Linker.php::prelinkedVendorObjectPaths()` reads `object_ok` entries from the manifest. CI: `BOOTSTRAP_VENDOR_PRELINK_SYNC_GATE=1` (bundles); `BOOTSTRAP_VENDOR_PRELINK_GATE=1` for compile probe in wave-check (opt-in).
Expand Down
Loading