diff --git a/src/Infrastructure/Field/tests/ESMF_FieldRegridUTest.F90 b/src/Infrastructure/Field/tests/ESMF_FieldRegridUTest.F90 index a94a682782..96a04c6f8d 100644 --- a/src/Infrastructure/Field/tests/ESMF_FieldRegridUTest.F90 +++ b/src/Infrastructure/Field/tests/ESMF_FieldRegridUTest.F90 @@ -45028,6 +45028,7 @@ subroutine test_sph_vec_blnr_csG_to_llG(rc) real(ESMF_KIND_R8), pointer :: tmp1farrayPtr(:,:) real(ESMF_KIND_R8), pointer :: tmp2farrayPtr(:,:) real(ESMF_KIND_R8), pointer :: tmp3farrayPtr(:,:) + real(ESMF_KIND_R8), pointer :: dstVecfarrayPtr(:,:,:) integer :: clbnd(2),cubnd(2) integer :: fclbnd(3),fcubnd(3) integer :: i1,i2,i3, index(2) @@ -45411,6 +45412,13 @@ subroutine test_sph_vec_blnr_csG_to_llG(rc) return endif + call ESMF_FieldGet(dstVecField, lDE, dstVecfarrayPtr, rc=localrc) + if (localrc /=ESMF_SUCCESS) then + rc=ESMF_FAILURE + return + endif + + !! Set Field value do i1=fclbnd(1),fcubnd(1) @@ -45441,7 +45449,14 @@ subroutine test_sph_vec_blnr_csG_to_llG(rc) xfarrayPtr(i1,i2,2) = x*n_vec(1)+y*n_vec(2)+z*n_vec(3) ! initialize destination field - farrayPtr(i1,i2,i3)=0.0 + farrayPtr(i1,i2,1)=0.0 + farrayPtr(i1,i2,2)=0.0 + + ! initialize dest vec field + dstVecfarrayPtr(i1,i2,1)=1.0 + dstVecfarrayPtr(i1,i2,2)=2.0 + dstVecfarrayPtr(i1,i2,3)=3.0 + enddo enddo diff --git a/src/Infrastructure/Grid/src/ESMCI_Grid.C b/src/Infrastructure/Grid/src/ESMCI_Grid.C index 3aea47db9a..7739d738d7 100644 --- a/src/Infrastructure/Grid/src/ESMCI_Grid.C +++ b/src/Infrastructure/Grid/src/ESMCI_Grid.C @@ -8630,7 +8630,7 @@ void GridIter::getArrayVecData( arrayInd[undistDim]=d; // Get data - localArray->getDataInternal(curInd, data+pos); + localArray->getDataInternal(arrayInd, data+pos); // Advance to next entry in data pos++; diff --git a/src/Infrastructure/Mesh/src/ESMCI_Mesh_GToM_Glue.C b/src/Infrastructure/Mesh/src/ESMCI_Mesh_GToM_Glue.C index 594b2ad9b7..1f2a74d41a 100644 --- a/src/Infrastructure/Mesh/src/ESMCI_Mesh_GToM_Glue.C +++ b/src/Infrastructure/Mesh/src/ESMCI_Mesh_GToM_Glue.C @@ -116,26 +116,6 @@ void ESMCI_GridToMesh(const Grid &grid_, int staggerLoc, "- Grid being used in Regrid call does not contain coordinates at appropriate staggerloc ", ESMC_CONTEXT, &localrc); throw localrc; } - - - for (UInt i = 0; i < arrays.size(); ++i) { - - int rank=arrays[i]->getRank(); - - - // Get array undist. dim - int undistDimCount=arrays[i]->getTensorCount(); - - const int *arrayToDistGridMap=arrays[i]->getArrayToDistGridMap(); - - printf("%d rank=%d tensorCount=%d arrayToDistGridMap=",i,rank,undistDimCount); - for (int r=0; rgetName(),data[0],data[1],data[2]); + } } #ifdef G2M_DBG