Support native Raspberry Pi build for XNNPACK delegate

PiperOrigin-RevId: 309419029
Change-Id: I06334be1e5bc2960570e7fee0f1d7619bb263309
This commit is contained in:
Marat Dukhan 2020-05-01 09:24:59 -07:00 committed by TensorFlower Gardener
parent 6bcfc5e26a
commit a952fa1b1c
2 changed files with 16 additions and 4 deletions
tensorflow
third_party/cpuinfo

View File

@ -177,11 +177,11 @@ def tf_repositories(path_prefix = "", tf_repo_name = ""):
tf_http_archive(
name = "XNNPACK",
sha256 = "41a0a396a5a9cb2171c1c7f6d7689316beaa6f638663161fc7f86450eba33070",
strip_prefix = "XNNPACK-5871703602c459b98c12be301c01255ae68a45e2",
sha256 = "aebbd8c707224b73f4bfafbac200f56b0d8c8da6053d21bd3e6c3df47d64ac69",
strip_prefix = "XNNPACK-582094e4c765fd78d8d3d28c2147e68c82a91768",
urls = [
"https://storage.googleapis.com/mirror.tensorflow.org/github.com/google/XNNPACK/archive/5871703602c459b98c12be301c01255ae68a45e2.zip",
"https://github.com/google/XNNPACK/archive/5871703602c459b98c12be301c01255ae68a45e2.zip",
"https://storage.googleapis.com/mirror.tensorflow.org/github.com/google/XNNPACK/archive/582094e4c765fd78d8d3d28c2147e68c82a91768.zip",
"https://github.com/google/XNNPACK/archive/582094e4c765fd78d8d3d28c2147e68c82a91768.zip",
],
)

View File

@ -97,6 +97,8 @@ cc_library(
name = "cpuinfo_impl",
srcs = select({
":linux_x86_64": COMMON_SRCS + X86_SRCS + LINUX_SRCS + LINUX_X86_SRCS,
":linux_arm": COMMON_SRCS + ARM_SRCS + LINUX_SRCS + LINUX_ARM32_SRCS,
":linux_armhf": COMMON_SRCS + ARM_SRCS + LINUX_SRCS + LINUX_ARM32_SRCS,
":linux_aarch64": COMMON_SRCS + ARM_SRCS + LINUX_SRCS + LINUX_ARM64_SRCS,
":macos_x86_64": COMMON_SRCS + X86_SRCS + MACH_SRCS + MACH_X86_SRCS,
":windows_x86_64": COMMON_SRCS + X86_SRCS + WINDOWS_X86_SRCS,
@ -165,6 +167,16 @@ config_setting(
values = {"cpu": "k8"},
)
config_setting(
name = "linux_arm",
values = {"cpu": "arm"},
)
config_setting(
name = "linux_armhf",
values = {"cpu": "armhf"},
)
config_setting(
name = "linux_aarch64",
values = {"cpu": "aarch64"},