review fixes of the block drafter's short block (independent review)

- declare_drafter: a block drafter's proposal_pitch, now the row pitch the engine reads row s
  at, defaults to depth (it defaulted to 1, which a pitch-reading engine would take as packed
  rows: wrong drafts from the second sequence and a read past the readback) and is refused
  under depth. The engine's fallback goes.
- run_block_drafter: hysteresis -- the short block goes on at --draft-short-from decoding
  sequences and off only two below, so a load wavering at the threshold does not switch the
  block (a new pass shape, the adaptive estimates) every step. Comment: the proposals are for
  the next step.
- block_begin's comment: after a long block a short one's reservation stops short of the trunk
  step's end; the rejected rows past it land on freed pages with slot -1, which every kv_store
  drops. Named as the load-bearing rule it is.
- The --draft-short-from warning names a serial head as such; the arch_test stub returns the
  real builder's codes.
- build_test: the pitch's default and refusal.

Co-Authored-By: Claude Opus 5.5 (1M context) <noreply@anthropic.com>
This commit is contained in:
mici81andClaude Opus 5.5 committed 2026-10-23 11:24:45 +00:00
1 parent 90e14c5015
commit da52bc8593
6 files changed
+55 -9

No files matched your search

+4 -3
View File
@@ -1306,9 +1306,10 @@ int Engine::declare() {
drafter_short_ = drafter_.kind == RAD_DRAFT_BLOCK && cfg_.draft_short_from > 0
? p0.drafter_short_block : 0;
if (cfg_.draft_short_from > 0 && drafter_.kind != RAD_DRAFT_NONE && !drafter_short_)
RAD_WARN("--draft-short-from %lld: '%s' declares no shorter block, so its block stays %lld",
(long long)cfg_.draft_short_from, drafter_name_.c_str(),
(long long)drafter_.block);
RAD_WARN("--draft-short-from %lld: '%s' %s", (long long)cfg_.draft_short_from,
drafter_name_.c_str(),
drafter_.kind == RAD_DRAFT_BLOCK ? "declares no shorter block, so its block stays"
: "is a serial head, which proposes no block");
if (drafter_short_)
RAD_INFO("speculation: from %lld decoding sequences on, '%s' runs its short block of %lld "
"row(s), %lld token(s), on the host's block driver", (long long)cfg_.draft_short_from,