2009-08-24 03:28:59 +08:00
|
|
|
// FIXME: We forcibly strip the names so that the test doesn't vary between
|
|
|
|
// builds with and without asserts. We need a better solution for this.
|
|
|
|
|
2009-12-16 04:14:24 +08:00
|
|
|
// RUN: %clang_cc1 -fblocks -triple x86_64-apple-darwin10 -emit-llvm-bc -o - %s | opt -strip | llvm-dis > %t
|
2009-11-08 09:45:36 +08:00
|
|
|
// RUN: grep '%6 = call i32 (...)\* @rhs()' %t | count 1
|
|
|
|
// RUN: grep '%7 = getelementptr inbounds %0\* %1, i32 0, i32 1' %t | count 1
|
|
|
|
// RUN: grep '%8 = load %0\*\* %7' %t | count 1
|
|
|
|
// RUN: grep '%10 = call i32 (...)\* @rhs()' %t | count 1
|
|
|
|
// RUN: grep '%11 = getelementptr inbounds %0\* %1, i32 0, i32 1' %t | count 1
|
2009-09-10 09:32:12 +08:00
|
|
|
// RUN: grep '%12 = load %0\*\* %11' %t | count 1
|
2009-05-22 05:05:15 +08:00
|
|
|
|
|
|
|
int rhs();
|
|
|
|
|
|
|
|
void foo() {
|
|
|
|
__block int i;
|
|
|
|
i = rhs();
|
2009-05-23 03:07:20 +08:00
|
|
|
i += rhs();
|
2009-05-22 05:05:15 +08:00
|
|
|
}
|