Work on Neon tests for future github action #23
Workflow file for this run
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
name: Neon tests | |
on: | |
workflow_dispatch: | |
pull_request: | |
branches: [main] | |
push: | |
branches: [main] | |
permissions: | |
actions: read | |
security-events: write | |
jobs: | |
CI_test_run: | |
runs-on: ubuntu-22.04-arm | |
steps: | |
- name: Checkout | |
uses: actions/checkout@v4 | |
- name: Setup Python 3.10 | |
uses: actions/setup-python@v5 | |
with: | |
python-version: '3.10' | |
- name: Install system packages | |
run: | | |
sudo add-apt-repository ppa:deadsnakes/ppa | |
sudo apt-get install libpython3.9 libtinfo5 | |
sudo apt install build-essential | |
sudo update-alternatives --install /usr/bin/gcc gcc /usr/bin/gcc-11 60 --slave /usr/bin/g++ g++ /usr/bin/g++-11 | |
sudo update-alternatives --install /usr/bin/gcc gcc /usr/bin/gcc-12 40 --slave /usr/bin/g++ g++ /usr/bin/g++-12 | |
sudo update-alternatives --set gcc /usr/bin/gcc-12 | |
- name: Activate vcpkg | |
uses: ARM-software/cmsis-actions/vcpkg@v1 | |
with: | |
config: "./vcpkg-neon-configuration.json" | |
- name: Prepare framework | |
run: | | |
cd Testing | |
echo "Create missing folders" | |
mkdir FullBenchmark | |
mkdir Output | |
mkdir GeneratedInclude | |
mkdir GeneratedSource | |
mkdir GeneratedIncludeBench | |
mkdir GeneratedSourceBench | |
mkdir build | |
echo "Install missing python packages" | |
pip install -r requirements.txt | |
echo "Preprocess test description" | |
python preprocess.py -f desc.txt -o Output.pickle | |
python preprocess.py -f desc_neon.txt -o Output_neon.pickle | |
python preprocess.py -f desc_f16.txt -o Output_f16.pickle | |
echo "Generate missing CPP headers" | |
python processTests.py -gen . -p Patterns -d Parameters -f Output.pickle -e | |
python processTests.py -gen . -p Patterns -d Parameters -f Output_neon.pickle -e | |
python processTests.py -gen . -p Patterns -d Parameters -f Output_f16.pickle -e | |
cd build | |
cmake -G "Ninja" .. | |
# - name: Setup tmate session | |
# uses: mxschmitt/action-tmate@v3 | |
- name: Execute generic tests | |
run: | | |
cd Testing/build | |
python ../processTests.py -p ../Patterns -d ../Parameters -gen .. -e -f ../Output.pickle | |
ninja | |
./test > result.txt | |
python ../processResult.py --noerr -e -f ../Output.pickle -r result.txt -html > result.html | |
- name: Execute neon specific C tests | |
run: | | |
cd Testing/build | |
python ../processTests.py -p ../Patterns -d ../Parameters -gen .. -e -f ../Output_neon.pickle | |
ninja | |
./test > result_neon.txt | |
python ../processResult.py --noerr -e -f ../Output_neon.pickle -r result_neon.txt -html > result_neon.html | |
- name: Execute f16 C tests | |
run: | | |
cd Testing/build | |
python ../processTests.py -p ../Patterns -d ../Parameters -gen .. -e -f ../Output_f16.pickle | |
ninja | |
./test > result_f16.txt | |
python ../processResult.py --noerr -e -f ../Output_f16.pickle -r result_f16.txt -html > result_f16.html | |
- name: Upload test report | |
uses: actions/upload-artifact@v4 | |
with: | |
name: neon-test-report | |
path: | | |
Testing/build/result.html | |
Testing/build/result_neon.html | |
Testing/build/result_f16.html | |
- name: Check error | |
run: | | |
cd Testing/build | |
echo "Checking output..." | |
test "$(grep "FAILED" result.html | wc -l)" -eq 0 | |
test "$(grep "FAILED" result_neon.html | wc -l)" -eq 0 | |
test "$(grep "FAILED" result_f16.html | wc -l)" -eq 0 | |