@@ -24,6 +24,16 @@ void fun() {
24
24
// CHECK: %add = add i64 %1, 50, !dbg [[G4R2:!.*]]
25
25
// CHECK: store i64 %add, ptr @g{{.*}}, !dbg [[G4R1:!.*]]
26
26
g += 50 ;
27
+
28
+ // Pre/Post Inc/Dec.
29
+ // CHECK: %2 = load i64, ptr @g
30
+ // CHECK: %inc = add i64 %2, 1, !dbg [[G5R2:!.*]]
31
+ // CHECK: store i64 %inc, ptr @g{{.*}}, !dbg [[G5R1:!.*]]
32
+ ++ g ;
33
+ // CHECK: %3 = load i64, ptr @g
34
+ // CHECK: %dec = add i64 %3, -1, !dbg [[G6R2:!.*]]
35
+ // CHECK: store i64 %dec, ptr @g{{.*}}, !dbg [[G6R1:!.*]]
36
+ g -- ;
27
37
}
28
38
29
39
// CHECK: [[G1R1]] = !DILocation({{.*}}, atomGroup: 1, atomRank: 1)
@@ -32,3 +42,7 @@ void fun() {
32
42
// CHECK: [[G2R1]] = !DILocation({{.*}}, atomGroup: 2, atomRank: 1)
33
43
// CHECK: [[G4R2]] = !DILocation({{.*}}, atomGroup: 4, atomRank: 2)
34
44
// CHECK: [[G4R1]] = !DILocation({{.*}}, atomGroup: 4, atomRank: 1)
45
+ // CHECK: [[G5R2]] = !DILocation({{.*}}, atomGroup: 5, atomRank: 2)
46
+ // CHECK: [[G5R1]] = !DILocation({{.*}}, atomGroup: 5, atomRank: 1)
47
+ // CHECK: [[G6R2]] = !DILocation({{.*}}, atomGroup: 6, atomRank: 2)
48
+ // CHECK: [[G6R1]] = !DILocation({{.*}}, atomGroup: 6, atomRank: 1)
0 commit comments