Skip to content

Commit bc0d911

Browse files
authored
Merge branch 'main' into add-gt-lt-scalar-ops
2 parents d886022 + feead18 commit bc0d911

File tree

164 files changed

+3064
-586
lines changed

Some content is hidden

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

164 files changed

+3064
-586
lines changed

.ci/scripts/build_android_instrumentation.sh

Lines changed: 0 additions & 21 deletions
This file was deleted.

.github/workflows/_android.yml

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -14,7 +14,7 @@ jobs:
1414
with:
1515
runner: linux.2xlarge
1616
docker-image: executorch-ubuntu-22.04-clang12-android
17-
submodules: 'true'
17+
submodules: 'recursive'
1818
ref: ${{ github.event_name == 'pull_request' && github.event.pull_request.head.sha || github.sha }}
1919
timeout: 90
2020
upload-artifact: android-apps
@@ -36,7 +36,8 @@ jobs:
3636
cp ${BUILD_AAR_DIR}/executorch.aar $ARTIFACTS_DIR_NAME
3737
3838
mkdir -p ${ARTIFACTS_DIR_NAME}/library_test_dir
39-
bash .ci/scripts/build_android_instrumentation.sh
39+
bash extension/android/executorch_android/android_test_setup.sh
40+
(cd extension/android; ANDROID_HOME="${ANDROID_SDK:-/opt/android/sdk}" ./gradlew :executorch_android:assembleAndroidTest)
4041
cp extension/android/executorch_android/build/outputs/apk/androidTest/debug/executorch_android-debug-androidTest.apk "${ARTIFACTS_DIR_NAME}/library_test_dir"
4142
4243
mkdir -p ${ARTIFACTS_DIR_NAME}/fp32-xnnpack-custom

.github/workflows/android-perf.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -345,7 +345,7 @@ jobs:
345345
with:
346346
runner: linux.2xlarge
347347
docker-image: executorch-ubuntu-22.04-clang12-android
348-
submodules: 'true'
348+
submodules: 'recursive'
349349
ref: ${{ github.event_name == 'pull_request' && github.event.pull_request.head.sha || github.sha }}
350350
timeout: 90
351351
upload-artifact: android-apps

.github/workflows/android-release-artifacts.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -45,7 +45,7 @@ jobs:
4545
secrets-env: EXECUTORCH_MAVEN_SIGNING_KEYID EXECUTORCH_MAVEN_SIGNING_PASSWORD EXECUTORCH_MAVEN_CENTRAL_PASSWORD EXECUTORCH_MAVEN_CENTRAL_USERNAME EXECUTORCH_MAVEN_SIGNING_GPG_KEY_CONTENTS
4646
runner: linux.2xlarge
4747
docker-image: executorch-ubuntu-22.04-clang12-android
48-
submodules: 'true'
48+
submodules: 'recursive'
4949
ref: ${{ github.sha }}
5050
timeout: 90
5151
upload-artifact: android-apps

.mypy.ini

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -80,6 +80,9 @@ ignore_missing_imports = True
8080
[mypy-serializer.*]
8181
ignore_missing_imports = True
8282

83+
[mypy-tosa_tools.*]
84+
ignore_missing_imports = True
85+
8386
[mypy-setuptools.*]
8487
ignore_missing_imports = True
8588

CONTRIBUTING.md

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -102,6 +102,8 @@ executorch
102102
## Contributing workflow
103103
We actively welcome your pull requests (PRs).
104104

