OpenBLAS icon indicating copy to clipboard operation
OpenBLAS copied to clipboard

GitHub Actions: Add cross compile tests

Open FlyGoat opened this issue 3 years ago • 6 comments

Add cross compile tests without running checks. Currently only mips64el and riscv64 is wired up. Just help us make sure those less popular CPUs are not messed up by changes.

And it seems like riscv64 is already broken in tree :-(

FlyGoat avatar Aug 08 '22 19:08 FlyGoat

You need to supply a valid TARGET (as enumerated in TargetList.txt) when cross-compiling, I do not see that in your PR?

martin-frbg avatar Aug 08 '22 19:08 martin-frbg

Ah I see, in #3720 I added DYNAMIC_ARCH support for MIPS64 and it will be able to probe arch and target from toolchain. For riscv64 it is incapable to do so. Will fix.

Thanks.

FlyGoat avatar Aug 08 '22 19:08 FlyGoat

You need either DYNAMIC_ARCH or a TARGET, there is no build-time probing of cpu in cross-compiling as the target cpu will in most cases be on a completely different computer. RISCV already has RISCV64_GENERIC but no DYNAMIC_ARCH support (would be a bit overkill when it is just a choice between two targets, the optimized C910V and the generic one).

martin-frbg avatar Aug 09 '22 05:08 martin-frbg

Debian has cross-toolchains for all of its own arches, should be like 1:1 to just convert distro to debian 11 now, then extend if some niche arch gets problems some day.

brada4 avatar Aug 09 '22 20:08 brada4

Debian has cross-toolchains for all of its own arches, should be like 1:1 to just convert distro to debian 11 now, then extend if some niche arch gets problems some day.

GitHub Action itself doesn't provide Debian VM. Using Docker seems a little bit overkill. Ubuntu 22.04 provides almost all cross toolchains shipped with Debian11 :-)

FlyGoat avatar Aug 10 '22 13:08 FlyGoat

Now mipsel and alpha are wired up as well. Alpha build issues are addressed by #3725.

FlyGoat avatar Aug 11 '22 14:08 FlyGoat

unrelated manylinux build failure was fixed by my #3726 (guess this only came up as the manylinux instance lost its fortran compiler somehow). sorry for the delay in merging

martin-frbg avatar Aug 19 '22 18:08 martin-frbg