1
#ifndef _RPC_PERFCOUNT_H
2
#define _RPC_PERFCOUNT_H
4
typedef struct perf_counter_definition
6
/* sizeof(PERF_COUNTER_DEFINITION) */
8
uint32 CounterNameTitleIndex;
9
uint32 CounterNameTitlePointer;
10
uint32 CounterHelpTitleIndex;
11
uint32 CounterHelpTitlePointer;
18
PERF_COUNTER_DEFINITION;
20
typedef struct perf_counter_block
22
/* Total size of the data block, including all data plus this header */
28
typedef struct perf_instance_definition
30
/* Total size of the instance definition, including the length of the terminated Name string */
32
uint32 ParentObjectTitleIndex;
33
uint32 ParentObjectTitlePointer;
35
/* From the start of the PERF_INSTANCE_DEFINITION, the byte offset to the start of the Name string */
38
/* Unicode string containing the name for the instance */
40
PERF_COUNTER_BLOCK counter_data;
42
PERF_INSTANCE_DEFINITION;
44
typedef struct perf_object_type
46
/* Total size of the object block, including all PERF_INSTANCE_DEFINITIONs,
47
PERF_COUNTER_DEFINITIONs and PERF_COUNTER_BLOCKs in bytes */
48
uint32 TotalByteLength;
49
/* Size of this PERF_OBJECT_TYPE plus all PERF_COUNTER_DEFINITIONs in bytes */
50
uint32 DefinitionLength;
51
/* Size of this PERF_OBJECT_TYPE */
53
uint32 ObjectNameTitleIndex;
54
uint32 ObjectNameTitlePointer;
55
uint32 ObjectHelpTitleIndex;
56
uint32 ObjectHelpTitlePointer;
59
uint32 DefaultCounter;
64
PERF_COUNTER_DEFINITION *counters;
65
PERF_INSTANCE_DEFINITION *instances;
66
PERF_COUNTER_BLOCK counter_data;
70
/* PerfCounter Inner Buffer structs */
71
typedef struct perf_data_block
73
/* hardcoded to read "P.E.R.F" */
76
/* both currently hardcoded to 1 */
79
/* bytes of PERF_OBJECT_TYPE data, does NOT include the PERF_DATA_BLOCK */
80
uint32 TotalByteLength;
81
/* size of PERF_DATA_BLOCK including the uint8 *data */
83
/* number of PERF_OBJECT_TYPE structures encoded */
84
uint32 NumObjectTypes;
86
SYSTEMTIME SystemTime;
87
/* This will guarantee that we're on a 64-bit boundary before we encode
88
PerfTime, and having it there will make my offset math much easier. */
90
/* Now when I'm marshalling this, I'll need to call prs_align_uint64()
91
before I start encodint the UINT64_S structs */
92
/* clock rate * seconds uptime */
94
/* The clock rate of the CPU */
96
/* used for high-res timers -- for now PerfTime * 10e7 */
97
UINT64_S PerfTime100nSec;
98
uint32 SystemNameLength;
99
uint32 SystemNameOffset;
100
/* The SystemName, in unicode, terminated */
102
PERF_OBJECT_TYPE *objects;
106
#endif /* _RPC_PERFCOUNT_H */