General Matrix Multiply Sample

Published: 09/11/2014, Last Updated: 02/12/2015

Download for Windows* Download for Linux* Download Documentation

Description

General Matrix Multiply (GEMM) sample demonstrates how to efficiently utilize an OpenCL™ device to perform general matrix multiply operation on two dense square matrices. The primary target devices that are suitable for this sample are the devices with cache memory: Intel® Xeon Phi™ and Intel® Architecture CPU devices.

The sample:

  • Optimizes trivial matrix multiplication nested loop to utilize the memory cache more efficiently
  • Supports single-precision and double-precision data types
  • Demonstrates how to use different storage methods for matrices
  • Demonstrates how to utilize the automatic vectorizer efficiently and avoid gathers

Supported Devices: CPU, Intel® Xeon Phi™ coprocessor
Supported OS: Windows* and Linux* OS
Complexity Level: Intermediate

For more information about the sample refer to the sample documentation inside the package.

ZIP sample package contains sample files for Windows* OS
TAR.GZ sample package contains sample files for Linux* OS.

* OpenCL and the OpenCL logo are trademarks of Apple Inc. used by permission by Khronos.

Additional Resources

Intel® SDK for OpenCL™ Applications

Product and Performance Information

1

Intel's compilers may or may not optimize to the same degree for non-Intel microprocessors for optimizations that are not unique to Intel microprocessors. These optimizations include SSE2, SSE3, and SSSE3 instruction sets and other optimizations. Intel does not guarantee the availability, functionality, or effectiveness of any optimization on microprocessors not manufactured by Intel. Microprocessor-dependent optimizations in this product are intended for use with Intel microprocessors. Certain optimizations not specific to Intel microarchitecture are reserved for Intel microprocessors. Please refer to the applicable product User and Reference Guides for more information regarding the specific instruction sets covered by this notice.

Notice revision #20110804