-
Notifications
You must be signed in to change notification settings - Fork 17
Add more multi image intrinsic function calls to the integration #337
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
Draft
ktras
wants to merge
2
commits into
BerkeleyLab:main
Choose a base branch
from
ktras:add-more-intrinsics-to-app-test
base: main
Could not load branches
Branch not found: {{ refName }}
Loading
Could not load tags
Nothing to show
Loading
Are you sure you want to change the base?
Some commits from the old base branch may be removed from the timeline,
and old review comments may become outdated.
+56
−1
Draft
Changes from all commits
Commits
Show all changes
2 commits
Select commit
Hold shift + click to select a range
File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
There are no files selected for viewing
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Original file line number | Diff line number | Diff line change |
|---|---|---|
|
|
@@ -58,7 +58,7 @@ program native_multi_image | |
| #endif | ||
|
|
||
| #ifndef HAVE_COARRAY | ||
| #define HAVE_COARRAY 0 | ||
| #define HAVE_COARRAY 1 | ||
| #endif | ||
| #ifndef HAVE_MAIN_COARRAY | ||
| #define HAVE_MAIN_COARRAY HAVE_COARRAY | ||
|
|
@@ -67,6 +67,23 @@ program native_multi_image | |
| #define HAVE_ALLOC_COARRAY HAVE_COARRAY | ||
| #endif | ||
|
|
||
| ! coarray query intrinsics | ||
| #ifndef HAVE_COARRAY_QUERY | ||
| #define HAVE_COARRAY_QUERY HAVE_COARRAY | ||
| #endif | ||
| #ifndef HAVE_COBOUND | ||
| #define HAVE_COBOUND HAVE_COARRAY_QUERY | ||
| #endif | ||
| #ifndef HAVE_COSHAPE | ||
| #define HAVE_COSHAPE HAVE_COARRAY_QUERY | ||
| #endif | ||
| #ifndef HAVE_IMAGE_INDEX | ||
| #define HAVE_IMAGE_INDEX HAVE_COARRAY_QUERY | ||
| #endif | ||
| #ifndef HAVE_THIS_IMAGE_COARRAY | ||
| #define HAVE_THIS_IMAGE_COARRAY HAVE_COARRAY_QUERY | ||
| #endif | ||
|
|
||
| ! Helper macros | ||
| #define CHECK_TYPE_COMPLIANCE(subject_type, subject, is_team, min_size) \ | ||
| BLOCK ; \ | ||
|
|
@@ -190,6 +207,44 @@ program native_multi_image | |
| write(*,'(A,I3)') "After END TEAM statement, TEAM_NUMBER() is ", TEAM_NUMBER() | ||
| # endif | ||
|
|
||
| # if HAVE_MAIN_COARRAY | ||
| # if HAVE_COBOUND | ||
| call status("Testing LCOBOUND/UCOBOUND...") | ||
| write(*,'(A,2I3)') "lcobound(sca_int_2) = ", LCOBOUND(sca_int_2) | ||
| write(*,'(A,2I3)') "ucobound(sca_int_2) = ", UCOBOUND(sca_int_2) | ||
| write(*,'(A,3I3)') "lcobound(sca_int_3) = ", LCOBOUND(sca_int_3) | ||
| write(*,'(A,3I3)') "ucobound(sca_int_3) = ", UCOBOUND(sca_int_3) | ||
| write(*,'(A,I3)') "lcobound(sca_int_3, dim=2) = ", LCOBOUND(sca_int_3, dim=2) | ||
| write(*,'(A,I3)') "ucobound(sca_int_3, dim=2) = ", UCOBOUND(sca_int_3, dim=2) | ||
| write(*,'(A,I3)') "lcobound(sca_int_3, dim=2, kind=8) = ", LCOBOUND(sca_int_3, dim=2, kind=8) | ||
| write(*,'(A,I3)') "ucobound(sca_int_3, dim=2, kind=8) = ", UCOBOUND(sca_int_3, dim=2, kind=8) | ||
| # endif | ||
| # if HAVE_COSHAPE | ||
| call status("Testing COSHAPE...") | ||
| write(*,'(A,3I3)') "coshape(sca_int_3) = ", COSHAPE(sca_int_3) | ||
| write(*,'(A,3I3)') "coshape(sca_int_3, kind=8) = ", COSHAPE(sca_int_3, kind=8) | ||
| # endif | ||
| # if HAVE_IMAGE_INDEX | ||
| call status("Testing IMAGE_INDEX...") | ||
| write(*,'(A,I3)') "image_index(sca_int_1, [1]) = ", IMAGE_INDEX(sca_int_1, [1]) | ||
| write(*,'(A,I3)') "image_index(sca_int_2, [1,1]) = ", IMAGE_INDEX(sca_int_2, [1,1]) | ||
| write(*,'(A,I3)') "image_index(sca_int_3, [1,1,1]) = ", IMAGE_INDEX(sca_int_3, [1,1,1]) | ||
| # if HAVE_TEAM | ||
| ! write(*,'(A,I3)') "image_index(sca_int_1, [1], get_team()) = ", IMAGE_INDEX(sca_int_1, [1], GET_TEAM()) | ||
| write(*,'(A,I3)') "image_index(sca_int_1, [1], team_number=-1) = ", IMAGE_INDEX(sca_int_1, [1], TEAM_NUMBER=-1) | ||
| ! write(*,'(A,I3)') "image_index(sca_int_3, [1,1,1], get_team()) = ", IMAGE_INDEX(sca_int_3, [1,1,1], GET_TEAM()) | ||
| write(*,'(A,I3)') "image_index(sca_int_3, [1,1,1], team_number=-1) = ", IMAGE_INDEX(sca_int_3, [1,1,1], TEAM_NUMBER=-1) | ||
| # endif | ||
| # endif | ||
| # if HAVE_THIS_IMAGE_COARRAY | ||
| call status("Testing THIS_IMAGE(coarray)...") | ||
| write(*,'(A,I3)') "this_image(sca_int_1) = ", THIS_IMAGE(sca_int_1) | ||
| write(*,'(A,2I3)') "this_image(sca_int_2) = ", THIS_IMAGE(sca_int_2) | ||
| write(*,'(A,3I3)') "this_image(sca_int_3) = ", THIS_IMAGE(sca_int_3) | ||
| write(*,'(A,I3)') "this_image(sca_int_3, dim=2) = ", THIS_IMAGE(sca_int_3, dim=2) | ||
|
Comment on lines
+241
to
+244
Member
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. These three lines are the only new output that will be image-specific. I suggest that all the new write statements but these be conditional on |
||
| # endif | ||
| # endif | ||
|
|
||
| # if HAVE_EVENT_TYPE | ||
| CHECK_TYPE_COMPLIANCE(EVENT_TYPE, default_event, .false., 64) | ||
| # endif | ||
|
|
||
Oops, something went wrong.
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Please revert this change to the default, which would break existing CI jobs for versions predating coarray support.