66
77load("@fbcode_macros//build_defs:export_files.bzl", "export_file")
88load("@fbcode_macros//build_defs:python_library.bzl", "python_library")
9+ load("@fbcode_macros//build_defs:python_unittest.bzl", "python_unittest")
910load(
1011 "@fbsource//tools/build_defs:default_platform_defs.bzl",
1112 "CXX",
1213)
1314load("@fbsource//xplat/executorch/codegen:codegen.bzl", "executorch_generated_lib")
14- load("@fbcode_macros//build_defs:python_unittest.bzl", "python_unittest")
1515
1616oncall("odai_jarvis")
1717
@@ -36,18 +36,18 @@ python_library(
3636 "compiler.py",
3737 ],
3838 deps = [
39- ":passes",
40- ":utils",
39+ ":memory_planning",
4140 ":ops_registrations",
41+ ":passes",
4242 ":replace_ops",
43- ":memory_planning ",
43+ ":utils ",
4444 "//caffe2:torch",
4545 "//executorch/backends/cadence/aot/quantizer:fusion_pass",
4646 "//executorch/backends/cadence/aot/quantizer:quantizer",
4747 "//executorch/backends/transforms:decompose_sdpa",
4848 "//executorch/backends/transforms:remove_clone_ops",
49- "//executorch/exir:lib",
5049 "//executorch/devtools:lib",
50+ "//executorch/exir:lib",
5151 ],
5252)
5353
@@ -57,19 +57,19 @@ python_library(
5757 "export_example.py",
5858 ],
5959 deps = [
60- ":passes",
61- ":utils",
6260 ":ops_registrations",
61+ ":passes",
6362 ":replace_ops",
63+ ":utils",
6464 "//caffe2:torch",
6565 "//executorch/backends/cadence/aot/quantizer:fusion_pass",
66- "//executorch/backends/cadence/runtime:runtime",
6766 "//executorch/backends/cadence/aot/quantizer:quantizer",
68- "//executorch/backends/xnnpack/quantizer:xnnpack_quantizer ",
67+ "//executorch/backends/cadence/runtime:runtime ",
6968 "//executorch/backends/transforms:decompose_sdpa",
7069 "//executorch/backends/transforms:remove_clone_ops",
71- "//executorch/exir:lib ",
70+ "//executorch/backends/xnnpack/quantizer:xnnpack_quantizer ",
7271 "//executorch/devtools:lib",
72+ "//executorch/exir:lib",
7373 ],
7474)
7575
@@ -94,12 +94,12 @@ python_library(
9494 "passes.py",
9595 ],
9696 deps = [
97- ":utils",
9897 ":fuse_ops",
99- ":simplify_ops",
100- ":replace_ops",
101- ":reorder_ops",
10298 ":remove_ops",
99+ ":reorder_ops",
100+ ":replace_ops",
101+ ":simplify_ops",
102+ ":utils",
103103 "//caffe2:torch",
104104 "//executorch/exir:pass_base",
105105 "//executorch/exir/dialects:lib",
@@ -131,7 +131,6 @@ python_library(
131131 ],
132132)
133133
134-
135134export_file(name = "functions.yaml")
136135
137136executorch_generated_lib(
@@ -191,9 +190,9 @@ python_library(
191190 ],
192191 typing = True,
193192 deps = [
194- "//caffe2:torch",
195- ":ops_registrations",
196193 ":compiler_utils",
194+ ":ops_registrations",
195+ "//caffe2:torch",
197196 "//executorch/backends/cadence/aot:pass_utils",
198197 "//executorch/backends/cadence/aot:utils",
199198 "//executorch/exir:pass_base",
@@ -228,11 +227,11 @@ python_library(
228227 "//caffe2:torch",
229228 "//executorch/backends/cadence/aot:pass_utils",
230229 "//executorch/backends/cadence/aot:simplify_ops",
230+ "//executorch/backends/transforms:remove_clone_ops",
231231 "//executorch/exir:pass_base",
232232 "//executorch/exir/dialects:lib",
233233 "//executorch/exir/dialects/edge:lib",
234234 "//executorch/exir/passes:spec_prop_pass",
235- "//executorch/backends/transforms:remove_clone_ops"
236235 ],
237236)
238237
@@ -283,13 +282,13 @@ python_unittest(
283282 ],
284283 typing = True,
285284 deps = [
285+ ":ops_registrations",
286286 "//caffe2:torch",
287287 "//executorch/backends/cadence/aot:graph_builder",
288288 "//executorch/backends/cadence/aot:pass_utils",
289289 "//executorch/exir:pass_base",
290290 "//executorch/exir/dialects:lib",
291291 "//later:lib",
292- ":ops_registrations"
293292 ],
294293)
295294
@@ -319,8 +318,10 @@ python_unittest(
319318 srcs = [
320319 "tests/test_fusion_ops_passes.py",
321320 ],
321+ supports_static_listing = False,
322322 typing = True,
323323 deps = [
324+ "fbsource//third-party/pypi/parameterized:parameterized",
324325 ":compiler",
325326 "//caffe2:torch",
326327 "//executorch/backends/cadence/aot:compiler",
@@ -391,7 +392,6 @@ python_unittest(
391392 ],
392393)
393394
394-
395395python_library(
396396 name = "memory_planning",
397397 srcs = [
@@ -409,7 +409,6 @@ python_library(
409409 ],
410410)
411411
412-
413412python_library(
414413 name = "memory_constraints",
415414 srcs = [
@@ -425,7 +424,6 @@ python_library(
425424 ],
426425)
427426
428-
429427python_unittest(
430428 name = "test_memory_passes",
431429 srcs = [
0 commit comments