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.

64 lines
1.5 KiB

  1. /*++
  2. Copyright (c) 1992 Microsoft Corporation
  3. Module Name:
  4. stktrace.h
  5. Abstract:
  6. This header file defines the format of the stack trace data base
  7. used to track caller backtraces. This is a header file so debugger
  8. extensions can lookup entries in the database remotely.
  9. Author:
  10. Steve Wood (stevewo) 13-Sep-1992
  11. Revision History:
  12. --*/
  13. #ifndef _STKTRACE_H_
  14. #define _STKTRACE_H_
  15. typedef struct _RTL_STACK_TRACE_ENTRY {
  16. struct _RTL_STACK_TRACE_ENTRY *HashChain;
  17. ULONG TraceCount;
  18. USHORT Index;
  19. USHORT Depth;
  20. PVOID BackTrace[ MAX_STACK_DEPTH ];
  21. } RTL_STACK_TRACE_ENTRY, *PRTL_STACK_TRACE_ENTRY;
  22. typedef struct _STACK_TRACE_DATABASE {
  23. union {
  24. RTL_CRITICAL_SECTION CriticalSection;
  25. ERESOURCE Resource;
  26. } Lock;
  27. PRTL_ACQUIRE_LOCK_ROUTINE AcquireLockRoutine;
  28. PRTL_RELEASE_LOCK_ROUTINE ReleaseLockRoutine;
  29. PRTL_OKAY_TO_LOCK_ROUTINE OkayToLockRoutine;
  30. BOOLEAN PreCommitted;
  31. BOOLEAN DumpInProgress;
  32. PVOID CommitBase;
  33. PVOID CurrentLowerCommitLimit;
  34. PVOID CurrentUpperCommitLimit;
  35. PCHAR NextFreeLowerMemory;
  36. PCHAR NextFreeUpperMemory;
  37. ULONG NumberOfEntriesLookedUp;
  38. ULONG NumberOfEntriesAdded;
  39. PRTL_STACK_TRACE_ENTRY *EntryIndexArray; // Indexed by [-1 .. -NumberOfEntriesAdded]
  40. ULONG NumberOfBuckets;
  41. PRTL_STACK_TRACE_ENTRY Buckets[ 1 ];
  42. } STACK_TRACE_DATABASE, *PSTACK_TRACE_DATABASE;
  43. PSTACK_TRACE_DATABASE
  44. RtlpAcquireStackTraceDataBase( VOID );
  45. VOID
  46. RtlpReleaseStackTraceDataBase( VOID );
  47. #endif // _STKTRACE_H_