PERF_DATA_BLOCK structure (winperf.h)

Describes the performance data block that you queried, for example, the number of performance objects returned by the provider and the time-based values that you use when calculating performance values.

Syntax

typedef struct _PERF_DATA_BLOCK {
  WCHAR         Signature[4];
  DWORD         LittleEndian;
  DWORD         Version;
  DWORD         Revision;
  DWORD         TotalByteLength;
  DWORD         HeaderLength;
  DWORD         NumObjectTypes;
  LONG          DefaultObject;
  SYSTEMTIME    SystemTime;
  LARGE_INTEGER PerfTime;
  LARGE_INTEGER PerfFreq;
  LARGE_INTEGER PerfTime100nSec;
  DWORD         SystemNameLength;
  DWORD         SystemNameOffset;
} PERF_DATA_BLOCK, *PPERF_DATA_BLOCK;

Members

Signature[4]

Array of four wide-characters that contains "PERF".

LittleEndian

Indicates if the counter values are in big endian format or little endian format. If one, the counter values are in little endian format. If zero, the counter values are in big endian format. This value may be zero (big endian format) if you retrieve performance data from a foreign computer, such as a UNIX computer.

Version

Version of the performance structures.

Revision

Revision of the performance structures.

TotalByteLength

Total size of the performance data block, in bytes.

HeaderLength

Size of this structure, in bytes. You use the header length to find the first PERF_OBJECT_TYPE structure in the performance data block.

NumObjectTypes

Number of performance objects in the performance data block.

DefaultObject

Reserved.

SystemTime

Time when the system was monitored. This member is in Coordinated Universal Time (UTC) format.

PerfTime

Performance-counter value, in counts, for the system being monitored. For more information, see QueryPerformanceCounter.

PerfFreq

Performance-counter frequency, in counts per second, for the system being monitored. For more information, see QueryPerformanceFrequency.

PerfTime100nSec

Performance-counter value, in 100 nanosecond units, for the system being monitored. For more information, see GetSystemTimeAsFileTime.

SystemNameLength

Size of the computer name located at SystemNameOffset, in bytes.

SystemNameOffset

Offset from the beginning of this structure to the Unicode name of the computer being monitored.

Remarks

The performance data block is returned when a consumer calls RegQueryValueEx to retrieve one or more performance objects. This structure is the first structure in the returned block. The next structure in the block is the PERF_OBJECT_TYPE structure, which defines a performance object. For details on the layout of the performance data block, see Performance Data Format.

Consumers use PerfTime, PerfFreq, and PerfTime100nSec when calculating counter values unless the counter type contains the PERF_OBJECT_TIMER flag in which case the consumer uses the PerfTime and PerfFreq members of PERF_OBJECT_TYPE.

Requirements

Requirement Value
Minimum supported client Windows XP [desktop apps only]
Minimum supported server Windows Server 2003 [desktop apps only]
Header winperf.h (include Windows.h)

See also

PERF_OBJECT_TYPE

Performance Data Format