The ISPC 1.24 compiler by Intel now available, featuring SPMD parallelization model.

Intel Company published compiler ISPC 1.24 (Implicit SPMD Program Compiler), which provides assembly of C code with extensions to support the parallel programming method SPMD (Single Program, Multiple Data), in which several instances of the same program are executed in parallel with different sets of input data. The project code is written in C++ and distributed by under BSD license. Supports work on Linux, Windows, macOS, Linux and FreeBSD (plus the code can be compiled for Android, iOS and PS4/PS5).

A C program with SPMD extensions is compiled for execution on compute units SIMDprovided by the CPU and GPU, which allows you to use SIMD vectorization mechanisms in programs without low-level optimizations and explicit use of SIMD instructions in the code. To write parallelizable functions used familiar syntax and idioms of the C language. These SPMD functions can integrate with C/C++ applications and directly interact with their functions and structures. Existing debuggers can be used to debug programs.

The LLVM infrastructure is used as a backend for code generation and optimization. The use of x86 (SSE2, SSE4, AVX, AVX2, AVX512) and ARM (NEON) vector instructions is supported, as well as offloading calculations to the GPU side (Intel Gen9 and Xe). On architectures with SSE vector blocks that process 4 elements at a time, the use of ISPC allows for acceleration of program execution by 3 or more times, and on architectures with AVX vector blocks that process 8 elements at a time, the acceleration can reach 5-6 times. Moreover, in addition to the size of the vector block, scaling is also achieved due to execution on different processor cores.

Key innovations added in ISPC version 1.24:

  • Added support for untyped template parameters. You can now use unified integer and enumerated values ​​as template parameters (with the “uniform“).
  • Added dot functions for signed and unsigned int8 and int16 types that use the AVX-VNNI and AVX512-VNN instructions.
  • Added macro definitions for number constraints.
  • Added new target platforms: avx2vnni-i32x4, avx2vnni-i32x8, avx2vnni-i32x16 with support for the AVX-VNNI instruction, and avx512icl-x4, avx512icl-x8, avx512icl-x16, avx512icl-x32, 4 with support for the AVX512-VNNI instruction.
  • Problems with the use of unnecessary vector instructions when generating code for the GPU have been resolved.
  • The “–pic” command line flag is made to match the “-fpic” flag in Clang and GCC, and the “–PIC” flag is made to match the “-fPIC” flag.

Thanks for reading: