numba_dpex.ocl.stubs module

class numba_dpex.ocl.stubs.Stub

Bases: object

A stub object to represent special objects which is meaningless outside the context of DPPY compilation context.

class numba_dpex.ocl.stubs.atomic

Bases: numba_dpex.ocl.stubs.Stub

atomic namespace

add(ary, idx, val)

Perform atomic ary[idx] += val.

Returns the old value at the index location as if it is loaded atomically.

Note

Supported on int32, int64, float32, float64 operands only.

sub(ary, idx, val)

Perform atomic ary[idx] -= val.

Returns the old value at the index location as if it is loaded atomically.

Note

Supported on int32, int64, float32, float64 operands only.

numba_dpex.ocl.stubs.barrier(*args, **kargs)

OpenCL barrier()

numba_dpex.ocl.stubs.get_global_id(*args, **kargs)

OpenCL get_global_id()

numba_dpex.ocl.stubs.get_global_size(*args, **kargs)

OpenCL get_global_size()

numba_dpex.ocl.stubs.get_group_id(*args, **kargs)

OpenCL get_group_id()

numba_dpex.ocl.stubs.get_local_id(*args, **kargs)

OpenCL get_local_id()

numba_dpex.ocl.stubs.get_local_size(*args, **kargs)

OpenCL get_local_size()

numba_dpex.ocl.stubs.get_num_groups(*args, **kargs)

OpenCL get_num_groups()

numba_dpex.ocl.stubs.get_work_dim(*args, **kargs)

OpenCL get_work_dim()

class numba_dpex.ocl.stubs.local

Bases: numba_dpex.ocl.stubs.Stub

local namespace

array(shape, dtype)

Allocate a local array.

numba_dpex.ocl.stubs.mem_fence(*args, **kargs)

OpenCL mem_fence()

class numba_dpex.ocl.stubs.private

Bases: numba_dpex.ocl.stubs.Stub

private namespace

array(shape, dtype)

Allocate a private array.

numba_dpex.ocl.stubs.sub_group_barrier()

OpenCL 2.0 sub_group_barrier