Vectorization: Introduction
Vectorization is a process by which floating-point computations in scientific code are compiled into special instructions that execute elementary operations (+,-,*, etc.)
or functions (exp, cos, etc.) in parallel on fixed-size vector arrays. The ultimate goal of vectorization is an increase in floating-point performance (possibly
integer and logical performance as well) through hardware parallelism.
This module describes the vectorization process as it relates to computing hardware, compilers, and coding practices. Knowing where in code vectorization ought to occur,
how vectorization will increase performance, and whether the compiler is vectorizing loops within a code as it should are critical to getting the full potential from
the CPUs of modern HPC systems such as
Stampede2.
Steve Lantz
Cornell Center for Advanced Computing
With contributions from Aaron Birkland and the
Texas Advanced Computing Center
Revisions: 3/2023, 9/2022, 5/2021, 1/2021, 5/2018, 6/2017, 10/2013 (original)