-
Notifications
You must be signed in to change notification settings - Fork 524
/
Copy pathTARGETS
114 lines (105 loc) · 2.88 KB
/
TARGETS
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
# Any targets that should be shared between fbcode and xplat must be defined in
# targets.bzl. This file can contain fbcode-only targets.
load("@fbsource//xplat/executorch/backends:backends.bzl", "get_all_cpu_aot_and_backend_targets")
load("@fbsource//xplat/executorch/build:runtime_wrapper.bzl", "runtime")
load(":targets.bzl", "define_common_targets")
oncall("executorch")
define_common_targets()
# Use runtime.python_library instead of the one defined in python_library.bzl,
# so we can have access to EXECUTORCH_CLIENTS list.
runtime.python_library(
name = "backend_api",
srcs = [
"backend_api.py",
],
visibility = [
"//executorch/...",
"//executorch/test/...",
"@EXECUTORCH_CLIENTS",
],
deps = [
":backend_details",
":compile_spec_schema",
"//caffe2:torch",
"//executorch/exir/backend:utils",
"//executorch/exir/backend/canonical_partitioners:duplicate_constant_node_pass",
],
)
runtime.python_library(
name = "compile_spec_schema",
srcs = [
"compile_spec_schema.py",
],
visibility = [
"//executorch/...",
"//executorch/test/...",
"@EXECUTORCH_CLIENTS",
],
)
runtime.python_library(
name = "partitioner",
srcs = [
"partitioner.py",
],
visibility = [
"//executorch/...",
"//executorch/test/...",
"@EXECUTORCH_CLIENTS",
],
deps = [
":compile_spec_schema",
"//caffe2:torch",
],
)
runtime.python_library(
name = "backend_details",
srcs = [
"backend_details.py",
],
visibility = [
"//executorch/...",
"//executorch/test/...",
"@EXECUTORCH_CLIENTS",
],
deps = [
":compile_spec_schema",
":partitioner",
"//caffe2:torch",
"//executorch/exir:delegate",
"//executorch/exir:graph_module",
],
)
# backend_lib includes all ahead of time apis and supported backends,
# it's supposed to be only used on server side and not for production on device.
runtime.python_library(
name = "backend_lib",
visibility = [
"//executorch/...",
"//executorch/test/...",
"@EXECUTORCH_CLIENTS",
],
deps = [
":backend_api",
":backend_details",
":utils",
"//executorch/exir/backend/canonical_partitioners:canonical_partitioner_lib",
] + get_all_cpu_aot_and_backend_targets(),
)
runtime.python_library(
name = "utils",
srcs = [
"utils.py",
],
visibility = [
"//executorch/...",
"//executorch/exir/backend/...",
"//executorch/test/...",
"@EXECUTORCH_CLIENTS",
],
deps = [
"fbsource//third-party/pypi/pandas:pandas",
"//caffe2:torch",
"//executorch/exir:lowered_backend_module",
"//executorch/exir/backend/canonical_partitioners:duplicate_constant_node_pass",
],
)