Lines Matching refs:Stub
143 IFSStub(const IFSStub &Stub) in IFSStub() argument
144 : IfsVersion(Stub.IfsVersion), Triple(Stub.Triple), in IFSStub()
145 ObjectFileFormat(Stub.ObjectFileFormat), SOName(Stub.SOName), in IFSStub()
146 NeededLibs(Stub.NeededLibs), Symbols(Stub.Symbols) {} in IFSStub()
147 IFSStub(IFSStub &&Stub) in IFSStub() argument
148 : IfsVersion(std::move(Stub.IfsVersion)), Triple(std::move(Stub.Triple)), in IFSStub()
149 ObjectFileFormat(std::move(Stub.ObjectFileFormat)), in IFSStub()
150 SOName(std::move(Stub.SOName)), NeededLibs(std::move(Stub.NeededLibs)), in IFSStub()
151 Symbols(std::move(Stub.Symbols)) {} in IFSStub()
158 static void mapping(IO &IO, IFSStub &Stub) { in mapping()
163 IO.setContext(&Stub); in mapping()
164 IO.mapRequired("IfsVersion", Stub.IfsVersion); in mapping()
165 IO.mapOptional("Triple", Stub.Triple); in mapping()
166 IO.mapOptional("ObjectFileFormat", Stub.ObjectFileFormat); in mapping()
167 IO.mapOptional("SOName", Stub.SOName); in mapping()
168 IO.mapOptional("NeededLibs", Stub.NeededLibs); in mapping()
169 IO.mapRequired("Symbols", Stub.Symbols); in mapping()
186 std::unique_ptr<IFSStub> Stub(new IFSStub()); in readInputFile() local
187 YamlIn >> *Stub; in readInputFile()
192 if (Stub->IfsVersion > IFSVersionCurrent) in readInputFile()
194 "IFS version " + Stub->IfsVersion.getAsString() + " is unsupported.", in readInputFile()
197 return std::move(Stub); in readInputFile()
345 static int writeIfso(const IFSStub &Stub, bool IsWriteIfs, raw_ostream &Out) { in writeIfso() argument
348 YamlOut << const_cast<IFSStub &>(Stub); in writeIfso()
353 ForceFormat.empty() ? Stub.ObjectFileFormat : ForceFormat; in writeIfso()
356 return writeElfStub(llvm::Triple(Stub.Triple), Stub.Symbols, in writeIfso()
357 Stub.ObjectFileFormat, Out); in writeIfso()
359 return writeTbdStub(llvm::Triple(Stub.Triple), Stub.Symbols, in writeIfso()
360 Stub.ObjectFileFormat, Out); in writeIfso()
384 IFSStub Stub; in main() local
396 if (Stub.Triple.empty()) { in main()
398 Stub.IfsVersion = TargetStub->IfsVersion; in main()
399 Stub.Triple = TargetStub->Triple; in main()
400 Stub.ObjectFileFormat = TargetStub->ObjectFileFormat; in main()
401 Stub.SOName = TargetStub->SOName; in main()
402 Stub.NeededLibs = TargetStub->NeededLibs; in main()
404 Stub.ObjectFileFormat = !Stub.ObjectFileFormat.empty() in main()
405 ? Stub.ObjectFileFormat in main()
408 if (Stub.IfsVersion != TargetStub->IfsVersion) { in main()
409 if (Stub.IfsVersion.getMajor() != IFSVersionCurrent.getMajor()) { in main()
413 << InputFilePath << "\nIfsVersion Values: " << Stub.IfsVersion in main()
417 if (TargetStub->IfsVersion > Stub.IfsVersion) in main()
418 Stub.IfsVersion = TargetStub->IfsVersion; in main()
420 if (Stub.ObjectFileFormat != TargetStub->ObjectFileFormat && in main()
425 << Stub.ObjectFileFormat << " " in main()
429 if (Stub.Triple != TargetStub->Triple && !TargetStub->Triple.empty()) { in main()
433 << "\nTriple Values: " << Stub.Triple << " " in main()
437 if (Stub.SOName != TargetStub->SOName) { in main()
441 << "\nSOName Values: " << Stub.SOName << " " in main()
445 if (Stub.NeededLibs != TargetStub->NeededLibs) { in main()
490 if (Stub.IfsVersion != IFSVersionCurrent) in main()
491 if (Stub.IfsVersion.getMajor() != IFSVersionCurrent.getMajor()) { in main()
493 << Stub.IfsVersion << ", llvm-ifs supported version: " in main()
499 Stub.Symbols.push_back(Entry.second); in main()
511 return writeIfso(Stub, (Action == "write-ifs"), Out); in main()