• src/doors/syncretro/test_warmup.csrc/doors/syncretro/CMakeLists.txt GA

    From Rob Swindell (on Debian Linux)@VERT to Git commit to main/sbbs/master on Tue Jul 28 17:19:04 2026
    https://gitlab.synchro.net/main/sbbs/-/commit/7727f08ccde7c5c36645e226
    Added Files:
    src/doors/syncretro/test_warmup.c
    Modified Files:
    src/doors/syncretro/CMakeLists.txt GAMES_INI.md main.c retro_bridge.c syncretro.h syncretro_games.c syncretro_games.h test_games.c xtrn/syncarcade/README.md games.ini
    Log Message:
    syncretro: run a cabinet's power-on self-test at full speed

    An arcade driver spends its first seconds checking RAM and ROMs behind a test pattern, and the door paced all of it to the emulated 60 fps -- so the player watched fifteen seconds of something no coin-op will let them act on, since nothing responds until a credit is in.

    games.ini gains boot_frames: run the first N frames unpaced, with the core's video and audio discarded at the bridge, then arm the pacer and start drawing. Written before any section it is the install-wide default, and a section may override it; unlike the button labels it needs no per-romset measurement, because warming up past a short boot only lands the player further into the attract loop. Values are clamped to 18000 frames -- this is real CPU spent on every node with the player looking at a static screen. The arcade install
    ships 900.

    The emulation is not altered. The same instructions run on the same emulated cycle counts, self-tests and NVRAM load included; MAME's timing is in cycles, not host time, so the driver cannot tell. Only the waiting is gone. Measured
    on MAME 2003-Plus: 68-149x realtime standalone, ~47x inside the door, so 900 frames costs 0.11-0.29 s depending on romset.

    Not a save state, though the core supports one -- seven romsets round-trip byte-identically at 32-324 KB, declaring no serialization quirks. A state cannot speed up loading the ROM at all (retro_unserialize needs a loaded game, so the zip decode and ROM decrypt happen either way), the blob carries no version stamp so its cache must be keyed on core, romset and resolved options, save-state support in this lineage is per-driver across some 5000 drivers, and the core's NVRAM write at unload means a boot snapshot restored on every
    launch can roll back high scores.

    Input is suspended for the duration -- a key struck against a screen the
    player cannot see is not the game's -- while the pump keeps running
    underneath, so the terminal's probe replies still land. The loop polls for
    exit every frame, so a session limit or a dropped carrier still ends the door mid-warm-up.

    test_warmup.c pins the output gate by capturing the callbacks the bridge installs: nothing reaches termgfx or the audio stream while it is set, a suppressed batch still reports its frames consumed, and the pump is untouched. GAMES_INI.md sec 13 documents the key, the measurements and the rejected alternative.

    Co-Authored-By: Claude Opus 5 (1M context) <noreply@anthropic.com>

    ---
    þ Synchronet þ Vertrauen þ Home of Synchronet þ [vert/cvs/bbs].synchro.net