diff --git a/Trigger/TrigCost/TrigCostAnalysis/src/CostData.cxx b/Trigger/TrigCost/TrigCostAnalysis/src/CostData.cxx index 520bb1afa061fd1e7db0fa993c09a1840b6c7e7a..6bae94a556ec4aa5eedc1541b85f3a3ead218bb2 100644 --- a/Trigger/TrigCost/TrigCostAnalysis/src/CostData.cxx +++ b/Trigger/TrigCost/TrigCostAnalysis/src/CostData.cxx @@ -73,7 +73,7 @@ uint32_t CostData::onlineSlot() const { return m_slot; } -bool CostData::isMaterSlot() const { +bool CostData::isMasterSlot() const { return (onlineSlot() == 0); } diff --git a/Trigger/TrigCost/TrigCostAnalysis/src/CostData.h b/Trigger/TrigCost/TrigCostAnalysis/src/CostData.h index 0b86a3baadf11a953deb639208921f017a8439d5..7feb0ec2bae90a717c2e0c3353029c44c8306831 100644 --- a/Trigger/TrigCost/TrigCostAnalysis/src/CostData.h +++ b/Trigger/TrigCost/TrigCostAnalysis/src/CostData.h @@ -89,7 +89,7 @@ class CostData { /** * @return True if event was processed in the master slot (0), and hence contains cost data spanning all concurrent slots */ - bool isMaterSlot() const; + bool isMasterSlot() const; /** * @brief Getter of the total algorithm CPU time in the event. diff --git a/Trigger/TrigCost/TrigCostAnalysis/src/TrigCostAnalysis.cxx b/Trigger/TrigCost/TrigCostAnalysis/src/TrigCostAnalysis.cxx index f90937a039f1042de1b168ac474c15dbac321ebe..8efcae34b57bec6259c8124095e0a0255cd712dd 100644 --- a/Trigger/TrigCost/TrigCostAnalysis/src/TrigCostAnalysis.cxx +++ b/Trigger/TrigCost/TrigCostAnalysis/src/TrigCostAnalysis.cxx @@ -155,7 +155,7 @@ StatusCode TrigCostAnalysis::execute() { ATH_CHECK( range->newEvent( costData, getWeight(context) ) ); - if (checkDoFullEventDump(context, onlineSlot)) { + if (checkDoFullEventDump(context, costData)) { ATH_CHECK( dumpEvent(context) ); } @@ -163,8 +163,8 @@ StatusCode TrigCostAnalysis::execute() { } -bool TrigCostAnalysis::checkDoFullEventDump(const EventContext& context, const uint32_t onlineSlot) { - if (onlineSlot == 0 +bool TrigCostAnalysis::checkDoFullEventDump(const EventContext& context, const CostData& costData) { + if (costData.isMasterSlot() and m_fullEventDumps < m_maxFullEventDumps and context.eventID().event_number() % m_fullEventDumpProbability == 0) { diff --git a/Trigger/TrigCost/TrigCostAnalysis/src/TrigCostAnalysis.h b/Trigger/TrigCost/TrigCostAnalysis/src/TrigCostAnalysis.h index 5d2c7e5d64cff00de966612e6c00056dbcc71217..874e76e0abfa9814dc9adc71503590cfd7fe10e0 100644 --- a/Trigger/TrigCost/TrigCostAnalysis/src/TrigCostAnalysis.h +++ b/Trigger/TrigCost/TrigCostAnalysis/src/TrigCostAnalysis.h @@ -116,11 +116,10 @@ class TrigCostAnalysis: public ::AthHistogramAlgorithm { /** * @brief Check if event dumping should be performed for the current event. * @param[in] context Event context. - * @param[in] onelineSlot The slot used to process the event in the trigger. - * We only dump slot 0 as these events cary payload data for all events. + * @param[in] costData We only dump the master-slot (slot:0) as these events cary payload data for all slots / all threads. * @return True, if the event should be dumped. */ - bool checkDoFullEventDump(const EventContext& context, const uint32_t onlineSlot); + bool checkDoFullEventDump(const EventContext& context, const CostData& costData); /** * @brief Return or construct and return a Range for the Context. Might return nullptr range.