public class INTELAccelerator
extends java.lang.Object
The accelerator extension consists of a unified set of OpenCL runtime APIs to create, query, and manage the lifetime of objects which represent
acceleration processors, engines, or algorithms. Accelerator object instances are referenced with the generic cl_accelerator_intel type by the runtime
API, but they are always associated with a specific acceleration engine type, which is assigned by the application at accelerator object creation time.
Descriptors are used to assign acceleration engine-specific properties to the accelerator objects. This mechanism of specialized creation with generic
referencing is analogous to the way image objects are managed in the OpenCL 1.2 runtime API via generic cl_mem referencing but specialized
descriptor-based creation with CreateImage.
Each accelerator object is assigned a unique type id. Vendors are freely encouraged to define new accelerator types and ids. This base extension provides unified mechanism for the creation and lifetime management of new accelerator types, but the semantics and creation descriptors of these types are to be defined in acceleration engine-specific extensions.
Accelerator objects can be supplied to kernels as arguments. Unless an extension defines a new OpenCL C language type for the engine-specific accelerator (e.g. sampler_t), accelerator objects can only be used in conjunction with built-in kernels. If an extension does define such a new type, or if it provides a mechanism to access accelerator data within kernels, then accelerator objects can act as regular kernel arguments as well.
Requires CL12.
| Modifier and Type | Field and Description |
|---|---|
static int |
CL_ACCELERATOR_CONTEXT_INTEL
Possible values for cl_accelerator_info_intel.
|
static int |
CL_ACCELERATOR_DESCRIPTOR_INTEL
Possible values for cl_accelerator_info_intel.
|
static int |
CL_ACCELERATOR_REFERENCE_COUNT_INTEL
Possible values for cl_accelerator_info_intel.
|
static int |
CL_ACCELERATOR_TYPE_INTEL
Possible values for cl_accelerator_info_intel.
|
static int |
CL_ACCELERATOR_TYPE_NOT_SUPPORTED_INTEL
Error codes used by functions in this extension.
|
static int |
CL_INVALID_ACCELERATOR_DESCRIPTOR_INTEL
Error codes used by functions in this extension.
|
static int |
CL_INVALID_ACCELERATOR_INTEL
Error codes used by functions in this extension.
|
static int |
CL_INVALID_ACCELERATOR_TYPE_INTEL
Error codes used by functions in this extension.
|
| Modifier and Type | Method and Description |
|---|---|
static long |
clCreateAcceleratorINTEL(long context,
int accelerator_type,
java.nio.ByteBuffer descriptor,
int[] errcode_ret)
Array version of:
CreateAcceleratorINTEL |
static long |
clCreateAcceleratorINTEL(long context,
int accelerator_type,
java.nio.ByteBuffer descriptor,
java.nio.IntBuffer errcode_ret)
Accelerator objects represent the programmable state of an acceleration processor, engine, or algorithm.
|
static int |
clGetAcceleratorInfoINTEL(long accelerator,
int param_name,
java.nio.ByteBuffer param_value,
org.lwjgl.PointerBuffer param_value_size_ret)
Returns information about the accelerator object.
|
static int |
clGetAcceleratorInfoINTEL(long accelerator,
int param_name,
int[] param_value,
org.lwjgl.PointerBuffer param_value_size_ret)
Array version of:
GetAcceleratorInfoINTEL |
static int |
clGetAcceleratorInfoINTEL(long accelerator,
int param_name,
java.nio.IntBuffer param_value,
org.lwjgl.PointerBuffer param_value_size_ret)
Returns information about the accelerator object.
|
static int |
clGetAcceleratorInfoINTEL(long accelerator,
int param_name,
org.lwjgl.PointerBuffer param_value,
org.lwjgl.PointerBuffer param_value_size_ret)
Returns information about the accelerator object.
|
static int |
clReleaseAcceleratorINTEL(long accelerator)
Decrements the accelerator reference count.
|
static int |
clRetainAcceleratorINTEL(long accelerator)
Increments the accelerator reference count.
|
static long |
nclCreateAcceleratorINTEL(long context,
int accelerator_type,
long descriptor_size,
long descriptor,
long errcode_ret)
Unsafe version of:
CreateAcceleratorINTEL |
static int |
nclGetAcceleratorInfoINTEL(long accelerator,
int param_name,
long param_value_size,
long param_value,
long param_value_size_ret)
Unsafe version of:
GetAcceleratorInfoINTEL |
public static final int CL_ACCELERATOR_DESCRIPTOR_INTEL
public static final int CL_ACCELERATOR_REFERENCE_COUNT_INTEL
public static final int CL_ACCELERATOR_CONTEXT_INTEL
public static final int CL_ACCELERATOR_TYPE_INTEL
public static final int CL_INVALID_ACCELERATOR_INTEL
public static final int CL_INVALID_ACCELERATOR_TYPE_INTEL
public static final int CL_INVALID_ACCELERATOR_DESCRIPTOR_INTEL
public static final int CL_ACCELERATOR_TYPE_NOT_SUPPORTED_INTEL
public static long nclCreateAcceleratorINTEL(long context,
int accelerator_type,
long descriptor_size,
long descriptor,
long errcode_ret)
CreateAcceleratorINTELdescriptor_size - a value which specifies of the size, in bytes, of the immediately following descriptor structurepublic static long clCreateAcceleratorINTEL(long context,
int accelerator_type,
java.nio.ByteBuffer descriptor,
@Nullable
java.nio.IntBuffer errcode_ret)
This function creates an accelerator object. The accelerator object will be created with a reference count of one. Accelerator objects created with
this function have semantics defined by the parameter accelerator_type, which are defined and described by extensions external to this
document.
context - a valid OpenCL contextaccelerator_type - specifies the type of accelerator object created. The type constants are defined by acceleration engine-specific extensions. It is encouraged that
extensions follow the naming scheme of CL_ACCELERATOR_TYPE_{name}_INTEL where {name} is a descriptive acceleration engine string.descriptor - a pointer to a structure that defines the parameter set of the accelerator object. This parameter set describes the configurable state of the
underlying object. The actual structure supplied must be consistent with accelerator_type. The descriptor structures are defined by
acceleration engine-specific extensions. It is encouraged that extensions follow the naming scheme of cl_{name}_desc_INTEL where {name} is a
descriptive acceleration engine string.errcode_ret - will return an appropriate error code. If errcode_ret is NULL, no error code is returned.errcode_ret is set to SUCCESS if the accelerator object is created successfully. Otherwise, it returns a
NULL value with one of the following error values returned in errcode_ret:
INVALID_CONTEXT if context is not a valid context.INVALID_ACCELERATOR_TYPE_INTEL if the supplied accelerator type is not valid.INVALID_ACCELERATOR_DESCRIPTOR_INTEL if values specified in accelerator_desc are not valid (or a combination of values is not valid) or if
accelerator_desc is NULL.ACCELERATOR_TYPE_NOT_SUPPORTED_INTEL if the supplied accelerator type is not supported by the context.INVALID_OPERATION if none of the devices in the context support accelerator objects.OUT_OF_RESOURCES if there is a failure to allocate resources required by the OpenCL implementation on the device.OUT_OF_HOST_MEMORY if there is a failure to allocate resources required by the OpenCL implementation on the host.public static int clRetainAcceleratorINTEL(long accelerator)
CreateAcceleratorINTEL does an implicit retain.accelerator - a valid accelerator objectSUCCESS if the function is executed successfully. Otherwise, it returns one of the following errors:
INVALID_ACCELERATOR_INTEL if accelerator is a not a valid accelerator object.OUT_OF_RESOURCES if there is a failure to allocate resources required by the OpenCL implementation on the device.OUT_OF_HOST_MEMORY if there is a failure to allocate resources required by the OpenCL implementation on the host.public static int clReleaseAcceleratorINTEL(long accelerator)
accelerator - a valid accelerator objectSUCCESS if the function is executed successfully. Otherwise, it returns one of the following errors:
INVALID_ACCELERATOR_INTEL if accelerator is a not a valid accelerator object.OUT_OF_RESOURCES if there is a failure to allocate resources required by the OpenCL implementation on the device.OUT_OF_HOST_MEMORY if there is a failure to allocate resources required by the OpenCL implementation on the host.public static int nclGetAcceleratorInfoINTEL(long accelerator,
int param_name,
long param_value_size,
long param_value,
long param_value_size_ret)
GetAcceleratorInfoINTELparam_value_size - the size in bytes of memory pointed to by param_value. This size must be ≥ size of return type. If param_value is NULL, it is ignored.public static int clGetAcceleratorInfoINTEL(long accelerator,
int param_name,
@Nullable
java.nio.ByteBuffer param_value,
@Nullable
org.lwjgl.PointerBuffer param_value_size_ret)
accelerator - the accelerator object being queriedparam_name - the information to query. One of:ACCELERATOR_DESCRIPTOR_INTEL | ACCELERATOR_REFERENCE_COUNT_INTEL |
ACCELERATOR_CONTEXT_INTEL | ACCELERATOR_TYPE_INTEL |
param_value - a pointer to memory where the appropriate result being queried is returned. If param_value is NULL, it is ignored.param_value_size_ret - the actual size in bytes of data being queried by param_value. If NULL, it is ignored.SUCCESS if the function is executed successfully. Otherwise, it returns one of the following errors:
INVALID_VALUE if param_name is not valid or if size in bytes specified by param_value_size is < size of return type and
param_value is not NULL.INVALID_ACCELERATOR_INTEL if accelerator is a not a valid accelerator object.OUT_OF_RESOURCES if there is a failure to allocate resources required by the OpenCL implementation on the device.OUT_OF_HOST_MEMORY if there is a failure to allocate resources required by the OpenCL implementation on the host.public static int clGetAcceleratorInfoINTEL(long accelerator,
int param_name,
@Nullable
java.nio.IntBuffer param_value,
@Nullable
org.lwjgl.PointerBuffer param_value_size_ret)
accelerator - the accelerator object being queriedparam_name - the information to query. One of:ACCELERATOR_DESCRIPTOR_INTEL | ACCELERATOR_REFERENCE_COUNT_INTEL |
ACCELERATOR_CONTEXT_INTEL | ACCELERATOR_TYPE_INTEL |
param_value - a pointer to memory where the appropriate result being queried is returned. If param_value is NULL, it is ignored.param_value_size_ret - the actual size in bytes of data being queried by param_value. If NULL, it is ignored.SUCCESS if the function is executed successfully. Otherwise, it returns one of the following errors:
INVALID_VALUE if param_name is not valid or if size in bytes specified by param_value_size is < size of return type and
param_value is not NULL.INVALID_ACCELERATOR_INTEL if accelerator is a not a valid accelerator object.OUT_OF_RESOURCES if there is a failure to allocate resources required by the OpenCL implementation on the device.OUT_OF_HOST_MEMORY if there is a failure to allocate resources required by the OpenCL implementation on the host.public static int clGetAcceleratorInfoINTEL(long accelerator,
int param_name,
@Nullable
org.lwjgl.PointerBuffer param_value,
@Nullable
org.lwjgl.PointerBuffer param_value_size_ret)
accelerator - the accelerator object being queriedparam_name - the information to query. One of:ACCELERATOR_DESCRIPTOR_INTEL | ACCELERATOR_REFERENCE_COUNT_INTEL |
ACCELERATOR_CONTEXT_INTEL | ACCELERATOR_TYPE_INTEL |
param_value - a pointer to memory where the appropriate result being queried is returned. If param_value is NULL, it is ignored.param_value_size_ret - the actual size in bytes of data being queried by param_value. If NULL, it is ignored.SUCCESS if the function is executed successfully. Otherwise, it returns one of the following errors:
INVALID_VALUE if param_name is not valid or if size in bytes specified by param_value_size is < size of return type and
param_value is not NULL.INVALID_ACCELERATOR_INTEL if accelerator is a not a valid accelerator object.OUT_OF_RESOURCES if there is a failure to allocate resources required by the OpenCL implementation on the device.OUT_OF_HOST_MEMORY if there is a failure to allocate resources required by the OpenCL implementation on the host.public static long clCreateAcceleratorINTEL(long context,
int accelerator_type,
java.nio.ByteBuffer descriptor,
@Nullable
int[] errcode_ret)
CreateAcceleratorINTELpublic static int clGetAcceleratorInfoINTEL(long accelerator,
int param_name,
@Nullable
int[] param_value,
@Nullable
org.lwjgl.PointerBuffer param_value_size_ret)
GetAcceleratorInfoINTELCopyright LWJGL. All Rights Reserved. License terms.