diff options
author | Devang Patel <dpatel@apple.com> | 2011-05-12 19:06:16 +0000 |
---|---|---|
committer | Devang Patel <dpatel@apple.com> | 2011-05-12 19:06:16 +0000 |
commit | b11f80e94b590c90d07254dfa2406cf504e09cd3 (patch) | |
tree | 7737ee5850bae2f2c3f0605f9b7a45368a854b7f /lib | |
parent | 30adced41b17cc9a5c301386e80567faccaff04f (diff) |
Let Objective-C front-end identify class extension, in dwarf output, using an attribute DW_AT_APPLE_objc_class_extension.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@131238 91177308-0d34-0410-b5e6-96231b3b80d8
Diffstat (limited to 'lib')
-rw-r--r-- | lib/CodeGen/AsmPrinter/DwarfCompileUnit.cpp | 4 | ||||
-rw-r--r-- | lib/Support/Dwarf.cpp | 1 |
2 files changed, 5 insertions, 0 deletions
diff --git a/lib/CodeGen/AsmPrinter/DwarfCompileUnit.cpp b/lib/CodeGen/AsmPrinter/DwarfCompileUnit.cpp index 98af7a41e7..4eb4094775 100644 --- a/lib/CodeGen/AsmPrinter/DwarfCompileUnit.cpp +++ b/lib/CodeGen/AsmPrinter/DwarfCompileUnit.cpp @@ -766,6 +766,10 @@ void CompileUnit::constructTypeDIE(DIE &Buffer, DICompositeType CTy) { addToContextOwner(&Buffer, Context); } + if (CTy.isObjcClassExtension()) + addUInt(&Buffer, dwarf::DW_AT_APPLE_objc_class_extension, + dwarf::DW_FORM_flag, 1); + if (Tag == dwarf::DW_TAG_class_type) addTemplateParams(Buffer, CTy.getTemplateParams()); diff --git a/lib/Support/Dwarf.cpp b/lib/Support/Dwarf.cpp index 74a9fda7ab..cbf8aad5f2 100644 --- a/lib/Support/Dwarf.cpp +++ b/lib/Support/Dwarf.cpp @@ -207,6 +207,7 @@ const char *llvm::dwarf::AttributeString(unsigned Attribute) { case DW_AT_APPLE_property_getter: return "DW_AT_APPLE_property_getter"; case DW_AT_APPLE_property_setter: return "DW_AT_APPLE_property_setter"; case DW_AT_APPLE_property_attribute: return "DW_AT_APPLE_property_attribute"; + case DW_AT_APPLE_objc_class_extension: return "DW_AT_APPLE_objc_class_extension"; } return 0; } |