All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Properties Friends Macros Modules Pages
ProcessDescriptor.h
Go to the documentation of this file.
1 #ifndef GAUDIKERNEL_PROCESS_H
2 #define GAUDIKERNEL_PROCESS_H
3 
4 // Framework include files
5 #include "GaudiKernel/Kernel.h"
6 #include "GaudiKernel/SystemBase.h"
7 
8 namespace System {
9  // Forward declarations
10  class ProcessDescriptor;
12  ProcessDescriptor* getProcess();
13 
17  typedef struct _PEB *PPEB;
19  long ExitStatus;
21  unsigned long AffinityMask;
23  unsigned long UniqueProcessId;
25  };
26 
32  struct QUOTA_LIMITS {
33  unsigned long PagedPoolLimit;
34  unsigned long NonPagedPoolLimit;
35  unsigned long MinimumWorkingSetSize;
36  unsigned long MaximumWorkingSetSize;
37  unsigned long PagefileLimit;
39  };
40 
44  struct IO_COUNTERS {
45  unsigned long ReadOperationCount;
46  unsigned long WriteOperationCount;
47  unsigned long OtherOperationCount;
48  // longlong ReadOperationCount;
49  // longlong WriteOperationCount;
50  // longlong OtherOperationCount;
54  };
55 
59  struct VM_COUNTERS {
60  unsigned long PeakVirtualSize;
61  unsigned long VirtualSize;
62  unsigned long PageFaultCount;
63  unsigned long PeakWorkingSetSize;
64  unsigned long WorkingSetSize;
65  unsigned long QuotaPeakPagedPoolUsage;
66  unsigned long QuotaPagedPoolUsage;
68  unsigned long QuotaNonPagedPoolUsage;
69  unsigned long PagefileUsage;
70  unsigned long PeakPagefileUsage;
71  };
72 
73 
78  unsigned long PeakPagedPoolUsage;
79  unsigned long PagedPoolUsage;
80  unsigned long PagedPoolLimit;
81  unsigned long PeakNonPagedPoolUsage;
82  unsigned long NonPagedPoolUsage;
83  unsigned long NonPagedPoolLimit;
84  unsigned long PeakPagefileUsage;
85  unsigned long PagefileUsage;
86  unsigned long PagefileLimit;
87  };
88 
98  //longlong EllapsedTime; // Added by M.Frank
99  };
100 
111  void* m_handle;
113  public:
114  ProcessHandle(long pid);
115  virtual ~ProcessHandle();
116  long item() {
117  return m_needRelease ? 1 : 0;
118  }
119  void* handle() {
120  return m_handle;
121  }
122  };
130  public:
132  virtual ~ProcessDescriptor();
133  long query(long pid, InfoType info, PROCESS_BASIC_INFORMATION* buffer);
134  long query(long pid, InfoType info, POOLED_USAGE_AND_LIMITS* buffer);
135  long query(long pid, InfoType info, KERNEL_USER_TIMES* buffer);
136  long query(long pid, InfoType info, QUOTA_LIMITS* buffer);
137  long query(long pid, InfoType info, VM_COUNTERS* buffer);
138  long query(long pid, InfoType info, IO_COUNTERS* buffer);
139  long query(long pid, InfoType info, long* buffer);
140  };
141 }
142 #endif //GAUDIKERNEL_PROCESS_H
unsigned long QuotaPeakPagedPoolUsage
ProcessDescriptor * getProcess()
Retrieve Process structure.
unsigned long PagefileUsage
Process/Thread System and User Time NtQueryInformationProcess using ProcessTimes NtQueryInformationTh...
unsigned long MaximumWorkingSetSize
Note: OS specific details for environment resolution.
Definition: Debugger.h:19
unsigned long PeakPagefileUsage
Process I/O Counters NtQueryInformationProcess using ProcessIoCounters.
unsigned long PagefileLimit
unsigned long WorkingSetSize
unsigned long NonPagedPoolLimit
KERNEL_USER_TIMES m_KERNEL_USER_TIMES[2]
unsigned long PeakWorkingSetSize
unsigned long VirtualSize
unsigned long OtherOperationCount
unsigned long PageFaultCount
unsigned long QuotaNonPagedPoolUsage
unsigned long ReadOperationCount
POOLED_USAGE_AND_LIMITS m_POOLED_USAGE_AND_LIMITS[2]
unsigned long PeakVirtualSize
Process Quotas NtQueryInformationProcess using ProcessQuotaLimits NtQueryInformationProcess using Pro...
long query(long pid, InfoType info, PROCESS_BASIC_INFORMATION *buffer)
struct _PEB * PPEB
Basic Process Information NtQueryInformationProcess using ProcessBasicInfo.
Provides access to process information.
Process Virtual Memory Counters NtQueryInformationProcess using ProcessVmCounters.
unsigned long PagedPoolLimit
PROCESS_BASIC_INFORMATION m_PROCESS_BASIC_INFORMATION[2]
Process Pooled Quota Usage and Limits NtQueryInformationProcess using ProcessPooledUsageAndLimits.
unsigned long MinimumWorkingSetSize
unsigned long WriteOperationCount
unsigned long QuotaPeakNonPagedPoolUsage
InfoType
Enumeration for fetching information.
Definition: SystemBase.h:18
unsigned long QuotaPagedPoolUsage