opencv on mbed

Dependencies:   mbed

Embed: (wiki syntax)

« Back to documentation index

DeviceInfo Class Reference

Class providing functionality for querying the specified GPU properties. More...

#include <cuda.hpp>

Public Types

enum  ComputeMode { ComputeModeDefault, ComputeModeExclusive, ComputeModeProhibited, ComputeModeExclusiveProcess }

Public Member Functions

 DeviceInfo ()
 creates DeviceInfo object for the current GPU
 DeviceInfo (int device_id)
 The constructors.
int deviceID () const
 Returns system index of the CUDA device starting with 0.
const char * name () const
 ASCII string identifying device.
size_t totalGlobalMem () const
 global memory available on device in bytes
size_t sharedMemPerBlock () const
 shared memory available per block in bytes
int regsPerBlock () const
 32-bit registers available per block
int warpSize () const
 warp size in threads
size_t memPitch () const
 maximum pitch in bytes allowed by memory copies
int maxThreadsPerBlock () const
 maximum number of threads per block
Vec3i maxThreadsDim () const
 maximum size of each dimension of a block
Vec3i maxGridSize () const
 maximum size of each dimension of a grid
int clockRate () const
 clock frequency in kilohertz
size_t totalConstMem () const
 constant memory available on device in bytes
int majorVersion () const
 major compute capability
int minorVersion () const
 minor compute capability
size_t textureAlignment () const
 alignment requirement for textures
size_t texturePitchAlignment () const
 pitch alignment requirement for texture references bound to pitched memory
int multiProcessorCount () const
 number of multiprocessors on device
bool kernelExecTimeoutEnabled () const
 specified whether there is a run time limit on kernels
bool integrated () const
 device is integrated as opposed to discrete
bool canMapHostMemory () const
 device can map host memory with cudaHostAlloc/cudaHostGetDevicePointer
ComputeMode computeMode () const
 compute mode
int maxTexture1D () const
 maximum 1D texture size
int maxTexture1DMipmap () const
 maximum 1D mipmapped texture size
int maxTexture1DLinear () const
 maximum size for 1D textures bound to linear memory
Vec2i maxTexture2D () const
 maximum 2D texture dimensions
Vec2i maxTexture2DMipmap () const
 maximum 2D mipmapped texture dimensions
Vec3i maxTexture2DLinear () const
 maximum dimensions (width, height, pitch) for 2D textures bound to pitched memory
Vec2i maxTexture2DGather () const
 maximum 2D texture dimensions if texture gather operations have to be performed
Vec3i maxTexture3D () const
 maximum 3D texture dimensions
int maxTextureCubemap () const
 maximum Cubemap texture dimensions
Vec2i maxTexture1DLayered () const
 maximum 1D layered texture dimensions
Vec3i maxTexture2DLayered () const
 maximum 2D layered texture dimensions
Vec2i maxTextureCubemapLayered () const
 maximum Cubemap layered texture dimensions
int maxSurface1D () const
 maximum 1D surface size
Vec2i maxSurface2D () const
 maximum 2D surface dimensions
Vec3i maxSurface3D () const
 maximum 3D surface dimensions
Vec2i maxSurface1DLayered () const
 maximum 1D layered surface dimensions
Vec3i maxSurface2DLayered () const
 maximum 2D layered surface dimensions
int maxSurfaceCubemap () const
 maximum Cubemap surface dimensions
Vec2i maxSurfaceCubemapLayered () const
 maximum Cubemap layered surface dimensions
size_t surfaceAlignment () const
 alignment requirements for surfaces
bool concurrentKernels () const
 device can possibly execute multiple kernels concurrently
bool ECCEnabled () const
 device has ECC support enabled
int pciBusID () const
 PCI bus ID of the device.
int pciDeviceID () const
 PCI device ID of the device.
int pciDomainID () const
 PCI domain ID of the device.
bool tccDriver () const
 true if device is a Tesla device using TCC driver, false otherwise
int asyncEngineCount () const
 number of asynchronous engines
bool unifiedAddressing () const
 device shares a unified address space with the host
int memoryClockRate () const
 peak memory clock frequency in kilohertz
int memoryBusWidth () const
 global memory bus width in bits
int l2CacheSize () const
 size of L2 cache in bytes
int maxThreadsPerMultiProcessor () const
 maximum resident threads per multiprocessor
void queryMemory (size_t &totalMemory, size_t &freeMemory) const
 gets free and total device memory
bool supports (FeatureSet feature_set) const
 Provides information on CUDA feature support.
bool isCompatible () const
 Checks the CUDA module and device compatibility.

Detailed Description

Class providing functionality for querying the specified GPU properties.

Definition at line 629 of file core/cuda.hpp.


Member Enumeration Documentation

Enumerator:
ComputeModeDefault 

default compute mode (Multiple threads can use cudaSetDevice with this device)

ComputeModeExclusive 

compute-exclusive-thread mode (Only one thread in one process will be able to use cudaSetDevice with this device)

ComputeModeProhibited 

compute-prohibited mode (No threads can use cudaSetDevice with this device)

ComputeModeExclusiveProcess 

