Skip to content

Commit d9b3287

Browse files
committed
Update base for Update on "Convert args to LlmConfig"
Differential Revision: [D75263990](https://our.internmc.facebook.com/intern/diff/D75263990) [ghstack-poisoned]
2 parents ba7353f + d9503e6 commit d9b3287

File tree

122 files changed

+2017
-1826
lines changed

Some content is hidden

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

122 files changed

+2017
-1826
lines changed
Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1 +1 @@
1-
59d5cf083b4f860dea76fe8936076177f9367f10
1+
01f1cc44cbbfdf6307aa01b803a4ee22f9ade946

.github/workflows/build-presets.yml

Lines changed: 29 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -20,7 +20,7 @@ jobs:
2020
strategy:
2121
fail-fast: false
2222
matrix:
23-
preset: [macos-arm64, pybind, llm]
23+
preset: [macos, ios, ios-simulator, pybind, llm]
2424
with:
2525
job-name: build
2626
ref: ${{ github.event_name == 'pull_request' && github.event.pull_request.head.sha || github.sha }}
@@ -39,7 +39,7 @@ jobs:
3939
strategy:
4040
fail-fast: false
4141
matrix:
42-
preset: [pybind, llm]
42+
preset: [linux, pybind, llm]
4343
runner: [linux.2xlarge, linux.arm64.2xlarge]
4444
docker-image: [executorch-ubuntu-22.04-clang12, executorch-ubuntu-22.04-gcc11-aarch64]
4545
# Excluding specific runner + docker image combinations that don't make sense:
@@ -65,4 +65,30 @@ jobs:
6565
6666
./install_requirements.sh > /dev/null
6767
cmake --preset ${{ matrix.preset }}
68-
cmake --build cmake-out -j$(( $(nproc) - 1 ))
68+
69+
windows:
70+
uses: pytorch/test-infra/.github/workflows/windows_job.yml@main
71+
strategy:
72+
fail-fast: false
73+
matrix:
74+
preset: [pybind]
75+
with:
76+
job-name: build
77+
ref: ${{ github.event_name == 'pull_request' && github.event.pull_request.head.sha || github.sha }}
78+
submodules: recursive
79+
timeout: 90
80+
script: |
81+
set -eux
82+
conda init powershell
83+
powershell -Command "& {
84+
\$ErrorActionPreference = 'Stop'
85+
Set-PSDebug -Trace 1
86+
87+
conda create --yes --quiet -n et python=3.12
88+
conda activate et
89+
90+
python install_requirements.py
91+
cmake --preset ${{ matrix.preset }}
92+
\$numCores = [System.Environment]::GetEnvironmentVariable('NUMBER_OF_PROCESSORS') - 1
93+
cmake --build cmake-out -j \$numCores
94+
}"

.github/workflows/trunk.yml

Lines changed: 0 additions & 26 deletions
Original file line numberDiff line numberDiff line change
@@ -692,29 +692,3 @@ jobs:
692692
build-mode: Release
693693
build-tool: cmake
694694
docker-image: executorch-ubuntu-22.04-clang12
695-
696-
unittest-nxp-neutron:
697-
uses: pytorch/test-infra/.github/workflows/linux_job_v2.yml@main
698-
permissions:
699-
id-token: write
700-
contents: read
701-
with:
702-
runner: linux.2xlarge
703-
docker-image: executorch-ubuntu-22.04-clang12
704-
submodules: 'true'
705-
ref: ${{ github.event_name == 'pull_request' && github.event.pull_request.head.sha || github.sha }}
706-
timeout: 90
707-
script: |
708-
set -eux
709-
710-
# The generic Linux job chooses to use base env, not the one setup by the image
711-
CONDA_ENV=$(conda env list --json | jq -r ".envs | .[-1]")
712-
conda activate "${CONDA_ENV}"
713-
714-
# Build and install Executorch
715-
PYTHON_EXECUTABLE=python \
716-
CMAKE_ARGS="-DEXECUTORCH_BUILD_NXP_NEUTRON=ON" \
717-
.ci/scripts/setup-linux.sh --build-tool "cmake"
718-
719-
# Run pytest
720-
PYTHON_EXECUTABLE=python bash backends/nxp/run_unittests.sh

