Closed aliuTT closed 8 months ago
@tt-dma This tests all ethernet links in your system:
- export TT_METAL_ENV=dev && export TT_METAL_HOME=$PWD && export ARCH_NAME=wormhole_b0 && export PYTHONPATH=$TT_METAL_HOME && make build
- make tests
- TT_METAL_SLOW_DISPATCH_MODE=1 ./build/test/tt_metal/unit_tests --gtest_filter="DeviceFixture.EthKernelsDirectSendAllConnectedChips"
The test is run using slow dispatch and multi threaded runtime, one thread per Device. The user kernels are here:
tests/tt_metal/tt_metal/test_kernels/dataflow/unit_tests/erisc/eth_l1_direct_send.cpp
tests/tt_metal/tt_metal/test_kernels/dataflow/unit_tests/erisc/eth_l1_direct_receive.cpp
I have a similar FW structure to the ncrisc or brisc kernels. There is a base FW tt_metal/hw/firmware/src/erisc.cc
that launches the user kernel FW tt_metal/hw/firmware/src/erisck.cc
. Ethernet physical cores can be accessed with these apis:
for (const auto& eth_core : device_0->get_active_ethernet_cores()) {
const auto& physical_core = device_0->ethernet_core_from_logical_core(eth_core);
}
Try to DPRINT from the local chip ethernet core and remote chip ethernet core. Let me know if you encounter any issues!
PR: https://github.com/tenstorrent-metal/tt-metal/pull/4709 implements this. We should have support + a gtest for printing from ethernet cores now.
Thanks David!
Likely that if context switching is done properly in eth FW this should be functional.