Skip to content

Commit

Permalink
gh-actions: test loongson + lsx with gcc14 from Ubuntu Oracular
Browse files Browse the repository at this point in the history
Bonus: we no longer have to skip tests due to the updated qemu
  • Loading branch information
mr-c committed Sep 11, 2024
1 parent d210e29 commit 061d625
Show file tree
Hide file tree
Showing 2 changed files with 28 additions and 26 deletions.
34 changes: 8 additions & 26 deletions .github/workflows/ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -864,42 +864,24 @@ jobs:
ninja -C build test
linux-gcc-loongarch64:
runs-on: ubuntu-22.04
runs-on: ubuntu-24.04
container: amd64/ubuntu:24.10
steps:
- uses: actions/checkout@v4
- name: CPU Information
run: cat /proc/cpuinfo
- name: Install APT Dependencies
run: |
sudo add-apt-repository ppa:savoury1/virtualisation
sudo apt-get install -y ninja-build ninja-build meson qemu-user-static
- name: Download and install loongarch64-toolchain
run: |
wget https://github.com/loongson/build-tools/releases/download/2022.09.06/loongarch64-clfs-7.3-cross-tools-gcc-glibc.tar.xz
tar -xf loongarch64-clfs-7.3-cross-tools-gcc-glibc.tar.xz -C /opt
apt-get update && apt-get install -y --no-install-recommends \
ninja-build ninja-build meson qemu-user-static binfmt-support \
libc6-loong64-cross libstdc++-14-dev-loong64-cross \
gcc-14-loongarch64-linux-gnu g++-14-loongarch64-linux-gnu
- name: ccache
uses: hendrikmuhs/[email protected]
with:
key: ${{ github.job }}-loongarch64-gcc-13
- name: set env
run: |
echo "LD_LIBRARY_PATH=/opt/cross-tools/target/usr/lib64:/opt/cross-tools/loongarch64-unknown-linux-gnu/lib64:$LD_LIBRARY_PATH" >> $GITHUB_ENV
echo "PATH=$GITHUB_WORKSPACE:/opt/cross-tools/bin:$PATH" >> $GITHUB_ENV
- name: Disable SVML tests
run: |
sed -i "/svml/d" test/x86/meson.build
rm test/x86/svml.c
echo "Due to the qemu versions 7.2 through 8.0 causing timeouts in four sets of test cases,"
echo "the SVML tests have been temporarily disabled."
- name: Disable RND*X tests
run: |
sed -i "/rndx/d" meson.build
sed -i "/rnd..x/d" meson.build
rm test/arm/neon/rndx.c test/arm/neon/rnd32x.c test/arm/neon/rnd64x.c
echo "Due to the qemu versions 7.2 through 8.0 causing timeouts in four sets of test cases,"
echo "the RNDX, RND32X, and RND64X tests have been temporarily disabled."
key: ${{ github.job }}-gcc-14
- name: Configure
run: meson setup build --cross-file=docker/cross-files/loongarch64-gcc-13-ccache.cross
run: meson setup build --cross-file=docker/cross-files/loongarch64-gcc-14-ccache.cross || (cat build/meson-logs/meson-log.txt ; false)
- name: Build
run: meson compile -C build -v
- name: Test
Expand Down
20 changes: 20 additions & 0 deletions docker/cross-files/loongarch64-gcc-14-ccache.cross
Original file line number Diff line number Diff line change
@@ -0,0 +1,20 @@
[binaries]
c = ['ccache', 'loongarch64-linux-gnu-gcc-14']
cpp = ['ccache', 'loongarch64-linux-gnu-g++-14']
ar = 'loongarch64-linux-gnu-gcc-ar-14'
strip = 'loongarch64-linux-gnu-strip'
objcopy = 'loongarch64-linux-gnu-objcopy'
ld = 'loongarch64-linux-gnu-ld'
exe_wrapper = ['qemu-loongarch64-static', '-L', '/usr/loongarch64-linux-gnu/', '-cpu', 'la464']

[properties]
c_args = ['-march=loongarch64', '-Wextra', '-Werror', '-mlsx']
cpp_args = ['-march=loongarch64', '-Wextra', '-Werror', '-mlsx']
#c_args = ['-march=la464', '-Wextra', '-Werror']
#cpp_args = ['-march=la464', '-Wextra', '-Werror']

[host_machine]
system = 'linux'
cpu_family = 'loongarch64'
cpu = 'loongarch64'
endian = 'little'

0 comments on commit 061d625

Please sign in to comment.