mirror of
https://github.com/mirror/processhacker
synced 2026-06-08 16:03:24 +00:00
f4009aaa4a
* no longer uses RtlQueryProcessDebugInformation to get WOW64 modules * renamed header guards * updated CHANGELOG.txt git-svn-id: svn://svn.code.sf.net/p/processhacker/code@3436 21ef857c-d57f-4fe0-8362-d861dc6d29cd
129 lines
2.5 KiB
C
129 lines
2.5 KiB
C
#ifndef _NTKEAPI_H
|
|
#define _NTKEAPI_H
|
|
|
|
typedef enum _KTHREAD_STATE
|
|
{
|
|
Initialized,
|
|
Ready,
|
|
Running,
|
|
Standby,
|
|
Terminated,
|
|
Waiting,
|
|
Transition,
|
|
DeferredReady,
|
|
GateWait,
|
|
MaximumThreadState
|
|
} KTHREAD_STATE, *PKTHREAD_STATE;
|
|
|
|
typedef enum _KWAIT_REASON
|
|
{
|
|
Executive = 0,
|
|
FreePage = 1,
|
|
PageIn = 2,
|
|
PoolAllocation = 3,
|
|
DelayExecution = 4,
|
|
Suspended = 5,
|
|
UserRequest = 6,
|
|
WrExecutive = 7,
|
|
WrFreePage = 8,
|
|
WrPageIn = 9,
|
|
WrPoolAllocation = 10,
|
|
WrDelayExecution = 11,
|
|
WrSuspended = 12,
|
|
WrUserRequest = 13,
|
|
WrEventPair = 14,
|
|
WrQueue = 15,
|
|
WrLpcReceive = 16,
|
|
WrLpcReply = 17,
|
|
WrVirtualMemory = 18,
|
|
WrPageOut = 19,
|
|
WrRendezvous = 20,
|
|
Spare2 = 21,
|
|
Spare3 = 22,
|
|
Spare4 = 23,
|
|
Spare5 = 24,
|
|
WrCalloutStack = 25,
|
|
WrKernel = 26,
|
|
WrResource = 27,
|
|
WrPushLock = 28,
|
|
WrMutex = 29,
|
|
WrQuantumEnd = 30,
|
|
WrDispatchInt = 31,
|
|
WrPreempted = 32,
|
|
WrYieldExecution = 33,
|
|
WrFastMutex = 34,
|
|
WrGuardedMutex = 35,
|
|
WrRundown = 36,
|
|
MaximumWaitReason = 37
|
|
} KWAIT_REASON, *PKWAIT_REASON;
|
|
|
|
typedef enum _KPROFILE_SOURCE
|
|
{
|
|
ProfileTime,
|
|
ProfileAlignmentFixup,
|
|
ProfileTotalIssues,
|
|
ProfilePipelineDry,
|
|
ProfileLoadInstructions,
|
|
ProfilePipelineFrozen,
|
|
ProfileBranchInstructions,
|
|
ProfileTotalNonissues,
|
|
ProfileDcacheMisses,
|
|
ProfileIcacheMisses,
|
|
ProfileCacheMisses,
|
|
ProfileBranchMispredictions,
|
|
ProfileStoreInstructions,
|
|
ProfileFpInstructions,
|
|
ProfileIntegerInstructions,
|
|
Profile2Issue,
|
|
Profile3Issue,
|
|
Profile4Issue,
|
|
ProfileSpecialInstructions,
|
|
ProfileTotalCycles,
|
|
ProfileIcacheIssues,
|
|
ProfileDcacheAccesses,
|
|
ProfileMemoryBarrierCycles,
|
|
ProfileLoadLinkedIssues,
|
|
ProfileMaximum
|
|
} KPROFILE_SOURCE;
|
|
|
|
NTSYSCALLAPI
|
|
NTSTATUS
|
|
NTAPI
|
|
NtCallbackReturn(
|
|
__in_bcount_opt(OutputLength) PVOID OutputBuffer,
|
|
__in ULONG OutputLength,
|
|
__in NTSTATUS Status
|
|
);
|
|
|
|
NTSYSCALLAPI
|
|
NTSTATUS
|
|
NTAPI
|
|
NtQueryDebugFilterState(
|
|
__in ULONG ComponentId,
|
|
__in ULONG Level
|
|
);
|
|
|
|
NTSYSCALLAPI
|
|
NTSTATUS
|
|
NTAPI
|
|
NtSetDebugFilterState(
|
|
__in ULONG ComponentId,
|
|
__in ULONG Level,
|
|
__in BOOLEAN State
|
|
);
|
|
|
|
NTSYSCALLAPI
|
|
NTSTATUS
|
|
NTAPI
|
|
NtYieldExecution();
|
|
|
|
#if (PHNT_VERSION >= PHNT_VISTA)
|
|
// winnt:FlushProcessWriteBuffers
|
|
NTSYSCALLAPI
|
|
VOID
|
|
NTAPI
|
|
NtFlushProcessWriteBuffers();
|
|
#endif
|
|
|
|
#endif
|