X-Git-Url: http://demsky.eecs.uci.edu/git/?a=blobdiff_plain;f=lib%2FAnalysis%2FLibCallSemantics.cpp;h=81b0f46f3740e730221158d42906cc0cb289c8d5;hb=a704bc9354d8b03fd98da9bd7de5ae1dc49af961;hp=29850471f7dc3958a0ff62523f214433438f26d5;hpb=14852f27e792470232287371c5ffd4cee1d5b943;p=oota-llvm.git diff --git a/lib/Analysis/LibCallSemantics.cpp b/lib/Analysis/LibCallSemantics.cpp index 29850471f7d..81b0f46f374 100644 --- a/lib/Analysis/LibCallSemantics.cpp +++ b/lib/Analysis/LibCallSemantics.cpp @@ -40,7 +40,8 @@ const LibCallLocationInfo &LibCallInfo::getLocationInfo(unsigned LocID) const { /// getFunctionInfo - Return the LibCallFunctionInfo object corresponding to /// the specified function if we have it. If not, return null. -const LibCallFunctionInfo *LibCallInfo::getFunctionInfo(Function *F) const { +const LibCallFunctionInfo * +LibCallInfo::getFunctionInfo(const Function *F) const { StringMap *Map = getMap(Impl); /// If this is the first time we are querying for this info, lazily construct @@ -57,9 +58,6 @@ const LibCallFunctionInfo *LibCallInfo::getFunctionInfo(Function *F) const { } // Look up this function in the string map. - const char *ValueName = F->getNameStart(); - StringMap::iterator I = - Map->find(ValueName, ValueName+F->getNameLen()); - return I != Map->end() ? I->second : 0; + return Map->lookup(F->getName()); }