ILGPU  0.9.0
ILGPU.Runtime.OpenCL.CLAccelerator Class Reference

Represents an OpenCL accelerator (CPU or GPU device). More...

Inheritance diagram for ILGPU.Runtime.OpenCL.CLAccelerator:
ILGPU.Runtime.KernelAccelerator< CLCompiledKernel, CLKernel >

Public Member Functions

 CLAccelerator (Context context, CLAcceleratorId acceleratorId)
 Constructs a new OpenCL accelerator. More...
 
override TExtension CreateExtension< TExtension, TExtensionProvider > (TExtensionProvider provider)
 

Public Attributes

IntPtr ContextPtr => contextPtr
 Returns the native OpenCL-context ptr. More...
 
new CLBackend Backend => base.Backend as CLBackend
 Returns the OpenCL backend of this accelerator. More...
 

Protected Member Functions

override MemoryBuffer< T, TIndex > AllocateInternal< T, TIndex > (TIndex extent)
 
override CLKernel CreateKernel (CLCompiledKernel compiledKernel)
 
override CLKernel CreateKernel (CLCompiledKernel compiledKernel, MethodInfo launcher)
 
override AcceleratorStream CreateStreamInternal ()
 
override void SynchronizeInternal ()
 
override void OnBind ()
 
override void OnUnbind ()
 
override bool CanAccessPeerInternal (Accelerator otherAccelerator)
 
override void EnablePeerAccessInternal (Accelerator otherAccelerator)
 
override void DisablePeerAccessInternal (Accelerator otherAccelerator)
 
override MethodInfo GenerateKernelLauncherMethod (CLCompiledKernel kernel, int customGroupSize)
 
override int EstimateMaxActiveGroupsPerMultiprocessorInternal (Kernel kernel, int groupSize, int dynamicSharedMemorySizeInBytes)
 
override int EstimateGroupSizeInternal (Kernel kernel, Func< int, int > computeSharedMemorySize, int maxGroupSize, out int minGridSize)
 
override int EstimateGroupSizeInternal (Kernel kernel, int dynamicSharedMemorySizeInBytes, int maxGroupSize, out int minGridSize)
 
override void Dispose (bool disposing)
 
- Protected Member Functions inherited from ILGPU.Runtime.KernelAccelerator< CLCompiledKernel, CLKernel >
 KernelAccelerator (Context context, AcceleratorType type)
 Constructs a new kernel accelerator. More...
 
sealed override Kernel LoadKernelInternal (CompiledKernel kernel)
 
sealed override Kernel LoadImplicitlyGroupedKernelInternal (CompiledKernel kernel, int customGroupSize, out KernelInfo kernelInfo)
 Loads an implicitly grouped kernel on the current accelerator. More...
 
sealed override Kernel LoadAutoGroupedKernelInternal (CompiledKernel kernel, out KernelInfo kernelInfo)
 Loads an auto grouped kernel on the current accelerator. More...
 
abstract MethodInfo GenerateKernelLauncherMethod (TCompiledKernel kernel, int customGroupSize)
 Generates a dynamic kernel-launcher method that will be just-in-time compiled during the first invocation. Using the generated launcher lowers the overhead for kernel launching dramatically, since unnecessary operations (like boxing) can be avoided. More...
 
abstract TKernel CreateKernel (TCompiledKernel compiledKernel)
 Creates an abstract kernel without an initialized launcher. More...
 
abstract TKernel CreateKernel (TCompiledKernel compiledKernel, MethodInfo launcher)
 Creates an abstract kernel with an initialized launcher. More...
 

Properties

static ImmutableArray< CLAcceleratorIdCLAccelerators [get]
 Represents the list of available and supported OpenCL accelerators. More...
 
static ImmutableArray< CLAcceleratorIdAllCLAccelerators [get]
 Represents the list of all available OpenCL accelerators. More...
 
IntPtr PlatformId [get]
 Returns the native OpenCL platform id. More...
 
string PlatformName [get]
 Returns the associated platform name. More...
 
string VendorName [get]
 Returns the associated vendor. More...
 
CLAcceleratorVendor Vendor [get]
 Returns the main accelerator vendor type. More...
 
IntPtr DeviceId [get]
 Returns the native OpenCL device id. More...
 
CLDeviceType DeviceType [get]
 Returns the OpenCL device type. More...
 
int ClockRate [get]
 Returns the clock rate. More...
 
CLCVersion CVersion [get]
 Returns the supported OpenCL C version. More...
 
bool SubGroupSupport [get]
 Returns true if this accelerator has sub-group support. More...
 

Detailed Description

Represents an OpenCL accelerator (CPU or GPU device).

Constructor & Destructor Documentation

ILGPU.Runtime.OpenCL.CLAccelerator.CLAccelerator ( Context  context,
CLAcceleratorId  acceleratorId 
)

