59 lines
1.7 KiB
C
59 lines
1.7 KiB
C
/*
|
|
* Copyright (C) 2017 Austin English
|
|
*
|
|
* This library is free software; you can redistribute it and/or
|
|
* modify it under the terms of the GNU Lesser General Public
|
|
* License as published by the Free Software Foundation; either
|
|
* version 2.1 of the License, or (at your option) any later version.
|
|
*
|
|
* This library is distributed in the hope that it will be useful,
|
|
* but WITHOUT ANY WARRANTY; without even the implied warranty of
|
|
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
|
|
* Lesser General Public License for more details.
|
|
*
|
|
* You should have received a copy of the GNU Lesser General Public
|
|
* License along with this library; if not, write to the Free Software
|
|
* Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA
|
|
*/
|
|
|
|
#ifndef _PERFLIB_H_
|
|
#define _PERFLIB_H_
|
|
|
|
#ifdef __cplusplus
|
|
extern "C" {
|
|
#endif
|
|
|
|
typedef LPVOID (CDECL * PERF_MEM_ALLOC)(SIZE_T,LPVOID);
|
|
typedef void (CDECL * PERF_MEM_FREE)(LPVOID,LPVOID);
|
|
typedef ULONG (WINAPI * PERFLIBREQUEST)(ULONG,PVOID,ULONG);
|
|
|
|
typedef struct _PERF_COUNTERSET_INFO {
|
|
GUID CounterSetGuid;
|
|
GUID ProviderGuid;
|
|
ULONG NumCounters;
|
|
ULONG InstanceType;
|
|
} PERF_COUNTERSET_INFO, * PPERF_COUNTERSET_INFO;
|
|
|
|
typedef struct _PERF_COUNTERSET_INSTANCE {
|
|
GUID CounterSetGuid;
|
|
ULONG dwSize;
|
|
ULONG InstanceId;
|
|
ULONG InstanceNameOffset;
|
|
ULONG InstanceNameSize;
|
|
} PERF_COUNTERSET_INSTANCE, * PPERF_COUNTERSET_INSTANCE;
|
|
|
|
typedef struct _PROVIDER_CONTEXT {
|
|
DWORD ContextSize;
|
|
DWORD Reserved;
|
|
PERFLIBREQUEST ControlCallback;
|
|
PERF_MEM_ALLOC MemAllocRoutine;
|
|
PERF_MEM_FREE MemFreeRoutine;
|
|
LPVOID pMemContext;
|
|
} PERF_PROVIDER_CONTEXT, * PPERF_PROVIDER_CONTEXT;
|
|
|
|
#ifdef __cplusplus
|
|
} /* extern "C" */
|
|
#endif
|
|
|
|
#endif /* _PERFLIB_H_ */
|