Bumps the qemu gitlink from 133f91266b to 94754705d1, 62 commits of a review of the fork against smh/master 3403936c99: 29 defects fixed (QBUG-1..27) and 49 reductions, among them the wasm64 translator and the DSP fast loops moved into .c.inc files of their own, R5 on wasm64 only, the bswap and inverted-operand emitters through TCG's generic expansion and the never-taken general 35BE iteration gone. git diff --stat against 3403936c99: +19,802/-519 -> +18,722/-377. Whole candidate against 133f91266b, free-run: towerblox +1.5 %, bobby +1.7 %, midi +0.7 %, video MIPS -0.5 % (12 rounds, se ~0.35); S75 and KE970 boots within noise. stopwatch, music, idle and the EL71 boot were not measured: EL71v41lg91.bin was missing from the container. doc/version-pins.md has the entry, doc/wasm-fast-paths.md the changed rows, the marking and "Returned to upstream", and doc/performance.md the History row and a "2026-11-21 review cleanup" section with the numbers. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
40 KiB
Submodule bump history
What the qemu and bsp submodules were bumped to and why, by date, newest
first. Since 2026-11-14 the gitlinks are the pins: versions.env is gone,
scripts/build-release.sh builds exactly the gitlinks, and the toolchain
versions live in scripts/build-deps.sh. Before that the pins were
QEMU_PMB887X_REV and PMB887X_BSP_REV in versions.env, and these lists
were its comment block. Figures are as measured at the time.
The qemu source
Pinning for the qemu-pmb887x wasm build.
The qemu source is the root-level qemu/ submodule (Azq2/qemu-pmb887x, branch wasm-browser-port, which tracks origin/wasm-browser-port): the whole wasm/TCI/perf series committed on top of siemens-mobile-hacks/qemu-pmb887x master, which is merged in regularly (the DSP LLE reached master from its dsp-lle branch). (The former patches/*.patch files were removed on 2026-09-12; the commits are the series.) The pmb887x-emu meta-repo is checked out alongside at master; its own qemu submodule is not used (the root qemu/ submodule is the build source), but the repo is where the page's Siemens module comes from: the siemensfw library (src/siemens) that scripts/build-recalc-wasm.sh compiles -- key recalculation, ESN recovery and the Siemens half of device detection (probeFullflash).
Why the series was based on dsp-lle before the DSP LLE reached master: master alone aborted every Siemens fullflash during L1 GSM frame handling (">>EXIT<< FILE: l1bbcsg") unless it carried the "hacky AFE (LLE+HLE)" commit from dsp-stuff; dsp-lle ran the real DSP firmware instead, which also gave the Siemens boards sound.
qemu (the qemu/ gitlink; QEMU_PMB887X_REV before 2026-11-14)
94754705d1(2026-11-21) review of the fork against smh/master 3403936c99 (29 defects, 49 reductions). Fixed: an inlined call after a cross-page absorbed branch broketb->size(QBUG-1), the fill-time TLB grow lost the large-page record (QBUG-2), a deferred MMIO BQL hold that nothing bounded without icount or vcpu-timers (QBUG-3), GPTU T012RUN not re-arming T0/T1 (QBUG-4), back-edges across an instruction-set switch (QBUG-5), superblocks under memory timing (QBUG-6), the back-edge's instruction count before its budget exit (QBUG-7), next-TB cache fills for memory-timed TBs and under breakpoints (QBUG-10), a screendump resumed on the vCPU thread (QBUG-13), an uninitialised dif_v2 read (QBUG-16), the DSP chain memo across frees (QBUG-17), leaks of evicted batches' records and abandoned translations' interpreter records and the 32 MB record store (QBUG-24..26), the batch state per thread (QBUG-27), and stale comments. Closer to upstream: the wasm64 translator and the DSP fast loops in.c.incfiles of their own (translate.c's deviation 1,904 -> 273 lines, dsp/tcg.c's 2,863 -> 1,261), R5 on wasm64 only, the bswap and inverted-operand emitters through TCG's generic expansion, the general 35BE iteration gone (a census: never taken), lab-notebook comments trimmed.git diff --stat 3403936c99: +19,802/-519 -> +18,722/-377 (in upstream's own files +11,002/-519 -> +7,745/-377; ~2,900 lines moved into fork-owned files). Priced and kept: C5 (towerblox -15.4 % without it), A7's deferral (towerblox -3.1 %, video -4.9 %), the C6 stash (S75 boot audio +3..19 % without it), C1's per-piece loops (video -1.7 %), P7/P8/the 14/15 arm (midi -3.6 %), R2's rebuild drop. Whole candidate against 133f91266b, free-run: towerblox +1.5 %, bobby +1.7 %, midi +0.7 %, video MIPS -0.5 % (12 rounds, se ~0.35); boots in performance.md History. stopwatch, music, idle and the EL71 boot were not measured in this round: EL71v41lg91.bin, the image they need, was missing from the container133f91266b(2026-11-14) gsm-bts records what it answered the phone, as the read-only propertyms-state(registered, GPRS attached, PDP context active), and ui/wasm'swasm_gsm_state()hands it to the page's network badge. The fork's first change to upstream's hw/gsm besides 9bf917bb6e: twelve lines in gsm-bts.h, gsm-bts.c and gsm-bts-gprs.c, each markedWASM PORT (removable), approved by the owner for this feature only48858038d9(2026-11-14) anexit()from a thread that holds the BQL runs the exit notifiers on that thread, as on a native host: a start-up error (an unknown option, a board without a display, error_fatal) no longer freezes the page. From here the gitlink is the pin8fb9035755(2026-11-13) ui/wasm:wasm_send_key_after, key edges spaced in guest time, for the page's typing. The gitlink moved here whileQEMU_PMB887X_REVstayed at d992a03bf8, so build-qemu.sh would have moved qemu back to an engine without that exportd992a03bf8(2026-11-13) merge of smh/master 3403936c99 -- the cfi-flash CFI/PRI decode and AMD command set (OTP data now without lock words), PMB627X / Bright 6PLA / HD155165BP transceivers, the TPU's RF SSC timing, the cell configurable (default DCS1800 ARFCN 512). With bsp 191612c the CX70 gets its pmb6270, which ends its l1bbcsg panics47d1ff26aa(2026-11-12) merge of smh/master 0539060008 -- the HD15515X transceivers, the DSP modulator per hardware version, gprscu reads. Speed level on every scene, 8 pairs each9de7811900(2026-11-12) ui/wasm.c gets a network port for the page, the GSM cell's IP side in the browser (site/gprs-net.js). Idle unless the page attachesd5421c70af(2026-11-11) merge of smh/master 23d7df3200 -- the GSM stack: GSMNetwork, gsm-air, the built-in cell gsm-bts with GPRS, burst channel coding, gsm-osmotrx, GEA/KASUMI; the TPU on an exact time base, SIM timing in nanoseconds, dmac and lcd cleanups. hw/gsm is upstream's, unchanged. A machine without gsm-network= has no cell. Speed level on every scene once the SL65 scenes start at a fixed guest time: that phone boots in 23 s where it took 53 s9bf917bb6e(2026-11-11) gsm-bts takes uplink LLC frames of the N201-U the phone negotiated; it lost every IP packet over ~240 bytes. GPRS data checked by tools/gprscheck.mjs. Not on the browser's path: the browser build has no netdevdcb799b05c(2026-11-10) the firmware's colour-keyed blit loop runs in C at its back-edge, like the fill loop: stopwatch +7.0 % over 7 pairs, towerblox +1.0 % (se 1.8)462123cd8d(2026-11-10) wasm_accessory_buf/plug, for the page's Accessory control9e7d3d4ce5(2026-11-10) the DSP chain helper enters repeat-headed and over-budget blocks itself, and the inline chain test reads its flags in one load: together about +2 % on midi and video, +1-4 % on towerbloxdb5ec3b899(2026-11-10) review of the fork against smh/master. Fixed: instruction counts not handed back on a TB unwind, 32-bit operands read raw from a 64-bit local (umull after a flag-setting register shift), DSP blocks of an evicted batch aborting, a stale view after set_readonly(false), memory timing in the fused MMIO load, GPTU config writes, the timed cond wait. stopwatch +4.0 %, other scenes level3486f1e2b7(2026-11-09) smh/master 9e5a6bbfd6 merged in d7fab9092f -- debug channels (-debug-channels log=...,io=...) replace trace.h and the PMB887X_TRACE_* environment, the CFI flash writes back by itself (the fork's flash-blk.c write-behind is gone), core Fifo8/Fifo32, hw/dma's sink cache, the LCD and GPU models under hw/lcd and hw/gpu, audio routed through audio lines to PCMOut; tomlc17 is a meson wrap-git subproject; needs bsp >= de47d4b. Plus the audio line's per-write fast path. Free-run A/B against af7a5a4bf6, 8 pairs: towerblox 0.0 %, midi 0.0 %, stopwatch -0.3 % (se 1.1), bobby +0.6 %, video -0.1 %; EL71 boot burst -1.1 %6b8a64baa5(2026-11-09) the 35BE correlator kernel reads and stores guest memory itself -- no address walks or operand copies, no dependency chain through the ring index: stopwatch +6.3 %, midi +6.0 %, bobby +4.3 %, towerblox +3.8 %, video +2.1 %42bb89c091(2026-11-06) no tb_flush when a DSP block crosses a code region, entry counts reset at flush: removes the EL71 boots ~1.5 s late, 2 of 11; scenes flat328087aa34(2026-11-06) wasm64 liveness walks only the touched temps, A9: tcg_gen_code -12.5 %, EL71 boot burst -1.5 %, stopwatch +5.9 %, other scenes flataf7a5a4bf6(2026-11-06) wasm64 constant temps in a per-thread open-addressed table, not a GHashTable, A10: EL71 boot burst -1.0 / -2.1 %, scenes flat172f58552d(2026-11-05) the Thumb fill stores 8 bytes at a time (df96eb2617), the audio stream end and stretch counters (e1d27d837b, a357f7ab05), and the fill helper runs whole rectangles: towerblox +1.7-1.9 %d4380167b9(2026-11-05) a shorter pc-cache probe at goto_ptr exits: EL71 boot burst -1.7 %, steady state +0.4 to +1.2 %434be28741(2026-11-05) the lookup helpers probe the pc cache, the inline probe only at promoted exits: EL71 boot burst -7.0 / -5.4 %, steady state -0.3 to -1.6 %, the owner's one-time exception36e3b3cc4c(2026-11-05) the pc-cache probe as a function of each batch module, promotion dropped: EL71 boot burst -6.5 % vs d4380167b9, steady state within +-1 %c5f522fbfa(2026-11-05) setjmp/longjmp as wasm exception handling, exnref: EL71 boot burst -4.4 / -7.6 %, towerblox +4.9 %, video +3.6 %; remove build/qemu-wasm64 once4903acdf72(2026-11-05) one run thunk for every batch module: EL71 boot burst -7.2 / +0.1 %, every scene +0.5 to +3.2 %1b51f8e577(2026-11-04) smh/master a05a9df1da merged in 6cd424cdb5 -- the SIM moved to hw/smartcard and PPS works, so the PPS revert is gone; needs bsp >= 85d4f78 and -device gsm-sim. Then the fork deviations that neither speed nor correctness needs went back to upstream, as far as the whole build stayed as fast as before on every scene; doc/wasm-fast-paths.md has the list92f6a90e56(2026-11-04) smh/master d9cf65ef40 merged -- DSP chain exits with two links checked for program context and mode, exits only for deliverable interrupts, one cycle count per slice. Free-run A/B against 1b51f8e577: bobby +4.4 %, midi +1.4 %, video mips +0.7 %, towerblox +3.6 %, stopwatch +1.9 %f45db9a125(2026-11-03) the submodule commit since 7807572; this pin had been left at 6e821e08b6, so build-qemu.sh would have moved wasm-browser-port 116 commits back6e821e08b6(2026-10-29) fixes on the merge: SL65 DSP mov translation, LG USIF single-request TX DMA, DIF TX FIFO overflow, AFE voice reinit, audio gaps and host-clock pacing, unpadded PPM screendumps, lockstep exit with the BQL free3a2585b297(2026-10-29) merge of dsp-lle 393263e08d: DSP LLE, reworked capcom/dif/dmac/flash/vic/lcd, icount2 dropped, tcg_qemu_tb_exec re-entrant for the nested DSP JITc4919f185b(2026-09-24) round fifty-three: the flag-setting register shifts inline on wasm64 -- video -1.1 %, J2ME -0.7 %8273aafd5c(2026-09-24) round fifty-three: the dispatcher's call frame is per thread -- the DSP JIT thread shared the vCPU's0bb467886e(2026-09-24) cleanup from the convergence review: the flat-measured lookup shortcut back to the upstream hook, an ifdef fold, lab-notebook comments trimmed to intent, W64_ACCT_TBSTATS renamed W64_ACCT_GUEST_INSNS; J2ME flat741597d60a(2026-09-24) round fifty-three: a full jump-cache flush is a generation bump -- the 16-bit clear was 65536 atomic stores per TLB flush, ~3 /Mi on an idle CX70; S75 flat3fb2c66465(2026-09-24) round fifty-three: jump cache and pc cache at 16 bits -- 92 % of the goto_ptr helper calls and 88 % of the qht lookups in J2ME play were conflict misses in 16384 entries; J2ME -5.6 % +- 4.0, video flat, boot flat8bacd9370c(2026-09-24) round fifty-three: TB bodies leave the code buffer once staged -- a heap copy feeds the batch, the retaddr encodes descriptor + offset, an evicted member is retired, the chain table bounds the flush. 1812 -> 378 bytes/TB; J2ME -2.8 % +- 2.4, video -2.6 % +- 1.35f450abf1b(2026-09-24) round fifty-three: get_page_addr_code_hostp takes the code page's ram_addr from the TLB entry instead of walking the RAM block list. The qht miss path was 7.9 % of the J2ME vCPU, not the 0.7 % it had been closed at, and qemu_ram_block_from_host was 2.69 % of it; J2ME game 1 -8.9 % +- 4.2 at tb-size=768 on a loaded host967f88004e(2026-09-24) cleanup: six commits drop what neither wasm nor performance needs -- N-page TB tracking back to upstream's two pages, the temp-module path, per-TB tables, MEMORY64=1 paths, TCG_REG_TMP, dead interp ops, pmb887x leftovers; 2117 lines out, 538 in. TBs 13 % smaller; J2ME -0.8 % +- 0.8, video -0.1 % +- 0.7 at tb-size=7687538f05950(2026-09-24) round fifty-two: a store to a code page's data that code_mask says misses every TB skips mmu_lookup/notdirty_write -- J2ME game 5 -8.9 %, game 1 -1.8 %, video flatcb4dbe103f(2026-09-24) round fifty-two: code_mask back to 4-byte granules at 4 KB pages -- the store-to-code-page walk was 38.6k list steps/Mi; J2ME -6..-10 %, video -1.2 %0a3e5f2ce3(2026-09-24) -ftrivial-auto-var-init=zero dropped on emscripten only, owner's call -- video -4.2 %, J2ME -1.5 %; native keeps it as the lockstep referencee546579764(2026-09-23) round fifty-one: a buffered program's duplicate- address scan was n^2 per buffer; skipped for ascending words -- flash_io_write self 3.7 % -> 0.6 % of KE970 bootbacb430bb6(2026-09-23) round fifty-one: flash partitions return to the ROM mapping after 16 array reads, not per reset -- 327k memory transactions per KE970 boot -> 7.4k; boot -11..-17 %920348722a(2026-09-23) round fifty-one: the wasm flash write-behind batches behind a 50 ms timer, one request in flight -- KE970 boot busy phase -17 to -22 %6f5ead34a8(2026-09-23) round forty-nine: the inline TLB probe runs in i32 for a 32-bit guest -- no movl narrowing on the chain of each access; SL65 video -2.6 % ms/Mi23914e9052(2026-09-23) round forty-nine: wasm branch hints on the inline TLB probe -- TurboFan stops spilling on the hit path of every guest load/store; SL65 video -20 % ms/Mida835da585(2026-09-23) native ldm {pc}^ exits to the loop again, as upstream: the review had missed that exception return, so native s75/el71 took unmasked IRQs late and aborted in l1bbcsg. wasm64 code unchangede2976ebbfe(2026-09-23) round forty-eight: msr cpsr that leaves the mode alone is written inline on wasm64 -- SL65 video -2.2 % ms/Mib9971ade2e(2026-09-23) review applied; 686c6d67ce with the review file moved out of the tree, code identical. Natively s75/el71 abort in l1bbcsg: see performance-handoff.md (git history) round forty-eight4e60f930b2(2026-09-22) round forty-seven: mrs cpsr emitted inline on wasm64 -- SL65 video -2.5 % ms/Mi520d682b91(2026-09-22) round forty-seven: comment only -- the arm_rebuild_hflags price is 12.3 ns, not 31.618f8cd44e9(2026-09-22) round forty-seven: a timer re-armed on the main-loop thread no longer notifies the main loop -- KE970 boot mlWake -45 %, milestones 3.5-4.9 % sooner46d7aa3e64(2026-09-22) round forty-seven: the exception return stops taking the BQL around empty hook lists but keeps releasing a deferred hold -- video -5.7 % ms/Mi; keeping the hold across the return deadlocked KE970's idle spinc0a93d01a2(2026-09-22) round forty-seven: lockstep budget exit() gives back a deferred BQL first -- the page froze on it4457396bbf(2026-09-22) round forty-seven: flash write-behind goes asynchronous -- the synchronous flush polled the thread pool with the BQL held, ~240 ms of every KE970 boot second, and the vCPU's flash MMIO waited it out. KE970 flash phase 30 -> 25.7 s, 1.6 G insns 41 -> 37 s95055ff451(2026-09-22) round forty-seven: 16 MB phys-summary buckets -- a KE970 romd flip walked the running code in the other half of its 32 MB bucket, ~2 300 entries per flip; now 68. ~4 % of the vCPU through the LG flash-programming boot, C-side timer1a043d7c57(2026-09-22) round forty-seven: flash-blk schedules its write-behind flush only when the dirty list starts -- a pending BH still aio_notify()s, so it was a main-loop futex wake per programmed word, ~140k/s through a KE970 boot. mlWake -75..-83 %6e361b6c8e(2026-09-22) round forty-seven: capcom times only the events that can raise an interrupt. 02ada89fe6 armed a timer per wrap and compare; the SL65's T0 PWM made that ~360 k icount exits per virtual second and cut video rt 2.5 -> 0.38 through rounds 45-46. Back to rt 2.40, execIter 34/Mi9146059(2026-09-20) merge pass over the two upstream topic branches that had grown off the wasm-browser-port tip. c2cb8c0 (origin/sgold-regression-fix, = smh mirror): the A32 TST/TEQ/CMP/CMN decode pinned the Rd nibble to 0000 and sent every other encoding to unallocated, but pre-V7 cores (the ARM926 in the SGOLD boards) decode the op, update the flags and skip the writeback — patched fullflashes branch into such literal-pool words. 9cb5eac (origin/pmb887x-usart-rx-pacing): usart_schedule_accept_input() waited one frame time and then let the chardev fill the whole RX FIFO, so a bulk transfer into the phone arrived as an interrupt storm — GSM L1 misses its deadline and the firmware resets; now paced to the baud rate and the FIFO fill level, one byte per frame. Both merged clean on top of 474bff9 (the device-model review pass, which had itself been pushed to origin/wasm-browser-port and smh/wasm-browser-port); the pin also catches up to the gitlink, which18bcbe5had moved to 474bff9 without bumping QEMU_PMB887X_REV from fada259275f61c(2026-09-16) round twenty-five, 0101-0103: the interpreter tier, and the two things it retired. 0101: the backend records every emitter's already register-allocated operands into a flat uint32 op stream (tcg/wasm64/w64-interp.h) and a C interpreter in the main module runs a TB before its module exists, so a batch is no longer closed early by the first member that has to run. 0102: speculative successor translation defaults OFF under the tier -- round 22 priced it at a 12.5 % break-even because a miss forced a module, and a miss no longer does, so break-even moves to ~100 % against a 66 % conversion. 0103: W64_BATCH_N 128 -> 256, a cap that could not bind until batches filled. EL71 12 s windows: 347 -> 576.7 Mi, +66.2 %; modules 18 650 -> 698, module time 2.02 -> 0.34 s, members per module 5.4 -> 152. Two invariants broke outside the backend and both failed silently: 32-bit signed compares were evaluated at 64 bits on zero-extended operands, so gen_tb_start'scount - n < 0icount test never fired; and tb_add_jump must refuse to link a chain into a target that has no module yet, before the cmpxchg that claims jmp_dest[n]. Module time is now dominated by its per-member term, which inverts round 24's law and retires the close count as a lever; translation is now the biggest single item at ~17 % of wall313e769(2026-09-16) round twenty-four, 0100: closePreEnt / closePreTb -- at each batch close, sum what the members have already executed (W64_TBHIST counts, exact per TB). With W64_NOCLOSEEXEC=1, which defers the close so batches fill to W64_BATCH_N, that is the interpreter tier's COST measured on the real thing instead of assumed: closes 35 873 -> 1 353, module time 3.54 -> 0.548 s, and 7 001 592 entries (1.45 % of all) run before their batch closes. At 109 ns each that is 0.76 s spent to save 2.99 s -- net +2.2 s of a ~27 s boot, ~8 %. The same sweep fits the module cost law over a 48x range of members (W64_SPEC_N 4/32/64, W64_BATCH_N 16/32/128, deferred close): ~86 us per close + ~2.8 us per member, so 96 % of module time is the fixed cost of closing too often and the close count is the only lever left. tools/modshape-probe.mjs finds no cheap corner in new WebAssembly.Module and withdraws round 19's "four fifths is cold cache" -- that measurement recompiled identical wire bytes, which V8 serves from a module cache; distinct bytes cost 2.0-3.8x more. Instrumentation only6a11e50(2026-09-16) round twenty-three, 0099: W64_TBHIST -- a per-TB entry counter in the prologue (one i32 load/add/store at a translation-time-constant address), which is the number open item 1 had been gated on since round twenty. EL71: 27.2 % of translated TBs are NEVER entered; of those that are, 35.9 % run exactly once and 74.0 % run <= 31 times, while 0.08 % of TBs take half of all 586 M entries. Bimodal with an enormous gap, and S75 agrees, so it is guest code not a board. With tools/interp-probe.c -- the same interpreter loop compiles to wasm at NATIVE speed, 7.26-7.42 vs 7.30-7.43 ns/op, while emitted TB code runs 2.7x slower than native -- the interpreter tier prices at +1.8 s of a ~27 s boot (~6 %), range +0.25..+2.35 s. Instrumentation only806bef8(2026-09-16) round twenty-three, 0098: price the inline TLB probe, and the dispatch it feeds. W64_TLBDUP emits N extra REAL probes per memop, each result to its own per-site slot: the probe is 5.07 % of EL71 wall, a two-load replacement 2.33 %, a one-load v128 one 4.09 % -- its cost is not its load count. Sites stay on one page 94.7 % of the time (W64_TLBHIT). Built on those three numbers, a per-site cache in FRONT of the probe measured 4.4-5.0 % SLOWER: a duplicate-probe instrument emits straight-line code, so it prices DELETING that code, never inserting a branch ahead of it. W64_XCOUNT counts TB exits: goto_tb which=0 41.4 %, which=1 29.8 %, goto_ptr 28.8 %, self-chaining 4.8 %; 4.16 guest insns per TB entry, dispatch 9.1 % of wall. Instrumentation onlyd52696f(2026-09-16) round twenty-two, 0097: price the miss stream and close "speculate harder". 39562 misses in 3878 pages = 10.2 per page, and a page holds ~529 basic blocks, so eager page translation is 7x negative. W64_MISSDUMP: 31397 misses at 31397 DISTINCT pcs (zero repeats), of which only 10.2 % appear anywhere in the 64 MB image as a pointer -- 89.8 % are reached by computed addresses no scan can see. Ceiling on every static-edge idea: 1.2 % of wall. The 12.5 % pipeline needs the interpreter tier or nothing. Instrumentation only8003584(2026-09-16) round twenty-two, 0096: W64_NOPCREL -- CF_PCREL is set on every ARM system-mode TB and nobody had asked what it costs. Off: -0.7 % 2/3 (noise) and +2 % misses, and tbGen does not move, so this firmware maps its code once and the generality is unused but not worth removing. No saving because cpu_R[15] is a TCG global living in a wasm local -- do not price a global access as a load on this backend. Ships on, knob off, native untouchedb6fdf43(2026-09-16) round twenty-two, 0095: W64_LINSPEC, a rejected speculation edge kept as its reproducer. Speculation already converts at 66 % against a 12.5 % break-even (a translation is ~12 us, a module ~96 us; W64_SPEC_N 0 vs 32: 127k extra translations remove 84k misses), but guessing the address after an unconditional transfer makes +89 % translations and removes no misses -- and after an indirect one it panics the EL71 firmware in 4.5 s. tb_flush, ISA alignment and stale-TB-over-reprogrammed-flash all ruled out by experiment. Ships offb0152f3(2026-09-16) round twenty-one, 0094: W64_BYTEPAD, the knob that prices emitted bytes against compile. 0/40/120 -> 5.1/7.7/14.5 KB per module -> 96/110/125 us: ~80 us fixed + 3.2 us/KB, so bytes are 17 % of the module cost and worth at most 2.2 % of wall driven to zero. Closes the emitted-byte question three earlier rounds left ambiguous - their 2.6-3.7 % cuts predicted 0.4 %, under every meter used. Live-module count is flat 500->6000 (tools/modgrow.mjs). Module count is the only lever left on the 12.5 % pipeline. Instrumentation only8d26a08(2026-09-16) round twenty-one, 0093: W64_LOCALPAD, the knob that prices the ~70 locals every TB function declares. wasm zeroes locals at entry and the baseline tier has no liveness analysis: +38.9 ns on a 49.9 ns call there, free in the optimizing tier (tools/locals-probe.mjs). The boot runs --liftoff-only +63 % and --wasm-tiering-budget=1000 -3.1 %, so ~3.6 % of TB entries execute baseline code; in-app the spare locals are worth under 1 %. Priced, not built. Instrumentation only45968bc(2026-09-16) round twenty-one, 0092: a lookup miss costs a wasm module - closeN == specMiss, and the pipeline is 12.5 % of an EL71 boot at 74 us fixed + 1.25 us/KB. Speculation is edge-limited, not budget-limited (W64_SPEC_N 8 == 128), and the call-return address is the one statically-known indirect edge nothing recorded on the Thumb-1 split BL and blx paths - this core is an ARM926EJ-S, so that is every Thumb call. Misses -2.6 %, 3/3 on fixed guest work, ~0.3 % of wall. W64_NORETSPEC=1 A/Bs itbd9ae89(2026-09-16) round twenty-one, 0091: every TB entry is a return_call_indirect through the shared chain table (~11 M/s) and used to follow the chain slot into the target's descriptor for fidx and tidx - one cache line per TB in ~20 MB the execution path never otherwise reads, on the dependency chain of an indirect branch. tools/dispatch-probe.mjs priced that load at +2.1 ns over a 256-TB working set and +8..9 ns over 1024-4096; the helpers and tb_set_jmp_target now carry the table index itself, tagged in the high half. Boot window, fixed guest work, 3 interleaved pairs: el71 -5.4 %, s75 -4.5 %, cx70 -7.0 %, ke800 -10.8 %, 3/3 eachbad630a3(2026-09-16) round twenty, 0090: the wasm64 op-suite leg had been a KNOWN HOLE since 2026-09-13 - "null function" in an Asyncify rewind on the versatilepb suite target, so the shipping backend had no op-suite coverage and lockstep+bootcheck carried it. A no-onlylist build ran the suite green, and QEMU_COSTACK=1 on the suite target (tools/costack-suite.mjs) captured the 7 switch stacks; resolving them found 20 functions missing from configs/meson/asyncify-only.txt, all on the versatilepb machine-init / legacy-SCSI / board-reset path no phone boot reaches (versatile_init, vpb_init, scsi_, resettable_, sd_*, pl181_reset, ...). Added as the minimal explicit set: wasm +12.6 KB, el71 boot A/B a tie (medians 29.45 s both legs, 3 interleaved pairs). WASM64_SUITE=1 run-tcg-isa.sh green 1156/1156 with serial byte-identical to native JIT; the KNOWN-HOLE special case in scripts/run-tcg-isa.sh is deleted so the leg gates again. See doc/performance-handoff.md (git history)b68326e2ab(2026-09-16) "icount: the post-window rt cap is a 500 ms budget, not strict (0089)" - the wasm default becomes QEMU_ICOUNT_RTCAP=budget:30:500: banked for the guest's first 30 s of its own clock as before, then a bank capped at 500 ms instead of strict, so a post-boot stall is repaid by at most half a second of sprinted clock (strict left the phone behind wall forever, banked sprinted the whole stall: v 4.2 -> 38 s in 4 s of wall on a 12x-throttled host). Page ?rt= gains budget[:[:]]; icount_rtcap_mode() gains 3 = budget for the pill/diagnosticsc07259d(2026-09-16) round nineteen, 0088: 0086's split left ~14.5 us per module outside every timer. MOD_PRE_NS finds it in w64_batch_instantiate's prologue -- a DataView and a Float64Array rebuilt over the 2 GB shared buffer per call, and the module bytes copied twice because HEAPU8.slice() already returns a Uint8Array. Views cached on buffer identity, wrapper dropped: 9.8 -> 5.3 us a module, 0.156 s per 25 s EL71 boot, ~0.62 % of wall.48926e6(2026-09-16) round nineteen, 0087: the module-GC nudge -- 32 MB of garbage every 256 instantiations, ~170 MB/s at boot rates -- exists for SpiderMonkey, where module code is not GC pressure and the worker never yields. V8 needs none of it and paid 0.27 s per 25 s EL71 boot, ~1.1 %. Decided from the user agent now; W64_GCNUDGE forces it. It does NOT inflate compile time: 2.8754 vs 2.8761 s.892eee3(2026-09-16) round nineteen, 0086: instrumentation. The topology commit split -- topoFull is 170 per 25 s EL71 boot against topoVar 16872, and 122 of those are startup add_subregion, so 0083 left nothing there. And MOD_NS decomposed: of 3.66 s, WebAssembly.Module is 2.82 and the import object 0.026. Two sources differing 178x in count and 1.05x in bytes solve to ~80 us FIXED per module call; W64_SPEC_N 8/32/128 agrees at 83.6/82.7/83.3 us. And W64_MODBENCH compiles one real module's bytes 200x back to back inside the vCPU worker: 12-31 us, against 83 us once in the normal flow -- four fifths of "compile" is cold cache, paid per compile event. (W64_MODBENCH was measured on 2026-09-16 with this commit's build, on an EL71 boot, against MOD_NS's ~83 us per module of the same boot. Its 200 compiles reused one module's bytes, so they read V8's compiled-module cache. Re-measured with distinct modules on 2026-11-14, these shapes compile in 46-51 us, not 12-31, so the "cold cache" was that cache: performance.md, Closed ideas, the module-shape row.)d8643d756d(2026-09-15) "pmb887x: run DIF v1 transfers where they are asked for, not from a timer (0079)" - round fifteen, 0078-0079, is the SGOLD round. The user added a CX70 fullflash and reported SGOLD as terrible; every earlier round measured SGOLD2 (S75/EL71) or the LG, and hw/arm/pmb887x/dif_v1.c had never had the work dif_v2.c got. The CX70 never halts (64 halts/s against the S75's 27091) and burned ~116 MIPS to hold 1.07x real time, with ~17 % of its vCPU in the DIF/DMAC/SSI chain. 0078 gives v1 the two things v2 already had: dif_mux() as a byte-lane table instead of a per-bit loop with two divisions and two modulos per bit per word, and a level filter on the two DMA request lines that were driven ~4x per word although the level almost never changes. 0079 stops handing every single word to timer_mod(transfer_timer, 0) - the deadline is zero, so the timer bought nothing, and because the DIF's breq then reached the DMAC from outside its run loop the DMAC armed its timer per burst too (10.87M against 10.86M bursts, where an S75 does 99/s against 11660/s). v2 has never called timer_mod at all. CX70 wall time for a fixed 8G guest instructions: +6.2 % then +7.3 %, every step winning every interleaved pair; the display output is byte identical at a fixed instruction count. The meter is new - tools/workbench.mjs, because the SGOLD idle screen animates and idle MIPS swings ~15 % between runs of one build. See doc/performance-handoff.md (git history)b7822c674b(2026-09-15) two merges. alula/dsp-stuff came in resolved to ours and changed no file: its two content commits are already here verbatim (the AFE cherry-pick has the same patch-id as alula's, and debfa3d6f5 is his RTC-seed commit), and what was left on his side is a dsp_hexdump() that indexes words where the offset counts bytes, the pre-fix dsp_realize(), and two #if 0 debug blocks. The merge is recorded so the branch stops looking behind. The one that matters is qemu-pmb887x master, plus a whitespace fix on top. Master brought one commit that counts here, "pmb887x: Fix dsp crash on Siemens SGOLD phones" (PR #4): it lands inside dsp.c's #ifdef STUB_DSP block, which upstream leaves disabled and this branch enables, so it is inert there and live here. dsp_realize() now seeds DSP shared-RAM word 0 from rom_version - the value board/dsp.c actually sets from the board's dsp.ram0_value - instead of the ram0_value property, which nothing ever sets and whose default is 0x0801. The boards that ask for 0x0602, siemens-cx75 and include/siemens-sgl-r65, get their own value for the first time; every other board already wanted 0x0801, which is why this never showed up on s75/el71/c81cd0ecd359d(2026-09-15) "wasm-diag: gate the counters that ended up on hot paths (0076)" - the tip of the series. Round fourteen, 0074-0076, is about what it costs to stay unwindable. -sASYNCIFY_ONLY names every function Asyncify must instrument for a coroutine switch, and instrumenting one is not free; the list still held eighteen entries reachable only from the vCPU thread, where rr_cpu_thread_fn() forbids coroutines outright and qemu_coroutine_switch() aborts, because the JIT'd TB frame below a helper cannot be instrumented at all. They were the stack of a vCPU flash write, the case flash-blk.c had already moved to a main-loop bottom half - the fix deleted the stack, nothing deleted the entries. 0074 removes them (verified with QEMU_COSTACK=1 and the new tools/asyncify-audit.mjs: 67 distinct frames on a 120 s S75 boot, all still covered, none of the eighteen among them). 0075 folds the MMIO fast path into its callers with a compile-time size, which also collapses a double bswap that cancelled on every little-endian device read. 0076 gates the ~14M diagnostic read-modify-writes a second that had accumulated on the hot paths (rebuild with WASM_DIAG_HOT_COUNTERS to get the rates back, and never wall-clock A/B such a build). S75 idle vs round thirteen: +8.5 % MIPS, +8.4 % v/wall (4/4 pairs); EL71 +3.4 % / +3.1 % (3/3) - less, because EL71 is compute-bound and spends little time in the functions this round un-instrumented. See doc/performance-handoff.md (git history)4368d0317b(2026-09-15) "system/cpus: do not give the BQL back after every device access (0073)" - round thirteen, 0070-0073, is mostly one finding: wasm has no relaxed atomic and no acquire fence, so every qatomic_set is a seq_cst iN.atomic.store and every smp_rmb() an atomic.fence, and QEMU pays for ordering it does not need here. 0070 read the virtual clock without the seqlock's fence pair or the atomic publish (icount_get 4.3 % -> 0.6 % of the vCPU; a ceiling probe said +5.0 % was available and the patch took +5.2 %), 0072 did the same for cpu_handle_interrupt's per-pass qatomic_set_mb plus three other fixed costs, and 0073 stopped handing the BQL back after every one of the S75's three million device accesses a second (bounded by the rr loop's own unlock before every tcg_cpu_exec, so a missed release is one icount slice of delay, not a deadlock). 0071 is the other kind: a short hflags rebuild for a CPU with no M/AArch64/EL2/EL3/PMSA/v6, verified by a build that takes the short path, computes the generic answer anyway and counts disagreements - ~59M rebuilds, zero. S75 idle vs round twelve: +14.6 % MIPS, +14.1 % v/wall (4/4 pairs); EL71 +10.0 % / +9.9 % (3/3); KE800 boot -10 %. See doc/performance-handoff.md (git history)2c59e1b(2026-09-15) round eighteen, 0085: cpsr_write rebuilt hflags whenever the write mask covered M/E/IL -- true of everymsr cpsr_cused to mask interrupts. Require the bits to actually move: 873k/s -> 317k/s. cx70 +1.0 % 3/3, el71 a tie. Checked with --enable-debug-tcg.f902fa1(2026-09-15) round eighteen, 0084: TB_JMP_CACHE_BITS 12 -> 14. 95 % of the qht fall-throughs were jump-cache conflict misses; 16k entries cut qht lookups per Mi by 62 % (el71) and 55 % (cx70). Warm window: cx70 +3.5 %, el71 +1.6 %. 16 bits is worse than 14 on both boards. Affordable only because 0083 took tcg_flush_jmp_cache to ~0/s.1326888(2026-09-15) round eighteen, 0083: a readonly flip is a flat-view variant, not a topology change. The pmb887x EBU opens the NOR flash chip-select for a CFI command and closes it again -- 599 times a second on an EL71 boot -- and each flip used to bump topo_gen, re-render every view and drop the romd stash. Folding the readonly set into the stash signature makes the A-B-A toggle a hit. Boot window, fixed guest work: el71 +55.6 %, cx70 +31.5 %, s75 +15.1 %.d857b65(2026-09-15) round seventeen, 0082: phase timers, and the deletion of the ldr pc,[pc,#-4] trampoline heuristic -- guarded on !CF_PCREL since birth, so it had never run, and once woken it fires on one walked node in 35k. The timers replaced the discredited profiler for the one question it was still trusted on: the translate+compile pipeline is 19.5 % of EL71 boot wall, so the early boot is NOT compile-bound and tiering is capped at the ~10 % compile slice25c93a1(2026-09-15) round sixteen, 0081: a key event arriving before wasm_display_init() created its bottom half took the whole module down with "memory access out of bounds" -- qemu_bh_schedule(NULL)'s atomic lands on a valid wasm address and succeeds, so the fault surfaces three dereferences later. It failed every board of bootcheck on every dist while looking like host memory pressure. Regression test: tools/earlykey.mjsb2fa7e8(2026-09-15) round sixteen, 0080: wasm-diag counters that price speculation, the jump cache and arm_rebuild_hflags. Instrumentation only, all of it wasm-gated. They exist because this round found that the wasm profile's per-function self-time names the wrong function -- see doc/lessons.md "The wasm profile names the wrong function"
bsp (the bsp/ gitlink; PMB887X_BSP_REV before 2026-11-14)
191612c(2026-11-14) the same revision becomes the top-levelbsp/submodule, which replaces the build/bsp clone that scripts/sync-bsp.sh used to check out. pmb887x-emu's own bsp submodule pins the same commit191612c(2026-11-13) master, with the qemu d992a03bf8 merge: every board config has an RF transceiver; the CX70's pmb6270 on TPU:RFSSC0 ends its l1bbcsg panics63b56fa(2026-09-22) master up to the commit before the pad rename. ebbb9c5 + 4da7eb0 "update ke970 config" give the KE970 jog dial a [peripheral.SCROLL] of type ke970-scroll, bound to NAV_UP/NAV_DOWN through the newkey = {}block, so the wheel the page now draws as a pad (site/keyboards.js, board ke970) reaches the firmware; the board also moves M_0/M_9 ontovoltageand remaps USB_CHG_EN/TF_DAT1. Deliberately NOT the tip: eb4f9fc "lib: fix pad names" swaps the names of GPIO 39 and 99 (DIF_HD <-> MMCI_DAT1) and names 32/33 I2S2_RX/I2S2_TX, and rewrites five board configs against them, while qemu's own pad table — generated from bsp and committed in the submodule, gen/cpu_regs.h — still has the old names. Those configs would bind the e71/el71/m72/s68 aliases to the wrong pin and fail the KE970 on an I2S2_RX the table does not havee79169f(2026-09-20) master. PR#6 landed upstream as e8d490e, so PMB887X_BSP_FIX_REV and its merge in scripts/sync-bsp.sh are gone — plain master is the whole checkout again. New boards this round: M65, M75, ME75, SK65 and SL65 (4a18db7, 828613d, 6b2db60), CX75 reworked onto the new siemens-sgl-sirius include, WHBABCON/WHBABSTAT bits (c19c914) and USART.cfg RX pacing. The device list (site/fullflashes.js DEVICE_RULES) grew the matching filename rules; boards.tar is re-packed from this rev by scripts/pack-boards.sh23fc945(2026-09-17) master + PR#6. Master's 55752c5 comments out the [peripheral.RF] hd155153np entries on the x75 and ELKA includes — the device the emulator has no table entry for, which used to abort board init with 'hardware error: Unknown device: hd155153np' and which this project carried a bsp-patches/ workaround for until now — and maps CAMERA and PLAY_PAUSE into the S75 keypad matrix, so the two side keys the page already draws finally reach the firmware. c0cf69a adds the END_CALL mapping to the SGOLD keypad, 23fc945 the WHBABCON SETABEN/CLRABEN flags. PR#6 (e6e73d1, "LG boards read the RTC counter as packed calendar fields") is still unmerged upstream: PMB887X_BSP_FIX_REV keeps it merged onto the master pin — scripts/sync-bsp.sh does the merge, so a fresh clone reproduces it — because the [rtc] format = "calendar" it carries is what the LG firmware needs and the companion of qemu's RTC cnt-format commit
bsp master (2026-09-20: e79169f). PR#6 ("LG boards read the RTC counter as packed calendar fields") landed upstream as e8d490e, so the separate PMB887X_BSP_FIX_REV pin is gone — plain master is the whole checkout again. That round added the boards the device list now ships: M65, M75, ME75, SK65 and SL65 (4a18db7, 828613d, 6b2db60), reworked CX75 onto the new siemens-sgl-sirius include, added the WHBABCON/WHBABSTAT bits (c19c914) and paced USART RX in modules/USART.cfg.
2026-09-22 → 63b56fa, for ebbb9c5 + 4da7eb0 "update ke970 config": the KE970's jog dial is a board peripheral at last — [peripheral.SCROLL] type = "ke970-scroll" out = { A = "SCROLL_KEY_A", B = "SCROLL_KEY_B" } key = { CW = "NAV_UP", CCW = "NAV_DOWN" } — so UP/DOWN reach the firmware as wheel detents instead of falling off the end of a keymap that never had them (the two [keyboard.gpio] lines were commented out before). It also moves the battery/current channels onto voltage and remaps USB_CHG_EN/TF_DAT1.
NOT master's tip: eb4f9fc "lib: fix pad names" swaps the names of GPIO 39 and 99 (DIF_HD ↔ MMCI_DAT1) and names 32/33 I2S2_RX/I2S2_TX, then rewrites five board configs against the new names. qemu's pad table is generated from bsp and committed in the submodule (hw/arm/pmb887x/gen/cpu_regs.h, still DIF_HD=39 / MMCI_DAT1=99), so those configs would bind e71/el71/m72/ s68 aliases to the wrong pin and fail the KE970 outright on I2S2_RX, which that table does not have. It can be picked up once qemu regenerates.
2026-11-04 → a5a992e (master), for the smh/master a05a9df1da merge: the boards declare an "iso7816-slot" (85d4f78), which that qemu needs and older qemu does not know; site/app.js and scripts/run-native.sh add -device gsm-sim when the board set has the slot. It includes eb4f9fc, and the merged qemu's cpu_regs.h carries the new pad names, so the paragraph above is history.
2026-11-09 -> de47d4b (master), for the smh/master 9e5a6bbfd6 merge: the generated tables in the merged qemu are this revision's (the RF transceiver registers are generated into their model directories), and the boards name device ports by child bus and wire the audio lines the merged qemu routes.