summaryrefslogtreecommitdiffstats
path: root/llvm/lib/Analysis/DebugInfo.cpp
diff options
context:
space:
mode:
authorEric Christopher <echristo@apple.com>2012-02-20 18:04:35 +0000
committerEric Christopher <echristo@apple.com>2012-02-20 18:04:35 +0000
commit300871076e8a492eb9df201adccffbbe3da71f95 (patch)
treef1ab7d759d808a9560ab62e73bc36e852435fc7c /llvm/lib/Analysis/DebugInfo.cpp
parent8979712685609f349df53b6e0b5bc10c43ffd0c1 (diff)
downloadbcm5719-llvm-300871076e8a492eb9df201adccffbbe3da71f95.tar.gz
bcm5719-llvm-300871076e8a492eb9df201adccffbbe3da71f95.zip
If a derived type is also a composite type, print that information
too. llvm-svn: 150974
Diffstat (limited to 'llvm/lib/Analysis/DebugInfo.cpp')
-rw-r--r--llvm/lib/Analysis/DebugInfo.cpp9
1 files changed, 7 insertions, 2 deletions
diff --git a/llvm/lib/Analysis/DebugInfo.cpp b/llvm/lib/Analysis/DebugInfo.cpp
index 84b789959c3..c655c4eabdb 100644
--- a/llvm/lib/Analysis/DebugInfo.cpp
+++ b/llvm/lib/Analysis/DebugInfo.cpp
@@ -721,8 +721,13 @@ void DIType::print(raw_ostream &OS) const {
if (isBasicType())
DIBasicType(DbgNode).print(OS);
- else if (isDerivedType())
- DIDerivedType(DbgNode).print(OS);
+ else if (isDerivedType()) {
+ DIDerivedType DTy = DIDerivedType(DbgNode);
+ DTy.print(OS);
+ DICompositeType CTy = getDICompositeType(DTy);
+ if (CTy.Verify())
+ CTy.print(OS);
+ }
else if (isCompositeType())
DICompositeType(DbgNode).print(OS);
else {
OpenPOWER on IntegriCloud