Interplane page as plain text, for reading tools and agents. English is the reference text: translate it with your own tool. Text in backticks and in ``` blocks (commands, fingerprints, file names) and link targets in <...> are exact: copy them, never translate them. Page: /drakestapleton/CUDApp/blob/main/evidence/ATTN-GENERAL-20261027-4d51f91f/ab2.sh # 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 Sign in to star 0 stars 0 watching About Files History Releases Proposed changes Issues For developers branch `main` Branches Tags History `CUDApp / evidence / ATTN-GENERAL-20261027-4d51f91f / ab2.sh` 31 lines · 1903 bytes Raw Blame History 1 #!/bin/bash 2 # AttnGeneral A/B v2 (diagnostic driver). One flock hold, beside the live 35B; defers to a Main WINDOW. 3 set -u 4 B=/home/drakestapleton/handoffs/BOARD.md 5 R=/home/drakestapleton/work/AttnGeneral/cudapp 6 M=/home/drakestapleton/work/AttnGeneral/main-`c30c0be` 7 ts() { date -u +%FT%TZ; } 8 post() { echo "$(ts) AttnGeneral: $*" >> "$B"; } 9 health() { apps=$(nvidia-smi --query-compute-apps=pid --format=csv,noheader | tr '\n' ' '); h=$(curl -s -m 2 127.0.0.1:18091/health); echo "apps=[$apps] health=$h"; } 10 window_open() { l=$(grep -E '^[0-9TZ:.-]+ Main: WINDOW-(START|END|ABORTED)' "$B" | tail -n 1); [[ "$l" == *WINDOW-START* ]]; } 11 exec 9>/tmp/aien-gb10.lock 12 window_open && { echo "window open"; exit 3; } 13 flock -w 900 9 || { echo "lock not acquired"; exit 3; } 14 window_open && { echo "window opened"; exit 3; } 15 pre=$(health); echo "pre: $pre" 16 case "$pre" in *"apps=[79557 ]"*'"status":"ok"'*) ;; *) post "NOT_RUN ab2: pre-health not clean ($pre)"; exit 4;; esac 17 D=$(ls -d $R/evidence/ATTN-GENERAL-`20261027`-*)/ab2; mkdir -p "$D" 18 post "GPU-START attn-general ab2 (flock, <=5 min, beside live 35B; $D)" 19 ( while :; do t=$(date +%s%N); h=$(curl -s -m 0.5 127.0.0.1:18091/health); f=$(printf '%s' "$h" | grep -o '"in_flight":[0-9]*' | cut -d: -f2); echo "$t ${f:--1}"; sleep 0.03; done ) > "$D/inflight.log" & 20 P=$!; sleep 0.3 21 for pair in $(seq 1 40); do 22 if (( pair % 2 )); then order="A B"; else order="B A"; fi 23 for arm in $order; do 24 bin=$R/build/gpu_attention_test; [ $arm = A ] && bin=$M/build/gpu_attention_test 25 t0=$(date +%s%N); "$bin" --timing --out "$D/$arm$pair.json" > "$D/$arm$pair.log" 2>&1; rc=$?; t1=$(date +%s%N) 26 echo -e "$arm\t$pair\t$t0\t$t1\t$rc" >> "$D/runs.tsv" 27 done 28 done 29 sleep 0.3; kill $P; wait $P 2>/dev/null 30 post_h=$(health); echo "$post_h" > "$D/health_post.txt"; echo "$pre" > "$D/health_pre.txt"; echo "post: $post_h" 31 post "GPU-END attn-general ab2; post: $post_h"