summaryrefslogtreecommitdiffstats
path: root/llvm/lib/IR
diff options
context:
space:
mode:
authorDavid Blaikie <dblaikie@gmail.com>2013-03-22 17:33:20 +0000
committerDavid Blaikie <dblaikie@gmail.com>2013-03-22 17:33:20 +0000
commit30ce0788e702cc9666efce63164a5bede3b2189a (patch)
treee91e4cafeb7a73a9a79dfa92fb7545931eb8d5b4 /llvm/lib/IR
parent9af68719ed44e34972b73d7ae1761faeb7ab30f5 (diff)
downloadbcm5719-llvm-30ce0788e702cc9666efce63164a5bede3b2189a.tar.gz
bcm5719-llvm-30ce0788e702cc9666efce63164a5bede3b2189a.zip
Refactor out the DIFile parameter to DILexicalBlock to refer to the raw file/directory pair
llvm-svn: 177742
Diffstat (limited to 'llvm/lib/IR')
-rw-r--r--llvm/lib/IR/DIBuilder.cpp2
-rw-r--r--llvm/lib/IR/DebugInfo.cpp4
2 files changed, 1 insertions, 5 deletions
diff --git a/llvm/lib/IR/DIBuilder.cpp b/llvm/lib/IR/DIBuilder.cpp
index a97b740d264..fe2176cf604 100644
--- a/llvm/lib/IR/DIBuilder.cpp
+++ b/llvm/lib/IR/DIBuilder.cpp
@@ -1023,7 +1023,7 @@ DILexicalBlock DIBuilder::createLexicalBlock(DIDescriptor Scope, DIFile File,
static unsigned int unique_id = 0;
Value *Elts[] = {
GetTagConstant(VMContext, dwarf::DW_TAG_lexical_block),
- File,
+ File.getFileNode(),
getNonCompileUnitScope(Scope),
ConstantInt::get(Type::getInt32Ty(VMContext), Line),
ConstantInt::get(Type::getInt32Ty(VMContext), Col),
diff --git a/llvm/lib/IR/DebugInfo.cpp b/llvm/lib/IR/DebugInfo.cpp
index 91968d8fbf0..990233404e7 100644
--- a/llvm/lib/IR/DebugInfo.cpp
+++ b/llvm/lib/IR/DebugInfo.cpp
@@ -666,8 +666,6 @@ StringRef DIScope::getFilename() const {
return StringRef();
if (isLexicalBlockFile())
return DILexicalBlockFile(DbgNode).getFilename();
- if (isLexicalBlock())
- return DILexicalBlock(DbgNode).getFilename();
return ::getStringField(getNodeField(DbgNode, 1), 0);
}
@@ -676,8 +674,6 @@ StringRef DIScope::getDirectory() const {
return StringRef();
if (isLexicalBlockFile())
return DILexicalBlockFile(DbgNode).getDirectory();
- if (isLexicalBlock())
- return DILexicalBlock(DbgNode).getDirectory();
return ::getStringField(getNodeField(DbgNode, 1), 1);
}
OpenPOWER on IntegriCloud