summaryrefslogtreecommitdiffstats
path: root/llvm/lib/Analysis
diff options
context:
space:
mode:
authorDevang Patel <dpatel@apple.com>2010-10-06 20:50:40 +0000
committerDevang Patel <dpatel@apple.com>2010-10-06 20:50:40 +0000
commit9a33ec24ebc1b5b7f1b781204a2a103e7c29fb55 (patch)
treecf7166c66dd9cf6279c7c6c3621bfd39bb1ae4e7 /llvm/lib/Analysis
parent56e6cbdaf0f38490061c94eb17c71bb46f9a27a6 (diff)
downloadbcm5719-llvm-9a33ec24ebc1b5b7f1b781204a2a103e7c29fb55.tar.gz
bcm5719-llvm-9a33ec24ebc1b5b7f1b781204a2a103e7c29fb55.zip
Add support for DW_TAG_unspecified_parameters.
llvm-svn: 115833
Diffstat (limited to 'llvm/lib/Analysis')
-rw-r--r--llvm/lib/Analysis/DebugInfo.cpp15
1 files changed, 14 insertions, 1 deletions
diff --git a/llvm/lib/Analysis/DebugInfo.cpp b/llvm/lib/Analysis/DebugInfo.cpp
index 06a66d5539e..3dd659833e0 100644
--- a/llvm/lib/Analysis/DebugInfo.cpp
+++ b/llvm/lib/Analysis/DebugInfo.cpp
@@ -199,6 +199,12 @@ bool DIDescriptor::isGlobal() const {
return isGlobalVariable();
}
+/// isUnspecifiedParmeter - Return true if the specified tab is
+/// DW_TAG_unspecified_parameters.
+bool DIDescriptor::isUnspecifiedParameter() const {
+ return DbgNode && getTag() == dwarf::DW_TAG_unspecified_parameters;
+}
+
/// isScope - Return true if the specified tag is one of the scope
/// related tag.
bool DIDescriptor::isScope() const {
@@ -724,7 +730,14 @@ DISubrange DIFactory::GetOrCreateSubrange(int64_t Lo, int64_t Hi) {
return DISubrange(MDNode::get(VMContext, &Elts[0], 3));
}
-
+/// CreateUnspecifiedParameter - Create unspeicified type descriptor
+/// for the subroutine type.
+DIDescriptor DIFactory::CreateUnspecifiedParameter() {
+ Value *Elts[] = {
+ GetTagConstant(dwarf::DW_TAG_unspecified_parameters)
+ };
+ return DIDescriptor(MDNode::get(VMContext, &Elts[0], 1));
+}
/// CreateCompileUnit - Create a new descriptor for the specified compile
/// unit. Note that this does not unique compile units within the module.
OpenPOWER on IntegriCloud