SetXStateFeaturesMask function

Sets the mask of XState features set within a CONTEXT structure.

Syntax


BOOL WINAPI SetXStateFeaturesMask(
  _Inout_  PCONTEXT Context,
  _In_     DWORD64 FeatureMask
);

Parameters

Context [in, out]

A pointer to a CONTEXT structure that has been initialized with InitializeContext.

FeatureMask [in]

A mask of XState features to set in the specified CONTEXT structure.

Return value

This function returns TRUE if successful, otherwise FALSE.

Remarks

The SetXStateFeaturesMask function sets the mask of valid features in the specified context. Before calling GetThreadContext, Wow64GetThreadContext, SetThreadContext, or Wow64SetThreadContext the application must call SetXStateFeaturesMask to specify which set of features to retrieve or set. The system silently ignores any feature specified in the FeatureMask which is not enabled on the processor.

Windows 7 with SP1 and Windows Server 2008 R2 with SP1:  The AVX API is first implemented on Windows 7 with SP1 and Windows Server 2008 R2 with SP1 . Since there is no SDK for SP1, that means there are no available headers and library files to work with. In this situation, a caller must declare the needed functions from this documentation and get pointers to them using GetModuleHandle on "Kernel32.dll", followed by calls to GetProcAddress. See Working with XState Context for details.

Requirements

Minimum supported client

Windows 7 with SP1 [desktop apps only]

Minimum supported server

Windows Server 2008 R2 with SP1 [desktop apps only]

Header

WinBase.h (include Windows.h)

Library

Kernel32.lib

DLL

Kernel32.dll

See also

CONTEXT
Intel AVX
Working with XState Context
GetThreadContext
SetThreadContext
Wow64GetThreadContext
Wow64SetThreadContext

 

 

Community Additions

ADD
Show:
© 2014 Microsoft