Assemble lane results in chunk order without sorting
This commit is contained in:
@@ -21,7 +21,8 @@ is substantially complete. Findings 1–2 come from the initial review. Findings
|
|||||||
Finding 1 come from a stage-ordered algorithmic pass. The latter are refactoring
|
Finding 1 come from a stage-ordered algorithmic pass. The latter are refactoring
|
||||||
opportunities for consideration, not measured production bottlenecks or new
|
opportunities for consideration, not measured production bottlenecks or new
|
||||||
performance guarantees. None calls for another compatibility layer or application
|
performance guarantees. None calls for another compatibility layer or application
|
||||||
execution abstraction. This document records findings, not implemented fixes.
|
execution abstraction. The evidence below describes the reviewed baselines;
|
||||||
|
per-finding completion markers record the subsequent remediation work.
|
||||||
|
|
||||||
## Finding 1: Retain Genuine Native Timeouts During Concurrent Error Selection
|
## Finding 1: Retain Genuine Native Timeouts During Concurrent Error Selection
|
||||||
|
|
||||||
@@ -460,6 +461,11 @@ add a mixed-resource case only if needed to verify equivalent mask routing.
|
|||||||
|
|
||||||
## Finding 9: Traverse Dense Chunk Results Without Sorting Their Keys
|
## Finding 9: Traverse Dense Chunk Results Without Sorting Their Keys
|
||||||
|
|
||||||
|
**Status: Complete.** Lane assembly traverses the materializer's dense ordinals
|
||||||
|
directly, retaining artifact/diagnostic order, fallback counts, and reuse
|
||||||
|
eligibility without allocating or sorting a temporary key slice. Pipeline
|
||||||
|
concurrency/ready-job tests and race checks pass.
|
||||||
|
|
||||||
Priority: P3. Relevant stages: 11, 25, and 37.
|
Priority: P3. Relevant stages: 11, 25, and 37.
|
||||||
|
|
||||||
### Evidence And Complexity
|
### Evidence And Complexity
|
||||||
@@ -575,3 +581,27 @@ production model quality or performance. Intentional changes such as the hard
|
|||||||
configuration/CLI cutover, native retry ownership, content-only cache identity,
|
configuration/CLI cutover, native retry ownership, content-only cache identity,
|
||||||
no semantic reassessment on hits, explicit permissive fallback, and native
|
no semantic reassessment on hits, explicit permissive fallback, and native
|
||||||
diagnostic visibility are part of the agreed target, not regressions.
|
diagnostic visibility are part of the agreed target, not regressions.
|
||||||
|
|
||||||
|
## Remediation Completion
|
||||||
|
|
||||||
|
All nine findings are addressed in focused commits, with completion markers at
|
||||||
|
their owning findings above. Final verification after the code changes passed:
|
||||||
|
|
||||||
|
- `GOWORK=off GOPROXY=off go test ./...`.
|
||||||
|
- `GOWORK=off GOPROXY=off go vet ./...`.
|
||||||
|
- A fresh `GOWORK=off GOPROXY=off go build` to a temporary binary.
|
||||||
|
- Race tests for `internal/framework/pipeline`, `internal/framework/chunkmap`,
|
||||||
|
`internal/core/source`, `internal/cli`, and
|
||||||
|
`internal/modules/dnd/extract/scenedescriptions`.
|
||||||
|
- Executable `version`, offline pipeline validation of both maintained D&D
|
||||||
|
examples, and native spell prompt-requirements inspection.
|
||||||
|
- `git diff --check`, this document's local link destinations, and the affected
|
||||||
|
configuration-reference anchors.
|
||||||
|
|
||||||
|
The scene-cache regression covers both repartitioning directions, bypass
|
||||||
|
controls, current IDs, actual reuse without reassessment, and unusable hits.
|
||||||
|
The fallback regression exercises a real typed spell pipeline with a fake long
|
||||||
|
provider failure; focused checks retain full causes and module diagnostics.
|
||||||
|
Source/cache/capture regressions cover nonmonotonic unit order, concurrent hits,
|
||||||
|
and exact sensitivity routing without native snapshot mutation. No production
|
||||||
|
inference, new permanent validation gate, or performance guarantee was added.
|
||||||
|
|||||||
@@ -5,7 +5,6 @@ import (
|
|||||||
"errors"
|
"errors"
|
||||||
"fmt"
|
"fmt"
|
||||||
"path"
|
"path"
|
||||||
"sort"
|
|
||||||
"strings"
|
"strings"
|
||||||
"sync"
|
"sync"
|
||||||
"time"
|
"time"
|
||||||
@@ -333,12 +332,8 @@ func (r *Runner) runExtractJob(ctx context.Context, input RunInput, doc *source.
|
|||||||
}
|
}
|
||||||
|
|
||||||
func finalizeLaneExtract(state *laneExtractState) {
|
func finalizeLaneExtract(state *laneExtractState) {
|
||||||
indexes := make([]int, 0, len(state.results))
|
// Materialization assigns dense ordinals; finalization follows all lane jobs.
|
||||||
for index := range state.results {
|
for index := 0; index < len(state.results); index++ {
|
||||||
indexes = append(indexes, index)
|
|
||||||
}
|
|
||||||
sort.Ints(indexes)
|
|
||||||
for _, index := range indexes {
|
|
||||||
result := state.results[index]
|
result := state.results[index]
|
||||||
state.values = append(state.values, result.value)
|
state.values = append(state.values, result.value)
|
||||||
state.diagnostics = append(state.diagnostics, result.diagnostics...)
|
state.diagnostics = append(state.diagnostics, result.diagnostics...)
|
||||||
|
|||||||
Reference in New Issue
Block a user