10 #include <unordered_map> 25 return left.label == right.label && left.instance == right.instance &&
26 left.process == right.process;
29 class PendingBTLEntry {
31 PendingBTLEntry(std::string
const& fcn,
32 std::string
const& moduleLabel,
33 std::string
const& instanceName,
34 std::string
const& procName,
36 : fcn_{fcn}, ct_{moduleLabel, instanceName, procName}, pid_{
pid}
50 process() const noexcept
72 std::vector<PendingBTLEntry> pendingEntries;
73 std::unordered_map<ProductID, CheapTag, ProductID::Hash> insertedABVs;
74 for (
auto const& [
pid, pd] : descriptions) {
75 auto const& prodFCN = pd.friendlyClassName();
76 auto const& procName = pd.processName();
77 result[prodFCN][procName].emplace_back(
pid);
80 auto const& moduleLabel = pd.moduleLabel();
81 auto const& instanceName = pd.productInstanceName();
82 auto const& className = pd.producedClassName();
88 if (!baseName.empty()) {
98 insertedABVs.emplace(
pid, CheapTag{moduleLabel, instanceName, procName});
102 auto const iend = insertedABVs.cend();
107 pendingEntries.cbegin(),
108 pendingEntries.cend(),
109 [&result, &insertedABVs, iend](
auto const& pe) {
110 auto& pids = result[pe.fcn()][pe.process()];
112 !std::any_of(pids.cbegin(),
115 auto i = insertedABVs.find(
pid);
116 return i != iend && pe.ct() == i->second;
118 pids.emplace_back(pe.pid());
bool operator==(Provenance const &a, Provenance const &b) noexcept
constexpr auto const & right(const_AssnsIter< L, R, D, Dir > const &a, const_AssnsIter< L, R, D, Dir > const &b)
const std::string instance
string name_of_assns_base(string assns_type_name)
ProductLookup_t createProductLookups(ProductDescriptionsByID const &descriptions)
std::string friendlyName(std::string const &iFullName)
constexpr auto const & left(const_AssnsIter< L, R, D, Dir > const &a, const_AssnsIter< L, R, D, Dir > const &b)
std::map< ProductID, BranchDescription > ProductDescriptionsByID
std::map< std::string, ProcessLookup > ProductLookup_t
bool is_assns(std::string const &type_name)