From 15d1ac33dbc54962578726d0add3d08137154457 Mon Sep 17 00:00:00 2001 From: eunhhu Date: Tue, 6 Oct 2026 04:32:27 +0100 Subject: 041 runs of stages 4 and 5, sums into cells and walks (b3 = 06c2978, b4 = c67f988): batches join 161.2 ms (the compiled code 74.4, alone 423.4), matmul 46.1, knapsack 15.1, roots 9.22; costs/: small modules timed three ways (an instruction about 20 ns a batch, a sum's end about 4 ns a round, an append about 100 ns as the executor's, the nested rounds 10.2 ms against the compiled code's 23.1) --- research/experiments/041-batches/costs/ops.aup | 17 +++++++++++++++++ 1 file changed, 17 insertions(+) create mode 100644 research/experiments/041-batches/costs/ops.aup (limited to 'research/experiments/041-batches/costs/ops.aup') diff --git a/research/experiments/041-batches/costs/ops.aup b/research/experiments/041-batches/costs/ops.aup new file mode 100644 index 0000000..cd49f85 --- /dev/null +++ b/research/experiments/041-batches/costs/ops.aup @@ -0,0 +1,17 @@ +state out = 0 +input go = message { + n: u32 +} +on go { + let total = 0 + for i in 0 .. go.n * 20 { + let a = i + 1 + let b = a + 2 + let c = b + 3 + let d = c + 4 + let e = d + 5 + let f = e + 6 + total = max(total, f) + } + out = total +} -- cgit v1.2.3