summaryrefslogtreecommitdiff
path: root/lib/IR
diff options
context:
space:
mode:
authorDavid Blaikie <dblaikie@gmail.com>2013-03-22 20:18:46 +0000
committerDavid Blaikie <dblaikie@gmail.com>2013-03-22 20:18:46 +0000
commit8faed2745c849fb35f6edf411263dfa564ef3643 (patch)
treefa73330d6b5dab14543dedcefabe3a4c7f4633b8 /lib/IR
parent7b246860bdf4c6b3ea4e09f6437537941cc0d1d4 (diff)
downloadllvm-8faed2745c849fb35f6edf411263dfa564ef3643.tar.gz
llvm-8faed2745c849fb35f6edf411263dfa564ef3643.tar.bz2
llvm-8faed2745c849fb35f6edf411263dfa564ef3643.tar.xz
Swap the DIFile in DILexicalBlockFile out for the raw name/directory pair
This is the last change in transitioning all DIScopes to have a common prefix. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@177756 91177308-0d34-0410-b5e6-96231b3b80d8
Diffstat (limited to 'lib/IR')
-rw-r--r--lib/IR/DIBuilder.cpp2
-rw-r--r--lib/IR/DebugInfo.cpp4
2 files changed, 1 insertions, 5 deletions
diff --git a/lib/IR/DIBuilder.cpp b/lib/IR/DIBuilder.cpp
index 56024573de..033af3bd1d 100644
--- a/lib/IR/DIBuilder.cpp
+++ b/lib/IR/DIBuilder.cpp
@@ -1007,7 +1007,7 @@ DILexicalBlockFile DIBuilder::createLexicalBlockFile(DIDescriptor Scope,
DIFile File) {
Value *Elts[] = {
GetTagConstant(VMContext, dwarf::DW_TAG_lexical_block),
- File,
+ File.getFileNode(),
Scope
};
DILexicalBlockFile R(MDNode::get(VMContext, Elts));
diff --git a/lib/IR/DebugInfo.cpp b/lib/IR/DebugInfo.cpp
index 990233404e..5ab64265e4 100644
--- a/lib/IR/DebugInfo.cpp
+++ b/lib/IR/DebugInfo.cpp
@@ -664,16 +664,12 @@ DIArray DISubprogram::getVariables() const {
StringRef DIScope::getFilename() const {
if (!DbgNode)
return StringRef();
- if (isLexicalBlockFile())
- return DILexicalBlockFile(DbgNode).getFilename();
return ::getStringField(getNodeField(DbgNode, 1), 0);
}
StringRef DIScope::getDirectory() const {
if (!DbgNode)
return StringRef();
- if (isLexicalBlockFile())
- return DILexicalBlockFile(DbgNode).getDirectory();
return ::getStringField(getNodeField(DbgNode, 1), 1);
}