Skip to content

Fix: raise batch_paged_attention heap and drop flaky wall-time test#538

Merged
ChaoWao merged 1 commit into
hw-native-sys:mainfrom
ChaoWao:fix/raise-batch-paged-attention-heap-to-1-gib
Apr 13, 2026
Merged

Fix: raise batch_paged_attention heap and drop flaky wall-time test#538
ChaoWao merged 1 commit into
hw-native-sys:mainfrom
ChaoWao:fix/raise-batch-paged-attention-heap-to-1-gib

Conversation

@ChaoWao

@ChaoWao ChaoWao commented Apr 13, 2026

Copy link
Copy Markdown
Collaborator

Summary

  • tests/st/a2a3/tensormap_and_ringbuffer/batch_paged_attention: set
    PTO2_RING_HEAP=1073741824 (1 GiB, 2^30) via RUNTIME_ENV. Default
    1024 B is too small for this scene's intermediate tensors and causes
    the test to fail on hardware.
  • tests/ut/py/test_dist_worker/test_group_task: delete
    TestGroupParallel.test_group_wall_time. The wall-time assertion is
    flaky under scheduler jitter (observed 0.36 s against the 0.36 s
    threshold on a 0.2 s parallel / 0.4 s serial target), and without it
    the test is redundant with TestGroupBasic.test_group_both_workers_execute.

Testing

  • Hardware: python examples/scripts/run_example.py -k tests/st/a2a3/tensormap_and_ringbuffer/batch_paged_attention/kernels -g tests/st/a2a3/tensormap_and_ringbuffer/batch_paged_attention/golden.py -p a2a3
  • pytest tests/ut/py/test_dist_worker/test_group_task.py

@gemini-code-assist gemini-code-assist Bot left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Code Review

This pull request updates the kernel configuration in kernel_config.py by adding a RUNTIME_ENV dictionary that defines the PTO2_RING_HEAP environment variable. I have no feedback to provide as there are no review comments.

@ChaoWao ChaoWao force-pushed the fix/raise-batch-paged-attention-heap-to-1-gib branch from 444ffe0 to 0d88772 Compare April 13, 2026 10:46
@ChaoWao ChaoWao changed the title Fix: raise batch_paged_attention heap to 1 GiB Fix: raise batch_paged_attention heap and drop flaky wall-time check Apr 13, 2026
- tests/st/a2a3/tensormap_and_ringbuffer/batch_paged_attention: set
  PTO2_RING_HEAP to 1 GiB (2^30) via RUNTIME_ENV. The default 1024 B
  heap is too small for this scene's intermediate tensors and causes
  the test to fail on hardware.
- tests/ut/py/test_dist_worker/test_group_task: remove
  TestGroupParallel.test_group_wall_time. The wall-time assertion is
  flaky under scheduler jitter, and without it the test is redundant
  with TestGroupBasic.test_group_both_workers_execute.
@ChaoWao ChaoWao force-pushed the fix/raise-batch-paged-attention-heap-to-1-gib branch from 0d88772 to 8858c9c Compare April 13, 2026 10:49
@ChaoWao ChaoWao changed the title Fix: raise batch_paged_attention heap and drop flaky wall-time check Fix: raise batch_paged_attention heap and drop flaky wall-time test Apr 13, 2026
@ChaoWao ChaoWao merged commit 8d2972c into hw-native-sys:main Apr 13, 2026
13 checks passed
@ChaoWao ChaoWao deleted the fix/raise-batch-paged-attention-heap-to-1-gib branch April 16, 2026 03:26
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