Skip to content / Aller au contenu
php127.hazyhaar.fr
Theme / Thème

Symfony and Composer on php127

WordPress and PrestaShop are applications; Symfony, Composer, Twig, PHPUnit and Laravel are the tools selected for the benches described here. On 2026-11-20 it was decided that making them work under php127 is part of the project's work, not an entry in a list of debts (decisions.md). This article describes the benches of revision 11f6d94 and distinguishes historical durations from the record for reference revision 5b31e86.

Composer

The acceptation/j4ecosysteme bench runs Composer 2.8.6, in the form of its composer.phar archive, on a stack of real libraries. Before anything else, it checks the installed versions: PHPUnit 10.5.38, nikic/php-parser 5.9.0, doctrine/dbal 4.6.0, monolog 3.13.0 and guzzlehttp/psr7 2.13.4. Then come four numbered cases, each played under PHP 8.3.6 and then under php127, whose output must be byte-for-byte identical:

  • composer --version, case 15;
  • composer about, case 16;
  • composer validate, case 17;
  • composer dump-autoload, case 18, played on a fresh copy of the stack for each runtime; the bench compares the exit code and standard streams, not the generated files (comparerExact).

Composer runs without network access (COMPOSER_DISABLE_NETWORK=1), with a home directory and a cache of its own for each run. The bench therefore plays neither composer install nor composer update against a package registry: it checks that Composer runs, reads a project and regenerates its autoloader, not that it fetches packages over the network.

The same bench covers other libraries. It runs Twig 3.30.0 and Symfony test suites, reads PHPUnit's XML configuration through DOM, and includes a Laravel 11 bench (version 11.57.1, with PHPUnit 11.5.58), which probes HTTP routing, Blade templates and the Eloquent ORM on SQLite.

Symfony

The acceptation/j6symfony bench runs the test suites of five Symfony 7.2 components: HttpFoundation, Console, DependencyInjection, Routing and Validator. For each component, the suite is played under PHP 8.3.6 and under php127, each on its own copy of the stack, and the status of every test, as recorded in the JUnit report, is compared on both sides. A test that passes under PHP 8.3.6 and fails under php127 is a discrepancy.

These five components were chosen and ordered on 2026-11-20: HttpFoundation, then Console, DependencyInjection, Routing and Validator. It was also decided to measure once on the head, then to make a single group of fixes per component, whose output names the test classes to be made to pass. The previous stage of the project, on the ecosystem, was sealed on 46 cases by agreement on the same day.

The team ran these internal benches with the following commands, quoted as a past method:

CGO_ENABLED=0 go test -count=1 ./acceptation/j4ecosysteme
CGO_ENABLED=0 go test -count=1 ./acceptation/j6symfony

It had the PHP 8.3.6 reference binary and the source corpora fixed by the benches; this description assumes no reader access to php127's code.

What is not right yet: run time

php127's main defect on Symfony is not a wrong result, it is time. On 2026-11-20, the test suite of the Routing component of Symfony 7.2.9 took 149 s under php127 against under one second under PHP 8.3.6; the Yaml suite took 116 s, and Twig's 58 s (constat-pratiques-performance.md). These durations were recorded after the fact, because no work output carried a duration at the time.

These figures are historical. The log for the node integrated as 5b31e86 (j9/c9_commande_ecarts_3.reprise.out.md.err) gives Routing as 23.178 s under php127 against 680 ms under PHP, with no status difference. This record does not establish a constant-protocol gain relative to the original 149 s observation.

In that same record, candidate durations for the five components range from 23.178 s to 1 min 13.521 s. The cost remains visible in these measurements, but they do not support a general duration for every application or by themselves settle suitability for a particular development loop.

Known discrepancies

The debt register (dettes.md) records the following historical observations at their stated dates; they are not new measurements of those functions on 5b31e86:

  • SplTempFileObject::eof() returns false after a read that goes past the content, where PHP 8.3.6 returns true; recorded on 2026-11-20 while working on HttpFoundation;
  • the Console test ProgressBarTest::testResumedTimeEstimation is unstable: it returns 2400.0 instead of 1200.0 when the one-second wait straddles two seconds, and passes on replay (2026-11-21);
  • the intl constants Spoofchecker::MIXED_NUMBERS and Spoofchecker::HIDDEN_OVERLAY, used by Validator, are 1 and 2 whereas the corresponding checks use 128 and 256 (2026-11-20);
  • getopt was reported missing on 2026-11-21 at 0:10, but is implemented in the code described as of 2026-11-21, revision 11f6d94, and in reference 5b31e86 (vm/getopt.go); this old debt does not establish that a tool using it will fail.

What this means for you

The results concern the Composer cases and Symfony suites named here, at the cited revisions and dates. Components absent from the benches gain no qualification from them. Durations remain above PHP's in the cited record. Comparing an application's own test statuses is the team's method for refining its observed behaviour; it does not guarantee cases that the suite does not exercise.

Lire en français