Skip to content

Make native parser extension visible#407

Merged
adamziel merged 1 commit into
trunkfrom
adamziel/show-native-extension
May 26, 2026
Merged

Make native parser extension visible#407
adamziel merged 1 commit into
trunkfrom
adamziel/show-native-extension

Conversation

@adamziel
Copy link
Copy Markdown
Collaborator

@adamziel adamziel commented May 26, 2026

What changed

Reorganizes the root README so Quick start stays first and the optional Native MySQL Parser Extension is discoverable without taking over the landing flow. The README links to the GitHub Pages landing page with the published WASM release list, manifest links, “Run in Playground” buttons, and native extension details.

Also expands packages/php-ext-wp-mysql-parser/README.md with local build/load instructions, WASM artifact details, checksum verification steps, and benchmark commands. The benchmark scripts now run cleanly on PHP 8.4+, can emit JSON, report exact processed counts, and the parser benchmark goes through the integration loader so php -d extension=... measures the native parser path instead of accidentally staying on the pure-PHP classes.

Why

The native extension and WASM artifacts were hard to discover. This keeps the normal README quick start prominent while giving users a clear path to optional native-extension docs, Playground links, and reproducible benchmark commands.

Self-review fixes

  • Fixed benchmark query counts to use an explicit processed counter instead of loop-index arithmetic.
  • Fixed run-parser-benchmark.php to include the first query and to load through src/load.php, matching runtime native-vs-PHP class selection.
  • Tightened docs so build commands do not leave readers in the package directory before repository-root verification commands.
  • Added checksum verification commands and refreshed benchmark numbers, including native parser results.

Related Pages work

Validation

  • composer validate --no-check-all
  • php -l packages/mysql-on-sqlite/tests/tools/run-lexer-benchmark.php
  • php -l packages/mysql-on-sqlite/tests/tools/run-parser-benchmark.php
  • php -l packages/mysql-on-sqlite/tests/tools/run-native-extension-benchmark.php
  • php packages/mysql-on-sqlite/tests/tools/run-lexer-benchmark.php --json --limit=100
  • php packages/mysql-on-sqlite/tests/tools/run-parser-benchmark.php --json --limit=100
  • php packages/mysql-on-sqlite/tests/tools/run-native-extension-benchmark.php --json --limit=100
  • php -d extension=/path/to/libwp_mysql_parser.dylib packages/mysql-on-sqlite/tests/tools/run-native-extension-benchmark.php --json --limit=100
  • php -d extension=/path/to/libwp_mysql_parser.dylib packages/mysql-on-sqlite/tests/tools/run-parser-benchmark.php --json --limit=100
  • Full benchmark rerun for published numbers: lexer PHP, parser PHP, native lexer, native parser.
  • npx @wp-playground/cli@latest run-blueprint --php=8.4 --php-extension=https://wordpress.github.io/sqlite-database-integration/wp_mysql_parser-wasm-extension/latest/manifest.json --blueprint=https://wordpress.github.io/sqlite-database-integration/native-extension/blueprint.json --verbosity=quiet

Note: composer run check-cs could not run in this workspace because vendor/bin/phpcs is not installed locally; CI runs it with dependencies installed.

@adamziel adamziel force-pushed the adamziel/show-native-extension branch from be04923 to b3ee23f Compare May 26, 2026 19:07
@adamziel adamziel changed the base branch from develop to trunk May 26, 2026 19:07
@adamziel adamziel force-pushed the adamziel/show-native-extension branch 3 times, most recently from 5b68210 to 797ba0c Compare May 26, 2026 20:19
@adamziel adamziel marked this pull request as ready for review May 26, 2026 20:33
@adamziel adamziel force-pushed the adamziel/show-native-extension branch from 797ba0c to 849df13 Compare May 26, 2026 21:40
@adamziel adamziel merged commit e551393 into trunk May 26, 2026
33 checks passed
@adamziel adamziel deleted the adamziel/show-native-extension branch May 26, 2026 21:56
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant