interplane.Get Omega
Read in your language

omega-mv

Omega: a language for verified programs, semantic identity and machine realization. Seed-born work and existing implementations have distinct provenance.

Brought by drakestapleton

branch main Branches Tags History

omega-mv / gpu / nvidia / checks / arest-gseg.om

24 lines · 663 bytes Raw Blame History
1note SPDX-License-Identifier: Apache-2.0
2note gpu/nvidia/checks/arest-gseg.om: argseg (gpu/nvidia/om/apirest/gseg.om), as misc_parts() of CUDApp
3note tests/api_rest_partitions.h calls it. Q its 16 q words, NY the output length; q after the call is output 128
4note on. Composed before arestg.om.
5text t_name "AREST-GSEG"
6text t_gseg "gseg"
7fn arop q view ulong 256 nq ulong ny ulong o edit ulong 256 to ulong
8if or or ne nq 16 gt ny 8 not ckis 0 t_gseg
9ckbad
10end
11a = new ulong 16 0
12for i ulong 16
13put a i get q i
14end
15y = new ulong 8 0x5a5a5a5a5a5a5a5a
16r = argseg a part y 0 ny
17for i ulong 8
18put o i get y i
19end
20for i ulong 16
21put o add 128 i get a i
22end
23ret r
24end