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/omega-mv/blob/main/gpu/nvidia/om/blackwell/cpui.om # 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 Sign in to star 1 stars 0 watching About Files History Releases Proposed changes Issues For developers branch `main` Branches Tags History `omega-mv / gpu / nvidia / om / blackwell / cpui.om` 36 lines ยท 765 bytes Raw Blame History 1 note SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception 2 fn bw_imac sum uint a uint b uint to uint 3 ret uint and add ulong sum mul ulong a ulong b `4294967295` 4 end 5 fn bw_idot a view uint * b view uint * r ulong sh ulong to uint 6 nn = and sh `4294967295` 7 kk = shr sh 32 8 ai = and mul div r nn kk `4294967295` 9 bi = rem r nn 10 sum = uint 0 11 for p ulong `4294967295` 12 if ge p kk 13 ret sum 14 end 15 sum = bw_imac sum get a ai get b bi 16 ai = and add ai 1 `4294967295` 17 bi = and add bi nn `4294967295` 18 end 19 ret sum 20 end 21 fn bw_cpui a view uint * b view uint * c edit uint * to int 22 nn = bw_dim len a len b len c 23 if eq nn 0 24 ret -1 25 end 26 kk = div len b nn 27 sh = or shl kk 32 nn 28 for t ulong `18446744073709551615` 29 if ge t len c 30 ret 0 31 end 32 v = bw_idot view a view b t sh 33 put c and t `4294967295` v 34 end 35 ret 0 36 end