Tpetra::MultiVector: Fix #4870 (prefer running norms on device)
Created by: mhoemmen
@trilinos/tpetra @trilinos/stokhos
Supersedes PR #4871.
Description
- Prefer running MultiVector norms on device, even if it is currently sync'd to host, unless the vector has too few local rows.
- Factor out the implementation of
Tpetra::MultiVector::norm*
into a separate function,Tpetra::Details::normImpl
. I do ETI for that function, when ETI is enabled. This required adding new ETI macros for iterating over the(Scalar, Node)
type combination. - Fix Stokhos to work around lack of ETI for
Tpetra::Details::normImpl
. Tpetra's ETI macro forTpetra::Details::normImpl
only takes 2 template parameters:Scalar
andNode
. This meant that I couldn't use Stokhos' ETI system (seeTPETRA_ETI_CLASSES
instokhos/src/CMakeLists.txt
). I hacked in a header file include in Stokhos to make this build.
Motivation and Context
- SPARC performance
- Build time
Related Issues
- Closes #4870 (closed)