-
Notifications
You must be signed in to change notification settings - Fork 858
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
mpif08: add big count get_contents/get_envelope
some cleanup for get_extent Signed-off-by: Howard Pritchard <howardp@lanl.gov>
- Loading branch information
Showing
13 changed files
with
328 additions
and
56 deletions.
There are no files selected for viewing
This file contains 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
This file contains 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
This file contains 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
This file contains 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 |
---|---|---|
@@ -0,0 +1,53 @@ | ||
/* | ||
* Copyright (c) 2004-2005 The Trustees of Indiana University and Indiana | ||
* University Research and Technology | ||
* Corporation. All rights reserved. | ||
* Copyright (c) 2004-2005 The University of Tennessee and The University | ||
* of Tennessee Research Foundation. All rights | ||
* reserved. | ||
* Copyright (c) 2004-2005 High Performance Computing Center Stuttgart, | ||
* University of Stuttgart. All rights reserved. | ||
* Copyright (c) 2004-2005 The Regents of the University of California. | ||
* All rights reserved. | ||
* Copyright (c) 2011-2012 Cisco Systems, Inc. All rights reserved. | ||
* Copyright (c) 2015 Research Organization for Information Science | ||
* and Technology (RIST). All rights reserved. | ||
* $COPYRIGHT$ | ||
* | ||
* Additional copyrights may follow | ||
* | ||
* $HEADER$ | ||
*/ | ||
|
||
#include "ompi_config.h" | ||
|
||
#include "ompi/mpi/fortran/mpif-h/bindings.h" | ||
|
||
void ompi_type_get_envelope_f_c(MPI_Fint *type, MPI_Count *num_integers, | ||
MPI_Count *num_addresses, | ||
MPI_Count *num_large_counts, | ||
MPI_Count *num_datatypes, MPI_Fint *combiner, | ||
MPI_Fint *ierr) | ||
{ | ||
int c_ierr; | ||
MPI_Datatype c_type = PMPI_Type_f2c(*type); | ||
OMPI_SINGLE_NAME_DECL(num_integers); | ||
OMPI_SINGLE_NAME_DECL(num_addresses); | ||
OMPI_SINGLE_NAME_DECL(num_datatypes); | ||
OMPI_SINGLE_NAME_DECL(combiner); | ||
|
||
c_ierr = PMPI_Type_get_envelope_c(c_type, | ||
OMPI_SINGLE_NAME_CONVERT(num_integers), | ||
OMPI_SINGLE_NAME_CONVERT(num_addresses), | ||
OMPI_SINGLE_NAME_CONVERT(num_large_counts), | ||
OMPI_SINGLE_NAME_CONVERT(num_datatypes), | ||
OMPI_SINGLE_NAME_CONVERT(combiner)); | ||
if (NULL != ierr) *ierr = OMPI_INT_2_FINT(c_ierr); | ||
|
||
if (MPI_SUCCESS == c_ierr) { | ||
OMPI_SINGLE_INT_2_FINT(num_integers); | ||
OMPI_SINGLE_INT_2_FINT(num_addresses); | ||
OMPI_SINGLE_INT_2_FINT(num_datatypes); | ||
OMPI_SINGLE_INT_2_FINT(combiner); | ||
} | ||
} |
This file contains 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
This file contains 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
This file contains 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
This file contains 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
This file contains 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
This file contains 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 |
---|---|---|
@@ -0,0 +1,33 @@ | ||
! -*- f90 -*- | ||
! | ||
! Copyright (c) 2009-2012 Cisco Systems, Inc. All rights reserved. | ||
! Copyright (c) 2009-2012 Los Alamos National Security, LLC. | ||
! All rights reserved. | ||
! Copyright (c) 2018-2020 Research Organization for Information Science | ||
! and Technology (RIST). All rights reserved. | ||
! $COPYRIGHT$ | ||
|
||
#include "mpi-f08-rename.h" | ||
|
||
subroutine MPI_Type_get_contents_f08_c(datatype, max_integers, max_addresses, max_large_counts, & | ||
max_datatypes, array_of_integers, array_of_addresses, & | ||
array_of_large_counts, array_of_datatypes, ierror) | ||
use :: mpi_f08_types, only : MPI_Datatype, MPI_ADDRESS_KIND, MPI_COUNT_KIND | ||
use :: ompi_mpifh_bindings, only : ompi_type_get_contents_f_c | ||
implicit none | ||
TYPE(MPI_Datatype), INTENT(IN) :: datatype | ||
INTEGER(KIND=MPI_COUNT_KIND), INTENT(IN) :: max_integers, max_addresses, & | ||
max_large_counts, max_datatypes | ||
INTEGER, INTENT(OUT) :: array_of_integers(max_integers) | ||
INTEGER(MPI_ADDRESS_KIND), INTENT(OUT) :: array_of_addresses(max_addresses) | ||
INTEGER(KIND=MPI_COUNT_KIND), INTENT(OUT) :: array_of_large_counts(max_large_counts) | ||
TYPE(MPI_Datatype), INTENT(OUT) :: array_of_datatypes(max_datatypes) | ||
INTEGER, OPTIONAL, INTENT(OUT) :: ierror | ||
integer :: c_ierror | ||
|
||
call ompi_type_get_contents_f_c(datatype%MPI_VAL,max_integers,max_addresses, & | ||
max_large_counts, max_datatypes,array_of_integers,array_of_addresses, & | ||
array_of_large_counts, array_of_datatypes(:)%MPI_VAL,c_ierror) | ||
if (present(ierror)) ierror = c_ierror | ||
|
||
end subroutine MPI_Type_get_contents_f08_c |
Oops, something went wrong.