/tt-review-skills:tt-multichip-ccl-reviewfrom Tenstorrent Review Skills
Reviews multi-chip and collective-communication code: num_links vs device topology, bias-before-all-reduce numerics, distributed RMSNorm correctness, gather/reduce axes, fabric init order, and CCL tuning claims. Use when reviewing changes touching CCL ops, mesh devices, fabric, or all_gather/reduce_scatter/all_reduce paths.
Ships in Tenstorrent Review Skills. Installing the plugin adds it to Claude Code.
What the skill costs in Claude's context, stage by stage
Name and description: Claude knows it exists.
SKILL.md joins the conversation and stays.
Read when SKILL.md points to them.
Assumes tt-review-core. The failures here are device hangs and silent numerical errors, so
severity skews high.
num_links must match the physical topologyttnn.experimental.all_gather_async(..., num_links=N, ...) and siblings require N to match the
device topology's physical ethernet link count:
| Part | num_links |
|---|---|
| N150, 1 chip | N/A — no CCL |
| N300, 2 chips, ring | 1 |
| Galaxy, 32 chips, ring | 4 |
| TG (Tensor Galaxy) | per-axis; see the model's tt_ccl.py |
A wrong value deadlocks the device — a watchdog hang, not a soft failure. Hardcoding Galaxy's value on N300 has hung for 10+ minutes before timeout and needed a device reset.
So: flag any hardcoded num_links. The safe pattern is to take it from a sibling model's
tt_ccl module (tt_transformers/tt/ccl.py auto-detects). A literal that happens to be right for
the author's machine is still a finding, because it is wrong on every other part.
num_devicesWhen a matmul is followed by AllGather + FastReduceNC — or any sum-reduce across devices — fusing
bias via ttnn.linear(bias=...) adds it on each device, and the cross-device sum multiplies it
by num_devices.
The fix is to pre-divide:
if args.num_devices > 1:
bias_torch = state_dict[...] / args.num_devices
else:
bias_torch = state_dict[...]
# Distinct cache filename (e.g. "bias_div") so the old cache is not reloaded.
The cache filename matters as much as the division — a correct pre-divide with a stale cache name silently reloads the undivided weights, which looks exactly like the original bug. Check both.
The same trap applies to any reduced intermediate followed by a bias or scale add.
Where hidden activations are sharded across the normalised dimension, local RMSNorm computes
incorrect statistics. The distributed primitive triple is ttnn.rms_norm_pre_all_gather → an
all-gather of the stats → ttnn.rms_norm_post_all_gather.
Correct RMSNorm is mandatory; distributed RMSNorm is not. A replicated-activation stream plus local RMSNorm is acceptable when it preserves the decoder chain layout and measures faster. Do not flag the absence of the distributed path as a bug on its own — flag incorrect statistics, which means checking whether the normalised dimension is actually sharded.
Check the axis, not just the op. On a 2D mesh, gathering the wrong axis produces correctly-shaped output with wrong content, and PCC catches it only if the test covers multi-device. Confirm the axis against the sharding of the tensor being gathered, and confirm cluster axis conventions against a sibling model rather than assuming.
Fabric must be configured before open_mesh_device. A change that reorders device setup, or
introduces a helper that opens the mesh earlier, is a finding even if it currently works — it
depends on initialisation ordering that is easy to perturb.
Watcher and async CCL interact badly enough that a hang under watcher is not automatically evidence
of a CCL bug. If a finding rests on a watcher-enabled run, say so, and downgrade one severity step
per tt-review-core's ground-or-abstain rule.
Ring CCL passes data through ethernet data movers whose buffer counts, sizes and semaphore vectors must agree between host setup and device kernel arguments, and between the two ends of a channel. Host/device disagreements here produce out-of-bounds access, silent corruption, or a hang, and no type system catches them.
See references/edm-channel-consistency.md — num_buffers_per_channel agreement, buffer/semaphore
vector lengths, eth_buffer_size_bytes drift, ring size versus device count, and sender/receiver
symmetry.
chunks_per_sync, num_workers_per_link, num_buffers_per_channel do not improve
monotonically. Measured on Gemma3 N300: chunks_per_sync 10 → 4 improved by 309 us, then 4 → 2
regressed by 976 us; num_workers_per_link 2 → 4 improved, 4 → 8 was neutral and wasted cores;
num_buffers_per_channel 2 → 4 regressed by 47 us.
Consequence for review: a directional argument about these knobs is not evidence. "Increasing
workers should help" is not a reason to accept or reject a value. Ask for the small targeted sweep
— three or four values per knob — and treat an unswept knob change as CONSIDER, not as a
regression you can assert.
What SKILL.md sets; muted values are Claude Code's defaults
Three short reads, in order
npx claudepluginhub tenstorrent/skills --plugin tt-review-skills15 skills in this plugin
/llk-perf-audit-reviewStatic performance review of Tensix compute kernels — wasted cycles, redundant register and memory traffic, loop-invariant work, and cheaper numerically-equivalent instruction sequences. Gated by a provenance lens (sfpi-compiled versus hand-written) and a semantic-equivalence test. Use when reviewing SFPU or Tensix kernel changes under tt_metal/tt-llk./llk-race-audit-reviewReviews tt-llk kernel changes for the nine intra-kernel race hazard classes plus stale hardware config across invocations — cfg-word overlap, dataflow CB sync, instruction latency, mailbox sync, MMIO ordering, NoC sync, reconfig stalls, semaphore handshakes, and srcreg bank sync — plus the cross-class seams between them. Use when reviewing changes under tt_metal/tt-llk./tt-comment-hygiene-reviewOther plugins' skills for the same job