A.2.1 Built-in scalar data types

List of built-in scalar data types.

Table A-1 Built-in scalar data types

Types for OpenCL kernels Types for application Description
bool - true (1) or false (0)
char cl_char 8-bit signed
unsigned char, uchar cl_uchar 8-bit unsigned
short cl_short 16-bit signed
unsigned short, ushort cl_ushort 16-bit unsigned
int cl_int 32-bit signed
unsigned int, uint cl_uint 32-bit unsigned
long cl_long 64-bit signed
unsigned long, ulong cl_ulong 64-bit unsigned
float cl_float 32-bit float
half cl_half 16-bit float, for storage only
size_t - 32-bit or 64-bit unsigned integer
ptrdiff_t - 32-bit or 64-bit unsigned integer
intptr_t - signed integer
uintptr_t - unsigned integer
void void void
Non-ConfidentialPDF file icon PDF versionARM 100614_0300_00_en
Copyright © 2012, 2013, 2015, 2016 ARM. All rights reserved.