Top Description Constructors Methods
org.lwjgl.opencl

public Class KHRSuggestedLocalWorkSize

extends Object
Class Inheritance
Imports
javax.annotation.*, org.lwjgl.*, org.lwjgl.system.*

Native bindings to the khr_suggested_local_work_size extension.

This extension adds the ability to query a suggested local work group size for a kernel running on a device for a specified global work size and global work offset. The suggested local work group size will match the work group size that would be chosen if the kernel were enqueued with the specified global work size and global work offset and a NULL local work size.

By using the suggested local work group size query an application has greater insight into the local work group size chosen by the OpenCL implementation, and the OpenCL implementation need not re-compute the local work group size if the same kernel is enqueued multiple times with the same parameters.

Constructor Summary

AccessConstructor and Description
protected

Method Summary

Modifier and TypeMethod and Description
public static int
clGetKernelSuggestedLocalWorkSizeKHR(long
specifies the command queue and device for the query
command_queue
,
long
the kernel object and kernel arguments for the query. The OpenCL context associated with kernel and command_queue must the same.
kernel
,
PointerBuffer
can be used to specify an array of at least work_dim global ID offset values for the query. This is optional and may be NULL to indicate there is no global ID offset.
global_work_offset
,
PointerBuffer global_work_size, PointerBuffer suggested_local_work_size)

Query a suggested local work size for a kernel object.

public static int
nclGetKernelSuggestedLocalWorkSizeKHR(long command_queue, long kernel, int
specifies the number of work dimensions in the input global work offset and global work size, and the output suggested local work size
work_dim
,
long global_work_offset, long global_work_size, long suggested_local_work_size)

Unsafe version of: GetKernelSuggestedLocalWorkSizeKHR

Inherited from java.lang.Object:
cloneequalsfinalizegetClasshashCodenotifynotifyAlltoStringwaitwaitwait

Constructor Detail

KHRSuggestedLocalWorkSizeback to summary
protected KHRSuggestedLocalWorkSize()

Method Detail

clGetKernelSuggestedLocalWorkSizeKHRback to summary
public static int clGetKernelSuggestedLocalWorkSizeKHR(long command_queue, long kernel, PointerBuffer global_work_offset, PointerBuffer global_work_size, PointerBuffer suggested_local_work_size)

Query a suggested local work size for a kernel object.

The returned suggested local work size is expected to match the local work size that would be chosen if the specified kernel object, with the same kernel arguments, were enqueued into the specified command queue with the specified global work size, specified global work offset, and with a NULL local work size.

Parameters
command_queue:long

specifies the command queue and device for the query

kernel:long

the kernel object and kernel arguments for the query. The OpenCL context associated with kernel and command_queue must the same.

global_work_offset:PointerBuffer

can be used to specify an array of at least work_dim global ID offset values for the query. This is optional and may be NULL to indicate there is no global ID offset.

Annotations
@NativeType:cl_int
nclGetKernelSuggestedLocalWorkSizeKHRback to summary
public static int nclGetKernelSuggestedLocalWorkSizeKHR(long command_queue, long kernel, int work_dim, long global_work_offset, long global_work_size, long suggested_local_work_size)

Unsafe version of: GetKernelSuggestedLocalWorkSizeKHR

Parameters
work_dim:int

specifies the number of work dimensions in the input global work offset and global work size, and the output suggested local work size