-
Notifications
You must be signed in to change notification settings - Fork 14
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Set dispatch core to Ethernet on N300, ensuring 8x8 grid across devic…
…es (#1897) Current behaviour always sets dispatch core type to worker. This leads to a different grid size on N300 `7x8` and N150 `8x8`, since N300 is dual row harvested. This change moves dispatch to Ethernet cores on N300, freeing up another row and giving the same grid size. While I was adding, I gave the option of overriding from FEs when opening the device.
- Loading branch information
1 parent
78601d6
commit 7214507
Showing
14 changed files
with
144 additions
and
52 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,41 @@ | ||
// SPDX-FileCopyrightText: (c) 2025 Tenstorrent AI ULC | ||
// | ||
// SPDX-License-Identifier: Apache-2.0 | ||
|
||
#ifndef TT_RUNTIME_DETAIL_COMMON_H | ||
#define TT_RUNTIME_DETAIL_COMMON_H | ||
|
||
#include <optional> | ||
|
||
#define FMT_HEADER_ONLY | ||
#include "tt-metalium/host_api.hpp" | ||
|
||
#include "tt/runtime/detail/logger.h" | ||
#include "tt/runtime/types.h" | ||
|
||
namespace tt::runtime::common { | ||
|
||
inline ::tt::tt_metal::DispatchCoreType | ||
getDispatchCoreType(std::optional<DispatchCoreType> dispatchCoreType) { | ||
|
||
::tt::tt_metal::DispatchCoreType type; | ||
if (dispatchCoreType.has_value()) { | ||
if (dispatchCoreType == DispatchCoreType::ETH) { | ||
type = ::tt::tt_metal::DispatchCoreType::ETH; | ||
} else if (dispatchCoreType == DispatchCoreType::WORKER) { | ||
type = ::tt::tt_metal::DispatchCoreType::WORKER; | ||
} else { | ||
LOG_FATAL("Unsupported dispatch core type"); | ||
} | ||
} else { | ||
size_t numDevices = ::tt::tt_metal::GetNumAvailableDevices(); | ||
size_t numPCIeDevices = ::tt::tt_metal::GetNumPCIeDevices(); | ||
type = numDevices == numPCIeDevices | ||
? ::tt::tt_metal::DispatchCoreType::WORKER | ||
: ::tt::tt_metal::DispatchCoreType::ETH; | ||
} | ||
return type; | ||
} | ||
|
||
} // namespace tt::runtime::common | ||
#endif // TT_RUNTIME_DETAIL_COMMON_H |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.