Skip to content

Commit d4f9a6f

Browse files
committed
Update
[ghstack-poisoned]
1 parent 4d2bfd2 commit d4f9a6f

File tree

2 files changed

+10
-9
lines changed

2 files changed

+10
-9
lines changed

extension/threadpool/targets.bzl

Lines changed: 4 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,5 @@
11
load("@fbsource//xplat/executorch/backends/xnnpack/third-party:third_party_libs.bzl", "third_party_dep")
2+
load("@fbsource//xplat/executorch/build:build_variables.bzl", "THREADPOOL_SRCS")
23
load("@fbsource//xplat/executorch/build:runtime_wrapper.bzl", "runtime")
34

45
def define_common_targets():
@@ -8,11 +9,9 @@ def define_common_targets():
89
TARGETS and BUCK files that call this function.
910
"""
1011

11-
_THREADPOOL_SRCS = [
12-
"thread_parallel.cpp",
13-
"threadpool.cpp",
14-
"threadpool_guard.cpp",
15-
] + (["fb/threadpool_use_n_threads.cpp"] if not runtime.is_oss else [])
12+
_THREADPOOL_SRCS = THREADPOOL_SRCS + (
13+
["fb/threadpool_use_n_threads.cpp"] if not runtime.is_oss else []
14+
)
1615

1716
_THREADPOOL_HEADERS = [
1817
"threadpool.h",

shim_et/xplat/executorch/build/build_variables.bzl

Lines changed: 6 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -364,12 +364,14 @@ EXTENSION_TENSOR_SRCS = [
364364
"extension/tensor/tensor_ptr_maker.cpp",
365365
]
366366

367-
EXTENSION_THREADPOOL_SRCS = [
368-
"extension/threadpool/thread_parallel.cpp",
369-
"extension/threadpool/threadpool.cpp",
370-
"extension/threadpool/threadpool_guard.cpp",
367+
THREADPOOL_SRCS = [
368+
"thread_parallel.cpp",
369+
"threadpool.cpp",
370+
"threadpool_guard.cpp",
371371
]
372372

373+
EXTENSION_THREADPOOL_SRCS = ["extension/threadpool/" + x for x in THREADPOOL_SRCS]
374+
373375
EXTENSION_TRAINING_SRCS = [
374376
"extension/data_loader/file_data_loader.cpp",
375377
"extension/data_loader/mmap_data_loader.cpp",

0 commit comments

Comments
 (0)