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/tests/grid_ab_exit_test.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 / tests / grid_ab_exit_test.sh` 22 lines · 727 bytes Raw Blame History 1 #!/bin/sh 2 # SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception 3 # Invalid lists stop before command-list creation. No device is opened. 4 set -eu 5 binary=${1:?usage: grid_ab_exit_test.sh BINARY} 6 tmp=$(mktemp -d) 7 trap 'rm -rf "$tmp"' EXIT HUP INT TERM 8 for arms in '' 'bad' '0:0' '0:0,bad' '0:0x,0:0'; do 9 rc=0 10 "$binary" --grid-ab "$arms" >"$tmp/output" 2>&1 || rc=$? 11 if [ "$rc" -ne 2 ]; then 12 cat "$tmp/output" 13 echo "FAIL: invalid grid list '$arms' returned $rc, expected 2" >&2 14 exit 1 15 fi 16 if grep -q ': PASS' "$tmp/output"; then 17 cat "$tmp/output" 18 echo 'FAIL: rejected grid list printed PASS' >&2 19 exit 1 20 fi 21 done 22 echo 'grid-ab invalid-list exit checks: PASS'