Lines Matching refs:SF
782 bool ModuleLinker::linkFunctionProto(Function *SF) {
783 GlobalValue *DGV = getLinkedToGlobal(SF);
790 if (getLinkageResult(DGV, SF, NewLinkage, NV, LinkFromSrc))
800 ValueMap[SF] = ConstantExpr::getBitCast(DGV, TypeMap.get(SF->getType()));
804 DoNotLinkFromSource.insert(SF);
811 // bring SF over.
812 Function *NewDF = Function::Create(TypeMap.get(SF->getFunctionType()),
813 SF->getLinkage(), SF->getName(), DstM);
814 copyGVAttributes(NewDF, SF);
824 if (SF->hasLocalLinkage() || SF
825 SF->hasAvailableExternallyLinkage()) {
826 DoNotLinkFromSource.insert(SF);
827 LazilyLinkFunctions.push_back(SF);
831 ValueMap[SF] = NewDF;
1237 for (Module::iterator SF = SrcM->begin(), E = SrcM->end(); SF != E; ++SF) {
1239 if (DoNotLinkFromSource.count(SF)) continue;
1242 if (SF->isDeclaration()) {
1243 if (!SF->isMaterializable())
1245 if (SF
1249 linkFunctionBody(cast<Function>(ValueMap[SF]), SF);
1250 SF->Dematerialize();
1275 Function *SF = *I;
1276 Function *DF = cast<Function>(ValueMap[SF]);
1281 if (SF->isDeclaration()) {
1282 if (!SF->isMaterializable())
1284 if (SF->Materialize(&ErrorMsg))
1289 linkFunctionBody(DF, SF);
1290 SF->Dematerialize();
1308 Function *SF = *I;
1309 Function *DF = cast<Function>(ValueMap[SF]);