summaryrefslogtreecommitdiffstats
path: root/clang/lib/CodeGen/CGDebugInfo.cpp
diff options
context:
space:
mode:
authorEric Christopher <echristo@apple.com>2012-01-26 07:01:04 +0000
committerEric Christopher <echristo@apple.com>2012-01-26 07:01:04 +0000
commit8913bd6c6352dbf8a6d515725932cffb4eb8602a (patch)
tree30e14df661821f2bed5e3a45da3c58d13b752b8d /clang/lib/CodeGen/CGDebugInfo.cpp
parent853b5ebfd3b4fdb4b40623671faa0558cdf7c8ce (diff)
downloadbcm5719-llvm-8913bd6c6352dbf8a6d515725932cffb4eb8602a.tar.gz
bcm5719-llvm-8913bd6c6352dbf8a6d515725932cffb4eb8602a.zip
Revert previous patch unifying all of the C++ record prep in one area,
the gdb testsuite complains too much about the ordering of items printed, even if the offsets in the debug info are correct. This reverts commit 027cb30af828f07750f9185782822297a5c57231. llvm-svn: 149049
Diffstat (limited to 'clang/lib/CodeGen/CGDebugInfo.cpp')
-rw-r--r--clang/lib/CodeGen/CGDebugInfo.cpp17
1 files changed, 11 insertions, 6 deletions
diff --git a/clang/lib/CodeGen/CGDebugInfo.cpp b/clang/lib/CodeGen/CGDebugInfo.cpp
index 7fd5daa1825..6a775ccba64 100644
--- a/clang/lib/CodeGen/CGDebugInfo.cpp
+++ b/clang/lib/CodeGen/CGDebugInfo.cpp
@@ -1171,16 +1171,21 @@ llvm::DIType CGDebugInfo::CreateType(const RecordType *Ty) {
// Convert all the elements.
SmallVector<llvm::Value *, 16> EltTys;
- // Collect static variables with initializers.
- CollectRecordStaticVars(RD, FwdDecl);
- CollectRecordFields(RD, DefUnit, EltTys, FwdDecl);
-
- // Collect C++ information.
+ // Note: The split of CXXDecl information here is intentional, the
+ // gdb tests will depend on a certain ordering at printout. The debug
+ // information offsets are still correct if we merge them all together
+ // though.
const CXXRecordDecl *CXXDecl = dyn_cast<CXXRecordDecl>(RD);
- llvm::DIArray TParamsArray;
if (CXXDecl) {
CollectCXXBases(CXXDecl, DefUnit, EltTys, FwdDecl);
CollectVTableInfo(CXXDecl, DefUnit, EltTys);
+ }
+
+ // Collect static variables with initializers and other fields.
+ CollectRecordStaticVars(RD, FwdDecl);
+ CollectRecordFields(RD, DefUnit, EltTys, FwdDecl);
+ llvm::DIArray TParamsArray;
+ if (CXXDecl) {
CollectCXXMemberFunctions(CXXDecl, DefUnit, EltTys, FwdDecl);
CollectCXXFriends(CXXDecl, DefUnit, EltTys, FwdDecl);
if (const ClassTemplateSpecializationDecl *TSpecial
OpenPOWER on IntegriCloud