This repository was archived by the owner on Apr 30, 2026. It is now read-only.
Commit 8a77e51
committed
test: assert ray_rowsel block size to actually catch over-allocation
The previous version of /rowsel/all_segments_compact only checked
seg_offsets[] values, which are computed identically on both buggy
and fixed code (they walk popcount[]). The bug was purely in the
size of the underlying ray_alloc block — invisible from the
seg_offsets surface.
Add a real regression assertion: BSIZEOF(sel->order) must be
strictly less than the buggy payload size (sized for total_pass).
For the 4-morsel/3-ALL/1-MIX shape: fixed payload is 66 bytes
(buddy order 7 -> 128 B block), buggy payload is 6210 bytes
(buddy order 13 -> 8192 B block). Verified by temporarily
re-introducing the bug — the assertion fires with
'actual_block < buggy_payload (8192 < 6210)'.1 parent ed61890 commit 8a77e51
1 file changed
Lines changed: 21 additions & 4 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
5 | 5 | | |
6 | 6 | | |
7 | 7 | | |
8 | | - | |
| 8 | + | |
9 | 9 | | |
10 | 10 | | |
11 | 11 | | |
| |||
279 | 279 | | |
280 | 280 | | |
281 | 281 | | |
282 | | - | |
283 | | - | |
284 | | - | |
| 282 | + | |
| 283 | + | |
| 284 | + | |
| 285 | + | |
285 | 286 | | |
286 | 287 | | |
287 | 288 | | |
288 | 289 | | |
289 | 290 | | |
290 | 291 | | |
291 | 292 | | |
| 293 | + | |
| 294 | + | |
| 295 | + | |
| 296 | + | |
| 297 | + | |
| 298 | + | |
| 299 | + | |
| 300 | + | |
| 301 | + | |
| 302 | + | |
| 303 | + | |
| 304 | + | |
| 305 | + | |
| 306 | + | |
| 307 | + | |
| 308 | + | |
292 | 309 | | |
293 | 310 | | |
294 | 311 | | |
| |||
0 commit comments