11# ------------------------------------------------------------------------------
2- # Copyright Matt Borland 2023.
3- # Copyright Christopher Kormanyos 2023.
2+ # Copyright Matt Borland 2023 - 2024 .
3+ # Copyright Christopher Kormanyos 2023 - 2024 .
44# Distributed under the Boost Software License,
55# Version 1.0. (See accompanying file LICENSE_1_0.txt
66# or copy at http://www.boost.org/LICENSE_1_0.txt)
@@ -27,28 +27,44 @@ jobs:
2727 fetch-depth : ' 0'
2828 - name : update-tools
2929 run : |
30- sudo apt install libncurses5 libpython2.7
30+ sudo apt update
31+ wget http://security.ubuntu.com/ubuntu/pool/universe/n/ncurses/libtinfo5_6.3-2ubuntu0.1_amd64.deb
32+ sudo apt install ./libtinfo5_6.3-2ubuntu0.1_amd64.deb
33+ wget http://security.ubuntu.com/ubuntu/pool/universe/n/ncurses/libncursesw5_6.3-2ubuntu0.1_amd64.deb
34+ sudo apt install ./libncursesw5_6.3-2ubuntu0.1_amd64.deb
3135 mkdir -p emu_env && cd emu_env
32- wget --no-check-certificate https://armkeil.blob.core.windows.net/developer/ Files/downloads/gnu-rm/10.3-2021.10/gcc- arm-none-eabi-10.3-2021.10 -x86_64-linux .tar.bz2
33- tar -xf gcc- arm-none-eabi-10.3-2021.10 -x86_64-linux .tar.bz2
34- wget --no-check-certificate https://github.com/xpack-dev-tools/qemu-arm-xpack/releases/download/v7.1.0 -1/xpack-qemu-arm-7.1.0 -1-linux-x64.tar.gz
35- tar -xzf xpack-qemu-arm-7.1.0 -1-linux-x64.tar.gz
36+ wget --no-check-certificate https://developer.arm.com/-/media/ Files/downloads/gnu/13.3.rel1/binrel/ arm-gnu-toolchain-13.3.rel1 -x86_64-arm-none-eabi .tar.xz
37+ tar -xf arm-gnu-toolchain-13.3.rel1 -x86_64-arm-none-eabi .tar.xz
38+ wget --no-check-certificate https://github.com/xpack-dev-tools/qemu-arm-xpack/releases/download/v8.2.6 -1/xpack-qemu-arm-8.2.6 -1-linux-x64.tar.gz
39+ tar -xzf xpack-qemu-arm-8.2.6 -1-linux-x64.tar.gz
3640 working-directory : ./test/metal/
3741 - name : build benchmark_single-stm32f429
3842 run : |
43+ PATH="${{ runner.workspace }}/decimal/test/metal/emu_env/arm-gnu-toolchain-13.3.rel1-x86_64-arm-none-eabi/bin:$PATH"
44+ echo 'Query arm-none-eabi-g++ version'
45+ echo
46+ arm-none-eabi-g++ -v
47+ echo
3948 mkdir -p bin
40- emu_env/gcc- arm-none-eabi-10.3-2021.10/bin/arm-none-eabi- g++ -std=c++17 -Wall -Wextra -Wpedantic -Os -g -gdwarf-2 -ffunction-sections -fdata-sections -x c++ -fno-rtti -fno-use-cxa-atexit -fno-exceptions -fno-nonansi-builtins -fno-threadsafe-statics -fno-enforce-eh-specs -fno-inline-functions -mcpu=cortex-m4 -mtune=cortex-m4 -mthumb -mfloat-abi=soft -mno-unaligned-access -mno-long-calls -I../../include -DBOOST_DECIMAL_DISABLE_CLIB -DAPP_BENCHMARK_STANDALONE_MAIN app_benchmark_non_std_decimal.cpp ./target/micros/stm32f429/make/single/crt.cpp ./target/micros/stm32f429/make/single/mcal_gcc_cxx_completion_with_stdlib.cpp -nostartfiles -Wl,--gc-sections -Wl,-Map,./bin/app_benchmark_non_std_decimal.map -T ./target/micros/stm32f429/make/stm32f429.ld --specs=nano.specs --specs=nosys.specs -Wl,--print-memory-usage -o ./bin/app_benchmark_non_std_decimal.elf
41- emu_env/gcc-arm-none-eabi-10.3-2021.10/bin/ arm-none-eabi-objcopy ./bin/app_benchmark_non_std_decimal.elf -O ihex ./bin/app_benchmark_non_std_decimal.hex
49+ arm-none-eabi-g++ -std=c++20 -Wall -Wextra -Wpedantic -Os -g -gdwarf-2 -ffunction-sections -fdata-sections -x c++ -fno-rtti -fno-use-cxa-atexit -fno-exceptions -fno-nonansi-builtins -fno-threadsafe-statics -fno-enforce-eh-specs -fno-inline-functions -mcpu=cortex-m4 -mtune=cortex-m4 -mthumb -mfloat-abi=soft -mno-unaligned-access -mno-long-calls -I../../include -DBOOST_DECIMAL_DISABLE_CLIB -DAPP_BENCHMARK_STANDALONE_MAIN app_benchmark_non_std_decimal.cpp ./target/micros/stm32f429/make/single/crt.cpp ./target/micros/stm32f429/make/single/mcal_gcc_cxx_completion_with_stdlib.cpp -nostartfiles -Wl,--gc-sections -Wl,-Map,./bin/app_benchmark_non_std_decimal.map -T ./target/micros/stm32f429/make/stm32f429.ld --specs=nano.specs --specs=nosys.specs -Wl,--print-memory-usage -o ./bin/app_benchmark_non_std_decimal.elf
50+ arm-none-eabi-objcopy ./bin/app_benchmark_non_std_decimal.elf -O ihex ./bin/app_benchmark_non_std_decimal.hex
4251 ls -la ./bin/app_benchmark_non_std_decimal.elf ./bin/app_benchmark_non_std_decimal.hex ./bin/app_benchmark_non_std_decimal.map
4352 working-directory : ./test/metal/
4453 - name : emulate-target stm32f429
4554 run : |
46- ./emu_env/xpack-qemu-arm-7.1.0-1/bin/qemu-system-gnuarmeclipse --verbose --mcu STM32F429ZI --nographic --gdb tcp::9999 -d unimp,guest_errors &
55+ PATH="${{ runner.workspace }}/decimal/test/metal/emu_env/xpack-qemu-arm-8.2.6-1/bin:$PATH"
56+ qemu-system-gnuarmeclipse --verbose --mcu STM32F429ZI --nographic --gdb tcp::9999 -d unimp,guest_errors &
57+ sleep 2
4758 working-directory : ./test/metal/
4859 - name : run-test-on-target
4960 run : |
50- ./emu_env/gcc-arm-none-eabi-10.3-2021.10/bin/arm-none-eabi-gdb-py ./bin/app_benchmark_non_std_decimal.elf -x ./target/build/test_app_benchmarks_emulator.py
51- qemu_result=$?
52- echo "qemu_result" "$qemu_result"
53- echo "qemu_result" "$qemu_result" | grep 'qemu_result 0'
61+ sleep 2
62+ PATH="${{ runner.workspace }}/decimal/test/metal/emu_env/arm-gnu-toolchain-13.3.rel1-x86_64-arm-none-eabi/bin:$PATH"
63+ echo 'Run test on target'
64+ echo
65+ arm-none-eabi-gdb ./bin/app_benchmark_non_std_decimal.elf -x ./target/build/test_app_benchmarks_emulator.gdb > ./app_benchmark_non_std_decimal.txt
66+ cat ./app_benchmark_non_std_decimal.txt
67+ echo
68+ echo 'We will now grep for the right answer...'
69+ grep 'value 0xF00DCAFE' ./app_benchmark_non_std_decimal.txt
5470 working-directory : ./test/metal/
0 commit comments