Skip to content

Reduce expensive test fixtures - #22950

Draft
NickSdot wants to merge 3 commits into
php:masterfrom
NickSdot:perf/reduce-expensive-test-fixtures
Draft

Reduce expensive test fixtures#22950
NickSdot wants to merge 3 commits into
php:masterfrom
NickSdot:perf/reduce-expensive-test-fixtures

Conversation

@NickSdot

@NickSdot NickSdot commented Jul 30, 2026

Copy link
Copy Markdown
Contributor

Extracted from #22917.

Reduces deliberately expensive test inputs where their original size or cost is not part of the tested behaviour. Password tests use lower valid work factors without changing production defaults or algorithm coverage. Phar fixtures remain above the historical regression boundary, and the passthrough test uses a deterministic 256 KiB pattern containing every byte value.

Result

Values in seconds; measured on macOS.

mode master this PR saved speedup
-j1 18.105 3.784 14.321 4.78×
-j10 7.911 1.604 6.307 4.93×

Reproduction:

sapi/cli/php run-tests.php -q -j10 \
    ext/phar/tests/bug13727.phpt \
    ext/phar/tests/phar_buildfromiterator10.phpt \
    ext/sodium/tests/php_password_hash_argon2i.phpt \
    ext/sodium/tests/php_password_hash_argon2id.phpt \
    ext/sodium/tests/php_password_verify.phpt \
    ext/standard/tests/file/bug22414.phpt \
    ext/standard/tests/password/password_hash.phpt \
    ext/standard/tests/password/password_hash_argon2.phpt \
    ext/standard/tests/password/password_removed_salt_option.phpt \
    ext/standard/tests/strings/crypt_chars.phpt

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant