Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Amesos2: compilation error w/ Tpetra deprecated code turned off #10247

Closed
ikalash opened this issue Feb 25, 2022 · 18 comments
Closed

Amesos2: compilation error w/ Tpetra deprecated code turned off #10247

ikalash opened this issue Feb 25, 2022 · 18 comments
Labels
client: Albany Issue impacting the Albany project client: LCM Solid mechanics fork of Albany pkg: Amesos2 type: bug The primary issue is a bug in Trilinos code or tests

Comments

@ikalash
Copy link
Contributor

ikalash commented Feb 25, 2022

@trilinos/amesos2

We have failed Trilinos builds in the Albany and Albany-LCM builds with Tpetra deprecated code turned off due to Amesos2:

[ 78%] Building CXX object packages/amesos2/src/CMakeFiles/amesos2.dir/Amesos2_KokkosCrsMatrix_MatrixAdapter.cpp.o
[ 78%] Building CXX object packages/amesos2/src/CMakeFiles/amesos2.dir/Amesos2_TpetraMultiVecAdapter.cpp.o
[ 78%] Building CXX object packages/amesos2/src/CMakeFiles/amesos2.dir/Amesos2_KokkosMultiVecAdapter.cpp.o
[ 78%] Building CXX object packages/amesos2/src/CMakeFiles/amesos2.dir/Amesos2_Util.cpp.o
[ 78%] Building CXX object packages/amesos2/src/CMakeFiles/amesos2.dir/Amesos2_Version.cpp.o
[ 78%] Building CXX object packages/amesos2/src/CMakeFiles/amesos2.dir/Amesos2_KLU2.cpp.o
[ 78%] Building CXX object packages/amesos2/src/CMakeFiles/amesos2.dir/Amesos2_KLU2_TypeMap.cpp.o
In file included from [packages/amesos2/src/Amesos2_KLU2.cpp:48](https://blob/master/packages/amesos2/src/Amesos2_KLU2.cpp#L48):
In file included from [packages/amesos2/src/Amesos2_KLU2_def.hpp:59](https://blob/master/packages/amesos2/src/Amesos2_KLU2_def.hpp#L59):
In file included from [packages/amesos2/src/Amesos2_SolverCore_def.hpp:56](https://blob/master/packages/amesos2/src/Amesos2_SolverCore_def.hpp#L56):
[packages/amesos2/src/Amesos2_MatrixAdapter_def.hpp:512](https://blob/master/packages/amesos2/src/Amesos2_MatrixAdapter_def.hpp#L512):61: error: no member named 'getNodeE

https://sems-cdash-son.sandia.gov/cdash/viewBuildError.php?buildid=29958
https://sems-cdash-son.sandia.gov/cdash/viewBuildError.php?buildid=29945

Could someone please have a look? Tagging @lxmota who will also be interested in this issue.

@ikalash ikalash added type: bug The primary issue is a bug in Trilinos code or tests pkg: Amesos2 client: Albany Issue impacting the Albany project client: LCM Solid mechanics fork of Albany labels Feb 25, 2022
@cgcgcg
Copy link
Contributor

cgcgcg commented Feb 25, 2022

@trilinos/framework Do we have a nightly build that disables deprecated code? This is the third time this stuff is hitting Albany in the last week or so.

@ZUUL42
Copy link
Contributor

ZUUL42 commented Feb 25, 2022

@cgcgcg, I'm not sure if it's useful for you in it's current state, but we do have this deprecated nightly build: CDash

@cgcgcg
Copy link
Contributor

cgcgcg commented Feb 25, 2022

@ZUUL42 Thank you! Any idea why that build displays in such a weird way? Makes parsing what's actually failing quite difficult.

@ZUUL42
Copy link
Contributor

ZUUL42 commented Feb 25, 2022

@cgcgcg, sorry, I have not had the chance to look into that.

@ndellingwood
Copy link
Contributor

Looks like the changes to replace getNode* by getLocal* in #10189 need to be made to Amesos2. I'll put in a PR shortly

ndellingwood added a commit to ndellingwood/Trilinos that referenced this issue Feb 25, 2022
@ndellingwood
Copy link
Contributor

Opened PR #10250, hopefully just the name change update is needed

@ikalash
Copy link
Contributor Author

ikalash commented Mar 1, 2022

Now there are issues with MueLu: https://sems-cdash-son.sandia.gov/cdash/viewBuildError.php?buildid=30080

[Trilinos/packages/muelu/src/Utils/MueLu_Utilities_kokkos_def.hpp:282](https://blob/master/Trilinos/packages/muelu/src/Utils/MueLu_Utilities_kokkos_def.hpp#L282):32: error: ‘class Tpetra::CrsMatrix<double, int, long long int, Kokkos::Compat::KokkosDeviceWrapperNode<Kokkos::Serial> >’ has no member named ‘getNodeMaxNumRowEntries’; did you mean ‘getLocalMaxNumRowEntries’?

This is turning into a game of wack-a-mole...!

@cgcgcg
Copy link
Contributor

cgcgcg commented Mar 1, 2022

@ikalash What's the SHA for that build? I did push some deprecated changes yesterday: #10256 and #10257.

EDIT: Looks like the build had #10256, but not #10257.

@ikalash
Copy link
Contributor Author

ikalash commented Mar 1, 2022

Here it is:

commit 1760977a3e33da0dc7310f1e815c2e88fd51ebde
Merge: 6e5d996 1e1bd8a
Author: trilinos-autotester <[email protected]>
Date:   Mon Feb 28 14:18:04 2022 -0700

    Merge Pull Request #10256 from cgcgcg/Trilinos/mueluFixes
    
    Automatically Merged using Trilinos Pull Request AutoTester
    PR Title: Deprecation fixes
    PR Author: cgcgcg

@cgcgcg
Copy link
Contributor

cgcgcg commented Mar 1, 2022

Ok. Hopefully you won't be seeing the MueLu issues anymore tomorrow. There are PRs #10261 and #10262 for the next set of packages.

@ikalash
Copy link
Contributor Author

ikalash commented Mar 1, 2022

Thanks @cgcgcg , I will keep my eye out for the fixes.

@ikalash
Copy link
Contributor Author

ikalash commented Mar 1, 2022

Could someone help me answer the following questions? It's for a code I support that uses Trilinos:

  • is Tpetra::StaticProfile going away with the deprecation? I'm seeing errors that look as following:
/home/ikalash/Trilinos/DataTransferKit/packages/Operators/test/tstPolynomialMatrix.cpp:111:54: error: ‘StaticProfile’ is not a member of ‘Tpetra’
                 row_map, col_map, poly_size, Tpetra::StaticProfile ) );
                                                      ^~~~~~~~~~~~~
  • It looks like getLocalRowView changed too - does it take a Kokkos::View now?
/home/ikalash/Trilinos/DataTransferKit/packages/Operators/test/tstCrsMatrixFill.cpp:173:54: error: no matching function for call to ‘Tpetra::CrsMatrix<double, int, long long int>::getLocalRowView(int, Teuchos::ArrayView<const int>&, Teuchos::ArrayView<const double>&)’
     A->getLocalRowView( 0, indices_view, values_view );

@cgcgcg
Copy link
Contributor

cgcgcg commented Mar 1, 2022

  • I believe StaticProfile was already the only option before, I think all you need to do is remove Tpetra::StaticProfile from the call.
    #ifdef TPETRA_ENABLE_DEPRECATED_CODE
    TPETRA_DEPRECATED
    CrsMatrix (const Teuchos::RCP<const map_type>& rowMap,
    const size_t maxNumEntriesPerRow,
    const ProfileType pftype,
    const Teuchos::RCP<Teuchos::ParameterList>& params = Teuchos::null);
    #endif
    CrsMatrix (const Teuchos::RCP<const map_type>& rowMap,
    const size_t maxNumEntriesPerRow,
    const Teuchos::RCP<Teuchos::ParameterList>& params = Teuchos::null);
  • Yes, it's Kokkos views now, see:
    #ifdef TPETRA_ENABLE_DEPRECATED_CODE
    TPETRA_DEPRECATED
    void
    getLocalRowView (LocalOrdinal LocalRow,
    Teuchos::ArrayView<const LocalOrdinal>& indices,
    Teuchos::ArrayView<const Scalar>& values) const override;
    #endif // TPETRA_ENABLE_DEPRECATED_CODE
    void
    getLocalRowView(LocalOrdinal LocalRow,
    local_inds_host_view_type &indices,
    values_host_view_type &values) const override;

@ikalash
Copy link
Contributor Author

ikalash commented Mar 1, 2022

Thanks @cgcgcg let me see if I can fix this. Thanks for your responsiveness - I haven't been following all the changes to Tpetra and your replies will save me a lot of time grepping through the code to try to figure out what changed!

@mperego
Copy link
Contributor

mperego commented Mar 2, 2022

@ikalash I also fixed a few calls to deprecated code in Zoltan2 (PR #10264) that were needed to build Albany. Not sure you use Zoltan2 in Albany-LCM. I also had to disable Galeri (which we do not use anyway). Other changes to Albany were trivial (sandialabs/Albany#797).

@ikalash
Copy link
Contributor Author

ikalash commented Mar 2, 2022

Thanks @mperego ! I had to make a few changes in LCM today (as well as DTK) but things seem clean now. I really hope the dashboard has no failures tomorrow for LCM at least!

@brian-kelley
Copy link
Contributor

@ikalash Did switching to the non-deprecated functions fix Albany?

@ikalash
Copy link
Contributor Author

ikalash commented Mar 15, 2022

Yes, I think so. This issue can be closed.

@mperego mperego closed this as completed Mar 15, 2022
@jhux2 jhux2 added this to Tpetra Aug 12, 2024
@jhux2 jhux2 moved this to Done in Tpetra Aug 12, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
client: Albany Issue impacting the Albany project client: LCM Solid mechanics fork of Albany pkg: Amesos2 type: bug The primary issue is a bug in Trilinos code or tests
Projects
Status: Done
Development

No branches or pull requests

6 participants