summaryrefslogtreecommitdiffstats
path: root/test/CodeGenCXX/blocks.cpp
diff options
context:
space:
mode:
authorStephen Lin <stephenwlin@gmail.com>2013-08-15 06:47:53 +0000
committerStephen Lin <stephenwlin@gmail.com>2013-08-15 06:47:53 +0000
commit93ab6bf534fb6c26563c00f28a8fc5581bb71dfd (patch)
tree938e985e9673d1b0d289e8ed751943edc097da1d /test/CodeGenCXX/blocks.cpp
parent233fbe1f56183878167a56be53425a6dd25ba334 (diff)
CHECK-LABEL-ify some code gen tests to improve diagnostic experience when tests fail.
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@188447 91177308-0d34-0410-b5e6-96231b3b80d8
Diffstat (limited to 'test/CodeGenCXX/blocks.cpp')
-rw-r--r--test/CodeGenCXX/blocks.cpp28
1 files changed, 14 insertions, 14 deletions
diff --git a/test/CodeGenCXX/blocks.cpp b/test/CodeGenCXX/blocks.cpp
index 81eef0e028..8a6fdacf8d 100644
--- a/test/CodeGenCXX/blocks.cpp
+++ b/test/CodeGenCXX/blocks.cpp
@@ -1,7 +1,7 @@
// RUN: %clang_cc1 %s -fblocks -triple x86_64-apple-darwin -emit-llvm -o - | FileCheck %s
namespace test0 {
- // CHECK: define void @_ZN5test04testEi(
+ // CHECK-LABEL: define void @_ZN5test04testEi(
// CHECK: define internal void @___ZN5test04testEi_block_invoke{{.*}}(
// CHECK: define internal void @___ZN5test04testEi_block_invoke_2{{.*}}(
void test(int x) {
@@ -13,7 +13,7 @@ extern void (^out)();
namespace test1 {
// Capturing const objects doesn't require a local block.
- // CHECK: define void @_ZN5test15test1Ev()
+ // CHECK-LABEL: define void @_ZN5test15test1Ev()
// CHECK: store void ()* bitcast ({{.*}} @__block_literal_global{{.*}} to void ()*), void ()** @out
void test1() {
const int NumHorsemen = 4;
@@ -21,7 +21,7 @@ namespace test1 {
}
// That applies to structs too...
- // CHECK: define void @_ZN5test15test2Ev()
+ // CHECK-LABEL: define void @_ZN5test15test2Ev()
// CHECK: store void ()* bitcast ({{.*}} @__block_literal_global{{.*}} to void ()*), void ()** @out
struct loc { double x, y; };
void test2() {
@@ -30,7 +30,7 @@ namespace test1 {
}
// ...unless they have mutable fields...
- // CHECK: define void @_ZN5test15test3Ev()
+ // CHECK-LABEL: define void @_ZN5test15test3Ev()
// CHECK: [[BLOCK:%.*]] = alloca [[BLOCK_T:<{.*}>]],
// CHECK: [[T0:%.*]] = bitcast [[BLOCK_T]]* [[BLOCK]] to void ()*
// CHECK: store void ()* [[T0]], void ()** @out
@@ -41,7 +41,7 @@ namespace test1 {
}
// ...or non-trivial destructors...
- // CHECK: define void @_ZN5test15test4Ev()
+ // CHECK-LABEL: define void @_ZN5test15test4Ev()
// CHECK: [[OBJ:%.*]] = alloca
// CHECK: [[BLOCK:%.*]] = alloca [[BLOCK_T:<{.*}>]],
// CHECK: [[T0:%.*]] = bitcast [[BLOCK_T]]* [[BLOCK]] to void ()*
@@ -69,22 +69,22 @@ namespace test2 {
~B();
};
- // CHECK: define void @_ZN5test24testEv()
+ // CHECK-LABEL: define void @_ZN5test24testEv()
void test() {
__block A a;
__block B b;
}
- // CHECK: define internal void @__Block_byref_object_copy
+ // CHECK-LABEL: define internal void @__Block_byref_object_copy
// CHECK: call void @_ZN5test21AC1ERKS0_(
- // CHECK: define internal void @__Block_byref_object_dispose
+ // CHECK-LABEL: define internal void @__Block_byref_object_dispose
// CHECK: call void @_ZN5test21AD1Ev(
- // CHECK: define internal void @__Block_byref_object_copy
+ // CHECK-LABEL: define internal void @__Block_byref_object_copy
// CHECK: call void @_ZN5test21BC1ERKS0_(
- // CHECK: define internal void @__Block_byref_object_dispose
+ // CHECK-LABEL: define internal void @__Block_byref_object_dispose
// CHECK: call void @_ZN5test21BD1Ev(
}
@@ -118,8 +118,8 @@ namespace test4 {
extern void consume(void(^)());
consume(^{ return foo(A()); });
}
- // CHECK: define void @_ZN5test44testEv()
- // CHECK: define internal void @___ZN5test44testEv_block_invoke
+ // CHECK-LABEL: define void @_ZN5test44testEv()
+ // CHECK-LABEL: define internal void @___ZN5test44testEv_block_invoke
// CHECK: [[TMP:%.*]] = alloca [[A:%.*]], align 1
// CHECK-NEXT: store i8* [[BLOCKDESC:%.*]], i8** {{.*}}, align 8
// CHECK-NEXT: load i8*
@@ -147,7 +147,7 @@ namespace test5 {
doWithBlock(b);
}
- // CHECK: define void @_ZN5test54testEb(
+ // CHECK-LABEL: define void @_ZN5test54testEb(
// CHECK: [[COND:%.*]] = alloca i8
// CHECK-NEXT: [[X:%.*]] = alloca [[A:%.*]], align 4
// CHECK-NEXT: [[B:%.*]] = alloca void ()*, align 8
@@ -197,7 +197,7 @@ namespace test6 {
bar();
}
- // CHECK: define void @_ZN5test64testEv()
+ // CHECK-LABEL: define void @_ZN5test64testEv()
// CHECK: [[TEMP:%.*]] = alloca [[A:%.*]], align 1
// CHECK-NEXT: call void @_ZN5test61AC1Ev([[A]]* [[TEMP]])
// CHECK-NEXT: call void @_ZN5test63fooERKNS_1AEU13block_pointerFvvE(