1 // RUN: %clangxx -target x86_64-unknown-unknown -g \
2 // RUN: %s -emit-llvm -S -o - | FileCheck %s
4 // RUN: %clangxx -target x86_64-unknown-unknown -g \
5 // RUN: -fno-elide-constructors %s -emit-llvm -S -o - | \
6 // RUN: FileCheck %s -check-prefix=NOELIDE
10 Foo(Foo
&&other
) { x
= other
.x
; }
13 void some_function(int);
26 // Check that NRVO variables are stored as a pointer with deref if they are
27 // stored in the return register.
29 // CHECK: %[[RESULT:.*]] = alloca ptr, align 8
30 // CHECK: call void @llvm.dbg.declare(metadata ptr %[[RESULT]],
31 // CHECK-SAME: metadata !DIExpression(DW_OP_deref)
33 // NOELIDE: %[[FOO:.*]] = alloca %struct.Foo, align 4
34 // NOELIDE: call void @llvm.dbg.declare(metadata ptr %[[FOO]],
35 // NOELIDE-SAME: metadata !DIExpression()