brintos

brintos / llvm-project-archived public Read only

0
0
Text · 397 B · 778a7eb Raw
12 lines · c
1// RUN: %clang_cc1 -triple riscv64 -O1 -emit-llvm %s -o - | FileCheck %s2#include <stdbool.h>3 4extern bool t1;5bool test1(void) {6// CHECK-LABEL: define{{.*}} i1 @test17// CHECK: load atomic i8, ptr @t1 monotonic, align 1, !range ![[$WS_RANGE:[0-9]*]], !noundef !{{[0-9]+}}8// CHECK-NEXT: trunc nuw i8 %{{.*}} to i19// CHECK-NEXT: ret i1 %{{.*}}10  return __atomic_load_n(&t1, __ATOMIC_RELAXED);11}12