Run DCE after a LoopFlatten test to reduce spurious output [nfc]
[llvm-project.git] / clang / test / CodeGenCXX / global-block-literal-helpers.cpp
blob8e82e38b2be3011c1dfc5c86079100bac90af861
1 // RUN: %clang_cc1 -std=c++11 -emit-llvm -fblocks -o - -triple x86_64-apple-darwin10 %s | FileCheck %s
3 namespace N {
4 typedef void (^BL)();
5 int func(BL, BL, BL);
7 // CHECK-LABEL: define internal void @_ZN1N8ArrBlockE_block_invoke(
8 // CHECK-LABEL: define internal void @_ZN1N8ArrBlockE_block_invoke_2(
9 // CHECK-LABEL: define internal void @_ZN1N8ArrBlockE_block_invoke_3
10 BL ArrBlock [] = { ^{}, ^{}, ^{} };
12 // CHECK-LABEL: define internal void @_ZN1N4ivalE_block_invoke_4(
13 // CHECK-LABEL: define internal void @_ZN1N4ivalE_block_invoke_5(
14 // CHECK-LABEL: define internal void @_ZN1N4ivalE_block_invoke_6(
15 int ival = func(^{}, ^{}, ^{});
17 // CHECK-LABEL: define internal void @_ZN1N9gvarlobalE_block_invoke_7(
18 void (^gvarlobal)(void) = ^{};
20 struct S {
21 BL field = ^{};
24 // CHECK-LABEL: define internal void @_ZN1N3blfE_block_invoke_8(
25 S blf;