[Docs] (P13): a matched P12/P13 FCL soak shows the silent death's rate does not depend on the MobileGL library, and the W6 progress is recorded.

This commit is contained in:
2026-10-06 19:23:08 -04:00
parent 737ef5e980
commit 5011c3d868
5 changed files with 115 additions and 1 deletions
+6
View File
@@ -25,6 +25,12 @@
| W5 S5 | 本地完成 | `b13af729` `b1978890` | 记录臂三旋钮进 `RecordArmTable`;`DataArmIsRecord` / `RecordArmAliasesFrontend`、`MonolithTakesRecordArm`、`MOBILEGL_PIPE_DATA_ARM` 跟 `RECORD_ARM`(不再跟传输) |
| W5 S6 | 本地完成 | `dd7fbbd7` | 集成 peek 在无传输构建里也答 `dataArmIsRecord`;跟踪器探针跟 `RECORD_ARM` |
| W5 S7 | 本地完成(CI 待跑) | `19610290` `23593c9f`…`e9a353c3` | **翻转**:`MOBILEGL_BUILD_RECORD_ARM` 恒 ON,无 MG_Remote 的库(FCL 形态)也跑记录臂。`MOBILEGL_PIPE_PERSISTENT_MPROTECT=0` 关掉跟踪器的 SIGSEGV 处理器(FCL 是 JVM;启动打日志;单元 `TheMprotectSwitchSendsEveryNewMapToTheHashScan`),mprotect 臂只在 Linux / Android 编。`runtime_mode_proof` 加正半:两形态都要 `MG_Record` 符号(push 294、split 300),自测含两条无 `MG_Record` 的红例。翻转后 push 单元暴露的残留误分类(记录动词的 verb 状态盖章、按记录读的顶点 / IBO / 绑定点 / 采样器路径、XFB 捕获回落、视图窗口 mip、镜像可绑定重铸、暂存库跟随、跟踪器成员资格、测试的前端臂钉)全部改跟 `RECORD_ARM`;push 单元 2028/2028 |
| W5 S8 | 已推(CI 37515697754:382 绿、2 红均已归类并修) | `7fb18840` `c1e985c8` | `MOBILEGL_BUILD_RECORD_ARM` 被 unifdef 掉,`retired_switches` 禁止它回到 `#if`。verify 车道的阴性对照 B 改省略 `ReadPixels:GetPixelStoreParameters`(monolith 记录臂不再读 GenerateMipmap 的活动单元);monolith 启动时记一行数据臂 |
| W6a | 已推(`887547c7`,CI 37534648608 / 37534648624) | `d61a4240` `740dd301` | 记录臂是唯一数据臂:`DataArmIsRecord()` 恒 true(constexpr),`MOBILEGL_PIPE_DATA_ARM` / `InitDataArm` / `ScopedMonolithFrontendArm` 删;`HandleRecycle.AbaControlHandles` 车道退役;立方面读回两条规则移到 `CubeFaceReadbackScenario` |
| W6b | 已推(同上) | `742d43ae` `e0113503` `3aed7ae0` `e822c933` | 数据臂谓词从两后端所有分支折掉,记录臂 return 之后的前端臂代码删;XFB 角色状态只留一份;10 个前端臂单元用例删(逐条记入 `docs/ci/ci-cleanup-log.md`),两条 GL 采样规则移到 `TextureUnitSamplingScenario` |
| W6c | 本地完成 | `dc1e95b4` | Magma 前端臂:前端 `MagmaProgramSource` 构造与 `IsWire()` 折掉,前端采样集遍历、占位纹理、VAO draw memo、`MagmaPipeIdentityTables` 与 ABA 旋钮、`TrySetupDrawFastPath` 与快照、前端 fallback 纹理删(约 7100 行) |
| W6d | 本地完成 | `8abae647` `8bc39c79` | Espryt 各族臂谓词(framebuffer / texture / sampler / program / buffer / vertex input 及其别名)折为记录臂,`g_fboTextureSyncList` 等前端遍历删;启动时只查色彩附件上限(`ResolveRecordArmFamilies`);未迁移仿真名单清空(审计保留,守 0) |
| W6e | 本地完成 | `dab827d5` `737ef5e9` | 后端表里 verb port 在各模式都覆盖的前端对象入口(`ClearNamedFramebuffer*`、`BlitNamedFramebuffer`、`GetTex(ture)Image`、`MultiDrawElements`)及其实现删;Magma 前端 render pass、pending clear、renderbuffer 半边删。link ratchet 171 → 58,`# P13` 95 → 11(余下 11 条:Espryt 以前端对象铸句柄的 slot 表入口与 apply 线程拒绝函数 7 条、`PipeInputs` 访问器 3 条、FBO 附件 `IsComplete` 1 条) |
### G1 退役读数(ID-P13-4,2026-10-06)
@@ -42,6 +42,18 @@ after (or do not reset that signal). Left for the user.
| clean (`soak-p13-clean-summary.txt`, `soak2.sh` with the SigCgt sampler and per-run ftrace) | P13 FCL lib at `c1e985c8` | 30 (22 Magma, 8 Espryt) | 18: Magma 13/22, Espryt 5/8 |
| P12 control (`soak-p12-control-summary.txt`) | P12 end `743f4e8e` | 10 Magma | 2 |
| matched A/B (`soak-ab-p12-p13-summary.txt`, `soak3.sh`): P12 and P13 libraries alternated launch by launch, Magma, same world, settings and network window, 40 s in-world | P12 `743f4e8e` / P13 `c1e985c8` | 10 + 10 | P12 4/10, P13 2/10 |
**Does the P13 library raise the rate?** No evidence it does. The clean soak's 18/30 against the
first P12 control's 2/10 was not a comparable pair: the two ran at different times (the rate tracks
whether FCL's background request is still pending, i.e. network conditions), and the P12 control
overlapped the contaminated P13 runs below. In the matched, interleaved A/B the P12 library died
more often (4/10) than the P13 one (2/10). The timeline is library-independent too: in every death
logcat FCL's `Renderer:` line is followed by the JVM's signal reset after 0.2-0.6 s and by
MobileGL's first log line after about 6.2 s for both libraries (P12 deaths: 6.3 s and 6.2 s), and
the late deaths land at a fixed ~9.4 s after the `Renderer:` line on both libraries - a timeout
started before MobileGL is loaded, not a window MobileGL's start-up widens.
Earlier P13 runs (first 5-run soak) are not counted: two soak scripts were found driving the
phone at once and force-stopping each other's runs; `soak2.sh` now takes a lock.
@@ -0,0 +1,22 @@
# run backend result mgl arm inworld deathTime exit sig34CaughtAtLaunch sig34CaughtInGame firstUncaught firstMGL ftraceFatal34 tomb+ kgsl
1 p12 ok mgl=3 arm=? inworld=0 death=- exit=[reason=10 (USER REQUESTED) reason=21 (FORCE STOP) status=0 ] launch34=yes game34=no firstUncaught=06:52:04.390 firstMGL=06:53:18.552 sig34gen/deliv=0/0 tomb+=0 kgsl=0
2 p13 ok mgl=310 arm=record inworld=9 death=- exit=[reason=10 (USER REQUESTED) reason=21 (FORCE STOP) status=0 ] launch34=yes game34=no firstUncaught=06:53:36.454 firstMGL=06:53:25.896 sig34gen/deliv=0/0 tomb+=0 kgsl=0
3 p12 ok mgl=284 arm=? inworld=9 death=- exit=[reason=10 (USER REQUESTED) reason=21 (FORCE STOP) status=0 ] launch34=yes game34=no firstUncaught=06:55:08.172 firstMGL=06:54:58.992 sig34gen/deliv=0/0 tomb+=0 kgsl=0
4 p13 ok mgl=310 arm=record inworld=9 death=- exit=[reason=10 (USER REQUESTED) reason=21 (FORCE STOP) status=0 ] launch34=yes game34=no firstUncaught=06:56:47.522 firstMGL=06:56:37.813 sig34gen/deliv=0/0 tomb+=0 kgsl=0
5 p12 ok mgl=284 arm=? inworld=9 death=- exit=[reason=10 (USER REQUESTED) reason=21 (FORCE STOP) status=0 ] launch34=yes game34=no firstUncaught=06:58:11.427 firstMGL=06:58:01.955 sig34gen/deliv=0/0 tomb+=0 kgsl=0
6 p13 ok mgl=310 arm=record inworld=9 death=- exit=[reason=10 (USER REQUESTED) reason=21 (FORCE STOP) status=0 ] launch34=yes game34=no firstUncaught=06:59:44.626 firstMGL=07:00:03.119 sig34gen/deliv=0/0 tomb+=0 kgsl=0
7 p12 ok mgl=284 arm=? inworld=9 death=- exit=[reason=10 (USER REQUESTED) reason=21 (FORCE STOP) status=0 ] launch34=yes game34=no firstUncaught=07:01:18.188 firstMGL=07:01:08.751 sig34gen/deliv=0/0 tomb+=0 kgsl=0
8 p13 ok mgl=310 arm=record inworld=9 death=- exit=[reason=10 (USER REQUESTED) reason=21 (FORCE STOP) status=0 ] launch34=yes game34=no firstUncaught=07:02:50.811 firstMGL=07:03:27.619 sig34gen/deliv=0/0 tomb+=0 kgsl=0
9 p12 ok mgl=284 arm=? inworld=9 death=- exit=[reason=10 (USER REQUESTED) reason=21 (FORCE STOP) status=0 ] launch34=yes game34=no firstUncaught=07:04:24.047 firstMGL=07:04:14.084 sig34gen/deliv=0/0 tomb+=0 kgsl=0
10 p13 DIED mgl=310 arm=record inworld=0 death=07:07:09.837 exit=[reason=2 (SIGNALED) reason=0 (UNKNOWN) status=34 ] launch34=yes game34=no firstUncaught=07:05:56.650 firstMGL=07:06:50.825 sig34gen/deliv=1/0 tomb+=0 kgsl=0
11 p12 DIED mgl=284 arm=? inworld=0 death=07:07:37.670 exit=[reason=2 (SIGNALED) reason=0 (UNKNOWN) status=34 ] launch34=yes game34=yes firstUncaught=07:07:28.471 firstMGL=07:07:18.998 sig34gen/deliv=3/2 tomb+=0 kgsl=0
12 p13 ok mgl=3 arm=? inworld=0 death=- exit=[reason=10 (USER REQUESTED) reason=21 (FORCE STOP) status=0 ] launch34=yes game34=no firstUncaught=07:09:01.657 firstMGL=07:10:14.637 sig34gen/deliv=0/0 tomb+=0 kgsl=0
13 p12 DIED mgl=4 arm=? inworld=0 death=07:10:33.932 exit=[reason=2 (SIGNALED) reason=0 (UNKNOWN) status=34 ] launch34=yes game34=yes firstUncaught=07:10:33.186 firstMGL=07:10:23.982 sig34gen/deliv=2/1 tomb+=0 kgsl=0
14 p13 ok mgl=310 arm=record inworld=9 death=- exit=[reason=10 (USER REQUESTED) reason=21 (FORCE STOP) status=0 ] launch34=yes game34=no firstUncaught=07:12:05.450 firstMGL=07:11:56.252 sig34gen/deliv=0/0 tomb+=0 kgsl=0
15 p12 ok mgl=284 arm=? inworld=9 death=- exit=[reason=10 (USER REQUESTED) reason=21 (FORCE STOP) status=0 ] launch34=yes game34=no firstUncaught=07:13:49.067 firstMGL=07:13:38.913 sig34gen/deliv=0/0 tomb+=0 kgsl=0
16 p13 ok mgl=310 arm=record inworld=9 death=- exit=[reason=10 (USER REQUESTED) reason=21 (FORCE STOP) status=0 ] launch34=yes game34=no firstUncaught=07:15:09.245 firstMGL=07:14:59.248 sig34gen/deliv=0/0 tomb+=0 kgsl=0
17 p12 DIED mgl=4 arm=? inworld=0 death=07:17:11.665 exit=[reason=2 (SIGNALED) reason=0 (UNKNOWN) status=34 ] launch34=yes game34=yes firstUncaught=07:16:39.632 firstMGL=07:17:00.892 sig34gen/deliv=3/2 tomb+=0 kgsl=0
18 p13 DIED mgl=310 arm=record inworld=9 death=07:18:27.221 exit=[reason=2 (SIGNALED) reason=0 (UNKNOWN) status=34 ] launch34=yes game34=yes firstUncaught=07:18:10.349 firstMGL=07:18:01.124 sig34gen/deliv=3/2 tomb+=0 kgsl=0
19 p12 DIED mgl=288 arm=? inworld=9 death=07:19:57.934 exit=[reason=10 (USER REQUESTED) reason=21 (FORCE STOP) status=0 ] launch34=yes game34=yes firstUncaught=07:19:41.110 firstMGL=07:19:31.642 sig34gen/deliv=1/0 tomb+=0 kgsl=0
20 p13 ok mgl=310 arm=record inworld=9 death=- exit=[reason=10 (USER REQUESTED) reason=21 (FORCE STOP) status=0 ] launch34=yes game34=no firstUncaught=07:21:11.922 firstMGL=07:21:02.057 sig34gen/deliv=0/0 tomb+=0 kgsl=0
soak done
@@ -0,0 +1,74 @@
#!/bin/bash
# soak3.sh <pairs> <secs>: matched A/B, alternating the P12 and P13 FCL libraries on Magma (same world, settings, network window).: FCL launch soak (ONE instance at a time - it takes a
# lock) with diagnostics, plus a device-side sampler of the FCL process's caught-signal mask (SigCgt), so a
# death by signal 34 can be tied to whether bionic/libcore's SIGRTMIN+2 handler is still installed.
export MSYS_NO_PATHCONV=1
NP=${1:-10}; SECS=${2:-40}
BASE=${SOAK_DIR:?set SOAK_DIR}
LOCK=/c/Users/yello/AppData/Local/Temp/claude/C--Users-yello-AndroidStudioProjects-FoldCraftLauncher-MobileGL/0e0e570f-5721-41d8-9d0f-80fcde638a84/scratchpad/soak.lock
if ! mkdir "$LOCK" 2>/dev/null; then echo "another soak holds $LOCK"; exit 1; fi
trap 'rmdir "$LOCK"' EXIT
mkdir -p "$BASE"
PKG=com.tungsten.fcl.mgdebug.debug
CFG=/data/data/$PKG/files/config.json
SUM=$BASE/summary.txt
echo "# run backend result mgl arm inworld deathTime exit sig34CaughtAtLaunch sig34CaughtInGame firstUncaught firstMGL ftraceFatal34 tomb+ kgsl" >> "$SUM"
adb logcat -G 16M >/dev/null 2>&1
# The sampler: every 0.5 s, "<time> <pid> <SigCgt>" for the package's main process.
adb shell "su -c 'cat > /data/local/tmp/p13/sigsample.sh'" <<'EOS'
end=$(( $(date +%s) + $1 ))
while [ $(date +%s) -lt $end ]; do
p=$(pidof com.tungsten.fcl.mgdebug.debug | cut -d" " -f1)
if [ -n "$p" ]; then echo "$(date +%H:%M:%S.%N | cut -c1-12) $p $(grep SigCgt /proc/$p/status | cut -f2)"; fi
sleep 0.5
done
EOS
order=""
for i in $(seq 1 $NP); do order="$order p12 p13"; done
idx=0
for be in $order; do
idx=$((idx+1))
lvl=$(adb shell dumpsys battery | grep level | tr -dc 0-9)
if [ "${lvl:-100}" -lt 40 ]; then echo "battery $lvl - stopping" >> "$SUM"; break; fi
OUT=$BASE/run$(printf %03d $idx)-$be; mkdir -p "$OUT"
C=cfg-magma.json
LIBDIR=$(adb shell "su -c 'ls -d /data/app/*/$PKG*/lib/arm64'" | tr -d '␍')
adb shell "su -c 'am force-stop $PKG; cat /data/local/tmp/p13/$C > $CFG; cat /data/local/tmp/p13/lib-$be.so > $LIBDIR/libMobileGL.so'"
adb shell "su -c 'ls /data/tombstones | wc -l'" > "$OUT/tomb-before.txt"
adb shell "su -c 'dmesg -c >/dev/null 2>&1; echo > /sys/kernel/tracing/trace'"
adb logcat -b all -c
adb shell "svc power stayon true; wm dismiss-keyguard" >/dev/null 2>&1
adb shell "su -c 'sh /data/local/tmp/p13/sigsample.sh $((SECS + 40))'" > "$OUT/sigcgt.txt" 2>&1 &
SAMP=$!
sleep 1
adb shell monkey -p $PKG -c android.intent.category.LAUNCHER 1 >/dev/null 2>&1
sleep $((SECS + 45))
wait $SAMP 2>/dev/null
adb exec-out screencap -p > "$OUT/screen.png"
adb logcat -b all -d > "$OUT/logcat.txt"
adb shell "su -c 'dmesg'" > "$OUT/dmesg.txt" 2>/dev/null
adb shell "su -c 'cat /sys/kernel/tracing/trace'" > "$OUT/ftrace.txt" 2>/dev/null
adb shell "dumpsys activity exit-info $PKG" > "$OUT/exitinfo.txt" 2>/dev/null
adb shell "su -c 'ls /data/tombstones | wc -l'" > "$OUT/tomb-after.txt"
adb shell "su -c 'am force-stop $PKG'"
died=$(grep -ac "Process $PKG (pid [0-9]*) has died" "$OUT/logcat.txt")
mgl=$(grep -ac " MobileGL" "$OUT/logcat.txt")
arm=$(grep -ao "monolith data arm = [a-z]*" "$OUT/logcat.txt" | head -1 | awk '{print $NF}')
inworld=$(grep -ac "Server thread\|Preparing spawn area\|Loaded [0-9]* advancements\|joined the game" "$OUT/logcat.txt")
firstmgl=$(grep -a " MobileGL" "$OUT/logcat.txt" | head -1 | cut -c7-18)
deatht=$(grep -a "Process $PKG (pid [0-9]*) has died" "$OUT/logcat.txt" | head -1 | cut -c7-18)
ex=$(grep -aE "reason=" "$OUT/exitinfo.txt" | head -1 | grep -oE "reason=[0-9]+ \([A-Z_ ]+\)|status=[0-9]+" | tr '\n' ' ')
# SigCgt bit 33 = signal 34 (SIGRTMIN+2, libcore's async-close wakeup).
bit() { [ -z "$1" ] && { echo "?"; return; }; [ $(( (0x$1 >> 33) & 1 )) -eq 1 ] && echo yes || echo no; }
launchMask=$(grep -aE "^[0-9:.]+ [0-9]+ [0-9a-f]{16}" "$OUT/sigcgt.txt" | head -1 | awk '{print $3}')
gameMask=$(grep -aE "^[0-9:.]+ [0-9]+ [0-9a-f]{16}" "$OUT/sigcgt.txt" | sed -n 60p | awk '{print $3}')
firstUn=$(grep -aE "^[0-9:.]+ [0-9]+ [0-9a-f]{16}" "$OUT/sigcgt.txt" | while read t p m; do [ "$(bit $m)" = no ] && { echo $t; break; }; done)
# A sig 34 generated toward the package with no matching delivery = the kernel's fatal fast path.
gen=$(grep -ac "signal_generate: sig=34" "$OUT/ftrace.txt"); del=$(grep -ac "signal_deliver: sig=34" "$OUT/ftrace.txt")
tb=$(( $(tr -dc 0-9 < "$OUT/tomb-after.txt") - $(tr -dc 0-9 < "$OUT/tomb-before.txt") ))
kg=$(grep -aciE "kgsl.*(fault|hang|recover|snapshot)|adreno.*fault" "$OUT/dmesg.txt")
res=ok; [ "$died" -gt 0 ] && res=DIED
echo "$idx $be $res mgl=$mgl arm=${arm:-?} inworld=$inworld death=${deatht:--} exit=[$ex] launch34=$(bit "$launchMask") game34=$(bit "$gameMask") firstUncaught=${firstUn:--} firstMGL=${firstmgl:--} sig34gen/deliv=$gen/$del tomb+=$tb kgsl=$kg" >> "$SUM"
done
adb shell "svc power stayon false"
echo "soak done" >> "$SUM"