%CUDADevice CUDA GPU device object
%   DEV = parallel.gpu.GPUDevice.getDevice(IDX) returns a CUDADevice
%   representing the device with index IDX.
%
%   DEV = parallel.gpu.GPUDevice.current() returns the currently selected
%   CUDADevice.
%
%   The CUDADevice has various properties describing the capabilities of the
%   underlying device.
%
%   parallel.gpu.CUDADevice methods:
%      reset - Reset GPU device
%      wait  - Wait for the GPU device to complete execution
%
%   parallel.gpu.CUDADevice properties:
%      Name                   - Name of the CUDA Device
%      Index                  - Index of the CUDA Device
%      ComputeCapability      - CUDA Compute Capability
%      SupportsDouble         - Does the device support double precision data
%      DriverVersion          - the CUDA driver version
%      ToolkitVersion         - the CUDA toolkit version
%      MaxThreadsPerBlock     - maximum supported thread block size
%      MaxShmemPerBlock       - maximum amount of shared memory per block
%      MaxThreadBlockSize     - maximum size in each dimension for thread block
%      MaxGridSize            - maximum size of grid of thread blocks
%      SIMDWidth              - number of simultaneously executing threads
%      TotalMemory            - total available memory in bytes on the device
%      AvailableMemory        - available memory in bytes on the device
%      MultiprocessorCount    - the number of vector processors present
%      ClockRateKHz           - the peak clock rate of the GPU in KHz
%      ComputeMode            - the compute mode of the device
%      GPUOverlapsTransfers   - whether the device supports overlapped transfers
%      KernelExecutionTimeout - if true, the device may abort long-running kernels
%      CanMapHostMemory       - if true, the device supports mapping host memory into the
%      DeviceSupported        - can this device be used
%      DeviceSelected         - is this the currently selected device
%
%   See also parallel.gpu.GPUDevice, gpuDevice, gpuDeviceCount.

%   Copyright 2010-2014 The MathWorks, Inc.

%{
properties
    % Name - Name of the CUDA Device
    Name;

    % Index - Index of the CUDA Device
    %   This is the index by which the device can be selected
    Index;

    % ComputeCapability - CUDA Compute Capability
    %   This indicates the computational capability of the device
    ComputeCapability;

    % SupportsDouble - Does the device support double precision data
    %   True for devices which can support double precision operations
    SupportsDouble;

    % DriverVersion - the CUDA driver version
    %   The CUDA device driver version currently in use
    DriverVersion;

    % ToolkitVersion - the CUDA toolkit version
    %   The CUDA toolkit version currently in use
    ToolkitVersion;

    % MaxThreadsPerBlock - maximum supported thread block size
    %   This is the maximum number of threads per block during
    %   CUDAKernel execution
    MaxThreadsPerBlock;

    % MaxShmemPerBlock - maximum amount of shared memory per block
    %   The maximum amount of shared memory that can be used by
    %   a thread block during CUDAKernel execution
    MaxShmemPerBlock;

    % MaxThreadBlockSize - maximum size in each dimension for thread block
    %   Each dimension of a thread block must not exceed these
    %   dimensions. Additionally, the product of the thread block size must
    %   not exceed MaxThreadsPerBlock.
    MaxThreadBlockSize;

    % MaxGridSize - maximum size of grid of thread blocks
    MaxGridSize;

    % SIMDWidth - number of simultaneously executing threads
    SIMDWidth;

    % TotalMemory - total available memory in bytes on the device
    TotalMemory;

    % AvailableMemory - available memory in bytes on the device
    %   The total amount of memory available for data is guaranteed to
    %   be at least as large as this property.  This property is
    %   available only for the currently selected device, and has the
    %   value NaN for unselected devices.
    AvailableMemory;

    % MultiprocessorCount - the number of vector processors present
    MultiprocessorCount;

    % ClockRateKHz - the peak clock rate of the GPU in KHz
    ClockRateKHz;

    % ComputeMode - the compute mode of the device
    %
    %   'Default' - The device is not restricted and can be used by
    %   multiple applications simultaneously. MATLAB can share the
    %   device with other applications, including other MATLAB sessions
    %   or workers.
    %
    %   'Exclusive thread' or 'Exclusive process' - The device can be
    %   used by only one application at a time. While the device is
    %   selected in MATLAB, it cannot be used by other applications,
    %   including other MATLAB sessions or workers.
    %
    %   'Prohibited' - The device cannot be used.
    ComputeMode;

    % GPUOverlapsTransfers - whether the device supports overlapped transfers
    GPUOverlapsTransfers;

    % KernelExecutionTimeout - if true, the device may abort long-running kernels
    KernelExecutionTimeout;

    % CanMapHostMemory - if true, the device supports mapping host memory into the
    % CUDA address space
    CanMapHostMemory;

    % DeviceSupported - can this device be used
    %   Not all devices are supported, for example if their ComputeCapability
    %   is insufficient.
    DeviceSupported;

    % DeviceSelected - is this the currently selected device
    DeviceSelected;
end
%}
