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

avoid collective call inside subroutine MAPL_GetGlobalHorzIJIndex #2436

Merged
merged 1 commit into from
Oct 31, 2023

Conversation

weiyuan-jiang
Copy link
Contributor

@weiyuan-jiang weiyuan-jiang commented Oct 31, 2023

It is expensive, inconvenient and unnecessary to have a collective call inside the subroutine MAPL_GetGlobalHorzIJIndex

Description

Related Issue

Motivation and Context

How Has This Been Tested?

Types of changes

  • Bug fix (non-breaking change which fixes an issue)
  • New feature (non-breaking change which adds functionality)
  • Breaking change (fix or feature that would cause existing functionality to change)
  • Trivial change (affects only documentation or cleanup)

Checklist:

  • I have tested this change with a run of GEOSgcm (if non-trivial)
  • I have added one of the required labels (0 diff, 0 diff trivial, 0 diff structural, non 0-diff)
  • I have updated the CHANGELOG.md accordingly following the style of Keep a Changelog

@weiyuan-jiang weiyuan-jiang added the 0 Diff The changes in this pull request have verified to be zero-diff with the target branch. label Oct 31, 2023
@weiyuan-jiang weiyuan-jiang requested a review from a team as a code owner October 31, 2023 15:28
Copy link
Collaborator

@tclune tclune left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Have you run this with bounds checking? The MAPL procedure that you have replaced returns the all the corners for the cells in the local domain, where the ESMF routines only return the left/south corners. (Corners that are shared by 2 or more domains are only "owned" by one domain in ESMF.)

@weiyuan-jiang
Copy link
Contributor Author

Have you run this with bounds checking? The MAPL procedure that you have replaced returns the all the corners for the cells in the local domain, where the ESMF routines only return the left/south corners. (Corners that are shared by 2 or more domains are only "owned" by one domain in ESMF.)

Yes. I only compare one left/south corner. The other comparisons are on edge without end points.

@tclune tclune self-requested a review October 31, 2023 18:25
@tclune tclune merged commit 3211d11 into develop Oct 31, 2023
35 checks passed
@tclune tclune deleted the feature/wjiang/change_grid_is_ok branch October 31, 2023 18:26
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
0 Diff The changes in this pull request have verified to be zero-diff with the target branch.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants