Library/ManagedCuda/PrimaryContext.cs
/// <summary>
/// Set flags for the primary context<para/>
/// Sets the flags for the primary context on the device overwriting perviously
/// set ones. If the primary context is already created
/// ::CUDA_ERROR_PRIMARY_CONTEXT_ACTIVE is returned.
/// <para/>
///	The three LSBs of the \p flags parameter can be used to control how the OS
///	thread, which owns the CUDA context at the time of an API call, interacts
///	with the OS scheduler when waiting for results from the GPU. Only one of
///	the scheduling flags can be set when creating a context.
/// </summary>
/// <param name="device">Device for which the primary context flags are set</param>
/// <param name="flags">New flags for the device</param>
Set flags for the primary context
Sets the flags for the primary context on the device overwriting perviously
set ones. If the primary context is already created
::CUDA_ERROR_PRIMARY_CONTEXT_ACTIVE is returned.

The three LSBs of the \p flags parameter can be used to control how the OS
thread, which owns the CUDA context at the time of an API call, interacts
with the OS scheduler when waiting for results from the GPU. Only one of
the scheduling flags can be set when creating a context.
Set flags for the primary context Sets the flags for the primary context on the device overwriting perviously set ones . If the primary context is already created :: CUDA_ERROR_PRIMARY_CONTEXT_ACTIVE is returned . The three LSBs of the \ p flags parameter can be used to control how the OS thread which owns the CUDA context at the time of an API call interacts with the OS scheduler when waiting for results from the GPU . Only one of the scheduling flags can be set when creating a context .
public static void SetFlags(CUdevice device, CUCtxFlags flags)
		{
			CUResult res;
			res = DriverAPINativeMethods.ContextManagement.cuDevicePrimaryCtxSetFlags(device, flags);
			Debug.WriteLine(String.Format("{0:G}, {1}: {2}", DateTime.Now, "cuDevicePrimaryCtxSetFlags", res));
			if (res != CUResult.Success)
				throw new CudaException(res);
		}
public static void SetFlags ( CUdevice device , CUCtxFlags flags ) { CUResult res ; res = DriverAPINativeMethods . ContextManagement . cuDevicePrimaryCtxSetFlags ( device , flags ) ; Debug . WriteLine ( String . Format ( " " , DateTime . Now , " " , res ) ) ; if ( res != CUResult . Success ) throw new CudaException ( res ) ; }
Set flags for the primary context
Sets the flags for the primary context on the device overwriting perviously
set ones.
Set flags for the primary context Sets the flags for the primary context on the device overwriting perviously set ones .
device
CUdevice
Device for which the primary context flags are set
Device for which the primary context flags are set
flags
CUCtxFlags
New flags for the device
New flags for the device