[CodeGen][RISCV] Fix clang/test/CodeGen/atomic_ops.c for RISC-V
By default the RISC-V target doesn't have the atomics standard extension enabled. The first RUN line in `clang/test/CodeGen/atomic_ops.c` didn't specify a target triple, which meant that on RISC-V Linux hosts it would target RISC-V, but because it used clang cc1 we didn't get the toolchain driver functionality to automatically turn on the extensions implied by the target triple (riscv64-linux includes atomics). This would cause the test to fail on RISC-V hosts. This patch changes the test to have RUN lines for two explicit targets, one with native atomics and one without. To work around FileCheck limitations and more accurately match the output, some tests now have separate prefixes for the two cases. Reviewers: jyknight, eli.friedman, lenary, efriedma Reviewed By: efriedma Differential Revision: https://reviews.llvm.org/D74847
Loading
Please sign in to comment