26 #include <type_traits> 29 namespace workerimpl {
81 template<
typename...
T>
99 template<
typename T,
typename P>
108 template<
typename T,
typename P>
153 return module_->prePrefetchSelection(
id,ep,mcc);
162 return module_->prePrefetchSelection(
id,ep,mcc);
171 return module_->prePrefetchSelection(
id,ep,mcc);
180 return module_->prePrefetchSelection(
id,ep,mcc);
187 module_->doBeginRun(rp, c, mcc);
197 module_->doStreamBeginRun(
id, rp, c, mcc);
206 module_->doStreamEndRun(
id, rp, c, mcc);
218 might_call(
this,
id,rp,c, mcc);
230 might_call(
this,
id,rp,c, mcc);
248 module_->doBeginLuminosityBlock(lbp, c, mcc);
258 module_->doStreamBeginLuminosityBlock(
id, rp, c, mcc);
267 module_->doStreamEndLuminosityBlock(
id, rp, c, mcc);
279 might_call(
this,
id,lbp,c, mcc);
291 might_call(
this,
id,lbp,c,mcc);
301 module_->doEndLuminosityBlock(lbp, c, mcc);
362 module_->doRespondToOpenInputFile(fb);
369 module_->doRespondToCloseInputFile(fb);
377 module_->doRegisterThinnedAssociations(registry, helper);
386 return &(
module_->sharedResourcesAcquirer().serialQueueChain());
389 return &(
module_->sharedResourcesAcquirer().serialQueueChain());
392 return &(
module_->sharedResourcesAcquirer().serialQueueChain());
395 return &(
module_->sharedResourcesAcquirer().serialQueueChain());
398 return &(
module_->sharedResourcesAcquirer().serialQueueChain());
401 return &(
module_->sharedResourcesAcquirer().serialQueueChain());
404 return &(
module_->sharedResourcesAcquirer().serialQueueChain());
407 return &(
module_->sharedResourcesAcquirer().serialQueueChain());
424 template <
typename T>
bool mustPrefetchMayGet();
426 template<>
bool mustPrefetchMayGet<EDAnalyzer>() {
return true;}
427 template<>
bool mustPrefetchMayGet<EDProducer>() {
return true;}
428 template<>
bool mustPrefetchMayGet<EDFilter>() {
return true;}
429 template<>
bool mustPrefetchMayGet<OutputModule>() {
return true;}
431 template<>
bool mustPrefetchMayGet<edm::one::EDProducerBase>() {
return true;}
432 template<>
bool mustPrefetchMayGet<edm::one::EDFilterBase>() {
return true;}
433 template<>
bool mustPrefetchMayGet<edm::one::EDAnalyzerBase>() {
return true;}
434 template<>
bool mustPrefetchMayGet<edm::one::OutputModuleBase>() {
return true;}
436 template<>
bool mustPrefetchMayGet<edm::global::EDProducerBase>() {
return true;}
437 template<>
bool mustPrefetchMayGet<edm::global::EDFilterBase>() {
return true;}
438 template<>
bool mustPrefetchMayGet<edm::global::EDAnalyzerBase>() {
return true;}
439 template<>
bool mustPrefetchMayGet<edm::global::OutputModuleBase>() {
return true;}
441 template<>
bool mustPrefetchMayGet<edm::limited::EDProducerBase>() {
return true;}
442 template<>
bool mustPrefetchMayGet<edm::limited::EDFilterBase>() {
return true;}
443 template<>
bool mustPrefetchMayGet<edm::limited::EDAnalyzerBase>() {
return true;}
444 template<>
bool mustPrefetchMayGet<edm::limited::OutputModuleBase>() {
return true;}
446 template<>
bool mustPrefetchMayGet<edm::stream::EDProducerAdaptorBase>() {
return true;}
447 template<>
bool mustPrefetchMayGet<edm::stream::EDFilterAdaptorBase>() {
return true;}
448 template<>
bool mustPrefetchMayGet<edm::stream::EDAnalyzerAdaptorBase>() {
return true;}
456 module_->updateLookup(iBranchType,iHelper,mustPrefetchMayGet<T>());
460 using ModuleToResolverIndicies = std::unordered_multimap<
std::string,
461 std::tuple<edm::TypeID const*, const char*, edm::ProductResolverIndex>>;
462 void resolvePutIndiciesImpl(
void*,
464 ModuleToResolverIndicies
const& iIndicies,
465 std::string
const& iModuleLabel) {
471 ModuleToResolverIndicies
const& iIndicies,
472 std::string
const& iModuleLabel) {
478 ModuleToResolverIndicies
const& iIndicies,
479 std::string
const& iModuleLabel) {
484 ModuleToResolverIndicies
const& iIndicies,
485 std::string
const& iModuleLabel) {
489 std::vector<ProductResolverIndex> s_emptyIndexList;
491 std::vector<ProductResolverIndex>
const& itemsShouldPutInEventImpl(
void const*) {
492 return s_emptyIndexList;
495 std::vector<ProductResolverIndex>
const& itemsShouldPutInEventImpl(
ProducerBase const* iProd) {
512 std::tuple<TypeID const*, const char*, edm::ProductResolverIndex>>
const& iIndicies) {
513 resolvePutIndiciesImpl(&
module(), iBranchType,iIndicies,
description().moduleLabel());
518 std::vector<ProductResolverIndex>
const&
520 return itemsShouldPutInEventImpl(&
module());
bool implDoStreamEnd(StreamID id, RunPrincipal const &rp, EventSetup const &c, ModuleCallingContext const *mcc) override
static const char module_[]
ModuleDescription const & description() const
roAction_t actions[nactions]
void callWorkerStreamEnd(D, StreamID id, RunPrincipal const &rp, EventSetup const &c, ModuleCallingContext const *mcc)
void implEndJob() override
void updateLookup(BranchType iBranchType, ProductResolverIndexHelper const &) override
bool implDoStreamBegin(StreamID id, RunPrincipal const &rp, EventSetup const &c, ModuleCallingContext const *mcc) override
ActivityRegistry * activityRegistry()
bool implDo(EventPrincipal const &ep, EventSetup const &c, ModuleCallingContext const *mcc) override
Types moduleType() const override
void resolvePutIndicies(BranchType iBranchType, ModuleToResolverIndicies const &iIndicies, std::string const &moduleLabel)
edm::propagate_const< std::shared_ptr< T > > module_
std::vector< edm::ProductResolverIndex > const & indiciesForPutProducts(BranchType iBranchType) const
void implRespondToOpenInputFile(FileBlock const &fb) override
std::vector< edm::ProductResolverIndex > const & indiciesForPutProducts(BranchType iBranchType) const
bool implDoPrePrefetchSelection(StreamID id, EventPrincipal const &ep, ModuleCallingContext const *mcc) override
void callWorkerEndStream(D, StreamID)
void operator()(WorkerT< T > *iWorker, StreamID id)
void operator()(const T &...)
void implBeginStream(StreamID) override
TaskQueueAdaptor serializeRunModule() override
void resolvePutIndicies(BranchType iBranchType, std::unordered_multimap< std::string, std::tuple< TypeID const *, const char *, edm::ProductResolverIndex >> const &iIndicies) override
void operator()(WorkerT< T > *iWorker, StreamID id)
void callWorkerStreamBegin(D, StreamID id, RunPrincipal const &rp, EventSetup const &c, ModuleCallingContext const *mcc)
bool implDoBegin(RunPrincipal const &rp, EventSetup const &c, ModuleCallingContext const *mcc) override
std::vector< ProductResolverIndex > const & itemsShouldPutInEvent() const override
DecomposeProduct< arg, typename Div::arg > D
void implEndStream(StreamID) override
void implBeginJob() override
void implRespondToCloseInputFile(FileBlock const &fb) override
std::pair< OmniClusterRef, TrackingParticleRef > P
void resolvePutIndicies(BranchType iBranchType, ModuleToResolverIndicies const &iIndicies, std::string const &moduleLabel)
void callWorkerBeginStream(D, StreamID)
void postDoEvent(EventPrincipal const &)
void implRegisterThinnedAssociations(ProductRegistry const &, ThinnedAssociationsHelper &) override
bool implDoEnd(RunPrincipal const &rp, EventSetup const &c, ModuleCallingContext const *mcc) override
std::string workerType() const override
WorkerT(std::shared_ptr< T >, ModuleDescription const &, ExceptionToActionTable const *actions)