Skip to content

Commit 23ec801

Browse files
committed
Update base for Update on "[ET-VK] Minor improvement to q_linear op shader."
This diff contains a minor improvement to the q_linear op shader in the Vulkan backend for Executorch. The code changes in the q_8w_linear.glsl file include a change in position parameter from a 3-element u16vec3 to a 2-element u16vec2. Differential Revision: [D68113154](https://our.internmc.facebook.com/intern/diff/D68113154/) [ghstack-poisoned]
2 parents 15dbe81 + 91f09aa commit 23ec801

File tree

33 files changed

+883
-514
lines changed

33 files changed

+883
-514
lines changed

backends/apple/coreml/test/test_coreml_partitioner.py

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -16,8 +16,7 @@
1616

1717

1818
class TestCoreMLPartitioner(unittest.TestCase):
19-
# TODO(T182928844): Delegate dim order op to backend.
20-
edge_compile_config = executorch.exir.EdgeCompileConfig(_skip_dim_order=True)
19+
edge_compile_config = executorch.exir.EdgeCompileConfig()
2120

2221
def test_add_sub_skip_mm(self):
2322
class Model(torch.nn.Module):

backends/arm/arm_backend.py

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -50,6 +50,7 @@ def __init__(self):
5050
self.output_format = None
5151
self.path_for_intermediates = None
5252
self.tosa_version = None
53+
self.tosa_spec = None
5354
self.input_order = None
5455

5556
def ethosu_compile_spec(

backends/arm/test/common.py

Lines changed: 0 additions & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -145,14 +145,3 @@ def get_u85_compile_spec_unbuilt(
145145
.dump_intermediate_artifacts_to(artifact_path)
146146
)
147147
return compile_spec
148-
149-
150-
def get_target_board(compile_spec: list[CompileSpec]) -> str | None:
151-
for spec in compile_spec:
152-
if spec.key == "compile_flags":
153-
flags = spec.value.decode()
154-
if "u55" in flags:
155-
return "corstone-300"
156-
elif "u85" in flags:
157-
return "corstone-320"
158-
return None

backends/arm/test/models/test_mobilenet_v2_arm.py

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -98,7 +98,7 @@ def test_mv2_u55_BI(self):
9898
)
9999
if conftest.is_option_enabled("corstone_fvp"):
100100
tester.run_method_and_compare_outputs(
101-
atol=1.0, qtol=1, inputs=self.model_inputs, target_board="corstone-300"
101+
atol=1.0, qtol=1, inputs=self.model_inputs
102102
)
103103

104104
@pytest.mark.slow
@@ -118,5 +118,5 @@ def test_mv2_u85_BI(self):
118118
)
119119
if conftest.is_option_enabled("corstone_fvp"):
120120
tester.run_method_and_compare_outputs(
121-
atol=1.0, qtol=1, inputs=self.model_inputs, target_board="corstone-320"
121+
atol=1.0, qtol=1, inputs=self.model_inputs
122122
)

backends/arm/test/ops/test_max_pool.py

Lines changed: 4 additions & 12 deletions
Original file line numberDiff line numberDiff line change
@@ -173,9 +173,7 @@ def test_maxpool2d_tosa_u55_BI(
173173
(test_data,),
174174
)
175175
if conftest.is_option_enabled("corstone_fvp"):
176-
tester.run_method_and_compare_outputs(
177-
qtol=1, inputs=(test_data,), target_board="corstone-300"
178-
)
176+
tester.run_method_and_compare_outputs(qtol=1, inputs=(test_data,))
179177

180178
@parameterized.expand(test_data_suite)
181179
@pytest.mark.corstone_fvp
@@ -191,9 +189,7 @@ def test_maxpool2d_tosa_u85_BI(
191189
(test_data,),
192190
)
193191
if conftest.is_option_enabled("corstone_fvp"):
194-
tester.run_method_and_compare_outputs(
195-
qtol=1, inputs=(test_data,), target_board="corstone-320"
196-
)
192+
tester.run_method_and_compare_outputs(qtol=1, inputs=(test_data,))
197193

198194
@parameterized.expand(test_data_suite_mult_batches)
199195
def test_maxpool2d_tosa_MI_mult_batches(
@@ -232,9 +228,7 @@ def test_maxpool2d_tosa_u55_BI_mult_batches(
232228
(test_data,),
233229
)
234230
if conftest.is_option_enabled("corstone_fvp"):
235-
tester.run_method_and_compare_outputs(
236-
qtol=1, inputs=(test_data,), target_board="corstone-300"
237-
)
231+
tester.run_method_and_compare_outputs(qtol=1, inputs=(test_data,))
238232

239233
@parameterized.expand(test_data_suite_mult_batches)
240234
@pytest.mark.corstone_fvp
@@ -251,6 +245,4 @@ def test_maxpool2d_tosa_u85_BI_mult_batches(
251245
(test_data,),
252246
)
253247
if conftest.is_option_enabled("corstone_fvp"):
254-
tester.run_method_and_compare_outputs(
255-
qtol=1, inputs=(test_data,), target_board="corstone-320"
256-
)
248+
tester.run_method_and_compare_outputs(qtol=1, inputs=(test_data,))

backends/arm/test/ops/test_maximum.py

Lines changed: 2 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -121,9 +121,7 @@ def test_maximum_u55_BI(self, operand1: torch.Tensor, operand2: torch.Tensor):
121121
self.Maximum(), common.get_u55_compile_spec(), test_data
122122
)
123123
if conftest.is_option_enabled("corstone_fvp"):
124-
tester.run_method_and_compare_outputs(
125-
qtol=1, inputs=test_data, target_board="corstone-300"
126-
)
124+
tester.run_method_and_compare_outputs(qtol=1, inputs=test_data)
127125

128126
@parameterized.expand(Maximum.test_parameters)
129127
def test_maximum_u85_BI(self, operand1: torch.Tensor, operand2: torch.Tensor):
@@ -132,6 +130,4 @@ def test_maximum_u85_BI(self, operand1: torch.Tensor, operand2: torch.Tensor):
132130
self.Maximum(), common.get_u85_compile_spec(), test_data
133131
)
134132
if conftest.is_option_enabled("corstone_fvp"):
135-
tester.run_method_and_compare_outputs(
136-
qtol=1, inputs=test_data, target_board="corstone-320"
137-
)
133+
tester.run_method_and_compare_outputs(qtol=1, inputs=test_data)

backends/arm/test/ops/test_minimum.py

Lines changed: 3 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -121,9 +121,7 @@ def test_minimum_u55_BI(self, operand1: torch.Tensor, operand2: torch.Tensor):
121121
self.Minimum(), common.get_u55_compile_spec(), test_data
122122
)
123123
if conftest.is_option_enabled("corstone_fvp"):
124-
tester.run_method_and_compare_outputs(
125-
qtol=1, inputs=test_data, target_board="corstone-300"
126-
)
124+
tester.run_method_and_compare_outputs(qtol=1, inputs=test_data)
127125

128126
@parameterized.expand(Minimum.test_parameters)
129127
def test_minimum_u85_BI(self, operand1: torch.Tensor, operand2: torch.Tensor):
@@ -133,5 +131,6 @@ def test_minimum_u85_BI(self, operand1: torch.Tensor, operand2: torch.Tensor):
133131
)
134132
if conftest.is_option_enabled("corstone_fvp"):
135133
tester.run_method_and_compare_outputs(
136-
qtol=1, inputs=test_data, target_board="corstone-320"
134+
qtol=1,
135+
inputs=test_data,
137136
)

0 commit comments

Comments
 (0)