Your browser sucks, JavaScript disabled! Gunnar's console needs JavaScript and WebAssembly. Git over SSH on port 2222 does not.

nordisk/kleene

bench/split.md

What a split is worth

Each graph is cut into K parts three ways: by a hash of the node id (SplitKey::Hash(K)), by K equal blocks of ids (SplitKey::Blocks), and by a part per node computed by balanced label spreading (computed_split, given as SplitKey::Property). For each split: the crossing edges (edges whose two ends lie in different parts: the border edges of the core's Split), the nodes of the smallest and the largest part, and the split mode's cost in ONE process through the core's rounds (khop_rounds, reach_rounds, components_rounds): rounds (exchanges between parts), border entries handed over, bytes before compaction (entries x (4-byte node + value)), and wall time. Every answer is checked equal to the unsplit graph's (one part). Entries are counted as the cluster sends them since Sends::combine: one per target part and node a round, folded with the query's add. The k hops run level by level, one hop a round in every split (one part too), and their entries count each level's whole frontier, the part's own nodes included; the search and the components count border entries only. Counts depend on the graph and the split only; wall times depend on the host's load, written beside them. Made by kleene split-report.

How it was run

oden (AMD Ryzen Threadripper PRO 3975WX 32-Cores), 32 threads, shared with other sessions (load averages per line below). Four processes of kleene split-report, each mostly one thread (the rounds run part after part); the tables below are theirs, rows put together:

rows command commit run (UTC) load at start / end
zox-M, road2048: one part, hash, id blocks kleene split-report <data> --zox <zox-M> --graphs zox,road2048 --max-rounds 500 d7b52b6 (the tree of e8ceb7f before its rebase) 20:39-20:49Z 51.29 / 14.72
road2048-shuffled: one part, hash, id blocks kleene split-report <data> --graphs road2048-shuffled (limit 5000) d7b52b6 20:33-20:44Z 17.76 / 16.83
rmat24: one part, hash, id blocks kleene split-report <data> --graphs rmat24 (limit 5000) d7b52b6 20:33-20:38Z 17.76 / 52.79
computed, all four graphs kleene split-report <data> --zox <zox-M> --ways computed (limit 5000) 89a861c (SplitCompute's default: 100 rounds) 20:49-20:56Z 37.77 / 17.09

<data> = oden ~/lanes/kd/data/gar (read only), <zox-M> = its zox-M. Wall times: one trial, the rounds alone (the split and each part's graph are built before). The computed split's time is computed_split on the CPU (32 threads), K = 4 and 8, defaults (SplitCompute::new(K): 5 % slack, seed 0, at most 100 rounds). road2048-shuffled is road2048 with its ids shuffled by a fixed seed (SHUFFLE_SEED), the search source the image of road2048's. rmat24's ids are already shuffled by the generator.

road2048 hash and id blocks ran with a limit of 500 rounds (--max-rounds 500): without it the hash split's weak components ran over 20 minutes (stopped by hand at 20:39Z). Uncapped, the hash K4 search finished: 3844 rounds, 7118172 entries, 138.5 s, equal (two earlier runs of b4977aa and d7b52b6, load 120-133 and about 88). A cell capped at 500 holds the rounds run, the entries and time of those rounds; its answer is a part and is not checked.

graph nodes edges source
zox-M 29772 59105 851
road2048 4194304 10063734 362332
road2048-shuffled 4194304 10063734 2024781
rmat24 16777216 132718372 3790722

Crossing edges

graph K split crossing edges % of edges smallest part largest part made in
zox-M 4 hash 44432 75.17 7439 7446 -
zox-M 4 id blocks 44148 74.69 7443 7443 -
zox-M 4 computed 12739 21.55 7313 7594 83 rounds, 31.8 ms on CPU, 32 threads
zox-M 8 hash 51873 87.76 3719 3723 -
zox-M 8 id blocks 51657 87.40 3721 3722 -
zox-M 8 computed 16764 28.36 3607 3817 99 rounds, 58.0 ms on CPU, 32 threads
road2048 4 hash 10063734 100.00 1048574 1048579 -
road2048 4 id blocks 7372 0.07 1048576 1048576 -
road2048 4 computed 1042788 10.36 1020824 1078514 100 rounds, 1452.3 ms on CPU, 32 threads
road2048 8 hash 10063734 100.00 524286 524290 -
road2048 8 id blocks 17004 0.17 524288 524288 -
road2048 8 computed 1303490 12.95 510602 540829 100 rounds, 2160.0 ms on CPU, 32 threads
road2048-shuffled 4 hash 7552622 75.05 1048574 1048579 -
road2048-shuffled 4 id blocks 7548962 75.01 1048576 1048576 -
road2048-shuffled 4 computed 1044354 10.38 1022261 1075921 100 rounds, 2876.1 ms on CPU, 32 threads
road2048-shuffled 8 hash 8806830 87.51 524286 524290 -
road2048-shuffled 8 id blocks 8804634 87.49 524288 524288 -
road2048-shuffled 8 computed 1306336 12.98 512160 540367 100 rounds, 2843.1 ms on CPU, 32 threads
rmat24 4 hash 99538659 75.00 4194301 4194309 -
rmat24 4 id blocks 99535873 75.00 4194304 4194304 -
rmat24 4 computed 81384155 61.32 4035134 4403665 15 rounds, 5107.1 ms on CPU, 32 threads
rmat24 8 hash 116130628 87.50 2097150 2097155 -
rmat24 8 id blocks 116126763 87.50 2097152 2097152 -
rmat24 8 computed 101414794 76.41 2029056 2201744 16 rounds, 6087.3 ms on CPU, 32 threads

The split mode's cost in one process

Per query: rounds / entries sent / MB before compaction / ms; equal = the answer equals one part's.

graph K split khop-10 bfs wcc check load
zox-M 1 one part 10 / 327 / 0.0 / 0.1 0 / 0 / 0.0 / 2.0 0 / 0 / 0.0 / 1.1 equal 51.29
zox-M 4 hash 10 / 370 / 0.0 / 0.1 42 / 31355 / 0.2 / 9.8 8 / 65496 / 0.5 / 8.9 equal 51.29
zox-M 4 id blocks 10 / 374 / 0.0 / 0.1 39 / 30931 / 0.2 / 9.0 8 / 61161 / 0.5 / 8.1 equal 51.29
zox-M 4 computed 10 / 354 / 0.0 / 0.1 17 / 7111 / 0.0 / 4.5 4 / 21397 / 0.2 / 2.6 equal 37.77
zox-M 8 hash 10 / 378 / 0.0 / 0.1 48 / 36341 / 0.2 / 9.6 9 / 78744 / 0.6 / 11.7 equal 51.29
zox-M 8 id blocks 10 / 378 / 0.0 / 0.1 46 / 36099 / 0.2 / 10.8 9 / 75302 / 0.6 / 11.9 equal 51.29
zox-M 8 computed 10 / 357 / 0.0 / 0.1 25 / 9575 / 0.0 / 5.2 4 / 27271 / 0.2 / 3.3 equal 37.77
road2048 1 one part 10 / 129 / 0.0 / 0.1 0 / 0 / 0.0 / 147.0 0 / 0 / 0.0 / 21.0 equal 51.29
road2048 4 hash 10 / 201 / 0.0 / 0.3 capped at 500 / 404622 / 2.0 / 846.9 capped at 500 / 1883682833 / 15069.5 / 391017.3 equal where finished 51.29
road2048 4 id blocks 10 / 129 / 0.0 / 0.3 6 / 7222 / 0.0 / 200.9 6 / 18965 / 0.2 / 35.8 equal 22.57
road2048 4 computed 10 / 145 / 0.0 / 0.3 321 / 1010394 / 5.1 / 12004.6 357 / 176616643 / 1412.9 / 21508.3 equal 35.39
road2048 8 hash 10 / 201 / 0.0 / 0.3 capped at 500 / 404622 / 2.0 / 1025.2 capped at 500 / 1883682833 / 15069.5 / 366211.0 equal where finished 18.05
road2048 8 id blocks 10 / 129 / 0.0 / 0.3 10 / 16710 / 0.1 / 194.0 10 / 77004 / 0.6 / 47.4 equal 24.04
road2048 8 computed 10 / 145 / 0.0 / 0.4 512 / 1255370 / 6.3 / 16773.0 552 / 323814538 / 2590.5 / 35470.8 equal 36.26
road2048-shuffled 1 one part 10 / 129 / 0.0 / 0.3 0 / 0 / 0.0 / 469.0 0 / 0 / 0.0 / 30.2 equal 17.76
road2048-shuffled 4 hash 10 / 190 / 0.0 / 0.4 2347 / 6100843 / 30.5 / 79055.0 2058 / 79981357 / 639.9 / 27971.3 equal 17.14
road2048-shuffled 4 id blocks 10 / 187 / 0.0 / 0.4 2329 / 6096539 / 30.5 / 78051.6 2045 / 79185587 / 633.5 / 26166.0 equal 19.13
road2048-shuffled 4 computed 10 / 149 / 0.0 / 0.3 329 / 1012083 / 5.1 / 11621.0 298 / 10728064 / 85.8 / 3106.2 equal 28.86
road2048-shuffled 8 hash 10 / 197 / 0.0 / 0.4 2993 / 6926004 / 34.6 / 99733.9 2631 / 92364289 / 738.9 / 28393.9 equal 41.93
road2048-shuffled 8 id blocks 10 / 196 / 0.0 / 0.5 3001 / 6924385 / 34.6 / 100120.1 2625 / 91759904 / 734.1 / 28017.4 equal 30.13
road2048-shuffled 8 computed 10 / 142 / 0.0 / 0.4 502 / 1258403 / 6.3 / 16516.9 454 / 14188193 / 113.5 / 4089.5 equal 27.22
rmat24 1 one part 8 / 5924758 / 47.4 / 1057.6 0 / 0 / 0.0 / 54.2 0 / 0 / 0.0 / 77.7 equal 17.76
rmat24 4 hash 9 / 9674399 / 77.4 / 3929.8 6 / 7994199 / 40.0 / 3474.7 5 / 13747345 / 110.0 / 12112.4 equal 17.14
rmat24 4 id blocks 9 / 9673639 / 77.4 / 4040.5 7 / 7991324 / 40.0 / 3615.1 5 / 13698096 / 109.6 / 12121.8 equal 15.61
rmat24 4 computed 8 / 9347882 / 74.8 / 3401.6 5 / 6590111 / 33.0 / 2805.1 4 / 9415014 / 75.3 / 8521.7 equal 29.02
rmat24 8 hash 9 / 9844671 / 78.8 / 4355.8 7 / 8625976 / 43.1 / 4308.0 5 / 15265400 / 122.1 / 14827.8 equal 18.68
rmat24 8 id blocks 9 / 9844581 / 78.8 / 4831.8 7 / 8633498 / 43.2 / 5023.5 5 / 15217093 / 121.7 / 14947.5 equal 24.57
rmat24 8 computed 8 / 9508096 / 76.1 / 3907.7 5 / 6747912 / 33.7 / 3483.7 4 / 10050750 / 80.4 / 10727.1 equal 25.89

The computed split on the GPU

From lane kn's note (seam file, 2026-11-29 20:35Z; main 81416aa), loki RTX 5080 against loki's CPU, cargo run --release -p kleene-cubecl --example split_time, load 9-15; every GPU result equal to the CPU's (part, sizes, crossing edges, rounds):

graph K one round: GPU / CPU 12 cores / CPU 6 cores whole computed_split: GPU / CPU 12 / CPU 6
rmat24 4 110 / 303 / 398 ms 4.5 / 6.5 / 9.5 s (15 rounds)
rmat24 8 - 5.3 / 7.6 / 10.5 s
rmat26 4 464 / 1229 / 1973 ms 19.8 / 30.3 / 44.9 s
rmat26 8 - 23.3 / 37.4 / 54.0 s

The GPU round is mostly transfer (100 ms of the 110 on rmat24). On dwarf's Radeon 660M (integrated) the GPU is level with the CPU, so integrated GPUs keep the CPU kernel. Not measured here: the GPU on zox-M or the road graphs (oden's GPU is not used).

What it gains

What it does not gain