Skip to content

fix: fail closed on post-spatial external skip in 1D-height tiling to match the 2D path - #35

Merged
asteinh merged 1 commit into
developfrom
feature/tile-failclosed-postspatial-skip
Aug 17, 2026
Merged

fix: fail closed on post-spatial external skip in 1D-height tiling to match the 2D path#35
asteinh merged 1 commit into
developfrom
feature/tile-failclosed-postspatial-skip

Conversation

@asteinh

@asteinh asteinh commented Aug 17, 2026

Copy link
Copy Markdown
Member

Summary

A rank-4 stage whose post-spatial Add/Mul/Concat consumes a stage-external,
output-resolution operand (e.g. [Conv(stride 2), Add(conv_out, skip)]) was admitted by
the 1D-height tiler, even though the 2D tiler already rejects that exact shape. The
1D-height executor loads every stage input at the spatial op's input-halo rows, so a
strided interior tile would read the external skip at stride*out_start rows -- the wrong
rows, and past the operand's height.

This shape is unreachable through the standard compile pipeline today (the greedy temporal
partition only emits a single forced op as an over-budget/tiled stage, so a multi-op stage
is never tiled), so it is a latent-correctness and path-consistency gap rather than an
active bug. It was confirmed by an adversarially-verified investigation. The fix makes the
1D-height and 2D paths reject in lockstep.

Change

  • New _has_post_spatial_binary(stage_ops): true when a Concat/Add/Mul is consumed
    at or after the stage's spatial op. Shared by _stage_2d_eligible (a behavior-preserving
    refactor of its existing post-spatial check) and _stage_tile_axis.
  • _stage_tile_axis returns TILE_AXIS_NONE for a rank-4 stage with a post-spatial
    binary/Concat, so it runs untiled via exec_stage_normal.
  • Tests: the new post-spatial shape is rejected on both the 1D and 2D paths; a pre-spatial
    co-tiled skip stays admitted on both.

Testing

Full suite: 338 passed, 2 skipped.

@asteinh
asteinh merged commit cf08cbe into develop Aug 17, 2026
10 checks passed
@asteinh
asteinh deleted the feature/tile-failclosed-postspatial-skip branch August 17, 2026 16:59
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant