Category
stdlib · php-src-strict · follow-up to #21900
Problem
#21900 LLVM session I/O (JitSessionStorageKernel::emitSessionWireSaveToPath / emitSessionWireLoadFromPath) is enough for 005-SessionsWeb (flash|s:N:"…";) but:
- Load parses only the first
key|s:N:"val"; pair (no loop for concatenated pairs)
- Save only emits TYPE_STRING values from
strKeys (skips int/bool/null/array)
- No numeric-key /
i: / b: / N; wire coverage
| Surface |
#21900 |
Target |
$_SESSION['a']='x'; $_SESSION['b']='y' round-trip |
partial (first key only on load) |
full php session wire |
$_SESSION['n']=1 |
not saved |
`n |
php-src reference
PHP implementation target
ext/standard/JitSessionStorageKernel.php — loop wire load; emit int/bool/null (and ideally arrays via NestedJIT once #NEXT strlen fix lands)
- Or restore NestedJIT
VmSessionSerializer after NestedJIT string-length fix
Repro
./script/docker-exec.sh -- bash -lc 'source script/php-env.sh
cat > /tmp/multi.php << "PHP"
<?php
session_start();
$_SESSION["a"] = "one";
$_SESSION["b"] = "two";
$_SESSION["n"] = 3;
session_write_close();
PHP
php bin/compile.php -o /tmp/multi.bin /tmp/multi.php
SESSION_DIR=$(mktemp -d)
GATEWAY_INTERFACE=CGI/1.1 REQUEST_METHOD=GET PHP_COMPILER_SESSION_DIR="$SESSION_DIR" /tmp/multi.bin
cat "$SESSION_DIR"/sess_*
'
Done when
Category
stdlib· php-src-strict · follow-up to #21900Problem
#21900 LLVM session I/O (
JitSessionStorageKernel::emitSessionWireSaveToPath/emitSessionWireLoadFromPath) is enough for 005-SessionsWeb (flash|s:N:"…";) but:key|s:N:"val";pair (no loop for concatenated pairs)strKeys(skips int/bool/null/array)i:/b:/N;wire coverage$_SESSION['a']='x'; $_SESSION['b']='y'round-trip$_SESSION['n']=1php-src reference
ext/session/session.c— php_session_encode / decodeext/session/mod_php.c— serialize handlerPHP implementation target
ext/standard/JitSessionStorageKernel.php— loop wire load; emit int/bool/null (and ideally arrays via NestedJIT once #NEXT strlen fix lands)VmSessionSerializerafter NestedJIT string-length fixRepro
Done when
SessionsWebAotExecuteTeststill green; add unit/compliance for multi-key