Skip to content

Commit 8ff65af

Browse files
committed
Update
[ghstack-poisoned]
2 parents 2d493a8 + cfd0bc4 commit 8ff65af

File tree

8 files changed

+65
-51
lines changed

8 files changed

+65
-51
lines changed

.ci/scripts/unittest-macos.sh

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -35,7 +35,7 @@ if [[ "$BUILD_TOOL" == "cmake" ]]; then
3535
.ci/scripts/unittest-macos-cmake.sh
3636
elif [[ "$BUILD_TOOL" == "buck2" ]]; then
3737
.ci/scripts/unittest-buck2.sh
38-
.ci/scripts/unittest-macos-buck2.sh
38+
# .ci/scripts/unittest-macos-buck2.sh
3939
else
4040
echo "Unknown build tool $BUILD_TOOL"
4141
exit 1

backends/arm/test/common.py

Lines changed: 27 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,4 @@
11
# Copyright 2024-2025 Arm Limited and/or its affiliates.
2-
# All rights reserved.
32
#
43
# This source code is licensed under the BSD-style license found in the
54
# LICENSE file in the root directory of this source tree.
@@ -159,13 +158,38 @@ def get_u85_compile_spec_unbuilt(
159158
not corstone300_installed() or not arm_executor_runner_exists("corstone-300"),
160159
reason="Did not find Corstone-300 FVP or executor_runner on path",
161160
)
162-
"""Skips a test if Corsone300 FVP is not installed, or if the executor runner is not built"""
161+
"""
162+
TO BE DEPRECATED - Use XfailIfNoCorstone300 instead
163+
Skips a test if Corsone300 FVP is not installed, or if the executor runner is not built
164+
"""
163165

164166
SkipIfNoCorstone320 = pytest.mark.skipif(
165167
not corstone320_installed() or not arm_executor_runner_exists("corstone-320"),
166168
reason="Did not find Corstone-320 FVP or executor_runner on path",
167169
)
168-
"""Skips a test if Corsone320 FVP is not installed, or if the executor runner is not built."""
170+
"""
171+
TO BE DEPRECATED - Use XfailIfNoCorstone320 instead
172+
Skips a test if Corsone320 FVP is not installed, or if the executor runner is not built
173+
"""
174+
175+
176+
XfailIfNoCorstone300 = pytest.mark.xfail(
177+
condition=not (
178+
corstone300_installed() and arm_executor_runner_exists("corstone-300")
179+
),
180+
raises=FileNotFoundError,
181+
reason="Did not find Corstone-300 FVP or executor_runner on path",
182+
)
183+
"""Xfails a test if Corsone300 FVP is not installed, or if the executor runner is not built"""
184+
185+
XfailIfNoCorstone320 = pytest.mark.xfail(
186+
condition=not (
187+
corstone320_installed() and arm_executor_runner_exists("corstone-320")
188+
),
189+
raises=FileNotFoundError,
190+
reason="Did not find Corstone-320 FVP or executor_runner on path",
191+
)
192+
"""Xfails a test if Corsone320 FVP is not installed, or if the executor runner is not built"""
169193

170194

