riscv-tests
riscv-tests copied to clipboard
fix compile for Clang
When trying to compile riscv-tests with clang, several incompatible compilation issues between clang and gcc are met, such as:
- https://github.com/riscv-software-src/riscv-tests/pull/225
- clang doesn't support immediates like
0f:7fc00000 - clang doesn't support bf16 until https://github.com/llvm/llvm-project/commit/e4888a37d36780872d685c68ef8b26b2e14d6d39, but it only works for X86 yet, and will not affect current release of clang (i.e. clang-14)
- GNU as let
.weakoverride.globl, while clang lets the last directive win https://reviews.llvm.org/D90108