aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorDouglas Gregor <dgregor@apple.com>2012-01-26 17:23:00 +0000
committerDouglas Gregor <dgregor@apple.com>2012-01-26 17:23:00 +0000
commita2a50282c34b6e1f95c5a14c5e2b8927c34427de (patch)
tree167414544c9b8b13ac31e4853f79d1249ec84ce6
parent419636316c04d570c183b4797fc811932c588358 (diff)
Force layout of more of the unions and structures in this test
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@149066 91177308-0d34-0410-b5e6-96231b3b80d8
-rw-r--r--test/CodeGen/override-layout.c8
1 files changed, 7 insertions, 1 deletions
diff --git a/test/CodeGen/override-layout.c b/test/CodeGen/override-layout.c
index 687cc04e30..dd7e953ade 100644
--- a/test/CodeGen/override-layout.c
+++ b/test/CodeGen/override-layout.c
@@ -52,7 +52,7 @@ struct PACKED X5 { double a[19]; signed char b; };
struct PACKED X6 { long double a; char b; };
// CHECK: Type: struct X7
-typedef struct X7 {
+struct X7 {
unsigned x;
unsigned char y;
} PACKED;
@@ -137,17 +137,23 @@ void use_structs() {
struct X7 x7;
x7.x = sizeof(struct X7);
+ x7.y = x7.x;
union X8 x8;
+ typedef int X8array[sizeof(union X8)];
x8.y = sizeof(union X8);
+ x8.x.x = x8.y;
struct X9 x9;
+ typedef int X9array[sizeof(struct X9)];
x9.y = sizeof(struct X9);
struct X10 x10;
+ typedef int X10array[sizeof(struct X10)];
x10.y = sizeof(struct X10);
struct X11 x11;
+ typedef int X11array[sizeof(struct X11)];
x11.y = sizeof(struct X11);
struct X12 x12;