Category
stdlib · php-src-strict · ext/intl Locale · pillar 4 · AOT
Problem
#20738 shipped VM/JIT compliance for Locale::canonicalize / parseLocale / composeLocale / getKeywords, but user-script AOT still hits JIT\Call\ExternalMethod for locale::canonicalize (null stub) and locale_canonicalize() throws JIT lowering not implemented.
| Repro |
Zend |
VM |
AOT (master after #20750) |
Locale::canonicalize('en-US') |
en_US |
en_US |
empty/null stub |
locale_canonicalize('en-US') |
en_US |
en_US |
compile fails (RuntimeException) |
php-src reference
Done when
Repro
./script/docker-exec.sh -- bash -lc 'source script/php-env.sh
export PHP_COMPILER_PROFILE=8.4 PHP_COMPILER_HELPER_RUNTIME_O=0
php bin/compile.php -o /tmp/c test/repro/issue_XXXX_locale_canonicalize_aot.php && /tmp/c'
Category
stdlib· php-src-strict · ext/intl Locale · pillar 4 · AOTProblem
#20738 shipped VM/JIT compliance for
Locale::canonicalize/parseLocale/composeLocale/getKeywords, but user-script AOT still hitsJIT\Call\ExternalMethodforlocale::canonicalize(null stub) andlocale_canonicalize()throwsJIT lowering not implemented.Locale::canonicalize('en-US')en_USen_USlocale_canonicalize('en-US')en_USen_USphp-src reference
ext/intl/locale/locale_methods.c—locale_canonicalizeLocaleParserJitHelper+lib/JIT/Builtin/LocaleParser.php(Stdlib: locale_get_primary_language/region/script — not registered on PHP_COMPILER_PROFILE=8.4 (re-#5125, ext/intl/locale_methods.c) #17072 / php-in-php: drop UserScriptAotDeferNestedJit from LocaleParser — always JitVmHelperLink + LocaleParserJitHelper (#1492) #20101)Done when
Locale::canonicalize('en-US')andlocale_canonicalize('en-US')→en_USunderphp bin/compile.php -o … && ./binary(PROFILE=8.4)LocaleParserJitHelper/JitLocaleParser+ registerlocale::canonicalizeproxyRepro