diff --git a/backends/cortex_m/test/BUCK b/backends/cortex_m/test/BUCK index 5630c928299..a715de08a4b 100644 --- a/backends/cortex_m/test/BUCK +++ b/backends/cortex_m/test/BUCK @@ -1,3 +1,5 @@ +load("@fbcode_macros//build_defs:build_file_migration.bzl", "fbcode_target", "non_fbcode_target") +oncall("executorch") # Copyright (c) Meta Platforms, Inc. and affiliates. # All rights reserved. # @@ -6,6 +8,32 @@ load("targets.bzl", "define_common_targets") -oncall("executorch") -define_common_targets() +non_fbcode_target(_kind = define_common_targets,) + +# !!!! fbcode/executorch/backends/cortex_m/test/TARGETS was merged into this file, see https://fburl.com/workplace/xl8l9yuo for more info !!!! + +# Copyright (c) Meta Platforms, Inc. and affiliates. +# All rights reserved. +# +# This source code is licensed under the BSD-style license found in the +# LICENSE file in the root directory of this source tree. + +load("@fbcode_macros//build_defs:python_unittest.bzl", "python_unittest") +load("targets.bzl", "define_common_targets") + +fbcode_target(_kind = python_unittest, + name="test_replace_quant_nodes", + srcs=[ + "test_helpers_passes_utils.py", + "test_replace_quant_nodes.py", + ], + deps=[ + "//pytorch/ao:torchao", # @manual + "//caffe2:torch", + "//executorch/backends/cortex_m/passes:replace_quant_nodes_pass", + "//executorch/backends/cortex_m/ops:ops", + ], +) + +fbcode_target(_kind = define_common_targets,) diff --git a/backends/cortex_m/test/TARGETS b/backends/cortex_m/test/TARGETS deleted file mode 100644 index 292a087a88a..00000000000 --- a/backends/cortex_m/test/TARGETS +++ /dev/null @@ -1,25 +0,0 @@ -# Copyright (c) Meta Platforms, Inc. and affiliates. -# All rights reserved. -# -# This source code is licensed under the BSD-style license found in the -# LICENSE file in the root directory of this source tree. - -load("@fbcode_macros//build_defs:python_unittest.bzl", "python_unittest") -load("targets.bzl", "define_common_targets") - -oncall("executorch") -python_unittest( - name="test_replace_quant_nodes", - srcs=[ - "test_helpers_passes_utils.py", - "test_replace_quant_nodes.py", - ], - deps=[ - "//pytorch/ao:torchao", # @manual - "//caffe2:torch", - "//executorch/backends/cortex_m/passes:replace_quant_nodes_pass", - "//executorch/backends/cortex_m/ops:ops", - ], -) - -define_common_targets() diff --git a/backends/cuda/TARGETS b/backends/cuda/BUCK similarity index 83% rename from backends/cuda/TARGETS rename to backends/cuda/BUCK index d1cf4216bf7..9af7687efc9 100644 --- a/backends/cuda/TARGETS +++ b/backends/cuda/BUCK @@ -1,8 +1,9 @@ +load("@fbcode_macros//build_defs:build_file_migration.bzl", "fbcode_target", "non_fbcode_target") load("@fbsource//xplat/executorch/build:runtime_wrapper.bzl", "runtime") oncall("executorch") -runtime.python_library( +fbcode_target(_kind = runtime.python_library, name = "cuda_passes", srcs = [ "passes/__init__.py", @@ -16,7 +17,7 @@ runtime.python_library( ], ) -runtime.python_library( +fbcode_target(_kind = runtime.python_library, name = "cuda_backend", srcs = [ "cuda_backend.py", @@ -36,7 +37,7 @@ runtime.python_library( ], ) -runtime.python_library( +fbcode_target(_kind = runtime.python_library, name = "cuda_partitioner", srcs = [ "cuda_partitioner.py", @@ -50,7 +51,7 @@ runtime.python_library( ], ) -runtime.python_library( +fbcode_target(_kind = runtime.python_library, name = "triton_kernels", srcs = [ "triton/kernels/__init__.py", @@ -67,7 +68,7 @@ runtime.python_library( ], ) -runtime.python_library( +fbcode_target(_kind = runtime.python_library, name = "triton_replacement_pass", srcs = [ "triton/__init__.py", diff --git a/backends/cuda/runtime/TARGETS b/backends/cuda/runtime/BUCK similarity index 91% rename from backends/cuda/runtime/TARGETS rename to backends/cuda/runtime/BUCK index f13f41ab8b7..f71622d7241 100644 --- a/backends/cuda/runtime/TARGETS +++ b/backends/cuda/runtime/BUCK @@ -1,9 +1,10 @@ +load("@fbcode_macros//build_defs:build_file_migration.bzl", "fbcode_target", "non_fbcode_target") load("@fbsource//xplat/executorch/build:runtime_wrapper.bzl", "runtime") -load("//tools/build/buck:nvcc_flags.bzl", "get_nvcc_arch_args") +load("@fbcode//tools/build/buck:nvcc_flags.bzl", "get_nvcc_arch_args") oncall("executorch") -runtime.cxx_library( +fbcode_target(_kind = runtime.cxx_library, name = "cuda_platform", srcs = [ "platform/platform.cpp", @@ -27,7 +28,7 @@ runtime.cxx_library( ], ) -runtime.cxx_library( +fbcode_target(_kind = runtime.cxx_library, name = "runtime_shims", srcs = [ "shims/cuda_guard.cpp", @@ -74,7 +75,7 @@ runtime.cxx_library( ], ) -runtime.cxx_library( +fbcode_target(_kind = runtime.cxx_library, name = "cuda_backend", srcs = [ "cuda_backend.cpp", diff --git a/backends/cuda/runtime/shims/tests/BUCK b/backends/cuda/runtime/shims/tests/BUCK new file mode 100644 index 00000000000..e1f13b4db7f --- /dev/null +++ b/backends/cuda/runtime/shims/tests/BUCK @@ -0,0 +1,7 @@ +load("@fbcode_macros//build_defs:build_file_migration.bzl", "fbcode_target", "non_fbcode_target") +load("@fbcode_macros//build_defs:cpp_unittest.bzl", "cpp_unittest") +load(":targets.bzl", "define_common_targets") + +oncall("executorch") + +fbcode_target(_kind = define_common_targets,) diff --git a/backends/cuda/runtime/shims/tests/TARGETS b/backends/cuda/runtime/shims/tests/TARGETS deleted file mode 100644 index 9ff3e83a8bd..00000000000 --- a/backends/cuda/runtime/shims/tests/TARGETS +++ /dev/null @@ -1,6 +0,0 @@ -load("@fbcode_macros//build_defs:cpp_unittest.bzl", "cpp_unittest") -load(":targets.bzl", "define_common_targets") - -oncall("executorch") - -define_common_targets()