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/seed/omc/tests/pools/gf.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 / seed / omc / tests / pools / gf.om` 63 lines ยท 1269 bytes Raw Blame History 1 note gate-pools 1: float pools. F (f64) and G (f32) grow by 4096 elements 40 times, a blocker pool B above 2 note them forcing moves; each value written is read back after every grow. Prints 2*F[k] and 4*G[k] (as 3 note ulong), their sums, both lengths, the last elements (0), then G at its length traps 3. 4 global B uchar * 5 global F f64 * 6 global G f32 * 7 global ob uchar 24 8 fn pnum v ulong to void 9 put ob 23 10 10 i = ulong 23 11 x = v 12 go = true 13 while go bound 21 14 i = sub i 1 15 put ob i uchar add rem x 10 48 16 x = div x 10 17 go = ne x 0 18 end 19 k = write 1 ob i sub 24 i 20 end 21 fn plong v long to void 22 if lt v 0 23 put ob 0 uchar 45 24 k = write 1 ob 0 1 25 pnum ulong neg v 26 else 27 pnum ulong v 28 end 29 end 30 fn main to int 31 r = enlarge B ulong 1 32 r = enlarge F ulong 1 33 r = enlarge G ulong 1 34 pnum ulong get F 0 35 k = ulong 0 36 while lt k 40 37 r = enlarge B add len B 4096 38 r = enlarge F add len F 4096 39 r = enlarge G add len G 4096 40 put F k add f64 k 0.5f64 41 put G k add f32 k 0.25f32 42 pnum ulong mul get F k 2.0f64 43 pnum ulong mul get G k 4.0f32 44 k = add k 1 45 end 46 s = ulong 0 47 t = ulong 0 48 k = ulong 0 49 while lt k 40 50 s = add s ulong mul get F k 2.0f64 51 t = add t ulong mul get G k 4.0f32 52 k = add k 1 53 end 54 pnum s 55 pnum t 56 pnum len F 57 pnum len G 58 pnum ulong get F sub len F 1 59 pnum ulong get G 40 60 n = len G 61 pnum ulong get G n 62 ret 0 63 end