Run DCE after a LoopFlatten test to reduce spurious output [nfc]
[llvm-project.git] / clang / test / CodeGenCXX / block-byref.cpp
blob8dc01f96baae12d0c92b1e9899a88f75a3397653
1 // RUN: %clang_cc1 %s -fblocks -triple x86_64-apple-darwin -std=c++11 -emit-llvm -o - | FileCheck %s
2 // REQUIRES: x86-registered-target
4 // CHECK: @b ={{.*}} global i32 0,
6 // CHECK: define {{.*}}void @{{.*}}test{{.*}}_block_invoke(
7 // CHECK: store i32 2, ptr @b,
8 // CHECK: ret void
10 int b;
12 void test() {
13 int &a = b;
14 ^{ a = 2; };