@@ -71,6 +71,12 @@ et_root_dir=$(cd ${script_dir}/../.. && pwd)
71
71
et_build_dir=${et_root_dir} /cmake-out
72
72
73
73
fvp_model=FVP_Corstone_SSE-300_Ethos-U55
74
+ if [[ ${target} =~ " ethos-u85" ]]
75
+ then
76
+ echo " target is ethos-u85 variant so switching to CS320 FVP"
77
+ fvp_model=FVP_Corstone_SSE-320
78
+ fi
79
+
74
80
toolchain_cmake=${script_dir} /ethos-u-setup/arm-none-eabi-gcc.cmake
75
81
_setup_msg=" please refer to ${script_dir} /ethos-u-setup/setup.sh to properly install necessary tools."
76
82
@@ -82,8 +88,7 @@ function generate_pte_file() {
82
88
83
89
local model_filename=${model} _arm_${target} .pte
84
90
if [[ " ${model_compiler_flags} " == * " --delegate" * ]]; then
85
- # Name aligned with default aot_arm_compiler output - run.sh only supports
86
- # running on Corstone-300 with Ethos-U55 FVP at the moment.
91
+ # Name aligned with default aot_arm_compiler output
87
92
model_filename=${model} _arm_delegate_${target} .pte
88
93
fi
89
94
cd $et_root_dir
@@ -173,13 +178,16 @@ function build_executorch_runner() {
173
178
local pte=${1}
174
179
if [[ ${target} == * " ethos-u55" * ]]; then
175
180
local target_cpu=cortex-m55
181
+ local target_board=corstone-300
176
182
else
177
183
local target_cpu=cortex-m85
184
+ local target_board=corstone-320
178
185
fi
179
186
cd ${script_dir} /executor_runner
180
- cmake -DCMAKE_TOOLCHAIN_FILE=${toolchain_cmake} \
187
+ cmake -DCMAKE_TOOLCHAIN_FILE=${toolchain_cmake} \
181
188
-DTARGET_CPU=${target_cpu} \
182
- -DETHOSU_TARGET_NPU_CONFIG=${target} \
189
+ -DTARGET_BOARD=${target_board} \
190
+ -DETHOSU_TARGET_NPU_CONFIG=${target} \
183
191
-B ${executor_runner_path} /cmake-out \
184
192
-DETHOS_SDK_PATH:PATH=${ethos_u_root_dir} \
185
193
-DET_DIR_PATH:PATH=${et_root_dir} \
@@ -203,9 +211,10 @@ function run_fvp() {
203
211
elf=$( find ${executor_runner_path} -name " ${elf_name} " )
204
212
[[ ! -f $elf ]] && { echo " [${FUNCNAME[0]} ]: Unable to find executor_runner elf: ${elf} " ; exit 1; }
205
213
num_macs=$( echo ${target} | cut -d - -f 3)
214
+
206
215
if [[ ${target} == * " ethos-u55" * ]]; then
207
- echo " Running ${elf} for ${target} run with FVP_Corstone_SSE-300_Ethos-U55 num_macs:${num_macs} "
208
- FVP_Corstone_SSE-300_Ethos-U55 \
216
+ echo " Running ${elf} for ${target} run with FVP: ${fvp_model} num_macs:${num_macs} "
217
+ ${fvp_model} \
209
218
-C cpu0.CFGITCMSZ=11 \
210
219
-C ethosu.num_macs=${num_macs} \
211
220
-C mps3_board.visualisation.disable-visualisation=1 \
@@ -215,6 +224,17 @@ function run_fvp() {
215
224
-a " ${elf} " \
216
225
--timelimit 120 || true # seconds
217
226
echo " [${FUNCNAME[0]} Simulation complete, $? "
227
+ elif [[ ${target} == * " ethos-u85" * ]]; then
228
+ ${fvp_model} \
229
+ -C mps4_board.subsystem.cpu0.CFGITCMSZ=11 \
230
+ -C mps4_board.subsystem.ethosu.num_macs=${num_macs} \
231
+ -C mps4_board.visualisation.disable-visualisation=1 \
232
+ -C vis_hdlcd.disable_visualisation=1 \
233
+ -C mps4_board.telnetterminal0.start_telnet=0 \
234
+ -C mps4_board.uart0.out_file=' -' \
235
+ -C mps4_board.uart0.shutdown_on_eot=1 \
236
+ -a " ${elf} " \
237
+ --timelimit 120 || true # seconds
218
238
else
219
239
echo " Running ${elf} for ${target} is not supported"
220
240
exit 1
0 commit comments