Developer Reference for Intel® oneAPI Math Kernel Library for C

ID 766684
Date 11/07/2023
Public

A newer version of this document is available. Customers should click here to go to the newest version.

Document Table of Contents

MKLFreeTls

Frees allocated VM/VS thread local storage memory from within DllMain routine. Use on Windows* OS only.

Syntax

void MKLFreeTls( const MKL_UINT fdwReason );

Include Files

  • mkl_vml_functions_win.h

Description

The MKLFreeTls routine frees thread local storage (TLS) memory which has been allocated when using MKL static libraries to link into a DLL on the Windows* OS. The routine should only be used within DllMain.

NOTE:

It is only necessary to use MKLFreeTls for TLS data in the VM and VS domains.

Input Parameters

Name

Type

Description

fdwReason

const MKL_UINT

Reason code from the DllMain call.

Example

BOOL WINAPI DllMain(HINSTANCE hInst, DWORD fdwReason, LPVOID lpvReserved)
{
    /*customer code*/
    MKLFreeTls(fdwReason);
    /*customer code*/
}