compute-exclusive-process mode (Many threads in one process will be able to use cudaSetDevice with this device)

Definition at line 705 of file core/cuda.hpp.


Constructor & Destructor Documentation

DeviceInfo (  )

creates DeviceInfo object for the current GPU

DeviceInfo ( int  device_id )

The constructors.

Parameters:
device_idSystem index of the CUDA device starting with 0.

Constructs the DeviceInfo object for the specified device. If device_id parameter is missed, it constructs an object for the current device.


Member Function Documentation

int asyncEngineCount (  ) const

number of asynchronous engines

bool canMapHostMemory (  ) const

device can map host memory with cudaHostAlloc/cudaHostGetDevicePointer

int clockRate (  ) const

clock frequency in kilohertz

ComputeMode computeMode (  ) const

compute mode

bool concurrentKernels (  ) const

device can possibly execute multiple kernels concurrently

int deviceID (  ) const

Returns system index of the CUDA device starting with 0.

bool ECCEnabled (  ) const

device has ECC support enabled

bool integrated (  ) const

device is integrated as opposed to discrete

bool isCompatible (  ) const

Checks the CUDA module and device compatibility.

This function returns true if the CUDA module can be run on the specified device. Otherwise, it returns false .

bool kernelExecTimeoutEnabled (  ) const

specified whether there is a run time limit on kernels

int l2CacheSize (  ) const

size of L2 cache in bytes

int majorVersion (  ) const

major compute capability

Vec3i maxGridSize (  ) const

maximum size of each dimension of a grid

int maxSurface1D (  ) const

maximum 1D surface size

Vec2i maxSurface1DLayered (  ) const

maximum 1D layered surface dimensions

Vec2i maxSurface2D (  ) const

maximum 2D surface dimensions

Vec3i maxSurface2DLayered (  ) const

maximum 2D layered surface dimensions

Vec3i maxSurface3D (  ) const

maximum 3D surface dimensions

int maxSurfaceCubemap (  ) const

maximum Cubemap surface dimensions

Vec2i maxSurfaceCubemapLayered (  ) const

maximum Cubemap layered surface dimensions

int maxTexture1D (  ) const

maximum 1D texture size

Vec2i maxTexture1DLayered (  ) const

maximum 1D layered texture dimensions

int maxTexture1DLinear (  ) const

maximum size for 1D textures bound to linear memory

int maxTexture1DMipmap (  ) const

maximum 1D mipmapped texture size

Vec2i maxTexture2D (  ) const

maximum 2D texture dimensions

Vec2i maxTexture2DGather (  ) const

maximum 2D texture dimensions if texture gather operations have to be performed

Vec3i maxTexture2DLayered (  ) const

maximum 2D layered texture dimensions

Vec3i maxTexture2DLinear (  ) const

maximum dimensions (width, height, pitch) for 2D textures bound to pitched memory

Vec2i maxTexture2DMipmap (  ) const

maximum 2D mipmapped texture dimensions

Vec3i maxTexture3D (  ) const

maximum 3D texture dimensions

int maxTextureCubemap (  ) const

maximum Cubemap texture dimensions

Vec2i maxTextureCubemapLayered (  ) const

maximum Cubemap layered texture dimensions

Vec3i maxThreadsDim (  ) const

maximum size of each dimension of a block

int maxThreadsPerBlock (  ) const

maximum number of threads per block

int maxThreadsPerMultiProcessor (  ) const

maximum resident threads per multiprocessor

int memoryBusWidth (  ) const

global memory bus width in bits

int memoryClockRate (  ) const

peak memory clock frequency in kilohertz

size_t memPitch (  ) const

maximum pitch in bytes allowed by memory copies

int minorVersion (  ) const

minor compute capability

int multiProcessorCount (  ) const

number of multiprocessors on device

const char* name (  ) const

ASCII string identifying device.

int pciBusID (  ) const

PCI bus ID of the device.

int pciDeviceID (  ) const

PCI device ID of the device.

int pciDomainID (  ) const

PCI domain ID of the device.

void queryMemory ( size_t &  totalMemory,
size_t &  freeMemory 
) const

gets free and total device memory

int regsPerBlock (  ) const

32-bit registers available per block

size_t sharedMemPerBlock (  ) const

shared memory available per block in bytes

bool supports ( FeatureSet  feature_set ) const

Provides information on CUDA feature support.

Parameters:
feature_setFeatures to be checked. See cuda::FeatureSet.

This function returns true if the device has the specified CUDA feature. Otherwise, it returns false

size_t surfaceAlignment (  ) const

alignment requirements for surfaces

bool tccDriver (  ) const

true if device is a Tesla device using TCC driver, false otherwise

size_t textureAlignment (  ) const

alignment requirement for textures

size_t texturePitchAlignment (  ) const

pitch alignment requirement for texture references bound to pitched memory

size_t totalConstMem (  ) const

constant memory available on device in bytes

size_t totalGlobalMem (  ) const

global memory available on device in bytes

bool unifiedAddressing (  ) const

device shares a unified address space with the host

int warpSize (  ) const

warp size in threads