summaryrefslogtreecommitdiffstats
path: root/llvm/lib/CodeGen
diff options
context:
space:
mode:
authorDevang Patel <dpatel@apple.com>2009-08-26 00:39:50 +0000
committerDevang Patel <dpatel@apple.com>2009-08-26 00:39:50 +0000
commita1b4dd96f298008e10f5ff09cf7b25556fab96b8 (patch)
tree76f4a50adef5c3c81145f86dc3ee031055fa6b77 /llvm/lib/CodeGen
parent2c73b1d2a2a016ade9434c19ffc36c097ea88713 (diff)
downloadbcm5719-llvm-a1b4dd96f298008e10f5ff09cf7b25556fab96b8.tar.gz
bcm5719-llvm-a1b4dd96f298008e10f5ff09cf7b25556fab96b8.zip
Add isClosure() predicate. This is used to add DW_AT_APPLE_block attribute.
Patch by Caroline Tice. llvm-svn: 80061
Diffstat (limited to 'llvm/lib/CodeGen')
-rw-r--r--llvm/lib/CodeGen/AsmPrinter/DwarfDebug.cpp5
1 files changed, 1 insertions, 4 deletions
diff --git a/llvm/lib/CodeGen/AsmPrinter/DwarfDebug.cpp b/llvm/lib/CodeGen/AsmPrinter/DwarfDebug.cpp
index 067db8b848e..e053597ab1c 100644
--- a/llvm/lib/CodeGen/AsmPrinter/DwarfDebug.cpp
+++ b/llvm/lib/CodeGen/AsmPrinter/DwarfDebug.cpp
@@ -695,10 +695,7 @@ void DwarfDebug::ConstructTypeDIE(CompileUnit *DW_Unit, DIE &Buffer,
Buffer.AddChild(ElemDie);
}
- // FIXME: We'd like an API to register additional attributes for the
- // frontend to use while synthesizing, and then we'd use that api in clang
- // instead of this.
- if (Name == "__block_literal_generic")
+ if (CTy.isClosure())
AddUInt(&Buffer, dwarf::DW_AT_APPLE_block, dwarf::DW_FORM_flag, 1);
unsigned RLang = CTy.getRunTimeLang();
OpenPOWER on IntegriCloud