Skip to content

AOT: mb_detect_encoding() NestedJIT for runtime strings (#34358) - #34360

Closed
PurHur wants to merge 1 commit into
masterfrom
agent/issue-34358-mb-detect-encoding-runtime
Closed

PurHur wants to merge 1 commit into
masterfrom
agent/issue-34358-mb-detect-encoding-runtime

Conversation

@PurHur

@PurHur PurHur commented Aug 24, 2026

Copy link
Copy Markdown
Owner

Summary

php-src: ext/mbstring/mbstring.c — PHP_FUNCTION(mb_detect_encoding).

Test plan

  • ./script/aot-smoke.sh → 8 passed, 0 failed
  • Repro (Zend/VM/AOT match):
    UTF-8
    UTF-8
    ASCII
    
    ./script/docker-exec.sh -- bash -lc 'php bin/vm.php test/repro/aot_mb_detect_encoding_runtime.php'
    ./script/docker-exec.sh -- bash -lc 'php bin/compile.php -o /tmp/det.bin test/repro/aot_mb_detect_encoding_runtime.php && /tmp/det.bin'
  • ./script/phpunit.sh --filter MbDetectEncodingRuntimeAotTest → OK (2 tests, 11 assertions)
  • php script/check-selfhost-spine-coverage-sync.php → OK (7876/7876)

Not run: full differential sweep, north-star5-verify-fast, compliance suites.

Made with Cursor

Thin AOT no longer throws LogicException on runtime haystack or literal
encodings-list calls — MbDetectEncodingJitHelper mirrors Zend detect order
without VmMbstring. php-src: ext/mbstring/mbstring.c PHP_FUNCTION(mb_detect_encoding).

Co-authored-by: Cursor <cursoragent@cursor.com>
@PurHur

PurHur commented Aug 24, 2026

Copy link
Copy Markdown
Owner Author

Superseded by #34359 already merged on master — duplicate NestedJIT mb_detect_encoding fix.

@PurHur PurHur closed this Aug 24, 2026
@PurHur
PurHur deleted the agent/issue-34358-mb-detect-encoding-runtime branch September 1, 2026 23:21
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.

AOT: mb_detect_encoding() refuses runtime strings — LogicException 1-arg NestedJIT (leftover of #3075, ext/mbstring/mbstring.c)

1 participant