aboutsummaryrefslogtreecommitdiff
path: root/test
diff options
context:
space:
mode:
Diffstat (limited to 'test')
-rw-r--r--test/CodeGen/const-init.c13
1 files changed, 10 insertions, 3 deletions
diff --git a/test/CodeGen/const-init.c b/test/CodeGen/const-init.c
index 13bfcd9cdf..296a01d8a4 100644
--- a/test/CodeGen/const-init.c
+++ b/test/CodeGen/const-init.c
@@ -48,11 +48,18 @@ int g9 = (2 + 3i) * (5 + 7i) != (-11 + 29i);
int g10 = (2.0 + 3.0i) * (5.0 + 7.0i) != (-11.0 + 29.0i);
// PR5108
-// CHECK: @ss = global %4 <{ i32 0, i8 7 }>, align 1
-struct s {
+// CHECK: @gv1 = global %4 <{ i32 0, i8 7 }>, align 1
+struct {
unsigned long a;
unsigned long b:3;
-} __attribute__((__packed__)) ss = { .a = 0x0, .b = 7, };
+} __attribute__((__packed__)) gv1 = { .a = 0x0, .b = 7, };
+
+// PR5118
+// CHECK: @gv2 = global %5 <{ i8 1, i8* null }>, align 1
+struct {
+ unsigned char a;
+ char *b;
+} __attribute__((__packed__)) gv2 = { 1, (void*)0 };
// Global references
// RUN: grep '@g11.l0 = internal global i32 ptrtoint (i32 ()\* @g11 to i32)' %t &&