You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Locally, script/ci-local.sh can report 133 JIT compliance tests skipped while 133 VM compliance tests pass (266 total). When LLVM 9 is present under .llvm/ or /opt/llvm9, the JIT suite should execute, not skip entirely — otherwise JIT regressions slip through.
JITTest::setUp() skips when LlvmToolchain::isReady() is false. Historical failures were also caused by LD_LIBRARY_PATH not reaching PHPUnit child processes and PHPLLVM\Chooser::choose() failing silently.
#250 (closed) added script/check-jit-compliance-ran.php so ci-local.shfails if LLVM exists but JIT compliance ran zero tests. This issue tracks fixing the root cause of skips when LLVM is actually installed.
Goal
./script/ci-local.sh (host or Docker) runs JIT compliance with the same pass/fail signal as VM compliance when libLLVM-9.so.1 is present.
GitHub Actions is optional; reproduce with Docker:
make docker-build-22
docker run --rm -v "$(pwd):/compiler" -w /compiler php-compiler:22.04-dev ./script/ci-local.sh
Implementation hints
Reproduce: run vendor/bin/phpunit --group llvm --log-junit /tmp/llvm.xml inside php-compiler:22.04-dev; inspect /tmp/llvm.xml for JITTest skipped count.
test/compliance/JITTest.php: extends BaseTest; ensure setUp() uses LlvmToolchain::isReady(dirname(__DIR__, 2)) — same root as ExampleWebAotTest.
phpunit.xml.dist: confirm <env name="LD_LIBRARY_PATH" value="./.llvm"/> or that script/ci-local.sh exports LD_LIBRARY_PATH before PHPUnit (lines 32–37).
test/bootstrap.php: mirror AOT bootstrap — call PHPLLVM\Chooser::choose() once and surface failure reason in skip message.
script/check-jit-compliance-ran.php: already wired at end of llvm group in ci-local.sh — keep as guard; do not weaken when fixing skips.
Problem
Locally,
script/ci-local.shcan report 133 JIT compliance tests skipped while 133 VM compliance tests pass (266 total). When LLVM 9 is present under.llvm/or/opt/llvm9, the JIT suite should execute, not skip entirely — otherwise JIT regressions slip through.JITTest::setUp()skips whenLlvmToolchain::isReady()is false. Historical failures were also caused byLD_LIBRARY_PATHnot reaching PHPUnit child processes andPHPLLVM\Chooser::choose()failing silently.#250 (closed) added
script/check-jit-compliance-ran.phpsoci-local.shfails if LLVM exists but JIT compliance ran zero tests. This issue tracks fixing the root cause of skips when LLVM is actually installed.Goal
./script/ci-local.sh(host or Docker) runs JIT compliance with the same pass/fail signal as VM compliance whenlibLLVM-9.so.1is present.GitHub Actions is optional; reproduce with Docker:
make docker-build-22 docker run --rm -v "$(pwd):/compiler" -w /compiler php-compiler:22.04-dev ./script/ci-local.shImplementation hints
vendor/bin/phpunit --group llvm --log-junit /tmp/llvm.xmlinsidephp-compiler:22.04-dev; inspect/tmp/llvm.xmlforJITTestskipped count.test/compliance/JITTest.php: extendsBaseTest; ensuresetUp()usesLlvmToolchain::isReady(dirname(__DIR__, 2))— same root asExampleWebAotTest.phpunit.xml.dist: confirm<env name="LD_LIBRARY_PATH" value="./.llvm"/>or thatscript/ci-local.shexportsLD_LIBRARY_PATHbefore PHPUnit (lines 32–37).test/bootstrap.php: mirror AOT bootstrap — callPHPLLVM\Chooser::choose()once and surface failure reason in skip message.script/check-jit-compliance-ran.php: already wired at end of llvm group inci-local.sh— keep as guard; do not weaken when fixing skips.PHP_COMPILER_ALLOW_JIT_SKIP=1for broken dev laptops only — document in Docs: Local CI matrix (host, Docker, GHA skips) in README #245 matrix, not default in Docker.Tasks
tests=forJITTest)LD_LIBRARY_PATH/PHP_COMPILER_LLVM_PATHpropagation into compliance subprocessesPHPLLVM\Chooser::choose()succeeds in Docker image (/opt/llvm9)test/unit/LlvmToolchainTest.phpassertion thatisReady()is true in CI image (optional).github/workflows/*jobs — local/Docker is canonical (Docs: Local CI matrix (host, Docker, GHA skips) in README #245, DevEx: make test-harness — canonical Runforge / empty bind-mount CI #272)Acceptance criteria
When
.llvm/libLLVM-9.so.1exists (or/opt/llvm9in 22.04-dev image):→ JUnit shows
JITTestcases executed (not 100% skipped);check-jit-compliance-ran.phpexits 0.Key files
test/compliance/JITTest.php,test/BaseTest.phplib/LlvmToolchain.php(if present) ortest/aot/AotTest.phppatternsscript/ci-local.sh,script/check-jit-compliance-ran.phpphpunit.xml.dist,test/bootstrap.phpRelated (de-duplicated)
make test-harness/docker-ci-local.shVerification (local only)
make test-docker # or harness: ./script/docker-ci-local.shNo GitHub Actions required to close this issue.