Team Fortress 2 Source Code as on 22/4/2020
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.

115 lines
3.4 KiB

  1. //========= Copyright Valve Corporation, All rights reserved. ============//
  2. //
  3. // Purpose:
  4. //
  5. // $NoKeywords: $
  6. //
  7. //=============================================================================//
  8. /**
  9. *** Copyright (C) 1999-2001 Intel Corporation. All rights reserved.
  10. ***
  11. *** The information and source code contained herein is the exclusive
  12. *** property of Intel Corporation and may not be disclosed, examined
  13. *** or reproduced in whole or in part without explicit written authorization
  14. *** from the company.
  15. **/
  16. /*********************************************************************************
  17. * vtuneapi.h 03-21-2001
  18. * Intel Corporation
  19. *
  20. * This header file describes VTune api's which are exported by vtuneapi.dll.
  21. *
  22. * To use these api's, include this header file and either link with vtuneapi.lib or load
  23. * vtuneapi.dll at runtime.
  24. *
  25. * VTune API's
  26. * -----------
  27. *
  28. * VOID VTPause(void) and VOID VTResume(void)
  29. *
  30. * VTPause and VTResume pause or resume data collection during a VTune Sampling, Counter Monitor, or Callgraph activity.
  31. *
  32. * If VTPause is called while a VTune Sampling collection is active, a flag is set which
  33. * suspends collection of PC samples on the current machine. Collection of PC samples
  34. * can be resumed by calling VTResume which clears the flag. The overhead to set and clear the flag
  35. * is very low, so the VTPause and VTResume can be called at a high frequency.
  36. *
  37. * If VTPause is called while a VTune Callgraph collection is active, Callgraph data collection
  38. * is paused for the current process. Callgraph data collection for the current process can
  39. * be resumed by calling VTResume.
  40. *
  41. * If VTPause is called while a VTune Counter Monitor collection is active, Counter Monitor data collection
  42. * is paused. Counter Monitor data collection can be resumed by calling VTResume.
  43. *
  44. * VTPause and VTResume can be safely called when the Sampling, Counter Monitor, and Callgraph collectors are not active.
  45. * In this case, the VTPause and VTResume do nothing.
  46. *
  47. * Note:
  48. *
  49. * VTune Sampling, Counter Monitor, and Callgraph activities are typically started with the VTune application.
  50. * The VTune GUI allows Sampling, Counter Monitor, and Callgraph activities to be started in "Pause" mode
  51. * which suspends data collection until a VTResume is called.
  52. * Data collection can also be paused and resumed by the Pause/Resume button in the VTune GUI.
  53. * See VTune onlilne help for more details.
  54. *
  55. \*********************************************************************************/
  56. #ifndef _VTUNEAPI_H_
  57. #define _VTUNEAPI_H_
  58. #ifndef _XBOX
  59. #include <windows.h>
  60. #else
  61. #include <XTL.h>
  62. #endif //!_XBOX
  63. #ifdef _XBOX
  64. #define VTUNEAPI
  65. #elif !defined(_VTUNEAPI_)
  66. #define VTUNEAPI __declspec(dllimport)
  67. #else
  68. #define VTUNEAPI __declspec(dllexport)
  69. #endif
  70. #define VTUNEAPICALL __cdecl
  71. #ifdef __cplusplus
  72. extern "C" {
  73. #endif // __cplusplus
  74. //
  75. // Pause and Resume data collection during VTune PC Sampling and Callgraph sessions.
  76. // The VTPause and VTResume api's effect
  77. // both VTune PC Sampling and VTune Callgraph
  78. //
  79. VTUNEAPI
  80. VOID VTUNEAPICALL VTPause(void);
  81. VTUNEAPI
  82. VOID VTUNEAPICALL VTResume(void);
  83. //Preserve VtPauseSampling and VtResumeSampling for backward compatibility...
  84. VTUNEAPI
  85. void VTUNEAPICALL VTPauseSampling(void);
  86. VTUNEAPI
  87. void VTUNEAPICALL VTResumeSampling(void);
  88. VTUNEAPI
  89. void VTUNEAPICALL CMPause(void);
  90. VTUNEAPI
  91. void VTUNEAPICALL CMResume(void);
  92. #ifdef __cplusplus
  93. }
  94. #endif // __cplusplus
  95. #endif // _VTUNEAPI_H_