• Intel® Graphics Performance Analyzers 2020 R1
  • 12/20/2019
  • Public Content
Contents

String Handle API

许多 API 调用需要标识 API 对象的名称。String handles(字符串句柄)是名称的指针。字符串句柄能够在运行时高效地处理命名的对象,并使收集的踪迹数据更加紧凑。
要创建并返回一个可与字符串关联的句柄值,请使用以下基元:
__itt_string_handle *ITTAPI __itt_string_handle_createA ( const char *name) __itt_string_handle *ITTAPI __itt_string_handle_createW ( const wchar_t *name)
或以如下方式使用宏:
__itt_string_handle *ITTAPI __itt_string_handle_create (__TEXT("My Task"))
用相同名称连续调用
__itt_string_handle_create
返回相同的值。字符串句柄集在应用程序执行期间预期会保持静态,因此,没有摧毁字符串句柄的机制。任何字符串句柄可以被进程中的任何线程访问,无论字符串句柄是哪个线程创建的。此调用是线程安全的。
基元参数:
[in]
name
输入字符串
 
 

Product and Performance Information

1

Intel's compilers may or may not optimize to the same degree for non-Intel microprocessors for optimizations that are not unique to Intel microprocessors. These optimizations include SSE2, SSE3, and SSSE3 instruction sets and other optimizations. Intel does not guarantee the availability, functionality, or effectiveness of any optimization on microprocessors not manufactured by Intel. Microprocessor-dependent optimizations in this product are intended for use with Intel microprocessors. Certain optimizations not specific to Intel microarchitecture are reserved for Intel microprocessors. Please refer to the applicable product User and Reference Guides for more information regarding the specific instruction sets covered by this notice.

Notice revision #20110804