Skip to content

Commit e8ef20d

Browse files
Add clang workflow for PPC
1 parent 8df8da7 commit e8ef20d

3 files changed

Lines changed: 25 additions & 3 deletions

File tree

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,5 @@
1+
set(CMAKE_SYSTEM_PROCESSOR powerpc64)
2+
set(triple powerpc64-linux-gnu)
3+
4+
include(${CMAKE_CURRENT_LIST_DIR}/clang.cmake)
5+
Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,5 @@
1+
set(CMAKE_SYSTEM_PROCESSOR powerpc64le)
2+
set(triple powerpc64le-linux-gnu)
3+
4+
include(${CMAKE_CURRENT_LIST_DIR}/clang.cmake)
5+

.github/workflows/cross-ppc.yml

Lines changed: 15 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -15,16 +15,27 @@ jobs:
1515
- { platform: 'ppc64', dir: 'powerpc64-linux-gnu', flags: '-maltivec -mvsx -mcpu=power10', full: 'OFF' }
1616
sys:
1717
- { compiler: 'gcc', version: '12' }
18+
- { compiler: 'clang', version: '20', gcc_runtime: '12' }
1819
steps:
19-
- name: Setup compiler
20+
- name: Setup GCC
2021
if: ${{ matrix.sys.compiler == 'gcc' }}
2122
run: |
2223
sudo apt-get update || exit 1
23-
sudo apt-get --no-install-suggests --no-install-recommends install g++-${{ matrix.sys.version }}-${{ matrix.target.dir }} g++-${{ matrix.sys.version }}-multilib || exit 1
24+
sudo apt-get -y --no-install-suggests --no-install-recommends install g++-${{ matrix.sys.version }}-${{ matrix.target.dir }} g++-${{ matrix.sys.version }}-multilib cmake || exit 1
2425
sudo update-alternatives --remove-all ${{ matrix.target.dir }}-gcc || true
2526
sudo update-alternatives --remove-all ${{ matrix.target.dir }}-g++ || true
2627
sudo update-alternatives --install /usr/bin/${{ matrix.target.dir }}-gcc ${{ matrix.target.dir }}-gcc /usr/bin/${{ matrix.target.dir }}-gcc-${{ matrix.sys.version }} 20
2728
sudo update-alternatives --install /usr/bin/${{ matrix.target.dir }}-g++ ${{ matrix.target.dir }}-g++ /usr/bin/${{ matrix.target.dir }}-g++-${{ matrix.sys.version }} 20
29+
- name: Setup LLVM
30+
if: ${{ matrix.sys.compiler == 'clang' }}
31+
run: |
32+
sudo apt-get update || exit 1
33+
sudo apt-get -y --no-install-suggests --no-install-recommends install g++-${{ matrix.sys.gcc_runtime }}-${{ matrix.target.dir }} g++-${{ matrix.sys.gcc_runtime }}-multilib cmake || exit 1
34+
sudo apt-get -y --no-install-suggests --no-install-recommends install clang-${{ matrix.sys.version }} || exit 1
35+
sudo update-alternatives --remove-all /usr/bin/clang || true
36+
sudo update-alternatives --remove-all /usr/bin/clang++ || true
37+
sudo update-alternatives --install /usr/bin/clang clang /usr/bin/clang-${{ matrix.sys.version }} 20
38+
sudo update-alternatives --install /usr/bin/clang++ clang++ /usr/bin/clang++-${{ matrix.sys.version }} 20
2839
- name: Setup QEMU
2940
run: |
3041
sudo apt-get --no-install-suggests --no-install-recommends install qemu-user
@@ -45,13 +56,14 @@ jobs:
4556
- name: Build
4657
run: cmake --build build/ --verbose -j1
4758
- name: Set CPU feature test expectations
48-
run: |
59+
run: /bin/true
4960
- name: Testing xsimd
5061
run: |
5162
# Set CPU feature test expectations, 0 is explicit absence of the feature
5263
export XSIMD_TEST_CPU_ASSUME_SSE4_2="0"
5364
export XSIMD_TEST_CPU_ASSUME_NEON64="0"
5465
export XSIMD_TEST_CPU_ASSUME_RVV="0"
66+
export XSIMD_TEST_CPU_ASSUME_VXE="0"
5567
export XSIMD_TEST_CPU_ASSUME_VSX="1"
5668
5769
qemu-${{ matrix.target.platform }} -cpu power10 -L /usr/${{ matrix.target.dir}}/ ./build/test/test_xsimd

0 commit comments

Comments
 (0)