interplane.Get Omega
Read in your language

CUDApp

CUDA++: AIEN’s GPU machine-code toolchain, runtime and driver client for NVIDIA GPUs without the CUDA toolkit. Hardware coverage and driver replacement limits are explicit.

Brought by drakestapleton

branch main Branches Tags History

CUDApp / evidence / uxl-brief-20261113 / archive / level2-rebuild / logs / runC-controls.sh

38 lines · 2786 bytes Raw Blame History
1# Controls, run from SCRATCH/C. Separate fresh clone so the Run B tree stays untouched.
2set -x
3date -u +%FT%TZ
4git clone -q https://www.aienos.com/rad/z4RxD8vXigmWg61nM8miQ8DVPAXEP.git CUDApp; echo "### rc=$?"
5git -C CUDApp checkout -q dc536882c06a692991be97dc65cd2d037d82b129; echo "### rc=$?"
6git -C CUDApp rev-parse HEAD
7# --- control 1: compiler with exactly one byte changed (last byte XOR 0x01) ---
8cp ../B/omega-mv/seed/out/omc omc-onebyte
9python3 -c "
10import pathlib; p=pathlib.Path('omc-onebyte'); b=bytearray(p.read_bytes()); b[-1]^=1; p.write_bytes(b)"
11cmp -l ../B/omega-mv/seed/out/omc omc-onebyte | wc -l
12sha256sum ../B/omega-mv/seed/out/omc omc-onebyte
13cd CUDApp
14ls -d build 2>&1
15python3 -I tests/amd-kfd-launch/check.py "$(realpath ../omc-onebyte)"; echo "### rc=$? wrong-compiler (one byte changed)"
16ls -d build 2>&1; echo "### ls-build rc=$? (2 = no build directory was created)"
17git status --short --ignored | head -5; echo "### git status lines above (none = tree untouched)"
18# --- control 2: the path form the brief's realpath protects against (relative path) ---
19python3 -I tests/amd-kfd-launch/check.py ../../B/omega-mv/seed/out/omc; echo "### rc=$? relative compiler path"
20ls -d build 2>&1
21# --- qemu-absent run: PATH is a symlink farm of /usr/bin without qemu-x86_64* ---
22mkdir -p ../noqemu-bin
23for f in /usr/bin/*; do b=$(basename "$f"); case "$b" in qemu-x86_64*) ;; *) ln -sf "$f" ../noqemu-bin/"$b";; esac; done
24NQ=$(realpath ../noqemu-bin)
25env PATH="$NQ" sh -c 'command -v qemu-x86_64; echo "### command -v qemu rc=$?"; command -v python3 cc'
26env PATH="$NQ" python3 -I tests/amd-kfd-launch/check.py "$(realpath ../../B/omega-mv/seed/out/omc)" > ../noqemu-gate-stdout.log 2> ../noqemu-gate-stderr.log; echo "### rc=$? gate without qemu-x86_64 on PATH"
27tail -2 ../noqemu-gate-stdout.log | cut -c1-240; tail -5 ../noqemu-gate-stderr.log
28grep -c '^PASS ' ../noqemu-gate-stdout.log; grep -c '^FAIL ' ../noqemu-gate-stdout.log
29python3 -c "
30import json; s=json.load(open('build/amd-kfd-launch/gate/summary.json')); print('summary checks',s['checks'],'failures',s['failures'],'qemu',s['qemu'])"
31sha256sum build/amd-kfd-launch/gate/launch-x86 build/amd-kfd-launch/gate/launch-a64 build/amd-kfd-launch/gate/vadd.hsaco
32# --- Level 1 tamper control (this throwaway clone only): change one byte of one published raw file ---
33python3 -I evidence/amd-qwen38-native-refusal-20261113/verify.py; echo "### rc=$? verify.py clean"
34python3 -c "
35import pathlib; p=pathlib.Path('evidence/amd-qwen38-native-refusal-20261113/native/sample1.stdout'); b=bytearray(p.read_bytes()); b[-2]^=1; p.write_bytes(b)"
36git status --short
37python3 -I evidence/amd-qwen38-native-refusal-20261113/verify.py; echo "### rc=$? verify.py after one-byte tamper of native/sample1.stdout"
38date -u +%FT%TZ