Skip to content

Revert "Add (and fix) OSS check that et_operator_library dtype_select… #11571

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 1 addition & 3 deletions .ci/scripts/unittest-buck2.sh
Original file line number Diff line number Diff line change
Expand Up @@ -25,9 +25,7 @@ BUILDABLE_KERNELS_PRIM_OPS_TARGETS=$(buck2 query //kernels/prim_ops/... | grep -
# //runtime/kernel/... is failing because //third-party:torchgen_files's shell script can't find python on PATH.
# //runtime/test/... requires Python torch, which we don't have in our OSS buck setup.
for op in "build" "test"; do
buck2 $op $BUILDABLE_OPTIMIZED_OPS \
//examples/selective_build:select_all_dtype_selective_lib_portable_lib \
//kernels/portable/... \
buck2 $op $BUILDABLE_OPTIMIZED_OPS //kernels/portable/... \
$BUILDABLE_KERNELS_PRIM_OPS_TARGETS //runtime/backend/... //runtime/core/... \
//runtime/executor: //runtime/kernel/... //runtime/platform/...
done
15 changes: 0 additions & 15 deletions examples/selective_build/targets.bzl
Original file line number Diff line number Diff line change
Expand Up @@ -25,21 +25,6 @@ def define_common_targets():
],
)

executorch_generated_lib(
name = "select_all_dtype_selective_lib",
functions_yaml_target = "//executorch/kernels/portable:functions.yaml",
kernel_deps = [
"//executorch/kernels/portable:operators",
],
# Setting dtype_selective_build without using list or dict selection isn't a
# typical use case; we just do it here so that we can test that our mechanism
# for getting buck deps right for dtype_selective_build is working.
dtype_selective_build = True,
deps = [
":select_all_ops",
],
)

# Select a list of operators: defined in `ops`
et_operator_library(
name = "select_ops_in_list",
Expand Down
2 changes: 1 addition & 1 deletion shim_et/xplat/executorch/codegen/codegen.bzl
Original file line number Diff line number Diff line change
Expand Up @@ -752,7 +752,7 @@ def executorch_generated_lib(
See: https://www.internalfb.com/wiki/PyTorch/Teams/Edge/PyTorch_Edge_Core_Team/Dtype_Selective_Build/""")

if dtype_selective_build:
if not expose_operator_symbols and not (is_xplat() or runtime.is_oss):
if not expose_operator_symbols and not is_xplat():
fail("""
Dtype selective build with expose_operator_symbols=False works only in xplat -
there are undefined symbols otherwise. Please try to use xplat, or talk to the
Expand Down
Loading