171195
def parametrize(

backends/arm/test/ops/test_add.py

Lines changed: 10 additions & 42 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
# Copyright (c) Meta Platforms, Inc. and affiliates.
2-
# Copyright 2024-2025 Arm Limited and/or its affiliates.
32
# All rights reserved.
3+
# Copyright 2024-2025 Arm Limited and/or its affiliates.
44
#
55
# This source code is licensed under the BSD-style license found in the
66
# LICENSE file in the root directory of this source tree.
@@ -106,79 +106,47 @@ def test_add_i32_tosa_BI(test_data: input_t1):
106106

107107

108108
@common.parametrize("test_data", Add.test_data)
109+
@common.XfailIfNoCorstone300
109110
def test_add_u55_BI(test_data: input_t1):
110-
pipeline = EthosU55PipelineBI[input_t1](
111-
Add(), test_data, aten_op, exir_op, run_on_fvp=False
112-
)
113-
pipeline.run()
114-
115-
116-
@common.parametrize("test_data", Add.test_data)
117-
def test_add_u85_BI(test_data: input_t1):
118-
pipeline = EthosU85PipelineBI[input_t1](
119-
Add(), test_data, aten_op, exir_op, run_on_fvp=False
120-
)
121-
pipeline.run()
122-
123-
124-
@common.parametrize("test_data", Add.test_data)
125-
@common.SkipIfNoCorstone300
126-
def test_add_u55_BI_on_fvp(test_data: input_t1):
127111
pipeline = EthosU55PipelineBI[input_t1](
128112
Add(), test_data, aten_op, exir_op, run_on_fvp=True
129113
)
130114
pipeline.run()
131115

132116

133117
@common.parametrize("test_data", Add.test_data)
134-
@common.SkipIfNoCorstone320
135-
def test_add_u85_BI_on_fvp(test_data: input_t1):
118+
@common.XfailIfNoCorstone320
119+
def test_add_u85_BI(test_data: input_t1):
136120
pipeline = EthosU85PipelineBI[input_t1](
137121
Add(), test_data, aten_op, exir_op, run_on_fvp=True
138122
)
139123
pipeline.run()
140124

141125

142126
@common.parametrize("test_data", Add2.test_data)
143-
def test_add2_tosa_MI(test_data: input_t2):
127+
def test_add_2_tosa_MI(test_data: input_t2):
144128
pipeline = TosaPipelineMI[input_t2](Add2(), test_data, aten_op, exir_op)
145129
pipeline.run()
146130

147131

148132
@common.parametrize("test_data", Add2.test_data)
149-
def test_add2_tosa_BI(test_data: input_t2):
133+
def test_add_2_tosa_BI(test_data: input_t2):
150134
pipeline = TosaPipelineBI[input_t2](Add2(), test_data, aten_op, exir_op)
151135
pipeline.run()
152136

153137

154138
@common.parametrize("test_data", Add2.test_data)
155-
def test_add2_u55_BI(test_data: input_t2):
156-
pipeline = EthosU55PipelineBI[input_t2](
157-
Add2(), test_data, aten_op, exir_op, run_on_fvp=False
158-
)
159-
pipeline.run()
160-
161-
162-
@common.parametrize("test_data", Add2.test_data)
163-
@common.SkipIfNoCorstone300
164-
def test_add2_u55_BI_on_fvp(test_data: input_t2):
139+
@common.XfailIfNoCorstone300
140+
def test_add_2_u55_BI(test_data: input_t2):
165141
pipeline = EthosU55PipelineBI[input_t2](
166142
Add2(), test_data, aten_op, exir_op, run_on_fvp=True
167143
)
168144
pipeline.run()
169145

170146

171147
@common.parametrize("test_data", Add2.test_data)
172-
def test_add2_u85_BI(test_data: input_t2):
173-
pipeline = EthosU85PipelineBI[input_t2](
174-
Add2(), test_data, aten_op, exir_op, run_on_fvp=False
175-
)
176-
pipeline.run()
177-
178-
179-
@common.parametrize("test_data", Add2.test_data)
180-
@common.SkipIfNoCorstone320
181-
def test_add2_u85_BI_on_fvp(test_data: input_t2):
148+
@common.XfailIfNoCorstone320
149+
def test_add_2_u85_BI(test_data: input_t2):
182150
pipeline = EthosU85PipelineBI[input_t2](
183151
Add2(), test_data, aten_op, exir_op, run_on_fvp=True
184152
)

backends/arm/test/runner_utils.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -529,7 +529,7 @@ def get_elf_path(target_board):
529529
"arm_executor_runner",
530530
)
531531
if not os.path.exists(elf_path):
532-
raise RuntimeError(
532+
raise FileNotFoundError(
533533
f"Did not find build arm_executor_runner in path {elf_path}, run setup_testing.sh?"
534534
)
535535
else:

backends/cadence/hifi/operators/op_quantized_conv_out.cpp

Lines changed: 7 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,10 @@
1-
// (c) Meta Platforms, Inc. and affiliates. Confidential and proprietary.
1+
/*
2+
* Copyright (c) Meta Platforms, Inc. and affiliates.
3+
* All rights reserved.
4+
*
5+
* This source code is licensed under the BSD-style license found in the
6+
* LICENSE file in the root directory of this source tree.
7+
*/
28

39
#include <executorch/backends/cadence/hifi/kernels/kernels.h>
410
#include <executorch/backends/cadence/hifi/operators/operators.h>

devtools/etdump/utils.h

Lines changed: 7 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,10 @@
1-
// (c) Meta Platforms, Inc. and affiliates. Confidential and proprietary.
1+
/*
2+
* Copyright (c) Meta Platforms, Inc. and affiliates.
3+
* All rights reserved.
4+
*
5+
* This source code is licensed under the BSD-style license found in the
6+
* LICENSE file in the root directory of this source tree.
7+
*/
28

39
#include <cstddef>
410
#include <cstdint>

examples/models/llama/norm.py

Lines changed: 5 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,8 @@
1-
# (c) Meta Platforms, Inc. and affiliates. Confidential and proprietary.
1+
# Copyright (c) Meta Platforms, Inc. and affiliates.
2+
# All rights reserved.
3+
#
4+
# This source code is licensed under the BSD-style license found in the
5+
# LICENSE file in the root directory of this source tree.
26

37
import torch
48
from torch import nn

examples/models/llama/runner/static_attention_io_manager.h

Lines changed: 7 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,10 @@
1-
// (c) Meta Platforms, Inc. and affiliates. Confidential and proprietary.
1+
/*
2+
* Copyright (c) Meta Platforms, Inc. and affiliates.
3+
* All rights reserved.
4+
*
5+
* This source code is licensed under the BSD-style license found in the
6+
* LICENSE file in the root directory of this source tree.
7+
*/
28

39
#include <memory>
410
#include <tuple>

0 commit comments

Comments
 (0)