e = RD->vbases_end(); i != e; ++i) {
const CXXRecordDecl *Base =
cast<CXXRecordDecl>(i->getType()->getAs<RecordType>()->getDecl());
- if (Base != PrimaryBase)
+ if (!PrimaryBaseWasVirtual || Base != PrimaryBase)
LayoutVirtualBase(Base);
}
}
// CHECK-LP64: movl $2, 8(%rax)
+struct test6_B2 { virtual void funcB2(); char b[1000]; };
+struct test6_B1 : virtual test6_B2 { virtual void funcB1(); };
+
+struct test6_D : test6_B2, virtual test6_B1 {
+};
+
+// CEHCK-LP32: .zerofill __DATA, __common, _d6, 2012, 4
+// CHECK-LP64: .zerofill __DATA, __common, _d6, 2024, 4
+
+
+
struct test3_B3 { virtual void funcB3(); };
struct test3_B2 : virtual test3_B3 { virtual void funcB2(); };
struct test3_B1 : virtual test3_B2 { virtual void funcB1(); };
// CHECK-LP64: .quad __ZN2D14bar5Ev
+test6_D d6;
test5_D d5;
test4_D d4;
test3_D d3;