Initial release of slime chunk search blog examples

This commit is contained in:
Yaossg 2026-11-20 22:11:27 +08:00
commit 057215c3a2
47 changed files with 40361 additions and 0 deletions

23
results/README.md Normal file
View file

@ -0,0 +1,23 @@
# 博客测量样本
保留[博客最终性能表](https://yaossg.com/site/docs/slime)对应的历史样本,测于 2026-10-19:
AMD Ryzen 7 5800H、NVIDIA GeForce RTX 3060 Laptop GPU。它们不是本次整理后重新测得的性能。
| 文件 | 内容 | 当前复现入口 |
| --- | --- | --- |
| `reverse.json` | 区间、输出差、预计算和成组筛选的逐轮样本 | `examples/bin/reverse` |
| `reuse.json` | 重复类与不同类输入的三版批次计时样本 | `examples/bin/reuse` |
| `full-search.json` | 正推吞吐样本、单点与半径 512 的 CLI 扫描样本 | `examples/bin/brute`、`bench/bin/slime-bench` |
`reverse.json` 的 `rows` 按博客顺序列出五版算法的历史样本;
其中剩余 30 位枚举为五轮中位数,区间及后三版为另一轮对照的 21 轮中位数。
当前 `reverse` 为便于复现,将五版合并到同一个程序轮换测量,不能据此认为旧数据来自这份整理后的源码。
复用输入保存在 `examples/data/`。历史数据中的计时口径见博客与示例说明;
`samples_ms` 为逐轮时间,`median_ms` 为中位数(均以毫秒计)。
`full-search.json` 的 CLI 样本计完整扫描墙钟,`brute` 的样本计 kernel 时间;
其中 `projected_full48_ms` 是吞吐外推。
不同阶段和不同输入的加速比不可直接相乘。新跑分请另存到 `artifacts/`。
已知图案、种子及预期计数分别放在 `bench/testdata/` 和 `examples/data/known-5x5.json`,
测试不依赖这些历史性能数据。

58
results/full-search.json Normal file
View file

@ -0,0 +1,58 @@
{
"brute": {
"count": 17179869184,
"samples_ms": [
300.036,
321.742,
332.635,
321.361,
326.042
],
"median_ms": 321.742,
"projected_full48_ms": 5271420.928
},
"cli_known": {
"center": [
51069,
419124
],
"radius_chunks": 0,
"square_size": 5,
"anchors": 1,
"position_batch": 32,
"job_batch": 2048,
"cache_classes": 4096,
"matches": 24,
"samples_ms": [
3.6075,
1.783925,
1.660317,
1.666167,
1.830725,
1.766916,
1.75565
],
"median_ms": 1.766916
},
"cli_region": {
"center": [
0,
0
],
"radius_chunks": 512,
"square_size": 5,
"anchors": 525313,
"position_batch": 128,
"job_batch": 2048,
"cache_classes": 4096,
"matches": 0,
"samples_ms": [
4406.497334,
4206.928895,
4306.823532,
4181.983991,
4355.03335
],
"median_ms": 4306.823532
}
}

94
results/reuse.json Normal file
View file

@ -0,0 +1,94 @@
{
"mixed512": {
"positions": 32768,
"jobs": 15424,
"matches": 0,
"rows": [
{
"mode": 1,
"classes": 32768,
"active_positions": 32768,
"samples_ms": [
147.004937,
149.773603,
154.089889,
146.688235,
157.906047
],
"median_ms": 149.773603
},
{
"mode": 2,
"classes": 512,
"active_positions": 32768,
"samples_ms": [
16.078712,
16.835057,
16.276929,
15.57441,
17.099009
],
"median_ms": 16.276929
},
{
"mode": 3,
"classes": 512,
"active_positions": 1216,
"samples_ms": [
9.526938,
10.984208,
12.278617,
9.392953,
10.389708
],
"median_ms": 10.389708
}
]
},
"random4096": {
"positions": 4096,
"jobs": 2960,
"matches": 0,
"rows": [
{
"mode": 1,
"classes": 4096,
"active_positions": 4096,
"samples_ms": [
21.293458,
21.163675,
20.567625,
20.537725,
20.631108
],
"median_ms": 20.631108
},
{
"mode": 2,
"classes": 4096,
"active_positions": 4096,
"samples_ms": [
22.357291,
22.729308,
22.8618,
22.176808,
22.662575
],
"median_ms": 22.662575
},
{
"mode": 3,
"classes": 4096,
"active_positions": 118,
"samples_ms": [
22.191759,
22.989958,
21.745316,
21.4955,
22.618483
],
"median_ms": 22.191759
}
]
}
}

129
results/reverse.json Normal file
View file

@ -0,0 +1,129 @@
{
"anchor": [
51069,
419124
],
"roots": 84,
"lower35": 11010048,
"rows": [
{
"mode": "low18_enumerate30",
"median_ms": 1692.736572,
"samples_ms": [
1709.381592,
1685.830688,
1692.736572,
1714.200562,
1681.941528
]
},
{
"mode": "intervals_only",
"median_ms": 0.780287981,
"samples_ms": [
0.780287981,
0.7792639732,
0.7823359966,
0.7792639732,
0.780287981,
0.780287981,
0.7813119888,
0.780287981,
0.7813119888,
0.780287981,
0.780287981,
0.780287981,
0.9953280091,
0.780287981,
0.7792639732,
0.780287981,
0.7813119888,
0.780287981,
0.7813119888,
0.780287981,
0.780287981
]
},
{
"mode": "difference_intervals",
"median_ms": 0.318464011,
"samples_ms": [
0.318464011,
0.3174400032,
0.3194879889,
0.318464011,
0.3133440018,
0.3194879889,
0.3194879889,
0.318464011,
0.318464011,
0.3143680096,
0.318464011,
0.3174400032,
0.3194879889,
0.318464011,
0.3174400032,
0.3174400032,
0.3194879889,
0.5335040092,
0.3133440018,
0.3194879889,
0.318464011
]
},
{
"mode": "precompute_intervals",
"median_ms": 0.2641919851,
"samples_ms": [
0.2641919851,
0.2641919851,
0.4423680007,
0.2641919851,
0.2641919851,
0.2641919851,
0.2641919851,
0.2641919851,
0.2641919851,
0.2641919851,
0.2641919851,
0.258047998,
0.2682879865,
0.2641919851,
0.2652159929,
0.2641919851,
0.2631680071,
0.2641919851,
0.2641919851,
0.2631680071,
0.2641919851
]
},
{
"mode": "group_intervals",
"median_ms": 0.1556479931,
"samples_ms": [
0.1556479931,
0.1556479931,
0.1576959938,
0.1556479931,
0.1556479931,
0.1556479931,
0.1566720009,
0.1556479931,
0.1556479931,
0.1556479931,
0.1556479931,
0.1546240002,
0.1556479931,
0.1546240002,
0.1556479931,
0.1556479931,
0.1556479931,
0.1556479931,
0.1556479931,
0.1556479931,
0.1556479931
]
}
]
}