|
96 | 96 | - name: codecov
|
97 | 97 | run: ./codecov -t ${{settings.CODECOV_TOKEN.access_token}} -C ${{ ci.sha }} -B ${{ ci.head_ref }} -f build/lcov.info
|
98 | 98 |
|
99 |
| - linux-gcc-gpu-lavapipe: |
100 |
| - name: linux-gcc-gpu-lavapipe |
101 |
| - runs-on: |
102 |
| - pool-name: docker |
103 |
| - container: |
104 |
| - image: bkci/ci:ubuntu |
105 |
| - steps: |
106 |
| - - name: checkout |
107 |
| - checkout: self |
108 |
| - with: |
109 |
| - strategy: FRESH_CHECKOUT |
110 |
| - enableGitLfs: false |
111 |
| - |
112 |
| - - name: install-deps |
113 |
| - run: | |
114 |
| - apt-get update |
115 |
| - apt-get install -y lcov libvulkan-dev libxcb-shm0 |
116 |
| - curl https://uploader.codecov.io/verification.gpg | gpg --no-default-keyring --keyring trustedkeys.gpg --import |
117 |
| - curl -Os https://uploader.codecov.io/latest/linux/codecov |
118 |
| - curl -Os https://uploader.codecov.io/latest/linux/codecov.SHA256SUM |
119 |
| - curl -Os https://uploader.codecov.io/latest/linux/codecov.SHA256SUM.sig |
120 |
| - gpgv codecov.SHA256SUM.sig codecov.SHA256SUM |
121 |
| - shasum -a 256 -c codecov.SHA256SUM |
122 |
| - chmod +x codecov |
123 |
| -
|
124 |
| - - name: cache-lavapipe |
125 |
| - id: cache-lavapipe |
126 |
| - uses: cache@1.* |
127 |
| - with: |
128 |
| - cachePaths: lavapipe-install |
129 |
| - cacheKey: lavapipe-linux-install-20211127-4 |
130 |
| - |
131 |
| - - name: checkout-lavapipe |
132 |
| - if: steps.cache-lavapipe.outputs.cacheHit != 'true' |
133 |
| - checkout: https://github.com/mesa3d/mesa.git |
134 |
| - with: |
135 |
| - pullType: COMMIT_ID |
136 |
| - refName: cd39180cfab20734744b379b085cc3b5c2cecd3a |
137 |
| - localPath: mesa |
138 |
| - enableSubmodule: false |
139 |
| - enableGitLfs: false |
140 |
| - |
141 |
| - - name: lavapipe |
142 |
| - if: steps.cache-lavapipe.outputs.cacheHit != 'true' |
143 |
| - run: | |
144 |
| - echo 'deb-src http://mirrors.cloud.tencent.com/debian bullseye main' | tee -a /etc/apt/sources.list |
145 |
| - echo 'deb-src http://mirrors.cloud.tencent.com/debian bullseye-updates main' | tee -a /etc/apt/sources.list |
146 |
| - apt-get update |
147 |
| - apt-get build-dep -y mesa |
148 |
| - mkdir -p "${{ci.workspace}}/lavapipe-install" |
149 |
| - cd mesa |
150 |
| - mkdir build |
151 |
| - cd build |
152 |
| - meson -Dprefix="${{ci.workspace}}/lavapipe-install" -Dbuildtype=release -Db_lto=true -Db_ndebug=true -Dplatforms="x11" -Ddri3=enabled -Ddri-drivers="" -Dgallium-drivers=swrast -Dgallium-vdpau=disabled -Dgallium-xvmc=disabled -Dgallium-omx=disabled -Dgallium-va=disabled -Dgallium-xa=disabled -Dgallium-opencl=disabled -Dopencl-native=false -Dvulkan-drivers=swrast -Dshader-cache=disabled -Dgles1=disabled -Dgles2=disabled -Dopengl=false -Dgbm=disabled -Dglx=disabled -Degl=disabled -Dllvm=enabled -Dvalgrind=disabled -Dlibunwind=disabled -Dlmsensors=disabled .. |
153 |
| - ninja -j$(nproc) |
154 |
| - ninja install |
155 |
| - find ${{ci.workspace}}/lavapipe-install |
156 |
| - cat ${{ci.workspace}}/lavapipe-install/share/vulkan/icd.d/lvp_icd.x86_64.json |
157 |
| -
|
158 |
| - - name: build |
159 |
| - run: | |
160 |
| - mkdir build && cd build |
161 |
| - cmake -DCMAKE_BUILD_TYPE=debug -DNCNN_COVERAGE=ON -DNCNN_RUNTIME_CPU=OFF -DNCNN_AVX2=ON -DNCNN_AVX512=OFF -DNCNN_XOP=OFF -DNCNN_OPENMP=OFF -DNCNN_VULKAN=ON -DNCNN_BUILD_TOOLS=OFF -DNCNN_BUILD_EXAMPLES=OFF -DNCNN_BUILD_TESTS=ON .. |
162 |
| - cmake --build . -j 4 |
163 |
| - - name: test |
164 |
| - run: | |
165 |
| - export LP_NUM_THREADS=4 |
166 |
| - export VK_ICD_FILENAMES="${{ci.workspace}}/lavapipe-install/share/vulkan/icd.d/lvp_icd.x86_64.json" |
167 |
| - cd build |
168 |
| - ctest --output-on-failure -j 4 |
169 |
| - - name: lcov-collect |
170 |
| - run: | |
171 |
| - cd build |
172 |
| - lcov -d ./src -c -o lcov.info |
173 |
| - lcov -r lcov.info '/usr/*' -o lcov.info |
174 |
| - lcov -r lcov.info '*/build/*' -o lcov.info |
175 |
| - lcov -r lcov.info '*/glslang/*' -o lcov.info |
176 |
| - lcov --list lcov.info |
177 |
| - - name: codecov |
178 |
| - run: ./codecov -t ${{settings.CODECOV_TOKEN.access_token}} -C ${{ ci.sha }} -B ${{ ci.head_ref }} -f build/lcov.info |
179 |
| - |
180 | 99 | linux-gcc-x64:
|
181 | 100 | name: linux-gcc-x64
|
182 | 101 | strategy:
|
@@ -840,149 +759,6 @@ jobs:
|
840 | 759 | - name: codecov
|
841 | 760 | run: ./codecov -t ${{settings.CODECOV_TOKEN.access_token}} -C ${{ ci.sha }} -B ${{ ci.head_ref }} -f build/lcov.info
|
842 | 761 |
|
843 |
| - linux-gcc-riscv64-rvv: |
844 |
| - name: linux-gcc-riscv64-rvv |
845 |
| - strategy: |
846 |
| - matrix: |
847 |
| - OPENMP: ['OFF', 'ON'] |
848 |
| - |
849 |
| - runs-on: |
850 |
| - pool-name: docker |
851 |
| - container: |
852 |
| - image: bkci/ci:ubuntu |
853 |
| - steps: |
854 |
| - - name: checkout |
855 |
| - checkout: self |
856 |
| - with: |
857 |
| - strategy: FRESH_CHECKOUT |
858 |
| - enableSubmodule: false |
859 |
| - enableGitLfs: false |
860 |
| - |
861 |
| - - name: install-deps |
862 |
| - run: | |
863 |
| - apt-get update |
864 |
| - apt-get install -y lcov libcapstone4 libglib2.0-0 |
865 |
| - curl https://uploader.codecov.io/verification.gpg | gpg --no-default-keyring --keyring trustedkeys.gpg --import |
866 |
| - curl -Os https://uploader.codecov.io/latest/linux/codecov |
867 |
| - curl -Os https://uploader.codecov.io/latest/linux/codecov.SHA256SUM |
868 |
| - curl -Os https://uploader.codecov.io/latest/linux/codecov.SHA256SUM.sig |
869 |
| - gpgv codecov.SHA256SUM.sig codecov.SHA256SUM |
870 |
| - shasum -a 256 -c codecov.SHA256SUM |
871 |
| - chmod +x codecov |
872 |
| -
|
873 |
| - - name: cache-qemu |
874 |
| - id: cache-qemu |
875 |
| - uses: cache@1.* |
876 |
| - with: |
877 |
| - cachePaths: qemu-install |
878 |
| - cacheKey: qemu-riscv64-install-20230624-1 |
879 |
| - |
880 |
| - - name: checkout-qemu |
881 |
| - if: steps.cache-qemu.outputs.cacheHit != 'true' |
882 |
| - checkout: https://github.com/qemu/qemu.git |
883 |
| - with: |
884 |
| - pullType: COMMIT_ID |
885 |
| - refName: b455ce4c2f300c8ba47cba7232dd03261368a4cb |
886 |
| - localPath: qemu |
887 |
| - enableSubmodule: false |
888 |
| - enableGitLfs: false |
889 |
| - |
890 |
| - - name: qemu |
891 |
| - if: steps.cache-qemu.outputs.cacheHit != 'true' |
892 |
| - run: | |
893 |
| - echo 'deb-src http://mirrors.cloud.tencent.com/debian bullseye main' | tee -a /etc/apt/sources.list |
894 |
| - echo 'deb-src http://mirrors.cloud.tencent.com/debian bullseye-updates main' | tee -a /etc/apt/sources.list |
895 |
| - apt-get update |
896 |
| - apt-get build-dep -y qemu |
897 |
| - apt-get install -y python3-pip |
898 |
| - python3 -m pip install --upgrade pip |
899 |
| - apt-get remove -y python3-setuptools |
900 |
| - pip3 install -U setuptools |
901 |
| - cd qemu |
902 |
| - wget https://raw.githubusercontent.com/nihui/ncnn-assets/master/qemu-patches/0007-linux-user-Expose-risc-v-V-isa-bit-in-get_elf_hwcap.patch |
903 |
| - patch -p1 -i 0007-linux-user-Expose-risc-v-V-isa-bit-in-get_elf_hwcap.patch |
904 |
| - ./configure --prefix=${{ci.workspace}}/qemu-install --target-list=riscv64-linux-user --disable-system |
905 |
| - make -j$(nproc) |
906 |
| - make install |
907 |
| -
|
908 |
| - - name: cache-rv64gcv |
909 |
| - id: cache-rv64gcv |
910 |
| - uses: cache@1.* |
911 |
| - with: |
912 |
| - cachePaths: rv64gcv-install |
913 |
| - cacheKey: rv64gcv-linux-install-20221029-1 |
914 |
| - |
915 |
| - - name: checkout-riscv-gnu-toolchain |
916 |
| - if: steps.cache-rv64gcv.outputs.cacheHit != 'true' |
917 |
| - checkout: https://github.com/riscv/riscv-gnu-toolchain.git |
918 |
| - with: |
919 |
| - pullType: COMMIT_ID |
920 |
| - refName: da01ba455ce3802ffa84fdca3a089079996dbfc3 |
921 |
| - localPath: riscv-gnu-toolchain |
922 |
| - enableSubmodule: false |
923 |
| - enableGitLfs: false |
924 |
| - |
925 |
| - - name: riscv-gnu-toolchain |
926 |
| - if: steps.cache-rv64gcv.outputs.cacheHit != 'true' |
927 |
| - run: | |
928 |
| - apt-get update |
929 |
| - apt-get install -y autoconf automake autotools-dev curl python3 libmpc-dev libmpfr-dev libgmp-dev gawk build-essential bison flex texinfo gperf libtool patchutils bc zlib1g-dev libexpat-dev device-tree-compiler |
930 |
| - cd riscv-gnu-toolchain |
931 |
| - git submodule update --init --recursive --depth 1 glibc |
932 |
| - git submodule update --init --recursive --depth 1 newlib |
933 |
| - #git submodule update --init --recursive --depth 1 riscv-binutils |
934 |
| - #git submodule update --init --recursive --depth 1 riscv-gcc |
935 |
| - git submodule update --init --recursive --depth 1 riscv-dejagnu |
936 |
| - git submodule update --init --recursive --depth 1 riscv-gdb |
937 |
| - rm -rf riscv-binutils |
938 |
| - git clone -b binutils-2_39-branch https://sourceware.org/git/binutils-gdb.git riscv-binutils |
939 |
| - rm -rf riscv-gcc |
940 |
| - git clone -b riscv-gcc-rvv-next https://github.com/riscv-collab/riscv-gcc.git riscv-gcc |
941 |
| - cd riscv-gcc |
942 |
| - git checkout 8a0c1b106f01c455a8fb478cfe52d859a69020fd |
943 |
| - cd .. |
944 |
| - sed -i '/__OBSOLETE_MATH/d' newlib/newlib/libm/common/math_errf.c |
945 |
| - ./configure --prefix=${{ci.workspace}}/rv64gcv-install --with-arch=rv64gcv_zfh |
946 |
| - make linux -j$(nproc) |
947 |
| - find ${{ci.workspace}}/rv64gcv-install -type f | xargs -i strip -g {} || true |
948 |
| -
|
949 |
| - - name: build |
950 |
| - run: | |
951 |
| - export RISCV_ROOT_PATH=${{ci.workspace}}/rv64gcv-install |
952 |
| - mkdir build && cd build |
953 |
| - cmake -DCMAKE_TOOLCHAIN_FILE=../toolchains/riscv64-unknown-linux-gnu.toolchain.cmake -DCMAKE_BUILD_TYPE=debug -DCMAKE_C_FLAGS="-O1" -DCMAKE_CXX_FLAGS="-O1" -DNCNN_COVERAGE=ON -DNCNN_RUNTIME_CPU=OFF -DNCNN_RVV=ON -DNCNN_OPENMP=${{matrix.OPENMP}} -DNCNN_BUILD_TOOLS=OFF -DNCNN_BUILD_EXAMPLES=OFF -DNCNN_BUILD_TESTS=ON .. |
954 |
| - cmake --build . -j 4 |
955 |
| - - name: test-vlen128 |
956 |
| - run: | |
957 |
| - export PATH=${{ci.workspace}}/qemu-install/bin:$PATH |
958 |
| - cd build |
959 |
| - TESTS_EXECUTABLE_LOADER=qemu-riscv64 TESTS_EXECUTABLE_LOADER_ARGUMENTS="-cpu;rv64,v=true,Zfh=true,x-zvfh=true,vlen=128,elen=64,vext_spec=v1.0;-L;${{ci.workspace}}/rv64gcv-install/sysroot" ctest --output-on-failure -j 4 |
960 |
| - - name: lcov-collect-vlen128 |
961 |
| - run: | |
962 |
| - cd build |
963 |
| - lcov --gcov-tool ${{ci.workspace}}/rv64gcv-install/bin/riscv64-unknown-linux-gnu-gcov -d ./src -c -o lcov.info |
964 |
| - lcov -r lcov.info '/usr/*' -o lcov.info |
965 |
| - lcov -r lcov.info '*/build/*' -o lcov.info |
966 |
| - lcov -r lcov.info '*/rv64gcv-install/*' -o lcov.info |
967 |
| - lcov --list lcov.info |
968 |
| - - name: codecov-vlen128 |
969 |
| - run: ./codecov -t ${{settings.CODECOV_TOKEN.access_token}} -C ${{ ci.sha }} -B ${{ ci.head_ref }} -f build/lcov.info |
970 |
| - - name: test-vlen256 |
971 |
| - run: | |
972 |
| - export PATH=${{ci.workspace}}/qemu-install/bin:$PATH |
973 |
| - cd build |
974 |
| - TESTS_EXECUTABLE_LOADER=qemu-riscv64 TESTS_EXECUTABLE_LOADER_ARGUMENTS="-cpu;rv64,v=true,Zfh=true,x-zvfh=true,vlen=256,elen=64,vext_spec=v1.0;-L;${{ci.workspace}}/rv64gcv-install/sysroot" ctest --output-on-failure -j 4 |
975 |
| - - name: lcov-collect-vlen256 |
976 |
| - run: | |
977 |
| - cd build |
978 |
| - lcov --gcov-tool ${{ci.workspace}}/rv64gcv-install/bin/riscv64-unknown-linux-gnu-gcov -d ./src -c -o lcov.info |
979 |
| - lcov -r lcov.info '/usr/*' -o lcov.info |
980 |
| - lcov -r lcov.info '*/build/*' -o lcov.info |
981 |
| - lcov -r lcov.info '*/rv64gcv-install/*' -o lcov.info |
982 |
| - lcov --list lcov.info |
983 |
| - - name: codecov-vlen256 |
984 |
| - run: ./codecov -t ${{settings.CODECOV_TOKEN.access_token}} -C ${{ ci.sha }} -B ${{ ci.head_ref }} -f build/lcov.info |
985 |
| - |
986 | 762 | linux-gcc-loongarch64:
|
987 | 763 | name: linux-gcc-loongarch64
|
988 | 764 | strategy:
|
|
0 commit comments