本文整理汇总了C++中DILocation::getOrigLocation方法的典型用法代码示例。如果您正苦于以下问题:C++ DILocation::getOrigLocation方法的具体用法?C++ DILocation::getOrigLocation怎么用?C++ DILocation::getOrigLocation使用的例子?那么, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在类DILocation
的用法示例。
在下文中一共展示了DILocation::getOrigLocation方法的5个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的C++代码示例。
示例1: processLocation
void DebugInfoFinder::processLocation(const Module &M, DILocation Loc) {
if (!Loc)
return;
InitializeTypeMap(M);
processScope(Loc.getScope());
processLocation(M, Loc.getOrigLocation());
}
示例2: processLocation
/// processLocation - Process DILocation.
void DebugInfoFinder::processLocation(DILocation Loc) {
if (!Loc.Verify()) return;
DIDescriptor S(Loc.getScope());
if (S.isCompileUnit())
addCompileUnit(DICompileUnit(S));
else if (S.isSubprogram())
processSubprogram(DISubprogram(S));
else if (S.isLexicalBlock())
processLexicalBlock(DILexicalBlock(S));
processLocation(Loc.getOrigLocation());
}
示例3: processLocation
/// processLocation - Process DILocation.
void DebugInfoFinder::processLocation(DILocation Loc) {
if (Loc.isNull()) return;
DIScope S(Loc.getScope().getNode());
if (S.isNull()) return;
if (S.isCompileUnit())
addCompileUnit(DICompileUnit(S.getNode()));
else if (S.isSubprogram())
processSubprogram(DISubprogram(S.getNode()));
else if (S.isLexicalBlock())
processLexicalBlock(DILexicalBlock(S.getNode()));
processLocation(Loc.getOrigLocation());
}
示例4: ExtractDebugLocation
/// ExtractDebugLocation - Extract debug location information
/// from DILocation.
DebugLoc ExtractDebugLocation(DILocation &Loc,
DebugLocTracker &DebugLocInfo) {
DebugLoc DL;
MDNode *Context = Loc.getScope().getNode();
MDNode *InlinedLoc = NULL;
if (!Loc.getOrigLocation().isNull())
InlinedLoc = Loc.getOrigLocation().getNode();
// If this location is already tracked then use it.
DebugLocTuple Tuple(Context, InlinedLoc, Loc.getLineNumber(),
Loc.getColumnNumber());
DenseMap<DebugLocTuple, unsigned>::iterator II
= DebugLocInfo.DebugIdMap.find(Tuple);
if (II != DebugLocInfo.DebugIdMap.end())
return DebugLoc::get(II->second);
// Add a new location entry.
unsigned Id = DebugLocInfo.DebugLocations.size();
DebugLocInfo.DebugLocations.push_back(Tuple);
DebugLocInfo.DebugIdMap[Tuple] = Id;
return DebugLoc::get(Id);
}
示例5: processLocation
/// processLocation - Process DILocation.
void DebugInfoFinder::processLocation(DILocation Loc) {
if (!Loc) return;
processScope(Loc.getScope());
processLocation(Loc.getOrigLocation());
}