Ehud Katz | 03a9526 | 2020-04-16 13:26:23 +0300 | [diff] [blame] | 1 | // RUN: %clang_cc1 -emit-llvm %s -o - | FileCheck %s |
2 | // PR45476 | ||||
3 | |||||
4 | // This test used to get into an infinite loop, | ||||
5 | // which, in turn, caused clang to never finish execution. | ||||
6 | |||||
7 | struct s3 { | ||||
8 | char a, b, c; | ||||
9 | }; | ||||
10 | |||||
11 | _Atomic struct s3 a; | ||||
12 | |||||
13 | extern "C" void foo() { | ||||
14 | // CHECK-LABEL: @foo | ||||
15 | // CHECK: store atomic i32 | ||||
16 | |||||
17 | a = s3{1, 2, 3}; | ||||
18 | } | ||||
19 |