aboutsummaryrefslogtreecommitdiff
path: root/driver_library/python/swig_generate.py
diff options
context:
space:
mode:
authorMikael Olsson <mikael.olsson@arm.com>2023-12-15 17:17:06 +0100
committerMikael Olsson <mikael.olsson@arm.com>2023-12-20 12:05:37 +0100
commite87446c9ce7f6cbefcd7bbaff324eebdca10687e (patch)
tree2c3911d181afc7ece79398a1b6afaf15483192ba /driver_library/python/swig_generate.py
parent5087ba6f9821cae6e5a2843b33368771adfa687d (diff)
downloadethos-u-linux-driver-stack-e87446c9ce7f6cbefcd7bbaff324eebdca10687e.tar.gz
Change PMU event counter values to use 64-bit
The PMU event counter value is an accumulation of 32-bit values during the inference and to ensure the total value fits in the rpmsg message and UAPI, the variable holding the value has been changed to 64-bit. The driver library, Python wrapper and inference runner have been changed accordingly to support the 64-bit values. Change-Id: I09a8e45eb75800c8a787f83abff5a3693148cc15 Signed-off-by: Mikael Olsson <mikael.olsson@arm.com>
Diffstat (limited to 'driver_library/python/swig_generate.py')
-rwxr-xr-xdriver_library/python/swig_generate.py3
1 files changed, 2 insertions, 1 deletions
diff --git a/driver_library/python/swig_generate.py b/driver_library/python/swig_generate.py
index bdd43a3..8394d96 100755
--- a/driver_library/python/swig_generate.py
+++ b/driver_library/python/swig_generate.py
@@ -1,4 +1,4 @@
-# SPDX-FileCopyrightText: Copyright 2021-2022 Arm Limited and/or its affiliates <open-source-office@arm.com>
+# SPDX-FileCopyrightText: Copyright 2021-2023 Arm Limited and/or its affiliates <open-source-office@arm.com>
# SPDX-License-Identifier: Apache-2.0
"""
This script executes SWIG commands to generate C++ library wrappers.
@@ -13,6 +13,7 @@ def generate_wrap(name, extr_includes):
print('Generating wrappers for {}'.format(name))
subprocess.check_output("swig -v -c++ -python" +
" -Wall" +
+ " -DSWIGWORDSIZE64 " + # Force 64-bit word size for uint64_t vector to work
" -o {}/src/ethosu_driver/_generated/{}_wrap.cpp ".format(__current_dir, name) +
"-outdir {}/src/ethosu_driver/_generated ".format(__current_dir) +
"{} ".format(extr_includes) +