S126 · SOURCE-BOUND GATE EVIDENCE
K1: strict ELF RuntimePmm tahsis→reclaim round-trip
Operations --test hedefi → focused test içindeki include_str!/#[path] bağı → kaynak kesiti Bu sayfa yalnız S126 kapısına aittir; komşu kapıların kaynakları bu kabulün içine katılmaz.
S126Focused kod testiOperations id exactsource SHA exacttest target exact
operation: k1-runtime-elf-reclaim-qemu-partial
uygulama/model · focused test · Operations · 3 exact excerpt
sequence-bound=true · implementation-bound=false
01 · Testin bağlı olduğu uygulama/model kodu
Kapının yürüttüğü gerçek kaynak
tam Rust öğesiL4302–L4320
kernel/src/task/scheduler.rs::qemu_s135_strict_peers_cancellation_state
/// S135 uses the same post-cancellation graph invariant, but both peers are
/// independently published RuntimePmm ELFs and must also be reclaimed.
#[cfg(feature = "board-qemu")]
pub(crate) unsafe fn qemu_s135_strict_peers_cancellation_state(
caller_task: u64,
responder_task: u64,
endpoint_owner: u64,
target_endpoint: crate::ui::capability::CapId,
reply_cap_id: crate::ui::capability::CapId,
) -> bool {
qemu_strict_peers_cancellation_state(
caller_task,
responder_task,
endpoint_owner,
target_endpoint,
reply_cap_id,
)
}snippet sha256: aedad38bcd8a…file sha256: 838dd474448c…
02 · Doğrulayan test kodu
Operations komutuna bağlı focused test
tam Rust öğesiL87–L124
simulation/tests/runtime_elf_reclaim_source.rs::reclaim_scrubs_then_frees_after_forest_quiescence_and_before_asid_reuse
#[test]
fn reclaim_scrubs_then_frees_after_forest_quiescence_and_before_asid_reuse() {
let reclaim = between(RUNTIME_ADAPTER, "fn scrub_and_free_runtime_frame(", "\n}");
let begin = reclaim.find("begin_scrub").expect("scrub token");
let access = reclaim
.find("prepare_scrub_access")
.expect("typed scrub access");
let map = reclaim
.find("map_reserved_owned_frames(")
.expect("scrub kmap");
let overwrite = reclaim.find("core::ptr::write_bytes").expect("full scrub");
let unmap = reclaim.find("drop(mapped)").expect("scrub unmap");
let close = reclaim
.find("close_scrub_access")
.expect("scrub access close");
let complete = reclaim.find("complete_scrub").expect("scrub completion");
let free = reclaim.find("memory.free").expect("RuntimePmm return");
assert!(begin < access && access < map && map < overwrite);
assert!(overwrite < unmap && unmap < close && close < complete && complete < free);
let reaper = between(
SCHEDULER,
" fn reap_retired_task(&mut self)",
" /// CFS tarzı weight hesabı",
);
let forest = reaper
.find("task.owned_user_page_tables.take()")
.expect("page-table forest drop");
let frames = reaper
.find("reclaim_owned_user_frames(")
.expect("runtime frame reclaim");
let asid = reaper.find("free_asid(retired_asid)").expect("ASID-last");
assert!(forest < frames && frames < asid);
assert!(reaper.contains("core::mem::forget(task)"));
assert!(ADDRESS_SPACE.contains("runtime_frame_ledger: Option<"));
assert!(ADDRESS_SPACE.contains("self.runtime_frame_ledger.take()"));
}snippet sha256: 9e063b432948…file sha256: 5a7400c2d695…
03 · Kapı kimlik kaydı
Operations sıra, kimlik ve başlık bağı
tam Operations kaydıL26804–L26902
website/src/lib/operations.ts::k1-runtime-elf-reclaim-qemu-partial
{
id: "k1-runtime-elf-reclaim-qemu-partial",
date: "2026-08-23",
sequence: 126,
status: "passed",
umbrella_status: "partial",
title: "K1: strict ELF RuntimePmm tahsis→reclaim round-trip",
summary:
"S125'te açık kalan production frame dönüşü, QEMU hello strict ELF diliminde kapatıldı. Boot frame yetkisi permanent runtime-memory manager'a tek seferde devredildi; LOAD ve usable-stack frame'leri linear AllocationToken'larla AddressSpace→Task ledger'ına taşındı. Loader yazmaları shared EL1-only kmap penceresinden geçti. Reaper quiescence sonrasında forest drop → typed scrub/unmap/TLBI → RuntimePmm free → ASID-last sırasını uyguladı. QEMU'da 5 frame free=6144→6144 ve active_allocations=0→0 baseline'ına döndü. Kmap slot reuse sırasında bulunan TLBI VAALE1IS operand hatası VA>>12 kodlamasıyla düzeltildi. Bu dar QEMU round-trip K1 COMPLETE değildir.",
evidence: [
"Runtime ELF reclaim source-contract 4/4 ve RuntimeMemory reconciliation 5/5 PASS.",
"ELF/kmap/lifecycle/ASID focused kapıları 20/20 PASS: elf_loader_source 7/7, kernel_kmap_source 4/4, task_lifecycle_source 5/5 ve task_spawn_asid_source 4/4.",
"QEMU smoke PASS: `[K1-MEM0] ... text=1 data=1 stack=3 total=5 UNCLASSIFIED=0 RECONCILED=YES` ve `[K1-RUNTIME-ELF-RECLAIM] ... frames=5 free=6144->6144 active_allocations=0->0 BASELINE=PASS`.",
"Aynı smoke strict ELF W^X 2/2, EL0 return x4096, IPC reply 3/3 ve scheduler SEC 5 kapılarını korudu.",
"Kmap slot reuse hatasının kökü TLBI VAALE1IS operandına byte VA verilmesiydi; AArch64 VA[55:12] sözleşmesi için operand VA>>12 olarak düzeltildi ve source kapısına bağlandı.",
"board-qemu, board-rpi4 ve board-rpi5 `aarch64-unknown-none` cargo check 3/3 PASS; bunlar compile applicability'dir, fiziksel board runtime kanıtı değildir.",
"Tam workspace, S126 dışı frozen S96 exceptions.S hash uyuşmazlığında kırmızıdır; full-workspace GREEN iddia edilmez.",
"Kalıcı kapsam ve açık sınırlar: `docs/K1-S126-Runtime-ELF-Reclaim-Proof.md`.",
],
commands: [
"cargo test -p aselsan_microkernel_simulation --test runtime_elf_reclaim_source --test runtime_memory_reconciliation --test elf_loader_source --test kernel_kmap_source --test task_lifecycle_source --test task_spawn_asid_source",
"make verify-qemu",
"cargo check -p aselsan_kernel --target aarch64-unknown-none --no-default-features --features board-qemu",
"cargo check -p aselsan_kernel --target aarch64-unknown-none --no-default-features --features board-rpi4",
"cargo check -p aselsan_kernel --target aarch64-unknown-none --no-default-features --features board-rpi5",
"cargo test --workspace -- --test-threads=1",
],
terminalSessions: [
{
id: "s126-runtime-elf-focused",
title: "Runtime ELF sahiplik, kmap ve lifecycle kapıları",
commandLines: [
"cargo test -p aselsan_microkernel_simulation --test runtime_elf_reclaim_source --test runtime_memory_reconciliation --test elf_loader_source --test kernel_kmap_source --test task_lifecycle_source --test task_spawn_asid_source",
],
outputLines: [
"runtime_elf_reclaim_source: 4 passed",
"runtime_memory_reconciliation: 5 passed",
"elf_loader_source: 7 passed",
"kernel_kmap_source: 4 passed",
"task_lifecycle_source: 5 passed",
"task_spawn_asid_source: 4 passed",
"six focused groups: 29/29 PASS",
],
exitCode: 0,
outputMode: "selected",
},
{
id: "s126-qemu-runtime-roundtrip",
title: "Strict ELF RuntimePmm QEMU round-trip",
commandLines: ["make verify-qemu"],
outputLines: [
"K1-MEM0 ELF_FRAME_LEDGER: text=1 data=1 stack=3 total=5 UNCLASSIFIED=0 RECONCILED=YES",
"K1-RUNTIME-ELF-RECLAIM: frames=5 free=6144->6144 active_allocations=0->0 BASELINE=PASS",
"QEMU smoke PASS: strict ELF W^X 2/2 + runtime MEM0 ledger/reclaim baseline + EL0 return x4096 + IPC reply 3/3 + scheduler SEC 5",
],
exitCode: 0,
outputMode: "selected",
},
{
id: "s126-aarch64-compile-profiles",
title: "Üç AArch64 board profilinde compile applicability",
commandLines: [
"cargo check -p aselsan_kernel --target aarch64-unknown-none --no-default-features --features board-qemu",
"cargo check -p aselsan_kernel --target aarch64-unknown-none --no-default-features --features board-rpi4",
"cargo check -p aselsan_kernel --target aarch64-unknown-none --no-default-features --features board-rpi5",
],
outputLines: [
"board-qemu: PASS",
"board-rpi4: PASS",
"board-rpi5: PASS",
],
exitCode: 0,
outputMode: "selected",
},
{
id: "s126-workspace-independent-frozen-hash-red",
title: "Tam workspace: S126 dışı frozen S96 hash kırmızısı",
commandLines: ["cargo test --workspace -- --test-threads=1"],
outputLines: [
"rpi5_g8h_integration_source::wiring_does_not_mutate_timer_gic_boot_or_expand_runtime_scope: FAILED",
"S96 mutated exceptions.S: observed f7b47672...04fd, frozen expected c0eed3e2...cb89",
"S126 focused and QEMU gates remain PASS; full-workspace GREEN is not claimed",
],
exitCode: 101,
outputMode: "selected",
outputNote:
"Bağımsız kırmızı test veya frozen hash S126 kapsamında değiştirilmedi ya da gevşetilmedi.",
},
],
terminalSessionsNote:
"S126 host + QEMU runtime + üç AArch64 compile profilinin dar kanıtıdır. Tam workspace'teki bağımsız frozen S96 hash kırmızısı açıkça korunur; fiziksel veya device işlemi yapılmadı.",
limitations: [
"K1 COMPLETE değildir. Production dönüş yalnız QEMU hello strict ELF LOAD/usable-stack frame'lerini kapsar; IPC ELF ve diğer legacy BumpAllocator üreticileri kapsam dışıdır.",
"Page-table forest storage RuntimePmm sınıfı değildir; strict user PTE'leri RuntimeMemory MappingToken kayıtlarıyla temsil edilmez.",
"Capability, endpoint, IRQ, DMA, surface ve IPC-loan belleği aynı reconciliation envanterinde değildir; repeated spawn/fault/exit soak ve SMP TLB shootdown açıktır.",
"S124 archive/promotion STOP kalır. Son fiziksel boot/runtime PASS S92 BOOT8G / CPU1_PER_CPU_TIMER_ONLY; S123 PHYSICAL_BOOT8H=REJECTED_NO_PASS.",
"CARD_WRITE=0, PHYSICAL_CARD_READBACK=0, SYNC=0, EJECT=0, UART=STOP, POWER=STOP ve PHYSICAL_BOOT8H=STOP.",
],
},snippet sha256: 2226a47547e4…file sha256: 9726dbf00f84…
Focused test komutu
cargo test -p aselsan_microkernel_simulation --test runtime_elf_reclaim_source --test runtime_memory_reconciliation --test elf_loader_source --test kernel_kmap_source --test task_lifecycle_source --test task_spawn_asid_sourceproof: docs/K1-S126-Runtime-ELF-Reclaim-Proof.md
Registry schema v5 · generator
website/scripts/generate-code-gates.mjs · Tam SHA-256: 91d38c7b6222f0b4c117be786454853543da55a160e543d9b951057cc20dcc06