.gitmodules

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -67,3 +67,6 @@
6767
[submodule "shim"]
6868
path = shim
6969
url = https://github.com/facebook/buck2-shims-meta
70+
[submodule "third-party/json"]
71+
path = third-party/json
72+
url = https://github.com/nlohmann/json.git

.lintrunner.toml

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -390,7 +390,6 @@ exclude_patterns = [
390390
"backends/arm/test/ops/**",
391391
"backends/vulkan/quantizer/**",
392392
"backends/vulkan/test/**",
393-
"backends/cadence/aot/quantizer/**",
394393
"backends/qualcomm/quantizer/**",
395394
"examples/qualcomm/**",
396395
"backends/xnnpack/quantizer/**",

CMakePresets.json

Lines changed: 51 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -7,13 +7,13 @@
77
"binaryDir": "${sourceDir}/cmake-out"
88
},
99
{
10-
"name": "macos-arm64",
11-
"displayName": "Build everything buildable on macOS arm64",
10+
"name": "macos",
11+
"displayName": "Build everything buildable on macOS",
1212
"inherits": ["common"],
1313
"generator": "Xcode",
1414
"cacheVariables": {
1515
"CMAKE_TOOLCHAIN_FILE": "${sourceDir}/third-party/ios-cmake/ios.toolchain.cmake",
16-
"EXECUTORCH_BUILD_PRESET_FILE": "${sourceDir}/tools/cmake/preset/macos-arm64.cmake",
16+
"EXECUTORCH_BUILD_PRESET_FILE": "${sourceDir}/tools/cmake/preset/macos.cmake",
1717
"PLATFORM": "MAC_ARM64",
1818
"DEPLOYMENT_TARGET": "10.15"
1919
},
@@ -23,6 +23,54 @@
2323
"rhs": "Darwin"
2424
}
2525
},
26+
{
27+
"name": "ios",
28+
"displayName": "Build everything buildable on iOS",
29+
"inherits": ["common"],
30+
"generator": "Xcode",
31+
"cacheVariables": {
32+
"CMAKE_TOOLCHAIN_FILE": "${sourceDir}/third-party/ios-cmake/ios.toolchain.cmake",
33+
"EXECUTORCH_BUILD_PRESET_FILE": "${sourceDir}/tools/cmake/preset/ios.cmake",
34+
"PLATFORM": "OS64",
35+
"DEPLOYMENT_TARGET": "17.0"
36+
},
37+
"condition": {
38+
"lhs": "${hostSystemName}",
39+
"type": "equals",
40+
"rhs": "Darwin"
41+
}
42+
},
43+
{
44+
"name": "ios-simulator",
45+
"displayName": "Build everything buildable on iOS simulator",
46+
"inherits": ["common"],
47+
"generator": "Xcode",
48+
"cacheVariables": {
49+
"CMAKE_TOOLCHAIN_FILE": "${sourceDir}/third-party/ios-cmake/ios.toolchain.cmake",
50+
"EXECUTORCH_BUILD_PRESET_FILE": "${sourceDir}/tools/cmake/preset/ios.cmake",
51+
"PLATFORM": "SIMULATORARM64",
52+
"DEPLOYMENT_TARGET": "17.0"
53+
},
54+
"condition": {
55+
"lhs": "${hostSystemName}",
56+
"type": "equals",
57+
"rhs": "Darwin"
58+
}
59+
},
60+
{
61+
"name": "linux",
62+
"displayName": "Build everything buildable on Linux",
63+
"inherits": ["common"],
64+
"cacheVariables": {
65+
"CMAKE_SYSTEM_NAME": "Linux",
66+
"EXECUTORCH_BUILD_PRESET_FILE": "${sourceDir}/tools/cmake/preset/linux.cmake"
67+
},
68+
"condition": {
69+
"lhs": "${hostSystemName}",
70+
"type": "equals",
71+
"rhs": "Linux"
72+
}
73+
},
2674
{
2775
"name": "pybind",
2876
"displayName": "Build pybindings exported in the wheel",

backends/apple/coreml/runtime/workspace/executorchcoreml.xcodeproj/project.pbxproj

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -925,7 +925,7 @@
925925
"$(SRCROOT)/../include/executorch/runtime/core/portable_type/c10",
926926
"$(SRCROOT)/../sdk",
927927
"$(SRCROOT)/../util",
928-
"$(SRCROOT)/../../third-party/nlohmann_json/single_include",
928+
"$(SRCROOT)/../../../../../third-party/json/single_include",
929929
"$(SRCROOT)/../../third-party/coremltools/deps/protobuf/src",
930930
);
931931
IPHONEOS_DEPLOYMENT_TARGET = 16.0;
@@ -957,7 +957,7 @@
957957
"$(SRCROOT)/../include/executorch/runtime/core/portable_type/c10",
958958
"$(SRCROOT)/../sdk",
959959
"$(SRCROOT)/../util",
960-
"$(SRCROOT)/../../third-party/nlohmann_json/single_include",
960+
"$(SRCROOT)/../../../../../third-party/json/single_include",
961961
"$(SRCROOT)/../../third-party/coremltools/deps/protobuf/src",
962962
);
963963
IPHONEOS_DEPLOYMENT_TARGET = 16.0;

