Tpetra: sort and merge values: CrsMatrix::insertLocalValues
Created by: tjfulle
What
Sort and merge new values in CrsMatrix::insertLocalValues
Why
CrsMatrix::insertLocalValues
does not sort/merge existing values. Instead, indices/values are appended to their row of the matrix, regardless if they are already present in the row. During fillComplete
, rows are sorted/merged so that duplicate entries are "compressed" out. For StaticProfile
matrix, this can lead to running out of capacity due to duplicate entries.
@trilinos/tpetra