Parallel data types Sample Clauses
Parallel data types. Parallel code may support new types that are not supported in serial code. These types include fixed precisions numbers, 16-bit floating point (half float) and non-IEEE floating point. There may be support for vector types, either as explicit 2/4/8 lane SIMD vectors or via coordinate types with explicit x, y, z and w elements. Conversely, parallel code may not support types that are available in serial code. Specif- ically, high-precision floating point (double and higher) may not be available on the parallel processor and thus may not be available in the programming model. Languages targeted at pure computation may also lack other types such as Booleans, enumerations and bit fields. Pointers types may not be supported or may be restricted to simple data types rather than pointing to objects or functions. This is particularly the case where a segmented memory architecture is supported because pointers do not translate between the two memory areas. The type of data that can be transferred between serial and parallel code are usually limited to scalar values, simple vectors and simple structures. Programming models that support multiple memory spaces tend to provide a set of pointer qualifiers, allowing the programmer to specify which memory space a pointer refers to [22, 17, 6, 8]. For example, in the OpenCL programming model [17] a pointer can be marked as private, local, global or constant. This allows the compiler to perform type checking, providing some guarantee that memory spaces are used correctly.
