File tree Expand file tree Collapse file tree 1 file changed +7
-7
lines changed Expand file tree Collapse file tree 1 file changed +7
-7
lines changed Original file line number Diff line number Diff line change 1
- // XFAIL: *
2
1
// RUN: %clang_cc1 -triple x86_64-unknown-linux-gnu -fclangir -emit-cir %s -o %t.cir
3
2
// RUN: FileCheck --input-file=%t.cir %s
4
3
@@ -24,13 +23,14 @@ void test2() { ({int x = 3; x; }); }
24
23
struct S { int x ; };
25
24
int test3 () { return ({ struct S s = {1 }; s ; }).x ; }
26
25
// CHECK: @test3
27
- // CHECK: %[[#RETVAL:]] = cir.alloca !rec_S, !cir.ptr<!rec_S>
28
26
// CHECK: cir.scope {
29
- // CHECK: %[[#VAR:]] = cir.alloca !rec_S, !cir.ptr<!rec_S>
30
- // [...]
31
- // CHECK: cir.copy %[[#VAR]] to %[[#RETVAL]] : !cir.ptr<!rec_S>
32
- // CHECK: }
33
- // CHECK: %[[#RETADDR:]] = cir.get_member %1[0] {name = "x"} : !cir.ptr<!rec_S> -> !cir.ptr<!s32i>
27
+ // CHECK: %[[#REF_TMP:]] = cir.alloca !rec_S, !cir.ptr<!rec_S>, ["ref.tmp0"]
28
+ // CHECK: cir.scope {
29
+ // CHECK: %[[#VAR:]] = cir.alloca !rec_S, !cir.ptr<!rec_S>
30
+ // [...]
31
+ // CHECK: cir.copy %[[#VAR]] to %[[#REF_TMP]] : !cir.ptr<!rec_S>
32
+ // CHECK: }
33
+ // CHECK: %[[#RETADDR:]] = cir.get_member %[[#REF_TMP]][0] {name = "x"} : !cir.ptr<!rec_S> -> !cir.ptr<!s32i>
34
34
// CHECK: %{{.+}} = cir.load{{.*}} %[[#RETADDR]] : !cir.ptr<!s32i>, !s32i
35
35
36
36
// Expression is wrapped in an expression attribute (just ensure it does not crash).
You can’t perform that action at this time.
0 commit comments