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 / tests / speculation / native-kernel-test.om

57 lines · 1237 bytes Raw Blame History
1note Physical seeded Omega vector-kernel qualification, full output checks and safe wrong-math control.
2global diag uchar 24
3text ok "NATIVE_SM121_VECTOR_PASS\n"
4text bad "NATIVE_SM121_VECTOR_FAIL\n"
5fn pack off ulong v long to void
6for i ulong 8
7put diag add off i uchar and shr v mul i 8 255
8end
9end
10fn ck yes bool to void
11if not yes
12pack 0 long get nvstage 0
13pack 8 get nverr 0
14closed = nvstop
15pack 16 long get nvfault 0
16r = write 2 bad 0 len bad
17r = write 1 diag 0 len diag
18exit int 80
19end
20end
21fn trial n uint salt ulong wrong bool to void
22prepare n salt
23ck gblaunch n
24verify n salt wrong
25end
26fn program wrong bool to void
27gbvec
28if wrong
29note IADD3 R9,R2,RZ safely computes the wrong value while retaining all memory bounds.
30put gbcode 276 255
31end
32m = nvalloc 4096 true
33ck gt m 0
34put gbmem 4 m
35ck eq mapwrite m 0 gbcode 0 get gblen 0 long get gblen 0
36end
37fn main to int
38ck gbopen 1048576
39ck not gblaunch 0
40ck not gblaunch 1048577
41trial 1 1 false
42trial 63 17 false
43trial 64 31 false
44trial 65 47 false
45trial 257 63 false
46trial 4097 97 false
47trial 65537 131 false
48trial 1048576 257 false
49program true
50trial 4097 311 true
51program false
52trial 4097 367 false
53ck nvstop
54ck eq get nvfault 0 0
55ck eq write 1 ok 0 len ok long len ok
56ret 0
57end