Skip to content

Commit dda2c59

Browse files
committed
Update on "[ET-VK][9/n] clone node"
Introduce a clone node for copy operation. Also register `aten.clone` to this node. Important to note that during model export, possible to point the lvalue of `aten.clone` to the underlying shared object of the rvalue to achieve no-copy. Differential Revision: [D56441547](https://our.internmc.facebook.com/intern/diff/D56441547/) [ghstack-poisoned]
2 parents 49cc26c + 9791d86 commit dda2c59

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

61 files changed

+1866
-914
lines changed

.ci/docker/ci_commit_pins/pytorch.txt

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1 +1 @@
1-
19f50333e91e9e8b20a78517becd74bca70c7d46
1+
b1984237a0fb32b760c1b84d6d02d2f0f7ed293b

.ci/docker/requirements-ci.txt

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -6,7 +6,7 @@ sympy==1.12
66
timm==0.6.13
77
tomli==2.0.1
88
torchsr==1.0.4
9-
transformers==4.36.0
9+
transformers==4.38.0
1010
zstd==1.5.5.1
1111
pytest==7.2.0
1212
pytest-cov==4.1.0

.github/dependabot.yml

Lines changed: 11 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,11 @@
1+
# From https://docs.github.com/en/code-security/dependabot/dependabot-version-updates/configuration-options-for-the-dependabot.yml-file
2+
version: 2
3+
updates:
4+
- package-ecosystem: "pip"
5+
directory: "/"
6+
schedule:
7+
interval: "weekly"
8+
reviewers:
9+
- "pytorch/team-executorch"
10+
allow:
11+
- dependency-name: "torchfix"

CMakeLists.txt

Lines changed: 9 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -562,6 +562,11 @@ if(EXECUTORCH_BUILD_PYBIND)
562562
list(APPEND _dep_libs custom_ops)
563563
endif()
564564

565+
if(EXECUTORCH_BUILD_QUANTIZED)
566+
target_link_options_shared_lib(quantized_ops_lib)
567+
list(APPEND _dep_libs quantized_kernels quantized_ops_lib)
568+
endif()
569+
565570
# TODO(larryliu): Fix macOS 2 dylibs having 2 sets of static variables issue
566571
if(EXECUTORCH_BUILD_CUSTOM_OPS_AOT AND NOT APPLE)
567572
list(APPEND _dep_libs custom_ops_aot_lib)
@@ -583,8 +588,11 @@ if(EXECUTORCH_BUILD_PYBIND)
583588

584589
# pybind portable_lib
585590
pybind11_add_module(portable_lib extension/pybindings/pybindings.cpp)
591+
# The actual output file needs a leading underscore so it can coexist with
592+
# portable_lib.py in the same python package.
593+
set_target_properties(portable_lib PROPERTIES OUTPUT_NAME "_portable_lib")
586594
target_compile_definitions(portable_lib
587-
PUBLIC EXECUTORCH_PYTHON_MODULE_NAME=portable_lib)
595+
PUBLIC EXECUTORCH_PYTHON_MODULE_NAME=_portable_lib)
588596
target_include_directories(portable_lib PRIVATE ${TORCH_INCLUDE_DIRS})
589597
target_compile_options(portable_lib PUBLIC ${_pybind_compile_options})
590598
target_link_libraries(portable_lib PUBLIC ${_dep_libs})

backends/apple/coreml/scripts/install_requirements.sh

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -24,7 +24,7 @@ rm -rf "$COREML_DIR_PATH/third-party"
2424
mkdir "$COREML_DIR_PATH/third-party"
2525

2626
echo "${green}ExecuTorch: Cloning coremltools."
27-
git clone "https://github.com/apple/coremltools.git" $COREMLTOOLS_DIR_PATH
27+
git clone --depth 1 --branch 7.2 "https://github.com/apple/coremltools.git" $COREMLTOOLS_DIR_PATH
2828
cd $COREMLTOOLS_DIR_PATH
2929

3030
STATUS=$?

backends/apple/mps/CMakeLists.txt

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -77,6 +77,9 @@ target_link_libraries(mpsdelegate
7777
${MPS_GRAPG_FRAMEWORK}
7878
)
7979

80+
target_link_options_shared_lib(mpsdelegate)
81+
target_compile_options(mpsdelegate PUBLIC ${_common_compile_options})
82+
8083
install(
8184
TARGETS mpsdelegate
8285
DESTINATION lib

0 commit comments

Comments
 (0)