cpuinfo changes for ppc64le support

This commit is contained in:
Sandeep Gupta 2024-09-26 19:15:17 +05:30
parent 07ba96e56a
commit 0bcd738d40
3 changed files with 25 additions and 0 deletions

View File

@ -182,6 +182,7 @@ def _tf_repositories():
name = "cpuinfo",
sha256 = "2bf2b62eb86e2d2eaf862d0b9683a6c467a4d69fb2f7f1dc47c799809148608f",
strip_prefix = "cpuinfo-fa1c679da8d19e1d87f20175ae1ec10995cd3dd3",
patch_file = ["//third_party/cpuinfo:cpuinfo_ppc64le_support.patch"],
urls = tf_mirror_urls("https://github.com/pytorch/cpuinfo/archive/fa1c679da8d19e1d87f20175ae1ec10995cd3dd3.zip"),
)

0
third_party/cpuinfo/BUILD vendored Normal file
View File

View File

@ -0,0 +1,24 @@
diff --git a/BUILD.bazel b/BUILD.bazel
index 2c6375f..5417d7e 100644
--- a/BUILD.bazel
+++ b/BUILD.bazel
@@ -137,6 +137,7 @@ cc_library(
":linux_riscv32": COMMON_SRCS + RISCV_SRCS + LINUX_SRCS + LINUX_RISCV_SRCS,
":linux_riscv64": COMMON_SRCS + RISCV_SRCS + LINUX_SRCS + LINUX_RISCV_SRCS,
":linux_s390x": COMMON_SRCS + LINUX_SRCS,
+ ":linux_ppc64le": COMMON_SRCS + LINUX_SRCS,
":macos_x86_64": COMMON_SRCS + X86_SRCS + MACH_SRCS + MACH_X86_SRCS,
":macos_x86_64_legacy": COMMON_SRCS + X86_SRCS + MACH_SRCS + MACH_X86_SRCS,
":macos_arm64": COMMON_SRCS + MACH_SRCS + MACH_ARM_SRCS,
@@ -277,6 +278,11 @@ config_setting(
values = {"cpu": "s390x"},
)
+config_setting(
+ name = "linux_ppc64le",
+ values = {"cpu": "ppc"},
+)
+
config_setting(
name = "macos_x86_64_legacy",
values = {