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/train/openaccel-lab/workloads/gemm_nt/omega.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 / train / openaccel-lab / workloads / gemm_nt / omega.om` 43 lines ยท 753 bytes Raw Blame History 1 note gemm_nt: fo[i*N + j] = sum_p fa[i*K + p] * fb[j*K + p], f32 accumulation in p order 2 note one function per output element keeps each function within omc's 16 registers (error 12) 3 global dm ulong 3 4 fn gnt_el i ulong j ulong to f32 5 k = get dm 2 6 ar = mul i k 7 br = mul j k 8 s = 0.0f32 9 for p ulong k 10 x = get fa add ar p 11 y = get fb add br p 12 s = add s mul x y 13 end 14 ret s 15 end 16 fn kern to void 17 n = get dm 1 18 for i ulong get dm 0 19 for j ulong n 20 put fo add mul i n j gnt_el i j 21 end 22 end 23 end 24 fn main to int 25 oal_begin 26 put dm 0 ulong oal_p 0 27 put dm 1 ulong oal_p 1 28 put dm 2 ulong oal_p 2 29 a = oal_fa 0 30 b = oal_fb 1 31 w = oal_warm 32 for i ulong add w oal_reps 33 t0 = monons 34 kern 35 t1 = monons 36 if ge i w 37 oal_tick sub t1 t0 38 end 39 end 40 oal_so 0 mul get dm 0 get dm 1 41 oal_end 42 ret 0 43 end