Skip to content

Commit

Permalink
Fix for T3K
Browse files Browse the repository at this point in the history
  • Loading branch information
joelsmithTT committed Feb 21, 2025
1 parent c037aa6 commit 107166e
Showing 1 changed file with 18 additions and 0 deletions.
18 changes: 18 additions & 0 deletions tests/wormhole/test_cluster_wh.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -104,6 +104,12 @@ TEST(SiliconDriverWH, Harvesting) {
int num_devices = target_devices.size();
std::unordered_map<chip_id_t, HarvestingMasks> simulated_harvesting_masks = {{0, {30, 0, 0}}, {1, {60, 0, 0}}};

for (auto chip : target_devices) {
if (!simulated_harvesting_masks.count(chip)) {
simulated_harvesting_masks[chip] = {60, 0, 0};
}
}

uint32_t num_host_mem_ch_per_mmio_device = 1;
Cluster cluster = Cluster(num_host_mem_ch_per_mmio_device, false, true, true, simulated_harvesting_masks);
auto sdesc_per_chip = cluster.get_virtual_soc_descriptors();
Expand Down Expand Up @@ -148,6 +154,12 @@ TEST(SiliconDriverWH, CustomSocDesc) {
std::set<chip_id_t> target_devices = get_target_devices();
std::unordered_map<chip_id_t, HarvestingMasks> simulated_harvesting_masks = {{0, {30, 0, 0}}, {1, {60, 0, 0}}};

for (auto chip : target_devices) {
if (!simulated_harvesting_masks.count(chip)) {
simulated_harvesting_masks[chip] = {60, 0, 0};
}
}

uint32_t num_host_mem_ch_per_mmio_device = 1;
// Initialize the driver with a 1x1 descriptor and explictly do not perform harvesting
Cluster cluster = Cluster(
Expand All @@ -174,6 +186,12 @@ TEST(SiliconDriverWH, HarvestingRuntime) {
std::set<chip_id_t> target_devices = get_target_devices();
std::unordered_map<chip_id_t, HarvestingMasks> simulated_harvesting_masks = {{0, {30, 0, 0}}, {1, {60, 0, 0}}};

for (auto chip : target_devices) {
if (!simulated_harvesting_masks.count(chip)) {
simulated_harvesting_masks[chip] = {60, 0, 0};
}
}

uint32_t num_host_mem_ch_per_mmio_device = 1;

Cluster cluster = Cluster(num_host_mem_ch_per_mmio_device, false, true, true, simulated_harvesting_masks);
Expand Down

0 comments on commit 107166e

Please sign in to comment.