MCPcopy Create free account
hub / github.com/Samsung/UTopia / getFromGVMap

Method getFromGVMap

lib/astirmap/DebugInfoMap.cpp:205–215  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

203}
204
205ASTDefNode *DebugInfoMap::getFromGVMap(const llvm::GlobalValue &G) const {
206 IRNode Node(*const_cast<llvm::GlobalValue *>(&G));
207 GVMapKey Key = {.Path = "", .Name = Node.getName()};
208 if (G.hasInternalLinkage() || G.hasPrivateLinkage())
209 Key.Path = Node.getIndex().getPath();
210
211 auto GVMapIter = GVMap.find(Key);
212 if (GVMapIter == GVMap.end())
213 return nullptr;
214 return GVMapIter->second.get();
215}
216
217VarDecl *DebugInfoMap::getConstVarDecl(ASTDefNode &Node) const {
218 auto *Assigned = Node.getAssigned();

Callers

nothing calls this directly

Calls 5

getPathMethod · 0.80
endMethod · 0.80
getNameMethod · 0.45
findMethod · 0.45
getMethod · 0.45

Tested by

no test coverage detected