ATLAS Offline Software
AlgorithmMemoryModule.cxx
Go to the documentation of this file.
1 /*
2  Copyright (C) 2002-2024 CERN for the benefit of the ATLAS collaboration
3 */
4 
6 
7 
8 
9 //
10 // includes
11 //
12 
14 
15 #include <EventLoop/ModuleData.h>
17 #include <TSystem.h>
18 
19 //
20 // method implementations
21 //
22 
23 namespace EL
24 {
25  namespace Detail
26  {
29  {
30  ::ProcInfo_t pinfo;
31  if (gSystem->GetProcInfo (&pinfo) != 0) {
32  ANA_MSG_ERROR ("Could not get memory usage information");
33  return StatusCode::FAILURE;
34  }
35  ANA_MSG_INFO ("Memory usage at start of job: " << pinfo.fMemResident << " kB resident, " << pinfo.fMemVirtual << " kB virtual");
36 
37  for (auto& alg : data.m_algs)
38  alg.m_algorithm = std::make_unique<AlgorithmMemoryWrapper>(std::move (alg.m_algorithm));
39  return StatusCode::SUCCESS;
40  }
41  }
42 }
data
char data[hepevt_bytes_allocation_ATLAS]
Definition: HepEvt.cxx:11
AlgorithmMemoryWrapper.h
SGout2dot.alg
alg
Definition: SGout2dot.py:243
EL::Detail::ModuleData
the data the EventLoop core classes are sharing with the Module implementation
Definition: ModuleData.h:64
ANA_MSG_ERROR
#define ANA_MSG_ERROR(xmsg)
Macro printing error messages.
Definition: Control/AthToolSupport/AsgMessaging/AsgMessaging/MessageCheck.h:294
EL::StatusCode
::StatusCode StatusCode
StatusCode definition for legacy code.
Definition: PhysicsAnalysis/D3PDTools/EventLoop/EventLoop/StatusCode.h:22
ANA_MSG_INFO
#define ANA_MSG_INFO(xmsg)
Macro printing info messages.
Definition: Control/AthToolSupport/AsgMessaging/AsgMessaging/MessageCheck.h:290
EL
This module defines the arguments passed from the BATCH driver to the BATCH worker.
Definition: AlgorithmWorkerData.h:24
xAOD::DiTauJetParameters::Detail
Detail
Definition: DiTauDefs.h:38
AlgorithmMemoryModule.h
ModuleData.h
EL::Detail::AlgorithmMemoryModule::firstInitialize
virtual StatusCode firstInitialize(ModuleData &data) override
action at the the very beginning of the worker job
Definition: AlgorithmMemoryModule.cxx:28