SPARC source build error from Tpetra_Experimental_BlockCrsMatrix_decl.hpp -Werror for shadowing warning with Clang 5.0.1 build
Created by: bartlettroscoe
CC: @trilinos/tpetra, @kddevin (Trilinos Data Services Product Lead), @mhoemmen, @bartlettroscoe, @fryeguy52, @micahahoward, @sebrowne
Next Action Status
Looks like PR #4226 merged to 'develop' on 1/23/2019 has fixed these build errors with SPARC as shown in the new SPARC 'master' + Trilinos 'develop' testing process being set up in TRIL-243. In particular, the 100% clean SPARC 'master' builds (against Trilinos from 1/31/2019) shown here proves this.
Description
As of the Trilinos 'develop' version 882d842b, the Clang 5.0.1 build of SPARC (using the cee-rhel6_clang-5.0.1_openmpi-1.10.2_serial_static_opt
build of Trilinos) is broken which uses -Werror in the build showing the build error:
In file included from /scratch/rabartl/SPARC.base/sparc/Trilinos/cee-rhel6_clang-5.0.1_openmpi-1.10.2_serial_static_opt/include/Xpetra_TpetraBlockCrsMatrix.hpp:53:
In file included from /scratch/rabartl/SPARC.base/sparc/Trilinos/cee-rhel6_clang-5.0.1_openmpi-1.10.2_serial_static_opt/include/Tpetra_Experimental_BlockCrsMatrix.hpp:1:
/scratch/rabartl/SPARC.base/sparc/Trilinos/cee-rhel6_clang-5.0.1_openmpi-1.10.2_serial_static_opt/include/Tpetra_Experimental_BlockCrsMatrix_decl.hpp:757:3: error: 'Tpetra::Experimental::BlockCrsMatrix<double, int, long long, Kokkos::Compat::KokkosDeviceWrapperNode<Kokkos::Serial, Kokkos::HostSpace> >::packAndPrepareNew' hides overloaded virtual function [-Werror,-Woverloaded-virtual]
packAndPrepareNew (const SrcDistObject& sourceObj,
^
../include/linsys/MatrixTpetraBlockCrs.h:71:25: note: in instantiation of template class 'Tpetra::Experimental::BlockCrsMatrix<double, int, long long, Kokkos::Compat::KokkosDeviceWrapperNode<Kokkos::Serial, Kokkos::HostSpace> >' requested here
return tpetra_mat_->getNodeNumRows() * block_size_;
^
/scratch/rabartl/SPARC.base/sparc/Trilinos/cee-rhel6_clang-5.0.1_openmpi-1.10.2_serial_static_opt/include/Tpetra_DistObject_decl.hpp:823:5: note: hidden overloaded virtual function 'Tpetra::DistObject<char, int, long long, Kokkos::Compat::KokkosDeviceWrapperNode<Kokkos::Serial, Kokkos::HostSpace> >::packAndPrepareNew' declared here: type mismatch at 3rd parameter ('Kokkos::DualView<packet_type *, buffer_device_type> &' (aka 'DualView<char *, Device<Kokkos::Serial, Kokkos::HostSpace> > &') vs 'Kokkos::DualView<impl_scalar_type *, buffer_device_type> &' (aka 'DualView<double *, Device<Kokkos::Serial, Kokkos::HostSpace> > &'))
packAndPrepareNew (const SrcDistObject& source,
^
In file included from ../src/hofd-aero/AlgorithmComputeResidualVolumeCCHOFD.C:8:
In file included from ../include/hofd-core/StructuredCCHOFDDiscretization.h:11:
In file included from ../include/disc-core/StructuredDiscretization.h:11:
In file included from ../include/sparc-util/Array4D.h:27:
In file included from ../include/sparc-util/ProjectDefs.h:28:
In file included from /scratch/rabartl/SPARC.base/sparc/Trilinos/cee-rhel6_clang-5.0.1_openmpi-1.10.2_serial_static_opt/include/Xpetra_TpetraBlockCrsMatrix.hpp:53:
In file included from /scratch/rabartl/SPARC.base/sparc/Trilinos/cee-rhel6_clang-5.0.1_openmpi-1.10.2_serial_static_opt/include/Tpetra_Experimental_BlockCrsMatrix.hpp:1:
/scratch/rabartl/SPARC.base/sparc/Trilinos/cee-rhel6_clang-5.0.1_openmpi-1.10.2_serial_static_opt/include/Tpetra_Experimental_BlockCrsMatrix_decl.hpp:765:3: error: 'Tpetra::Experimental::BlockCrsMatrix<double, int, long long, Kokkos::Compat::KokkosDeviceWrapperNode<Kokkos::Serial, Kokkos::HostSpace> >::unpackAndCombineNew' hides overloaded virtual function [-Werror,-Woverloaded-virtual]
unpackAndCombineNew (const Kokkos::DualView<const local_ordinal_type*, device_type>& importLIDs,
^
/scratch/rabartl/SPARC.base/sparc/Trilinos/cee-rhel6_clang-5.0.1_openmpi-1.10.2_serial_static_opt/include/Tpetra_DistObject_decl.hpp:889:5: note: hidden overloaded virtual function 'Tpetra::DistObject<char, int, long long, Kokkos::Compat::KokkosDeviceWrapperNode<Kokkos::Serial, Kokkos::HostSpace> >::unpackAndCombineNew' declared here: type mismatch at 2nd parameter ('const Kokkos::DualView<const packet_type *, buffer_device_type> &' (aka 'const DualView<const char *, Device<Kokkos::Serial, Kokkos::HostSpace> > &') vs 'const Kokkos::DualView<const impl_scalar_type *, buffer_device_type> &' (aka 'const DualView<const double *, Device<Kokkos::Serial, Kokkos::HostSpace> > &'))
unpackAndCombineNew (const Kokkos::DualView<const local_ordinal_type*, device_type>& importLIDs,
^
2 errors generated.
Not clear when this first started failing since we don't have automated builds of SPARC 'master' against Trilinos 'develop' running yet (see TRIL-243).
Current Status on CDash
Can't see this on CDash yet. Instead, must build SPARC 'master' against Trilinos 'develop' as described below.
Steps to Reproduce
Follow the directions here for building SPARC 'master' against Trilinos 'develop'. use the build name cee-rhel6_clang-5.0.1_openmpi-1.10.2_serial_static_opt
. To run just that build, use:
$ cd sparc/
$ ./sparc-tril-dev-scripts/build_and_test_atdm_trilinos_and_sparc.sh \
cee-rhel6_clang-5.0.1_openmpi-1.10.2_serial_static_opt