105+
If you're completely new to open-source projects, GitHub, or ExecuTorch, please see our [New Contributor Guide](./docs/source/new-contributor-guide.md) for a step-by-step walkthrough on making your first contribution. Otherwise, read on.
106+
105107
1. [Claim an issue](#claiming-issues), if present, before starting work. If an
106108
issue doesn't cover the work you plan to do, consider creating one to provide
107109
context about it, and to build consensus about the scope and solution.

backends/arm/operators/node_visitor.py

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -7,8 +7,9 @@
77

88
from typing import Dict, List
99

10-
import serializer.tosa_serializer as ts # type: ignore
1110
import torch
11+
12+
import tosa_tools.v0_80.serializer.tosa_serializer as ts # type: ignore
1213
from executorch.backends.arm.tosa_mapping import TosaArg
1314
from executorch.backends.arm.tosa_specification import TosaSpecification
1415
from torch.export import ExportedProgram

backends/arm/operators/op_abs.py

Lines changed: 3 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -9,15 +9,13 @@
99
import executorch.backends.arm.tosa_quant_utils as tqutils
1010
import executorch.backends.arm.tosa_utils as tutils
1111

12-
import serializer.tosa_serializer as ts # type: ignore
12+
import tosa_tools.v0_80.serializer.tosa_serializer as ts # type: ignore
1313
from executorch.backends.arm.operators.node_visitor import (
1414
NodeVisitor,
1515
register_node_visitor,
1616
)
1717
from executorch.backends.arm.tosa_mapping import TosaArg
1818
from executorch.backends.arm.tosa_specification import TosaSpecification
19-
20-
from serializer.tosa_serializer import TosaOp
2119
from torch.fx import Node
2220

2321

@@ -70,7 +68,7 @@ def define_node(
7068

7169
# Do the INT32 Abs
7270
tosa_graph.addOperator(
73-
TosaOp.Op().ABS,
71+
ts.TosaOp.Op().ABS,
7472
[
7573
rescaled_inputs[0].name,
7674
],
@@ -126,7 +124,7 @@ def define_node(
126124

127125
# MI lowering
128126
tosa_graph.addOperator(
129-
TosaOp.Op().ABS,
127+
ts.TosaOp.Op().ABS,
130128
[inputs[0].name],
131129
[output.name],
132130
None,

backends/arm/operators/op_add.py

Lines changed: 3 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -10,14 +10,13 @@
1010
import executorch.backends.arm.tosa_quant_utils as tqutils
1111
import executorch.backends.arm.tosa_utils as tutils
1212

13-
import serializer.tosa_serializer as ts # type: ignore
13+
import tosa_tools.v0_80.serializer.tosa_serializer as ts # type: ignore
1414
from executorch.backends.arm.operators.node_visitor import (
1515
NodeVisitor,
1616
register_node_visitor,
1717
)
1818
from executorch.backends.arm.tosa_mapping import TosaArg
1919
from executorch.backends.arm.tosa_specification import TosaSpecification
20-
from serializer.tosa_serializer import TosaOp
2120
from torch.fx import Node
2221

2322

@@ -82,7 +81,7 @@ def define_node(
8281

8382
# Do the INT32 Add
8483
tosa_graph.addOperator(
85-
TosaOp.Op().ADD,
84+
ts.TosaOp.Op().ADD,
8685
[input1.name, input2.name],
8786
[add_output.name],
8887
None,
@@ -135,7 +134,7 @@ def define_node(
135134

136135
# MI lowering
137136
tosa_graph.addOperator(
138-
TosaOp.Op().ADD,
137+
ts.TosaOp.Op().ADD,
139138
[input1.name, input2.name],
140139
[output.name],
141140
None,

backends/arm/operators/op_amax.py

Lines changed: 2 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -4,14 +4,13 @@
44
# LICENSE file in the root directory of this source tree.
55
from typing import List
66

7-
import serializer.tosa_serializer as ts
7+
import tosa_tools.v0_80.serializer.tosa_serializer as ts
88
from executorch.backends.arm._passes.arm_pass_utils import get_first_fake_tensor
99
from executorch.backends.arm.operators.node_visitor import (
1010
NodeVisitor,
1111
register_node_visitor,
1212
)
1313
from executorch.backends.arm.tosa_mapping import TosaArg
14-
from serializer.tosa_serializer import TosaOp
1514
from torch.fx import Node
1615

1716

@@ -48,5 +47,5 @@ def define_node(
4847
attr.AxisAttribute(input.dim_order.index(dim))
4948

5049
tosa_graph.addOperator(
51-
TosaOp.Op().REDUCE_MAX, [input.name], [output.name], attr
50+
ts.TosaOp.Op().REDUCE_MAX, [input.name], [output.name], attr
5251
)

0 commit comments

Comments
 (0)