summaryrefslogtreecommitdiffstats
path: root/test/CodeGen/bitfield.c
diff options
context:
space:
mode:
Diffstat (limited to 'test/CodeGen/bitfield.c')
-rw-r--r--test/CodeGen/bitfield.c21
1 files changed, 18 insertions, 3 deletions
diff --git a/test/CodeGen/bitfield.c b/test/CodeGen/bitfield.c
index dea5e43..c624d00 100644
--- a/test/CodeGen/bitfield.c
+++ b/test/CodeGen/bitfield.c
@@ -1,6 +1,5 @@
-// RUN: %clang_cc1 -triple i386-unknown-unknown %s -emit-llvm -o %t -O3
-// RUN: grep "ret i32" %t | count 4
-// RUN: grep "ret i32 1" %t | count 4
+// RUN: %clang_cc1 -triple i386-unknown-unknown %s -emit-llvm -o - -O3 -no-struct-path-tbaa | FileCheck %s
+// RUN: %clang_cc1 -triple i386-unknown-unknown %s -emit-llvm -o - -O3 | FileCheck %s --check-prefix=PATH
static int f0(int n) {
struct s0 {
@@ -17,6 +16,10 @@ static int f0(int n) {
}
int g0(void) {
+// CHECK-LABEL: @g0()
+// CHECK: ret i32 1
+// PATH-LABEL: @g0()
+// PATH: ret i32 1
return f0(-1) + 44335655;
}
@@ -35,6 +38,10 @@ static int f1(void) {
}
int g1(void) {
+// CHECK-LABEL: @g1()
+// CHECK: ret i32 1
+// PATH-LABEL: @g1()
+// PATH: ret i32 1
return f1() + 16;
}
@@ -51,6 +58,10 @@ static int f2(void) {
}
int g2(void) {
+// CHECK-LABEL: @g2()
+// CHECK: ret i32 1
+// PATH-LABEL: @g2()
+// PATH: ret i32 1
return f2() - 9;
}
@@ -70,5 +81,9 @@ static int f3(int n) {
}
int g3(void) {
+// CHECK-LABEL: @g3()
+// CHECK: ret i32 1
+// PATH-LABEL: @g3()
+// PATH: ret i32 1
return f3(20) + 130725747;
}
OpenPOWER on IntegriCloud