The probe stands in for Broadway with StarOS's own bench loader code, so that StarOS's H-1A bench (docs/architecture/h-1a.md, D-H1A-7) runs whole: its Starlet image on the ARM core, its Broadway side from StarOS's boot/wii/loader hw0c.c, hw0d.c and h1a.c, vendored unchanged in Tools/StarletBootstrapProbe/StarOSLoader (StarOS 480119d, stored -text so their bytes stay StarOS's) with their contract headers, and built over a host HAL in BroadwayHAL/. CMake computes the nine files' SHA-256s at configure; the probe prints them when the mode starts. As StarOS's loader around the jump: hw0c_setup() before the Starlet's first instruction, one hw0c_step() between each two slices, the timebase 243 MHz / 4 from the Starlet's cycles, until it says 1; once the image's trace is terminal and the bench is done, the trace, then the report between main.c's status and END lines on stdout. If the budget runs out, the report under SBL:TIMEOUT, and the run fails. The client reaches PPC memory only in the bench window 0x13500000..0x13510000, by whole words: the first access outside fails the run, and is not made. Dolphin's memory is coherent: the run rehearses the protocol, the capture and the judge, not the console's caches. --cycles may reach 2^34 in this mode only (MAX_CLIENT_CYCLES), 2^30 as before otherwise. --broadway-h1a takes neither --ipc-script nor --stage-spk, whose behaviour is unchanged. StarletProbeBroadwayTest: the window's bounds, the clock, Gecko's number formats, the budgets, the built-in sources; and, each in a death test's own process (the loader's state is global), the real loader code against a scripted Starlet: 3000 rounds and a COHERENT record, no READY, no Starlet END, a budget too short; a second client refused. Co-Authored-By: Claude Opus 5.5 <[email protected]>
32 lines
1.3 KiB
C
32 lines
1.3 KiB
C
/* SPDX-License-Identifier: GPL-2.0-only */
|
|
/*
|
|
* H-1A's bench on Broadway (docs/architecture/h-1a.md, G-H1A-2), built into
|
|
* the bench's loader only with -DSTAROS_HW0C -DSTAROS_HW0D -DSTAROS_H1A,
|
|
* never with -DSTAROS_HW0E or -DSTAROS_HW0F. crates/hw-bench's h1a::setup,
|
|
* mark, Broadway and collect are the reference it follows; the other loaders
|
|
* do not contain it.
|
|
*/
|
|
#ifndef STAROS_LOADER_H1A_H
|
|
#define STAROS_LOADER_H1A_H
|
|
|
|
#include <stdint.h>
|
|
|
|
/* In hw0c_setup, before the header: the record, page 0's near scrub and
|
|
* pages 1 to 3 cleared, Z in the pool's words, all published. */
|
|
void h1a_clear(void);
|
|
/* Once READY is seen, at timebase `now`: M in the pool's words, published;
|
|
* round 1 is posted D_POST later. */
|
|
void h1a_ready(uint64_t now);
|
|
/* One step at timebase `now`, at most one action: 0 while H-1A runs; 1 once
|
|
* the Starlet's END was seen after Broadway's own end; -1 when it was not by
|
|
* READY + H1A_END_TIMEOUT_MS. The record and the checks are read back before
|
|
* it gives 1 or -1. */
|
|
int h1a_step(uint64_t now);
|
|
/* The sentinel's words outside H-1A's areas that are not as Broadway left
|
|
* them, read now (hw0c.c's S0 end check, and the CHECK line). */
|
|
uint32_t h1a_sentinel_end(void);
|
|
/* After hw0d_report: the SBL:H1A block. */
|
|
void h1a_report(void);
|
|
|
|
#endif
|