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

Explicit array bounds #458

Merged
merged 80 commits into from
May 2, 2023
Merged

Explicit array bounds #458

merged 80 commits into from
May 2, 2023

Conversation

matt-frey
Copy link
Member

@matt-frey matt-frey commented Apr 19, 2023

There is a GCC issue that changes the bounds of allocatable arrays when calling subroutines with dimension(..). See also https://gcc.gnu.org/bugzilla/show_bug.cgi?id=97046 (and https://stackoverflow.com/questions/63824065/lbound-of-an-array-changes-after-call-to-mpi-gatherv-when-using-mpi-f08-module).

As the latest MPI module mpi_f08 heavily uses dimension(..) in its routines, we get wrong bounds after MPI calls, although they are correct before. According to the link I posted, the issue affects gcc/9.2.0 and gcc/10.2.0. It worked on my laptop as I am using gcc/9.3.0. One workaround is to specify the bounds explicitly in the MPI calls.

This PR further changes MPI_INT to MPI_INTEGER and removes the calls to MPI_Win_sync as we get the error Wrong synchronization of RMA calls on Archer2. These calls are intended to synchronise the private and public RMA memory. However, in a unified memory model, these are not necessary. We have put them in for safety reasons only.

Plus changes in #459 and #460.

@matt-frey matt-frey added bug Something isn't working 3D Issues and pull requests related to the 3D version MPI MPI related issues and pull requests labels Apr 19, 2023
@matt-frey matt-frey added this to the 0.13.0 milestone Apr 19, 2023
@matt-frey matt-frey self-assigned this Apr 19, 2023
@matt-frey matt-frey changed the base branch from main to 3d-mpi-model April 19, 2023 11:44
@matt-frey matt-frey marked this pull request as ready for review April 19, 2023 15:27
@matt-frey matt-frey requested a review from sjboeing April 19, 2023 15:27
@matt-frey matt-frey merged commit 46100e9 into 3d-mpi-model May 2, 2023
@matt-frey matt-frey deleted the explicit-array-bounds branch May 2, 2023 10:34
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
3D Issues and pull requests related to the 3D version bug Something isn't working MPI MPI related issues and pull requests
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants