Lines Matching defs:JDS

254                   JITDylibState &JDS);
268 Error requestPushSymbols(JITDylibState &JDS,
275 lookupSymbols(JITDylibState &JDS, std::unique_lock<std::mutex> &JDStatesLock,
288 JITDylibState &JDS);
290 JITDylibState &JDS);
294 JITDylibState &JDS);
296 JITDylibState &JDS, MachOJITDylibDepInfoMap &DepInfo);
300 JITDylibState &JDS);
302 JITDylibState &JDS);
306 JITDylibState &JDS);
439 auto &JDS = JDStates[Header];
440 JDS.Name = std::move(Name);
441 JDS.Header = Header;
442 JDNameToHeader[JDS.Name] = Header;
502 auto *JDS = getJITDylibStateByHeader(HeaderAddr.toPtr<void *>());
503 if (!JDS) {
512 JDS->SymbolTable[NameAddr.toPtr<const char *>()] = {SymAddr, Flags};
523 auto *JDS = getJITDylibStateByHeader(HeaderAddr.toPtr<void *>());
524 if (!JDS) {
533 JDS->SymbolTable.erase(NameAddr.toPtr<const char *>());
551 auto *JDS = getJITDylibStateByHeader(HeaderAddr.toPtr<void *>());
552 if (!JDS) {
572 JDS->UnwindSections.insert(CodeRange.Start.toPtr<char *>(),
590 assert(!JDS->DataSectionContent.count(KV.second.Start.toPtr<char *>()) &&
593 JDS->DataSectionContent[KV.second.Start.toPtr<char *>()] =
596 JDS->ZeroInitRanges[KV.second.Start.toPtr<char *>()] = KV.second.size();
601 JDS->ObjCRuntimeRegistrationObjects.add(KV.second.toSpan<char>());
603 JDS->ModInitsSections.add(KV.second.toSpan<void (*)()>());
628 auto *JDS = getJITDylibStateByHeader(HeaderAddr.toPtr<void *>());
629 if (!JDS) {
637 // FIXME: Implement faster-path by returning immediately if JDS is being
656 JDS->UnwindSections.erase(CodeRange.Start.toPtr<char *>(),
674 JDS->DataSectionContent.erase(KV.second.Start.toPtr<char *>());
676 JDS->ZeroInitRanges.erase(KV.second.Start.toPtr<char *>());
682 JDS->ObjCRuntimeRegistrationObjects.removeIfPresent(KV.second);
684 JDS->ModInitsSections.removeIfPresent(KV.second);
729 auto *JDS = getJITDylibStateByHeader(DSOHandle);
731 if (JDS) {
749 auto *JDS = getJITDylibStateByHeader(DSOHandle);
750 if (!JDS) {
761 if (auto Err = lookupSymbols(*JDS, Lock, {&Result, 1}, {&Lookup, 1})) {
777 auto *JDS = getJITDylibStateByHeader(DSOHandle);
778 if (!JDS) {
786 JDS->AtExits.push_back({F, Arg});
791 std::unique_lock<std::mutex> &JDStatesLock, JITDylibState &JDS) {
792 auto AtExits = std::move(JDS.AtExits);
807 auto *JDS = getJITDylibStateByHeader(DSOHandle);
813 if (JDS)
814 runAtExits(Lock, *JDS);
850 JITDylibState &JDS, span<std::pair<std::string_view, bool>> Symbols) {
855 ExecutorAddr::fromPtr(JDS.Header), Symbols)) {
863 JITDylibState &JDS, std::unique_lock<std::mutex> &JDStatesLock,
874 auto I = JDS.SymbolTable.find(Symbols[Idx].first);
875 if (I != JDS.SymbolTable.end())
898 JDS, {MissingSymbols.data(), MissingSymbols.size()}))
905 auto I = JDS.SymbolTable.find(Symbols[MissingIdx].first);
906 if (I != JDS.SymbolTable.end())
1000 std::unique_lock<std::mutex> &JDStatesLock, JITDylibState &JDS) {
1004 JDS.ObjCRuntimeRegistrationObjects.processNewSections(
1031 std::unique_lock<std::mutex> &JDStatesLock, JITDylibState &JDS) {
1033 InitSections.reserve(JDS.ModInitsSections.numNewSections());
1039 JDS.ModInitsSections.processNewSections(
1056 auto *JDS = getJITDylibStateByName(Path);
1058 if (!JDS)
1065 if (!JDS->referenced() || !JDS->Sealed) {
1066 if (auto Err = dlopenFull(Lock, *JDS))
1071 ++JDS->DlRefCount;
1074 return JDS->Header;
1078 std::unique_lock<std::mutex> &JDStatesLock, JITDylibState &JDS) {
1086 ExecutorAddr::fromPtr(JDS.Header)))
1093 if (auto Err = dlopenInitialize(JDStatesLock, JDS, *DepInfo))
1099 JDS.Name.c_str());
1104 << JDS.Name;
1112 std::unique_lock<std::mutex> &JDStatesLock, JITDylibState &JDS,
1116 JDS.Name.c_str());
1124 auto I = DepInfo.find(ExecutorAddr::fromPtr(JDS.Header));
1133 if (JDS.Sealed) {
1136 ErrStream << "Sealed JITDylib " << JDS.Header
1140 if (JDS.referenced())
1143 JDS.Sealed = DI.Sealed;
1147 std::swap(JDS.Deps, OldDeps);
1148 JDS.Deps.reserve(DI.DepHeaders.size());
1155 << JDS.Name;
1164 if (auto Err = registerObjCRegistrationObjects(JDStatesLock, JDS))
1166 if (auto Err = runModInits(JDStatesLock, JDS))
1186 auto *JDS = getJITDylibStateByHeader(DSOHandle);
1188 if (!JDS) {
1194 if (!JDS->referenced())
1197 if (!JDS->Sealed) {
1198 if (auto Err = dlupdateFull(Lock, *JDS))
1206 std::unique_lock<std::mutex> &JDStatesLock, JITDylibState &JDS) {
1214 ExecutorAddr::fromPtr(JDS.Header)))
1221 if (auto Err = dlupdateInitialize(JDStatesLock, JDS))
1228 std::unique_lock<std::mutex> &JDStatesLock, JITDylibState &JDS) {
1231 JDS.Name.c_str());
1235 if (auto Err = registerObjCRegistrationObjects(JDStatesLock, JDS))
1237 if (auto Err = runModInits(JDStatesLock, JDS))
1247 auto *JDS = getJITDylibStateByHeader(DSOHandle);
1249 if (!JDS) {
1256 --JDS->DlRefCount;
1258 if (!JDS->referenced())
1259 return dlcloseDeinitialize(Lock, *JDS);
1265 std::unique_lock<std::mutex> &JDStatesLock, JITDylibState &JDS) {
1269 JDS.Name.c_str());
1272 runAtExits(JDStatesLock, JDS);
1275 JDS.ModInitsSections.reset();
1278 for (auto &KV : JDS.DataSectionContent)
1280 for (auto &KV : JDS.ZeroInitRanges)
1284 for (auto *DepJDS : JDS.Deps) {