Lines Matching +full:arm +full:- +full:none +full:- +full:eabi
5 # Copyright 2023-2024 Arm Limited and/or its affiliates.
7 # This source code is licensed under the BSD-style license found in the
10 set -eu
12 if [[ "${1:-'.'}" == "-h" || "${#}" -gt 2 ]]; then
13 echo "Usage: $(basename $0) <--i-agree-to-the-contained-eula> [path-to-a-scratch-dir]"
22 ARCH="$(uname -m)"
23 OS="$(uname -s)"
26 [[ $# -ne 2 ]] \
32 local file_checksum="$(md5 -q $file)"
45 script_dir=$(cd -- "$( dirname -- "${BASH_SOURCE[0]}" )" &> /dev/null && pwd)
49 …one300_url="https://developer.arm.com/-/media/Arm%20Developer%20Community/Downloads/OSS/FVP/Corsto…
50 corstone300_model_dir="Linux64_GCC-9.3"
53 …one320_url="https://developer.arm.com/-/media/Arm%20Developer%20Community/Downloads/OSS/FVP/Corsto…
54 corstone320_model_dir="Linux64_GCC-9.3"
58 ….net/developer/Files/downloads/gnu/12.3.rel1/binrel/arm-gnu-toolchain-12.3.rel1-x86_64-arm-none-ea…
59 toolchain_dir="arm-gnu-toolchain-12.3.rel1-x86_64-arm-none-eabi"
63 …one300_url="https://developer.arm.com/-/media/Arm%20Developer%20Community/Downloads/OSS/FVP/Corsto…
64 corstone300_model_dir="Linux64_armv8l_GCC-9.3"
67 …one320_url="https://developer.arm.com/-/media/Arm%20Developer%20Community/Downloads/OSS/FVP/Corsto…
68 corstone320_model_dir="Linux64_armv8l_GCC-9.3"
73 …t/developer/Files/downloads/gnu/12.3.rel1/binrel/arm-gnu-toolchain-12.3.rel1-darwin-arm64-arm-none…
74 toolchain_dir="arm-gnu-toolchain-12.3.rel1-darwin-arm64-arm-none-eabi"
77 ….net/developer/Files/downloads/gnu/12.3.rel1/binrel/arm-gnu-toolchain-12.3.rel1-aarch64-arm-none-e…
78 toolchain_dir="arm-gnu-toolchain-12.3.rel1-aarch64-arm-none-eabi"
82 echo "[main] Error: only x86-64 & aarch64/arm64 architecture is supported for now!"; exit 1;
85 # ethos-u
86 ethos_u_repo_url="https://review.mlplatform.org/ml/ethos-u/ethos-u"
96 eula_acceptance="${1:-'.'}"
97 if [[ "${eula_acceptance}" != "--i-agree-to-the-contained-eula" ]]; then
99 …echo "Must pass first positional argument '--i-agree-to-the-contained-eula' to agree to EULA assoc…
102 …echo "Arm EULA for FVP agreed to with ARM_FVP_INSTALL_I_AGREE_TO_THE_CONTAINED_EULA=True environme…
111 root_dir=${1:-"${script_dir}/ethos-u-scratch"}
112 mkdir -p ${root_dir}
122 …echo "[${FUNCNAME[0]}] Warning: For MacOS, using https://github.com/Arm-Examples/FVPs-on-Mac is re…
132 if [[ ! -e "FVP_${fvp}.tgz" ]]; then
136 curl --output "FVP_${fvp}.tgz" "${fvp_url}"
143 rm -rf FVP-${fvp}
144 mkdir -p FVP-${fvp}
145 cd FVP-${fvp}
151 …./FVP_Corstone_SSE-300.sh --i-agree-to-the-contained-eula --force --destination ./ --quiet --no-in…
154 …./FVP_Corstone_SSE-320.sh --i-agree-to-the-contained-eula --force --destination ./ --quiet --no-in…
170 # Fixup for Corstone-320 python dependency
171 echo "export LD_LIBRARY_PATH=${root_dir}/FVP-corstone320/python/lib/" >> ${setup_path_script}
175 # Download and install the arm-none-eabi toolchain
177 if [[ ! -e gcc.tar.xz ]]; then
179 curl --output gcc.tar.xz "${toolchain_url}"
184 rm -rf "${toolchain_dir}"
188 hash arm-none-eabi-gcc
196 [[ ! -d ethos-u ]] && \
198 cd ethos-u
199 git reset --hard ${ethos_u_base_rev}
200 python3 ./fetch_externals.py -c ${ethos_u_base_rev}.json fetch
202 …echo "[${FUNCNAME[0]}] Done @ $(git describe --all --long 3> /dev/null) in ${root_dir}/ethos-u dir…
206 # This is a temporary hack until it finds a better home in one for the ARM Ml repos
208 echo -e "[${FUNCNAME[0]}] Preparing ${name}..."
211 git reset --hard ${base_rev}
213 patch_dir=${script_dir}/ethos-u-setup/${name}/patches/
214 [[ -e ${patch_dir} && $(ls -A ${patch_dir}) ]] && \
215 git am -3 ${patch_dir}/*.patch
217 …echo -e "[${FUNCNAME[0]}] Patched ${name} @ $(git describe --all --long 2> /dev/null) in ${repo_di…
225 if [[ ! -e reference_model ]]; then
229 git submodule update --init --recursive
233 mkdir -p build
241 n=$(( $(sysctl -n hw.logicalcpu) / 2 ))
246 if [[ "$n" -lt 1 ]]; then
250 make -j"${n}"
258 # Prepare the Vela compiler for AoT to Ethos-U compilation
261 if [[ ! -e ethos-u-vela ]]; then
262 git clone https://review.mlplatform.org/ml/ethos-u/ethos-u-vela
263 repo_dir="${root_dir}/ethos-u-vela"
267 cd "${root_dir}/ethos-u-vela"
270 …VNV=$(python3 -c "import sys; print('venv') if (sys.prefix != sys.base_prefix) else print('not_ven…
274 # if not venv, we need the site-path where the vela
275 vela_path=$(python -c "import site; print(site.USER_BASE+'/bin')")
277 pip install . --user
288 echo "[main] Error: only x86-64 & aarch64 architecture is supported for now!"
304 # Setup the ethos-u dev environment
307 # Patch the ethos-u dev environment to include executorch application
308 repo_dir="${root_dir}/ethos-u/core_platform"