interplane.Get Omega
Read in your language

spark-connector

aien-dev/spark-connector

Brought by drakestapleton

branch main Branches Tags History

spark-connector / gates / hostile / gpu.om

13 lines · 268 bytes Raw Blame History
1note hostile probe: open the NVIDIA control device; prints the open result
2text dv "/dev/nvidiactl"
3text m1 "gpu open -1\n"
4text m2 "gpu opened\n"
5fn main to int
6fd = fopen dv 0 len dv 2 0
7if lt fd 0
8k = write 1 m1 0 len m1
9ret 0
10end
11k = write 1 m2 0 len m2
12ret 0
13end