Gather-scatter (vector addressing)
Encyclopedia
Gather-scatter is a type of memory addressing that often arises when addressing
vectors in sparse
linear algebra
operations. It is the
vector-equivalent of register indirect addressing, with gather involving indexed
reads and scatter indexed writes. Vector processor
s have
hardware support for gather-scatter operations, providing instructions such as
Load Vector Indexed for gather and Store Vector Indexed for scatter.
the sparse gather of dense into denoted
, assigns .
The sparse scatter, denoted is the reverse operation.
It copies the nonzero values of sparse into the corresponding
locations in the dense vector , i.e. .
Scatter:
vectors in sparse
Sparse matrix
In the subfield of numerical analysis, a sparse matrix is a matrix populated primarily with zeros . The term itself was coined by Harry M. Markowitz....
linear algebra
Linear algebra
Linear algebra is a branch of mathematics that studies vector spaces, also called linear spaces, along with linear functions that input one vector and output another. Such functions are called linear maps and can be represented by matrices if a basis is given. Thus matrix theory is often...
operations. It is the
vector-equivalent of register indirect addressing, with gather involving indexed
reads and scatter indexed writes. Vector processor
Vector processor
A vector processor, or array processor, is a central processing unit that implements an instruction set containing instructions that operate on one-dimensional arrays of data called vectors. This is in contrast to a scalar processor, whose instructions operate on single data items...
s have
hardware support for gather-scatter operations, providing instructions such as
Load Vector Indexed for gather and Store Vector Indexed for scatter.
Definition
Denoting by the list of indices of sparse vector ,the sparse gather of dense into denoted
, assigns .
The sparse scatter, denoted is the reverse operation.
It copies the nonzero values of sparse into the corresponding
locations in the dense vector , i.e. .
Examples
Gather:Scatter: