Skip to content

x86 gate: simple_exit's by-design exit 42 is counted as a failed process, so run-boot-parallel.sh fails on main #781

Description

@ryanbreen

./docker/qemu/run-boot-parallel.sh 1 fails on main because simple_exit
exits 42, which is the only thing that program does.

What happens

[ INFO] kernel::syscall::handlers: TEST_TALLY: exited=22 nonzero=1 failed=[simple_exit:42]
[ERROR] kernel::syscall::handlers: TEST RUNNER: FAILED - 1 of 22 userspace processes exited nonzero
x86 userspace gate: FAIL - failing process is not allowlisted: simple_exit
Results: 0 passed, 1 failed out of 1

The boot itself is healthy: it reaches the
USERSPACE TEST COMPLETE marker first, and STRAND_CENSUS reports
threads_saved_blocked=11 stranded=0.

Why it is not a kernel failure

userspace/programs/src/simple_exit.rs is 3 lines of body:

fn main() {
    // Just exit with code 42 - no printing
    std::process::exit(42);
}

Its doc comment says the same: "Just exits with code 42, no other output."
Exiting 42 is the behaviour under test, so the tally's "nonzero exit means a
failed process" rule mislabels it, and
scripts/x86-gate-verdict.sh then fails the run because
scripts/x86-gate-allowlist.txt holds 0 entries (3 comment lines and nothing
else).

Where it reproduces

Measured on beast, breenix-x86, /root/breenix-a64r2, one run each, each
after touch kernel/src/task/scheduler.rs and a
--features testing,external_test_bins rebuild:

Revision Result
52491c4b (main, 2026-09-02) Results: 1 passed, 0 failed out of 1
bfbb7575 (main, 2026-09-04) TEST_TALLY: exited=22 nonzero=1 failed=[simple_exit:42], FAIL
d7679a7b (fix/562-761-aarch64-testing-profile round 2) same tally, FAIL
8a52c22f (same branch, round 3) same tally, FAIL, 2 of 2 runs

So it arrives on main between 52491c4b and bfbb7575, and the aarch64
testing-profile branch inherits it rather than causing it. 1 of the 1 run at
the older main passed, so the gate was green there.

What would close it

Either the tally stops counting a program whose contract is a nonzero exit as
a failed process, or simple_exit's expected code is declared somewhere the
tally reads. Adding it to scripts/x86-gate-allowlist.txt would be the wrong repair: that
file's own header says a listed test must still fail, and this test is not
failing.

Activity

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions