Init
This commit is contained in:
commit
0e4e4b0979
19 changed files with 3185 additions and 0 deletions
27
pkgs/umd/default.nix
Normal file
27
pkgs/umd/default.nix
Normal file
|
@ -0,0 +1,27 @@
|
|||
{ pkgs }:
|
||||
|
||||
pkgs.stdenv.mkDerivation {
|
||||
pname = "tt-umd";
|
||||
version = "main-2024-02-01";
|
||||
|
||||
src = pkgs.fetchFromGitHub {
|
||||
owner = "tenstorrent-metal";
|
||||
repo = "umd";
|
||||
rev = "341f5b7b299f128faaf2ca446a03298cb781a645";
|
||||
hash = "sha256-jMxhhFWnCjNZZvFiTCeuEHvxvE0+IoaP4NJkr/CDLy8=";
|
||||
};
|
||||
|
||||
patches = [ ./fmt_mystery.patch ./missing_headers.patch ];
|
||||
|
||||
makeFlags = [
|
||||
"DEVICE_CXX=${pkgs.stdenv.cc.targetPrefix}c++"
|
||||
"ARCH_NAME=grayskull"
|
||||
];
|
||||
|
||||
buildInputs = with pkgs; [ libyamlcpp boost fmt hwloc ];
|
||||
|
||||
installPhase = ''
|
||||
mkdir $out
|
||||
mv build/lib $out
|
||||
'';
|
||||
}
|
25
pkgs/umd/fmt_mystery.patch
Normal file
25
pkgs/umd/fmt_mystery.patch
Normal file
|
@ -0,0 +1,25 @@
|
|||
diff --git a/device/cpuset_lib.cpp b/device/cpuset_lib.cpp
|
||||
index f8d5e03..93e89b7 100644
|
||||
--- a/device/cpuset_lib.cpp
|
||||
+++ b/device/cpuset_lib.cpp
|
||||
@@ -9,6 +9,7 @@
|
||||
#include <thread>
|
||||
#include "device/device_api.h"
|
||||
#include <filesystem>
|
||||
+#include <fmt/std.h>
|
||||
namespace tt {
|
||||
|
||||
namespace fs = std::filesystem;
|
||||
diff --git a/device/tt_silicon_driver.cpp b/device/tt_silicon_driver.cpp
|
||||
index fb243ed..c8950ae 100644
|
||||
--- a/device/tt_silicon_driver.cpp
|
||||
+++ b/device/tt_silicon_driver.cpp
|
||||
@@ -4342,7 +4342,7 @@ void tt_SiliconDevice::set_power_state(tt_DevicePowerState device_state) {
|
||||
set_pcie_power_state(device_state);
|
||||
} else {
|
||||
int exit_code = set_remote_power_state(chip, device_state);
|
||||
- log_assert(exit_code == 0, "Failed to set power state to {} with exit code: {}", device_state, exit_code);
|
||||
+ log_assert(exit_code == 0, "Failed to set power state with exit code: {}", exit_code);
|
||||
}
|
||||
}
|
||||
}
|
24
pkgs/umd/missing_headers.patch
Normal file
24
pkgs/umd/missing_headers.patch
Normal file
|
@ -0,0 +1,24 @@
|
|||
diff --git a/device/tt_cluster_descriptor.h b/device/tt_cluster_descriptor.h
|
||||
index c5c066e..84f17ce 100644
|
||||
--- a/device/tt_cluster_descriptor.h
|
||||
+++ b/device/tt_cluster_descriptor.h
|
||||
@@ -11,6 +11,7 @@
|
||||
|
||||
#include <unordered_map>
|
||||
#include <unordered_set>
|
||||
+#include <cstdint>
|
||||
#include <set>
|
||||
#include <map>
|
||||
#include <tuple>
|
||||
diff --git a/device/tt_soc_descriptor.cpp b/device/tt_soc_descriptor.cpp
|
||||
index adf77c2..3813eab 100644
|
||||
--- a/device/tt_soc_descriptor.cpp
|
||||
+++ b/device/tt_soc_descriptor.cpp
|
||||
@@ -5,6 +5,7 @@
|
||||
#include "tt_soc_descriptor.h"
|
||||
|
||||
#include <assert.h>
|
||||
+#include <cstdint>
|
||||
#include <fstream>
|
||||
#include <iostream>
|
||||
#include <regex>
|
Loading…
Add table
Add a link
Reference in a new issue