Debugging Kernels That Use Filters
Use this guide when a kernel uses counter filters or filtered sockets.
Check what was received
A wavelet arriving at a tile does not prove the filter accepted it. Check the received array as well as the arrival log.
- Confirm the sender's color and route reach the intended receiver.
- Check the filter's settings:
.min/.maxfor a range filter;.tick,.limitand.maxpassfor a counter filter. - Check that the receive length matches the number of values the filter should accept.
- Inspect the result in
bench-sim.corewithmiget, or usememinspto find when individual words were written.
Use files from the same run:
miget image=bench-sim.core map=bench.map symbol=recv.result text
meminsp img_path=bench.img map_path=bench.map log_path=bench-sim.log tile_str=T0.0
At the meminsp> prompt, replace recv.result with a name from symbols:
symbols
print recv.result
diff recv.result @0 @200
seek 0
watch recv.result changed
run
See the meminsp reference for more commands.
Common symptoms
| Symptom | What to check |
|---|---|
| Arrivals look correct, but the receive is short | Filter settings and the arriving traffic's color and route |
| The last expected value is missing | Pass window, receive length, and packets still waiting at the cycle limit |
| Only a boundary row or column fails | Per-tile state inputs, padding, and clamping |
| Output remains zero | Whether the receive completes and the output-writing code runs |
| A run with generated filter state fails | The state-generation parameters and whether the intended state file was loaded |
Start with one filtered socket and a short sequence of distinct values. Check the final received element as well as the total count before scaling back up.