Brussels / 2 & 3 February 2019


Intel® Hardware Intrinsics in .NET Core

In this presentation, we will talk about the Intel Hardware Intrinsics in .NET Core, a new feature in .NET Core 3.0. For the first time, .NET developers will have the ability to directly exercise underlying CPU features, very similar to what C/C++ developers could do with intrinsic functions for their performance critical code. The Intel Hardware Intrinsics in .NET Core include more than 1300 intrinsic functions, which cover the instruction set architecture (ISA) SSE, SSE2, SSE3, SSSE3, SSE4.1, SSE4.2, AVX, AVX2, FMA, LZCNT, POPCNT, BMI1, BMI2, PCLMULQDQ, and AES. Many of the intrinsic functions are designed for Single Instruction Multiple Data (SIMD) computation, a common used technology to speed up computation intensive algorithms. To illustrate the benefits of using Hardware Intrinsics, we implemented a Structure of Array (SoA) based RayTracer and compared its performance with that of the traditional Array of Structure (AoS) based RayTracer which uses System.Numerics.Vectors. Our experience shows that significant performance improvement is possible when using Hardware Intrinsics for this particular application. Another use case is ML.NET, an open source machine learning framework for .NET developers, which leverages the Intel Hardware Intrinsics to simplify the acceleration of machine learning scenarios.

We will give an overview of SIMD and the Intel Hardware Intrinsics in .NET Core. In addition, we will talk about the differences of System.Numerics.Vectors and System.Runtime.Intrinsics, which are the two different ways to use SIMD in .NET Core. we will show live demos on how to use Intel hardware intrinsics. By the end of the presentation, the audience will learn the current status of the Intel Hardware Intrinsics in .NET Core and how to use the Intel Hardware Intrinsics to speed up their code.


Photo of Han Lee Han Lee