Constructs a new OpenCL accelerator.

Parameters
contextThe ILGPU context.
acceleratorIdThe accelerator id.

Member Function Documentation

override MemoryBuffer<T, TIndex> ILGPU.Runtime.OpenCL.CLAccelerator.AllocateInternal< T, TIndex > ( TIndex  extent)
protected

override bool ILGPU.Runtime.OpenCL.CLAccelerator.CanAccessPeerInternal ( Accelerator  otherAccelerator)
protected

override TExtension ILGPU.Runtime.OpenCL.CLAccelerator.CreateExtension< TExtension, TExtensionProvider > ( TExtensionProvider  provider)
override CLKernel ILGPU.Runtime.OpenCL.CLAccelerator.CreateKernel ( CLCompiledKernel  compiledKernel)
protected
override CLKernel ILGPU.Runtime.OpenCL.CLAccelerator.CreateKernel ( CLCompiledKernel  compiledKernel,
MethodInfo  launcher 
)
protected
override AcceleratorStream ILGPU.Runtime.OpenCL.CLAccelerator.CreateStreamInternal ( )
protected

override void ILGPU.Runtime.OpenCL.CLAccelerator.DisablePeerAccessInternal ( Accelerator  otherAccelerator)
protected

override void ILGPU.Runtime.OpenCL.CLAccelerator.Dispose ( bool  disposing)
protected

override void ILGPU.Runtime.OpenCL.CLAccelerator.EnablePeerAccessInternal ( Accelerator  otherAccelerator)
protected

override int ILGPU.Runtime.OpenCL.CLAccelerator.EstimateGroupSizeInternal ( Kernel  kernel,
Func< int, int >  computeSharedMemorySize,
int  maxGroupSize,
out int  minGridSize 
)
protected
override int ILGPU.Runtime.OpenCL.CLAccelerator.EstimateGroupSizeInternal ( Kernel  kernel,
int  dynamicSharedMemorySizeInBytes,
int  maxGroupSize,
out int  minGridSize 
)
protected
override int ILGPU.Runtime.OpenCL.CLAccelerator.EstimateMaxActiveGroupsPerMultiprocessorInternal ( Kernel  kernel,
int  groupSize,
int  dynamicSharedMemorySizeInBytes 
)
protected
override MethodInfo ILGPU.Runtime.OpenCL.CLAccelerator.GenerateKernelLauncherMethod ( CLCompiledKernel  kernel,
int  customGroupSize 
)
protected
override void ILGPU.Runtime.OpenCL.CLAccelerator.OnBind ( )
protected

override void ILGPU.Runtime.OpenCL.CLAccelerator.OnUnbind ( )
protected

override void ILGPU.Runtime.OpenCL.CLAccelerator.SynchronizeInternal ( )
protected

Member Data Documentation

new CLBackend ILGPU.Runtime.OpenCL.CLAccelerator.Backend => base.Backend as CLBackend

Returns the OpenCL backend of this accelerator.

IntPtr ILGPU.Runtime.OpenCL.CLAccelerator.ContextPtr => contextPtr

Returns the native OpenCL-context ptr.

Property Documentation

ImmutableArray<CLAcceleratorId> ILGPU.Runtime.OpenCL.CLAccelerator.AllCLAccelerators
staticget

Represents the list of all available OpenCL accelerators.

ImmutableArray<CLAcceleratorId> ILGPU.Runtime.OpenCL.CLAccelerator.CLAccelerators
staticget

Represents the list of available and supported OpenCL accelerators.

int ILGPU.Runtime.OpenCL.CLAccelerator.ClockRate
get

Returns the clock rate.

CLCVersion ILGPU.Runtime.OpenCL.CLAccelerator.CVersion
get

Returns the supported OpenCL C version.

IntPtr ILGPU.Runtime.OpenCL.CLAccelerator.DeviceId
get

Returns the native OpenCL device id.

CLDeviceType ILGPU.Runtime.OpenCL.CLAccelerator.DeviceType
get

Returns the OpenCL device type.

IntPtr ILGPU.Runtime.OpenCL.CLAccelerator.PlatformId
get

Returns the native OpenCL platform id.

string ILGPU.Runtime.OpenCL.CLAccelerator.PlatformName
get

Returns the associated platform name.

bool ILGPU.Runtime.OpenCL.CLAccelerator.SubGroupSupport
get

Returns true if this accelerator has sub-group support.

CLAcceleratorVendor ILGPU.Runtime.OpenCL.CLAccelerator.Vendor
get

Returns the main accelerator vendor type.

string ILGPU.Runtime.OpenCL.CLAccelerator.VendorName
get

Returns the associated vendor.


The documentation for this class was generated from the following file: