Files
xteink-web-emulator/ISSUES.md
T
evan 080a264b5c perf(web): disable icount by default (4.7x faster book open)
icount throttled TCG and starved the guest watchdog. Measured book open dropped from 146s to 31s. Off by default; ?icount restores it, ?noicount removed in favor of the new default. Harness now reports open-file timing.
2026-07-21 20:19:46 -04:00

3.7 KiB

Known Issues

Resolved: directory-backed SD reads corrupted WASM state

Opening /Test/example.txt through QEMU vvfat could corrupt coroutine/guest state. The browser now builds a standards-compliant 64 MiB FAT32 image from OPFS and mounts it as a raw block device, bypassing the failing host-file mapping path. The official CrossPoint 1.4.1 firmware can traverse Test/example.txt without a WASM trap or guest panic.

Resolved: SD card remained in receivingdata

ssi-sd consumed a write-data token while leaving response mode, then parsed payload bytes as commands. The adapter now enters token mode immediately after the final R1 byte. SPI CMD13 also uses the upstream-correct sd_r1 internal response so status polling no longer loops on Unexpected response to cmd 13.

Upstream limitation: compiled wasm32 store path (perf ceiling)

Opening a book panics only in WASM (Invalid read ... reason: rejected → Load access fault) inside uzlib_uncompress during the reader's font prewarmCache if compiled guest stores are enabled. Native QEMU from the same submodule renders fine.

Root cause (confirmed by full diff against pristine upstream): wasm_tci_only_tb = true in tcg_out_qemu_st is upstream qemu-wasm's own design. Upstream forces every store-containing TB to the TCI interpreter because its compiled restartable-block store path is not rewind-safe (a yielded softmmu helper replays the block; safe for loads, corrupting for stores). Font inflate is store-heavy, so that hot loop never JIT-promotes — a real but secondary perf ceiling.

Remaining fix is to make compiled stores rewind-safe and drop the blanket TCI — a substantial TCG-backend task, ~15 min per browser iteration, no native repro. Full analysis: docs/wasm-inflate-panic.md.

Resolved: -icount throttled book open ~4.7x

The browser ran with -icount shift=auto,align=off,sleep=off, which serialized TCG and starved the guest watchdog (the earlier wdt timeout panics). Measured book open: 146s with icount, 31s without. icount is now off by default in web/app.js; ?icount restores it. Guest timekeeping tracks host wall-clock, which is fine here because running flat-out feeds the watchdog faster, not slower.

Resolved: reader grayscale rendered inverted and muddled

The reader drew a crisp BW page, then a 4-level grayscale antialiasing pass (inverted plane polarity, near-empty planes) that the old model rendered as a full frame, wiping the page to an inverted muddle. The xteink_x3_eink model now keeps a persistent surface, identifies known BW and grayscale modes by exact comparison of the complete loaded LUT bank, and treats grayscale level 0 as no-drive (keep pixel) so only antialiased edges repaint over the retained BW page. Unknown LUTs are logged and skipped instead of guessed from pixel content. Reader text renders sharp on native and wasm.

Resolved: cold boot required a manual power-button hold

The browser now presses power after the panel's initial frame, releases it on the next frame (the Booting screen), and only then enables controls. This mirrors the previously reliable browser-test sequence without relying on a wall-clock delay. The browser test no longer presses power itself, proving cold boot is automatic. The preceding NVS NOT_FOUND messages remain expected first-boot initialization noise.

WASM heap balloons after watchdog reboot

The committed WASM heap starts near 176.3 MiB but can grow to approximately 631.8 MiB after the watchdog reboot described above.

This indicates translated-block or dynamic WebAssembly module state is retained across guest reboot. TB cleanup must release old dynamic instances during reset; reboot-time growth should remain bounded.