Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
29 changes: 24 additions & 5 deletions .claude/skills/test-all-device/SKILL.md
Original file line number Diff line number Diff line change
Expand Up @@ -16,15 +16,34 @@ Detection / isolation procedures referenced below live in
`--pto-session-timeout`.
4. **Select a device range** (§C, range ≤4) — or, when wrapping in
`task-submit`, let it pick via `--device auto --device-num <range size>`.
5. **Run through `task-submit`** (§E). The underlying command:
5. **Read the marker selector out of the same job** you took the timeout from.
`st-onboard-a2a3` is two pytest passes, not one: the sweep deselects
`-m "not sdma"` and a later step runs `-m sdma`. `st-onboard-a5` has no
marker filter. Take the expression from `ci.yml` rather than assuming, so
this skill cannot drift from the job it reproduces.
6. **Run through `task-submit`** (§E). The underlying command, on a platform
whose job carries the filter:

```bash
pytest examples tests/st --platform <platform> --device <range-or-$TASK_DEVICE> \
--pto-session-timeout <timeout> -v
pytest examples tests/st -m "not sdma" --platform <platform> \
--device <range-or-$TASK_DEVICE> --pto-session-timeout <timeout> -v
```

Then the quarantined pass, after it — never at the same time, since the
point of the split is that no fault-injection case meets a device that has
already provisioned SDMA:

```bash
pytest examples tests/st -m sdma --platform <platform> \
--device <2 devs or $TASK_DEVICE> --pto-session-timeout <timeout> -v
```

Dropping either pass changes what you tested: a single flat sweep is not
what CI runs and reports failures CI never sees
([`../testing/SKILL.md`](../testing/SKILL.md), issue #1425).

Parallelism is auto-driven by `--device`: on hardware, one in-flight
subprocess per device (`--max-parallel auto` = `len(--device)`); see
`docs/testing.md` for the full reuse hierarchy.
6. Report the results summary (pass/fail counts per task).
7. If any tests fail, show the relevant error output and which device failed.
7. Report the results summary (pass/fail counts per task), across both passes.
8. If any tests fail, show the relevant error output and which device failed.
23 changes: 19 additions & 4 deletions .claude/skills/test-runtime-device/SKILL.md
Original file line number Diff line number Diff line change
Expand Up @@ -18,15 +18,30 @@ Detection / isolation procedures referenced below live in
`--pto-session-timeout`.
5. **Select a device range** (§C, range ≤4) — or, when wrapping in
`task-submit`, let it pick via `--device auto --device-num <range size>`.
6. **Run through `task-submit`** (§E). The underlying command:
6. **Read the marker selector out of the same job** you took the timeout from.
`st-onboard-a2a3` is two pytest passes: the sweep deselects `-m "not sdma"`
and a later step runs `-m sdma`. `st-onboard-a5` has no marker filter. Both
quarantined tests are `tensormap_and_ringbuffer`, so the second pass is only
needed when `$ARGUMENTS` names that runtime.
7. **Run through `task-submit`** (§E). The underlying command:

```bash
pytest examples tests/st --platform <platform> --runtime $ARGUMENTS \
pytest examples tests/st -m "not sdma" --platform <platform> --runtime $ARGUMENTS \
--device <range-or-$TASK_DEVICE> \
--pto-session-timeout <timeout> -v
```

Then, for `tensormap_and_ringbuffer` on a platform whose job carries the
filter, the quarantined pass afterwards — never concurrently, since the
split exists so that no fault-injection case meets a device that has already
provisioned SDMA ([`../testing/SKILL.md`](../testing/SKILL.md), issue #1425):

```bash
pytest examples tests/st -m sdma --platform <platform> --runtime $ARGUMENTS \
--device <2 devs or $TASK_DEVICE> --pto-session-timeout <timeout> -v
```

Hardware parallelism is auto-driven by `--device` (one subprocess per
device); no extra flag needed.
7. Report the results summary (pass/fail counts per task).
8. If any tests fail, show the relevant error output and which device failed.
8. Report the results summary (pass/fail counts per task), across both passes.
9. If any tests fail, show the relevant error output and which device failed.
8 changes: 5 additions & 3 deletions docs/ci.md
Original file line number Diff line number Diff line change
Expand Up @@ -82,10 +82,12 @@ benefit — device bin-packing for L3, xdist fanout for L2, and a shared
`ChipWorker` per `(runtime, device)`:

```bash
# Recommended CI invocation
pytest examples tests/st --platform a2a3 --device 4-7 -x
# Recommended CI invocation — a2a3 deselects the SDMA marker, as the job does,
# and runs it as a second pass afterwards
pytest examples tests/st -m "not sdma" --platform a2a3 --device 4-7 -x
pytest examples tests/st -m sdma --platform a2a3 --device 4-5 -x

# Same for a5
# Same for a5, which has no marker filter
pytest examples tests/st --platform a5 --device 0-7 -x
```

Expand Down
Loading