Source code of Windows XP (NT5)
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

159 lines
5.8 KiB

  1. /*++
  2. Copyright (c) 1997 Microsoft Corporation
  3. Module Name:
  4. DATAJOB.h
  5. Abstract:
  6. Header file for the Windows NT Processor Job Object counters.
  7. This file contains definitions to construct the dynamic data
  8. which is returned by the Configuration Registry. Data from
  9. various system API calls is placed into the structures shown
  10. here.
  11. Author:
  12. Bob Watson 28-Oct-1996
  13. Revision History:
  14. --*/
  15. #ifndef _DATAJOB_H_
  16. #define _DATAJOB_H_
  17. // don't include the "TOTAL" counters since we are reporting only rates
  18. // (for now) the total rates are redundant.
  19. #ifndef _DATAJOB_INCLUDE_TOTAL_COUNTERS
  20. #define _DATAJOB_INCLUDE_TOTAL_COUNTERS
  21. #endif
  22. //
  23. // Process data object definitions.
  24. //
  25. //
  26. // This is the counter structure presently returned by NT. The
  27. // Performance Monitor MUST *NOT* USE THESE STRUCTURES!
  28. //
  29. typedef struct _JOB_DATA_DEFINITION {
  30. PERF_OBJECT_TYPE JobObjectType;
  31. PERF_COUNTER_DEFINITION cdCurrentProcessorTime;
  32. PERF_COUNTER_DEFINITION cdCurrentUserTime;
  33. PERF_COUNTER_DEFINITION cdCurrentKernelTime;
  34. #ifdef _DATAJOB_INCLUDE_TOTAL_COUNTERS
  35. PERF_COUNTER_DEFINITION cdTotalProcessorTime;
  36. PERF_COUNTER_DEFINITION cdTotalUserTime;
  37. PERF_COUNTER_DEFINITION cdTotalKernelTime;
  38. PERF_COUNTER_DEFINITION cdCurrentProcessorUsage;
  39. PERF_COUNTER_DEFINITION cdCurrentUserUsage;
  40. PERF_COUNTER_DEFINITION cdCurrentKernelUsage;
  41. #endif
  42. PERF_COUNTER_DEFINITION cdPageFaults;
  43. PERF_COUNTER_DEFINITION cdTotalProcessCount;
  44. PERF_COUNTER_DEFINITION cdCurrentProcessCount;
  45. PERF_COUNTER_DEFINITION cdTerminatedProcessCount;
  46. } JOB_DATA_DEFINITION, * PJOB_DATA_DEFINITION;
  47. typedef struct _JOB_COUNTER_DATA {
  48. PERF_COUNTER_BLOCK CounterBlock;
  49. LONGLONG CurrentProcessorTime;
  50. LONGLONG CurrentUserTime;
  51. LONGLONG CurrentKernelTime;
  52. #ifdef _DATAJOB_INCLUDE_TOTAL_COUNTERS
  53. LONGLONG TotalProcessorTime;
  54. LONGLONG TotalUserTime;
  55. LONGLONG TotalKernelTime;
  56. LONGLONG CurrentProcessorUsage;
  57. LONGLONG CurrentUserUsage;
  58. LONGLONG CurrentKernelUsage;
  59. #endif //_DATAJOB_INCLUDE_TOTAL_COUNTERS
  60. DWORD PageFaults;
  61. DWORD TotalProcessCount;
  62. DWORD ActiveProcessCount;
  63. DWORD TerminatedProcessCount;
  64. } JOB_COUNTER_DATA, * PJOB_COUNTER_DATA;
  65. extern JOB_DATA_DEFINITION JobDataDefinition;
  66. typedef struct _JOB_DETAILS_DATA_DEFINITION {
  67. PERF_OBJECT_TYPE JobDetailsObjectType;
  68. PERF_COUNTER_DEFINITION cdProcessorTime;
  69. PERF_COUNTER_DEFINITION cdUserTime;
  70. PERF_COUNTER_DEFINITION cdKernelTime;
  71. PERF_COUNTER_DEFINITION cdPeakVirtualSize;
  72. PERF_COUNTER_DEFINITION cdVirtualSize;
  73. PERF_COUNTER_DEFINITION cdPageFaults;
  74. PERF_COUNTER_DEFINITION cdPeakWorkingSet;
  75. PERF_COUNTER_DEFINITION cdTotalWorkingSet;
  76. #ifdef _DATAPROC_PRIVATE_WS_
  77. PERF_COUNTER_DEFINITION cdPrivateWorkingSet;
  78. PERF_COUNTER_DEFINITION cdSharedWorkingSet;
  79. #endif
  80. PERF_COUNTER_DEFINITION cdPeakPageFile;
  81. PERF_COUNTER_DEFINITION cdPageFile;
  82. PERF_COUNTER_DEFINITION cdPrivatePages;
  83. PERF_COUNTER_DEFINITION cdThreadCount;
  84. PERF_COUNTER_DEFINITION cdBasePriority;
  85. PERF_COUNTER_DEFINITION cdElapsedTime;
  86. PERF_COUNTER_DEFINITION cdProcessId;
  87. PERF_COUNTER_DEFINITION cdCreatorProcessId;
  88. PERF_COUNTER_DEFINITION cdPagedPool;
  89. PERF_COUNTER_DEFINITION cdNonPagedPool;
  90. PERF_COUNTER_DEFINITION cdHandleCount;
  91. PERF_COUNTER_DEFINITION cdReadOperationCount;
  92. PERF_COUNTER_DEFINITION cdWriteOperationCount;
  93. PERF_COUNTER_DEFINITION cdDataOperationCount;
  94. PERF_COUNTER_DEFINITION cdOtherOperationCount;
  95. PERF_COUNTER_DEFINITION cdReadTransferCount;
  96. PERF_COUNTER_DEFINITION cdWriteTransferCount;
  97. PERF_COUNTER_DEFINITION cdDataTransferCount;
  98. PERF_COUNTER_DEFINITION cdOtherTransferCount;
  99. } JOB_DETAILS_DATA_DEFINITION, * PJOB_DETAILS_DATA_DEFINITION;
  100. typedef struct _JOB_DETAILS_COUNTER_DATA {
  101. PERF_COUNTER_BLOCK CounterBlock;
  102. DWORD PageFaults;
  103. LONGLONG ProcessorTime;
  104. LONGLONG UserTime;
  105. LONGLONG KernelTime;
  106. LONGLONG PeakVirtualSize;
  107. LONGLONG VirtualSize;
  108. LONGLONG PeakWorkingSet;
  109. LONGLONG TotalWorkingSet;
  110. #ifdef _DATAPROC_PRIVATE_WS_
  111. DWORD PrivateWorkingSet;
  112. DWORD SharedWorkingSet;
  113. #endif
  114. LONGLONG PeakPageFile;
  115. LONGLONG PageFile;
  116. LONGLONG PrivatePages;
  117. DWORD ThreadCount;
  118. DWORD BasePriority;
  119. LONGLONG ElapsedTime;
  120. LONGLONG ProcessId;
  121. LONGLONG CreatorProcessId;
  122. DWORD PagedPool;
  123. DWORD NonPagedPool;
  124. DWORD HandleCount;
  125. DWORD Reserved; // for alignment
  126. LONGLONG ReadOperationCount;
  127. LONGLONG WriteOperationCount;
  128. LONGLONG DataOperationCount;
  129. LONGLONG OtherOperationCount;
  130. LONGLONG ReadTransferCount;
  131. LONGLONG WriteTransferCount;
  132. LONGLONG DataTransferCount;
  133. LONGLONG OtherTransferCount;
  134. } JOB_DETAILS_COUNTER_DATA, *PJOB_DETAILS_COUNTER_DATA;
  135. extern JOB_DETAILS_DATA_DEFINITION JobDetailsDataDefinition;
  136. #endif // _DATAJOB_H_