There doesn't seem to be a direct test of this, and I'm planning to make future changes which will affect it. I'm not particularly familiar with the blocks extension, so suggestions for better tests are welcome. Differential Revision: https://reviews.llvm.org/D88754
10 lines
542 B
C
10 lines
542 B
C
// RUN: %clang_cc1 -fblocks -debug-info-kind=limited -emit-llvm -o - %s | FileCheck %s
|
|
// Verify that the desired DIExpression are generated for blocks.
|
|
|
|
void test() {
|
|
// CHECK: call void @llvm.dbg.declare({{.*}}!DIExpression(DW_OP_plus_uconst, {{[0-9]+}}, DW_OP_deref, DW_OP_plus_uconst, {{[0-9]+}}){{.*}})
|
|
__block int i;
|
|
// CHECK: call void @llvm.dbg.declare({{.*}}!DIExpression(DW_OP_deref, DW_OP_plus_uconst, {{[0-9]+}}, DW_OP_deref, DW_OP_plus_uconst, {{[0-9]+}}, DW_OP_deref, DW_OP_plus_uconst, {{[0-9]+}}){{.*}})
|
|
^ { i = 1; }();
|
|
}
|