Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[DAQ] range check for microstate (140X) [backport] #44939

Merged
merged 1 commit into from
May 10, 2024
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
34 changes: 26 additions & 8 deletions EventFilter/Utilities/src/FastMonitoringService.cc
Original file line number Diff line number Diff line change
Expand Up @@ -651,14 +651,20 @@ namespace evf {
microstate_[getSID(sid)] = getmInput();
if (!tbbMonitoringMode_)
return;
tmicrostate_[getTID()] = getmInput();
auto tid = getTID();
if (tid >= nThreads_)
return;
tmicrostate_[tid] = getmInput();
}

void FastMonitoringService::postSourceEvent(edm::StreamID sid) {
microstate_[getSID(sid)] = getmFwkOvhSrc();
if (!tbbMonitoringMode_)
return;
tmicrostate_[getTID()] = getmIdle();
auto tid = getTID();
if (tid >= nThreads_)
return;
tmicrostate_[tid] = getmIdle();
}

void FastMonitoringService::preModuleEventAcquire(edm::StreamContext const& sc,
Expand All @@ -667,8 +673,11 @@ namespace evf {
microstateAcqFlag_[getSID(sc)] = 1;
if (!tbbMonitoringMode_)
return;
tmicrostate_[getTID()] = (void*)(mcc.moduleDescription());
tmicrostateAcqFlag_[getTID()] = 1;
auto tid = getTID();
if (tid >= nThreads_)
return;
tmicrostate_[tid] = (void*)(mcc.moduleDescription());
tmicrostateAcqFlag_[tid] = 1;
}

void FastMonitoringService::postModuleEventAcquire(edm::StreamContext const& sc,
Expand All @@ -677,22 +686,31 @@ namespace evf {
microstateAcqFlag_[getSID(sc)] = 0;
if (!tbbMonitoringMode_)
return;
tmicrostate_[getTID()] = getmIdle();
tmicrostateAcqFlag_[getTID()] = 0;
auto tid = getTID();
if (tid >= nThreads_)
return;
tmicrostate_[tid] = getmIdle();
tmicrostateAcqFlag_[tid] = 0;
}

void FastMonitoringService::preModuleEvent(edm::StreamContext const& sc, edm::ModuleCallingContext const& mcc) {
microstate_[getSID(sc)] = (void*)(mcc.moduleDescription());
if (!tbbMonitoringMode_)
return;
tmicrostate_[getTID()] = (void*)(mcc.moduleDescription());
auto tid = getTID();
if (tid >= nThreads_)
return;
tmicrostate_[tid] = (void*)(mcc.moduleDescription());
}

void FastMonitoringService::postModuleEvent(edm::StreamContext const& sc, edm::ModuleCallingContext const& mcc) {
microstate_[getSID(sc)] = getmFwkOvhMod();
if (!tbbMonitoringMode_)
return;
tmicrostate_[getTID()] = getmIdle();
auto tid = getTID();
if (tid >= nThreads_)
return;
tmicrostate_[tid] = getmIdle();
}

//from source
Expand Down