louise
The Louise language: compiler, runtime, std, tooling
Clone avec HTTPS, un jeton personnel en mot de passe, ou avec SSH, une clé ajoutée dans vos paramètres.
Dernier runÉchoué#94 · main · 15 min 28 s
0Étoiles
0Forks
40Issues
Runtime: gate ring out of the no-qemu aarch64 check (CI)
4687d75 made louise_rt_prims depend on ring unconditionally, and ring's build script needs a C cross-compiler for aarch64. The forge has no qemu, so its aarch64 leg only type-checks and assembles louise_rt with --no-default-features (scripts/ci.sh) — a path designed to avoid exactly such dependencies (the mimalloc precedent, ADR 0038's note about ring's C). It failed with ToolNotFound: aarch64-linux-gnu-gcc (CI runs 433+). Gate ring like mimalloc: - louise_rt_prims: ring is optional, behind the default `crypto` feature; src/crypto.rs is cfg'd on it. - louise_rt: a default `crypto` feature forwards to louise_rt_prims/crypto; the prims dependency takes no default features, so --no-default-features really drops ring. The workspace dependency on louise_rt_prims now defaults features off; louise_interp opts into `crypto` (it implements std/crypto), louise_codegen_c needs neither. - louise_rt/src/crypto.rs follows tls.rs: without the feature the tl_crypto_* externs stay exported and panic the actor with "crypto support not built in (louise_rt's `crypto` feature)". The extern table marks tl_crypto_sha256/tl_crypto_hmac_sha256 unwinds() accordingly (pbkdf2's blocking() already implies it): generated code checks ctx->yielding after the call, so the panic propagates instead of running on with a bogus value. - scripts/runtime.sh, pgo-runtime.sh, tsan.sh and ci.sh's ASan leg add `crypto` to their --no-default-features builds: those archives link real programs (tests/run/crypto.lse among them). spike.sh's C spike uses no crypto and stays as-is. std/crypto against a --no-default-features runtime: not reachable in any shipped workflow — the archives programs link come from `cargo build -p louise_rt` (default features) and scripts/runtime.sh (mimalloc,tls,crypto); the aarch64 fallback only type-checks and assembles. If it were done by hand, the program links (symbols exist) and the hash call panics with the message above, verified: `error: panic: crypto support not built in (louise_rt's `crypto` feature)`, exit 101. Nothing else in louise_rt reaches the ring prims: only src/crypto.rs (tls.rs's rustls ring provider is behind `tls`, off in the fallback). Alternative rejected: installing gcc-aarch64-linux-gnu in .toboggan/workflows/ci.yml. The workflow runs on a fixed ubuntu-latest image and only ensures clang/cc and rustup; an apt install would work there but couples CI to the runner's package mirror, and does nothing for local scripts/ci.sh runs on machines without the cross toolchain. The in-repo gate fixes both and matches how mimalloc and tls are already handled.
Parents 3b2735c
13 fichiers modifiés, 165 ajouts, 73 suppressions
Cargo.toml+5−2crates/louise_core/src/externs.rs+6−3crates/louise_interp/Cargo.toml+2−1docs/adr/0050-scram-primitives.md+16−0docs/runtime-abi.md+1−1runtime/louise_rt/Cargo.toml+9−2runtime/louise_rt/src/crypto.rs+102−51runtime/louise_rt_prims/Cargo.toml+10−4runtime/louise_rt_prims/src/lib.rs+4−1scripts/ci.sh+5−3scripts/pgo-runtime.sh+2−2scripts/runtime.sh+2−2scripts/tsan.sh+1−1