Skip to content

[Bug] Daily full-scene run #31722222789 exposes manual PA regressions and sim lane poisoning #1832

Description

@doraemonmj

Summary

Daily Full Scene Tests run #31722222789 at 9a6a785934c3747d29547c67ee8c5849cd5b2c72 failed in 5 of 7 jobs.

The run contains 26 pytest failure records, but only 20 are direct failures. The remaining 6 are cascades after an a2a3sim run lane was poisoned by a scheduler timeout.

This is not caused by Daily using a different execution environment from Per-PR. Daily and Per-PR reuse the same _st-* workflows and platforms. The important difference is selection:

  • Per-PR runs with manual_mode=exclude.
  • Daily runs with manual_mode=include, i.e. the Per-PR scene set plus manual cases.
  • The pytest node is usually reported as Class::test_run, while that method loops through multiple CASES. Therefore, the same class passing in Per-PR only proves that its non-manual cases passed.

For comparison, the corresponding scene jobs passed in PR run #31697418830. The Daily failures are all reached through manual cases; they do not contradict the Per-PR result.

Failure classification

Category Direct failure records Affected coverage Observed cause
Host Build Graph task-ring exhaustion 2 a2a3 and a5 onboard Task Allocator Deadlock - Task Ring Full, active=16383/16384; these HBG cases build roughly 64K tasks before scheduling
Paged Attention golden mismatch 12 a2a3 and a5 onboard 11 large BF16 Case3 workloads fail with max_diff around 1.05–1.08; new A5 SPMD zero-query case fails with max_diff=inf
SPMD PA compile failures 4 a2a3/a5 sim, macOS and Ubuntu Clang rejects unsigned long to uint32_t narrowing; Linux also calls nonexistent setEntryOffset instead of setentryOffset
HighPerf PA scheduler stall 2 a2a3sim on macOS and Ubuntu Manual b4_h32_kv8_s512_bs128_fp16 stalls with SCHEDULER_TIMEOUT, completed=0/1, stuck_task_id=0
Poisoned-lane cascades 6 tests following the HighPerf timeout chip run lane is poisoned: finalize_native_run failed with code -100; these are not independent defects

Precision failures

The previously green Per-PR runs did not exercise the same shapes:

  • 11 failures are the manual Case3 shape: batch=64, num_heads=64, kv_head_num=1, head_dim=256, block_size=64, context_len=8192, max_model_len=32768, BF16. The smaller non-manual cases in the same classes passed in Per-PR. This points to a scale/shape-dependent correctness problem, rather than an environment difference.
  • TestSpmdPagedAttentionA5::TwoWayOneBlockZeroQuery is a new manual-only case from test: add manual cross-runtime SPMD paged attention coverage #1817. It is small (batch=2, context_len=128) and fails with max_diff=inf, so this one is not explained by workload scale and should be treated as a new SPMD PA correctness regression. It overlaps with, but is not fully covered by, SPMD paged attention fails with multi-block and multi-core A5 workloads #1816.

The large Case3 failures affect:

  • a2a3: TestPagedAttention, TestPagedAttentionManualScope, TestBatchPagedAttention, TestPagedAttentionUnrollManualScope, TestPagedAttentionUnroll, and TestPagedAttentionUnroll4dims
  • a5: TestPagedAttention, TestBatchPagedAttention, TestPagedAttentionUnrollManualScope, TestPagedAttentionUnroll, and TestPagedAttentionUnroll4dims

Watch history / CI optimization impact

Of the 20 direct failure records:

In other words, #1790 exposed the existing manual backlog through the new Daily sweep, but none of this run's failed cases were newly down-selected by that change.

Detailed direct failures

1. Onboard Host Build Graph cases

  • TestPagedAttentionHostBuildGraph::Case1 on a2a3
  • TestPagedAttentionHostBuildGraphA5::Case1 on a5

Both fail during prepare_native_run with:

FATAL: Task Allocator Deadlock - Task Ring Full!
active=16383/16384 (100.0%)

The heap still has capacity, so the immediate resource is the task ring/window rather than host memory. The cases document roughly 64K tasks, while the current ring window is 16K.

2. SPMD PA compile portability

  • a2a3 HBG on macOS: narrowing conversions in spmd_paged_attention_orch.cpp:118-120
  • a2a3 HBG on Ubuntu: setEntryOffset at paged_attention_parallel.cpp:695,701; available API is setentryOffset
  • a5 HBG and TMR on macOS: narrowing conversions in spmd_paged_attention_orch.cpp:136-138

3. a2a3sim HighPerf stall and cascades

The non-manual b1_h32_kv8_s128_bs128_fp16 case passes. The next, manual b4_h32_kv8_s512_bs128_fp16 case times out on both runner OSes:

SCHEDULER_TIMEOUT
S1:running-stalled
completed=0/1, running=1, stuck_task_id=0, stuck_core=0

After this, six later tests fail only because the shared lane remains poisoned:

  • macOS: TestSpmdSyncStart, TestSpmdSyncStartEarlyDispatch, TestSpmdSyncStartStress, TestSyncStartEarlyLocalOwner
  • Ubuntu: TestSpmdSyncStartEdge, TestChipSwimlaneMixed

All six passed in the referenced Per-PR run. The first investigation step should be to raise PTO2_SCHEDULER_TIMEOUT_MS to distinguish a genuinely stuck kernel from a workload that simply exceeds the current simulator budget.

Expected behavior

  • Daily remains a superset of Per-PR and all selected manual cases pass, or unsupported/resource-bound cases are skipped with an explicit reason.
  • One failed simulator case does not turn subsequent independent tests into false failures.
  • CI output identifies the failing entry inside CASES, rather than only reporting the enclosing Class::test_run node.

Suggested acceptance criteria

  • Fix or explicitly constrain the large BF16 Case3 workloads on a2a3 and a5.
  • Resolve the A5 SPMD zero-query inf mismatch together with, or as a scoped follow-up to, SPMD paged attention fails with multi-block and multi-core A5 workloads #1816.
  • Fix the SPMD orchestration narrowing conversions and the setEntryOffset spelling/API mismatch on both compiler paths.
  • Make HBG ring sizing support the documented task count, or reject/reshape these cases before allocator deadlock.
  • Determine whether the HighPerf b4/s512 failure is a real deadlock or a timeout-budget issue, then prevent lane poisoning from being counted as six additional root failures.
  • Improve parameterized-case reporting so the failing case name and parameters are present in the pytest failure node or assertion context.

Related: #1816, #1772, #1790, #1817.

Metadata

Metadata

Assignees

No one assigned

    Labels

    bugSomething isn't working

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions