From 644a27a732e44003a9bb05385af5eb224810a375 Mon Sep 17 00:00:00 2001 From: eunhhu Date: Tue, 6 Oct 2026 10:32:56 +0100 Subject: 041 runs of b5 = bdfc4d7 and b6 = de9efad: batches knapsack 10.84 ms (the compiled code 7.93), matmul 36.41 (14.20), join 118.3 (78.7), sort 55.5 (35.6), roots 8.87 (9.57); the executor alone as many instructions as b4's; costs three ways on b5 and b6 (tagged by version, b4's too: adds 0.65, ops 4.00, recur 21.8, recur4 36.0); frontier.c: the suite's BFS as frontier batches (105,232 of 999,913 edges asked again in order, 99,997 added; walking a batch's edges together 2.17x the edges) --- research/experiments/041-batches/costs/recur4.aup | 13 +++++++++++++ research/experiments/041-batches/costs/time.c | 2 ++ 2 files changed, 15 insertions(+) create mode 100644 research/experiments/041-batches/costs/recur4.aup (limited to 'research/experiments/041-batches/costs') diff --git a/research/experiments/041-batches/costs/recur4.aup b/research/experiments/041-batches/costs/recur4.aup new file mode 100644 index 0000000..53e4650 --- /dev/null +++ b/research/experiments/041-batches/costs/recur4.aup @@ -0,0 +1,13 @@ +state out = 0 +input go = message { + n: u32 +} +on go { + let x = 1 + let total = 0 + for i in 0 .. go.n * 1000 { + x = x * 48271 - floor(x * 48271 / 2147483647) * 2147483647 + total = total + ((x - floor(x / 1000) * 1000) + (x - floor(x / 7) * 7)) + } + out = total + x +} diff --git a/research/experiments/041-batches/costs/time.c b/research/experiments/041-batches/costs/time.c index 621caa6..2fb99ea 100644 --- a/research/experiments/041-batches/costs/time.c +++ b/research/experiments/041-batches/costs/time.c @@ -8,6 +8,8 @@ * nest 200 x 200 x 200, the inner loop's rounds together: 200 lanes * adds 50,000 keys added in order to a DENSE list: an append's call * probes 100,000 keys added to a HASHED list, 1,000,000 found + * recur 1,000 x N rounds of MINSTD: a recurrence ahead of a batch + * recur4 recur and four reads of x into a sum (records of x in the lanes) * ops0, ops12, sum0, sum6, sum12: ops with one or twelve lets, and with * total = total + 1 for the max (n 51200, batches only): what * an instruction costs a batch apart from the reduction */ -- cgit v1.2.3