aboutsummaryrefslogtreecommitdiff
path: root/scripts
diff options
context:
space:
mode:
authorKristofer Jonsson <kristofer.jonsson@arm.com>2022-01-17 09:40:09 +0100
committerKristofer Jonsson <kristofer.jonsson@arm.com>2022-01-18 15:21:22 +0100
commitf7edeb7fcbb6fcb67c2711db16386c03d6f29d9d (patch)
treec9db33e5b85dbdf94611ae314f0c8e0ad30b3169 /scripts
parent6110f4122a478e6412d490178b3b11b3e8131893 (diff)
downloadethos-u-core-platform-f7edeb7fcbb6fcb67c2711db16386c03d6f29d9d.tar.gz
Build system updates
Move finding Python after the project command. This was causing incremental CMake configurations to fail. Moving ETHOSU_TARGET_* variables after adding the common subdirectory. It is necessary to set the variables before the core driver is included. Change-Id: I1c6883061cb9247336f8b33d82d2e2de870634fa
Diffstat (limited to 'scripts')
-rwxr-xr-xscripts/run_ctest.py15
1 files changed, 11 insertions, 4 deletions
diff --git a/scripts/run_ctest.py b/scripts/run_ctest.py
index c72d0f7..3e7abfc 100755
--- a/scripts/run_ctest.py
+++ b/scripts/run_ctest.py
@@ -1,7 +1,7 @@
#!/usr/bin/env python3
#
-# Copyright (c) 2021 Arm Limited. All rights reserved.
+# Copyright (c) 2021-2022 Arm Limited. All rights reserved.
#
# SPDX-License-Identifier: Apache-2.0
#
@@ -45,15 +45,22 @@ def check_output(args, **kwargs):
return subprocess.check_output(args, **kwargs)
def run_corstone_300(args):
+ if not args.arch or args.arch == 'ethos-u55':
+ fvp = 'FVP_Corstone_SSE-300_Ethos-U55'
+ elif args.arch == 'ethos-u65':
+ fvp = 'FVP_Corstone_SSE-300_Ethos-U65'
+ else:
+ raise 'Unsupported NPU arch'
+
# Verify supported FVP version
- version = subprocess.check_output(['FVP_Corstone_SSE-300_Ethos-U55', '--version']).decode()
+ version = subprocess.check_output([fvp, '--version']).decode()
supported_version = ['11.13', '11.14', '11.15', '11.16']
if not [s for s in supported_version if s in version]:
raise Exception("Incorrect FVP version. Supported versions are '{}'.".format(supported_version))
# FVP executable
- cmd = ['FVP_Corstone_SSE-300_Ethos-U55']
+ cmd = [fvp]
# NPU configuration
cmd += ['-C', 'ethosu.num_macs=' + str(args.macs)]
@@ -86,7 +93,7 @@ def run_corstone_300(args):
if __name__ == '__main__':
parser = argparse.ArgumentParser(description='Run a test with given test command and test binary.')
parser.add_argument('-t', '--target', choices=['corstone-300'], required=True, help='FVP target.')
- parser.add_argument('-a', '--arch', choices=['ethos-u55'], default='ethos-u55', help='NPU architecture.')
+ parser.add_argument('-a', '--arch', choices=['ethos-u55', 'ethos-u65'], help='NPU architecture.')
parser.add_argument('-m', '--macs', type=int, choices=[32, 64, 128, 256], default=128, help='NPU number of MACs.')
parser.add_argument('args', nargs='+', help='Arguments.')
args = parser.parse_args()