summaryrefslogtreecommitdiffstats
path: root/clang/lib/CodeGen/CGDebugInfo.h
diff options
context:
space:
mode:
authorMatthew Voss <matthew.voss@sony.com>2018-10-03 18:45:04 +0000
committerMatthew Voss <matthew.voss@sony.com>2018-10-03 18:45:04 +0000
commit2016536304c66618a8321bedeb9bcc8c7b3eee1e (patch)
tree2690db311b76ef0309ffa6a72395b98a2789a629 /clang/lib/CodeGen/CGDebugInfo.h
parentf8ab35a4f464753751c1df2b56b6c2f9c75d56a7 (diff)
downloadbcm5719-llvm-2016536304c66618a8321bedeb9bcc8c7b3eee1e.tar.gz
bcm5719-llvm-2016536304c66618a8321bedeb9bcc8c7b3eee1e.zip
Add template type and value parameter metadata nodes to template variable specializations
Summary: Add an optional attribute referring to a tuple of type and value template parameter nodes to the DIGlobalVariable node. This allows us to record the parameters of template variable specializations. Reviewers: dblaikie, aprantl, probinson, JDevlieghere, clayborg, jingham Reviewed By: JDevlieghere Subscribers: cfe-commits Tags: #debug-info Differential Revision: https://reviews.llvm.org/D52058 llvm-svn: 343707
Diffstat (limited to 'clang/lib/CodeGen/CGDebugInfo.h')
-rw-r--r--clang/lib/CodeGen/CGDebugInfo.h9
1 files changed, 8 insertions, 1 deletions
diff --git a/clang/lib/CodeGen/CGDebugInfo.h b/clang/lib/CodeGen/CGDebugInfo.h
index 8641c2d8969..b007621c723 100644
--- a/clang/lib/CodeGen/CGDebugInfo.h
+++ b/clang/lib/CodeGen/CGDebugInfo.h
@@ -248,6 +248,11 @@ class CGDebugInfo {
llvm::DINodeArray CollectFunctionTemplateParams(const FunctionDecl *FD,
llvm::DIFile *Unit);
+ /// A helper function to collect debug info for function template
+ /// parameters.
+ llvm::DINodeArray CollectVarTemplateParams(const VarDecl *VD,
+ llvm::DIFile *Unit);
+
/// A helper function to collect debug info for template
/// parameters.
llvm::DINodeArray
@@ -645,7 +650,9 @@ private:
/// Collect various properties of a VarDecl.
void collectVarDeclProps(const VarDecl *VD, llvm::DIFile *&Unit,
unsigned &LineNo, QualType &T, StringRef &Name,
- StringRef &LinkageName, llvm::DIScope *&VDContext);
+ StringRef &LinkageName,
+ llvm::MDTuple *&TemplateParameters,
+ llvm::DIScope *&VDContext);
/// Allocate a copy of \p A using the DebugInfoNames allocator
/// and return a reference to it. If multiple arguments are given the strings
OpenPOWER on IntegriCloud