Use indexed sources for fallible constant rows - #9629
Conversation
Merging this PR will regress 1 benchmark
|
5b08a97 to
f640ec1
Compare
95c4505 to
eb173d5
Compare
eb173d5 to
bf06cf4
Compare
bf06cf4 to
838db34
Compare
Signed-off-by: Connor Tsui <connor.tsui20@gmail.com>
838db34 to
0dcfaae
Compare
Summary
RowFnhandles constant inputs so row kernels do not need separate execution paths for each input shape. #9628 adds an indexed source for infallible execution, but fallibleexecute_ownedstill uses a separate loop whenever any input is constant. That loop selects between row and constant values on every iteration, duplicating the traversal and hiding the fixed batch input shape from LLVM.Depends on #9628.
Changes
Extends the decoded indexed source to fallible
execute_ownedcalls. Each source validates its decoded length and fixes its row-or-constant behavior before traversal, allowing every input shape to usemap_checked_intowithout changing output initialization or deferred failure handling.This removes the separate
LaneZipbranch. Optimized x86 IR preserves the vector loop while reducing the focused deferred Boolean executor by 27% and the deferredi64executor by 19%, with the same bounds-panic sites. Tests cover a constant left-hand input, and the focused benchmark covers varying inputs and both partial-constant orientations.