backends/apple/coreml/scripts/install_requirements.sh

Lines changed: 0 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -49,14 +49,6 @@ mkdir "$COREMLTOOLS_DIR_PATH/build"
4949
cmake -S "$COREMLTOOLS_DIR_PATH" -B "$COREMLTOOLS_DIR_PATH/build"
5050
cmake --build "$COREMLTOOLS_DIR_PATH/build" --parallel --target mlmodel
5151

52-
echo "${green}ExecuTorch: Cloning nlohmann."
53-
git clone https://github.com/nlohmann/json.git "$COREML_DIR_PATH/third-party/nlohmann_json"
54-
STATUS=$?
55-
if [ $STATUS -ne 0 ]; then
56-
echo "${red}ExecuTorch: Failed to clone nlohmann."
57-
exit 1
58-
fi
59-
6052
echo "${green}ExecuTorch: Copying protobuf files."
6153
mkdir -p "$COREML_DIR_PATH/runtime/sdk/format/"
6254
cp -rf "$PROTOBUF_FILES_DIR_PATH" "$COREML_DIR_PATH/runtime/sdk/format/"

backends/arm/README.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -101,7 +101,7 @@ backends/arm/test/setup_testing.sh
101101
The you can run the tests with
102102

103103
```
104-
pytest -c /dev/null -v -n auto backends/arm/test --arm_run_corstoneFVP
104+
pytest -c /dev/null -v -n auto backends/arm/test
105105
```
106106

107107
## Passes

backends/arm/_passes/__init__.py

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -20,7 +20,6 @@
2020
from .convert_split_to_slice import ConvertSplitToSlicePass # noqa
2121
from .convert_squeezes_to_view import ConvertSqueezesToViewPass # noqa
2222
from .convert_to_clamp import ConvertToClampPass # noqa
23-
from .decompose_batchnorm_pass import DecomposeBatchNormPass # noqa
2423
from .decompose_cosine_similarity_pass import DecomposeCosineSimilarityPass # noqa
2524
from .decompose_div_pass import DecomposeDivPass # noqa
2625
from .decompose_gelu_pass import DecomposeGeluPass # noqa

0 commit comments

Comments
 (0)