Update cpuinfo to the latest commit (#83620)

This hasn't been updated for a while, so pulling the latest commit from https://github.com/pytorch/cpuinfo. I wonder if it breaks anything

Fixes #83594

Pull Request resolved: https://github.com/pytorch/pytorch/pull/83620
Approved by: https://github.com/malfet
This commit is contained in:
Huy Do
2022-08-20 06:16:54 +00:00
committed by PyTorch MergeBot
parent b2ddef28d7
commit f0ee21fe0a
3 changed files with 4 additions and 58 deletions

View File

@ -88,6 +88,7 @@ new_local_repository(
name = "fbgemm",
build_file = "//third_party:fbgemm/BUILD.bazel",
path = "third_party/fbgemm",
repo_mapping = {"@cpuinfo" : "@org_pytorch_cpuinfo"}
)
new_local_repository(
@ -103,8 +104,8 @@ new_local_repository(
)
new_local_repository(
name = "cpuinfo",
build_file = "//third_party:cpuinfo.BUILD",
name = "org_pytorch_cpuinfo",
build_file = "//third_party:cpuinfo/BUILD.bazel",
path = "third_party/cpuinfo",
)

View File

@ -1,55 +0,0 @@
load("@rules_cc//cc:defs.bzl", "cc_library")
cc_library(
name = "clog",
srcs = [
"deps/clog/src/clog.c",
],
hdrs = glob([
"deps/clog/include/*.h",
]),
includes = [
"deps/clog/include/",
],
linkstatic = True,
visibility = ["//visibility:public"],
)
cc_library(
name = "cpuinfo",
srcs = glob(
[
"src/*.c",
"src/linux/*.c",
"src/x86/*.c",
"src/x86/cache/*.c",
"src/x86/linux/*.c",
],
exclude = [
"src/x86/mockcpuid.c",
"src/linux/mockfile.c",
],
),
hdrs = glob([
"include/*.h",
"src/*.h",
"src/cpuinfo/*.h",
"src/include/*.h",
"src/x86/*.h",
"src/x86/linux/*.h",
"src/linux/*.h",
]),
copts = [
"-DCPUINFO_LOG_LEVEL=2",
"-D_GNU_SOURCE=1",
],
includes = [
"include",
"src",
],
linkstatic = True,
visibility = ["//visibility:public"],
deps = [
":clog",
],
)