Skip to content

Commit

Permalink
Merge branch 'master' into develop
Browse files Browse the repository at this point in the history
This merge introduces fixes from the v5.2 release for building with PIO 2.x,
and it connects the v5.2 tag to future commits on develop.

* master:
  Check for GPTL library when building with PIO2
  For PIO2, set 'pio_mode' to zero when creating netCDF-4 files
  Obtain MPI_COMM_SELF from mpas_dmpar in MPAS_stream_mgr_block_write
  Export MPI_COMM_SELF from mpas_dmpar module
  Fix MPAS fillvalue usage when using PIO2
  Update version number to v5.2
  • Loading branch information
mgduda committed Aug 1, 2017
2 parents 422761e + a74c8d1 commit 70b953b
Show file tree
Hide file tree
Showing 11 changed files with 25 additions and 7 deletions.
6 changes: 6 additions & 0 deletions Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -404,6 +404,9 @@ ifeq "$(USE_PIO2)" "true"
CPPINCLUDES = -DUSE_PIO2 -I$(PIO)/include
FCINCLUDES = -DUSE_PIO2 -I$(PIO)/include
LIBS = -L$(PIO)/lib -lpiof -lpioc
ifneq ($(wildcard $(PIO)/lib/libgptl.a), ) # Check for GPTL library for PIO2
LIBS += -lgptl
endif
else
CPPINCLUDES = -I$(PIO)/include
FCINCLUDES = -I$(PIO)/include
Expand All @@ -414,6 +417,9 @@ ifeq "$(USE_PIO2)" "true"
CPPINCLUDES = -DUSE_PIO2 -I$(PIO)/include
FCINCLUDES = -DUSE_PIO2 -I$(PIO)/include
LIBS = -L$(PIO) -lpiof -lpioc
ifneq ($(wildcard $(PIO)/libgptl.a), ) # Check for GPTL library for PIO2
LIBS += -lgptl
endif
else
CPPINCLUDES = -I$(PIO)
FCINCLUDES = -I$(PIO)
Expand Down
2 changes: 1 addition & 1 deletion README.md
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
MPAS-v5.1
MPAS-v5.2
====

The Model for Prediction Across Scales (MPAS) is a collaborative project for
Expand Down
2 changes: 1 addition & 1 deletion src/core_atmosphere/Registry.xml
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
<?xml version="1.0"?>
<registry model="mpas" core="atmosphere" core_abbrev="atm" version="5.1">
<registry model="mpas" core="atmosphere" core_abbrev="atm" version="5.2">

<!-- **************************************************************************************** -->
<!-- ************************************** Dimensions ************************************** -->
Expand Down
2 changes: 1 addition & 1 deletion src/core_init_atmosphere/Registry.xml
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
<?xml version="1.0"?>
<registry model="mpas" core="init_atmosphere" core_abbrev="init_atm" version="5.1">
<registry model="mpas" core="init_atmosphere" core_abbrev="init_atm" version="5.2">

<!-- **************************************************************************************** -->
<!-- ************************************** Dimensions ************************************** -->
Expand Down
2 changes: 1 addition & 1 deletion src/core_landice/Registry.xml
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
<?xml version="1.0"?>
<registry model="mpas" core="landice" core_abbrev="li" version="5.1">
<registry model="mpas" core="landice" core_abbrev="li" version="5.2">


<!-- ======================================================================= -->
Expand Down
2 changes: 1 addition & 1 deletion src/core_ocean/Registry.xml
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
<?xml version="1.0"?>
<registry model="mpas" core="ocean" core_abbrev="ocn" version="5.1">
<registry model="mpas" core="ocean" core_abbrev="ocn" version="5.2">

<dims>
<dim name="nCells" units="unitless"
Expand Down
2 changes: 1 addition & 1 deletion src/core_sw/Registry.xml
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
<?xml version="1.0"?>
<registry model="mpas" core="sw" core_abbrev="sw" version="5.1">
<registry model="mpas" core="sw" core_abbrev="sw" version="5.2">
<dims>
<dim name="nCells"/>
<dim name="nEdges"/>
Expand Down
2 changes: 1 addition & 1 deletion src/core_test/Registry.xml
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
<?xml version="1.0"?>
<registry model="mpas" core="test" core_abbrev="test" version="5.1">
<registry model="mpas" core="test" core_abbrev="test" version="5.2">
<dims>
<dim name="nCells"/>
<dim name="nEdges"/>
Expand Down
6 changes: 6 additions & 0 deletions src/framework/mpas_dmpar.F
Original file line number Diff line number Diff line change
Expand Up @@ -57,6 +57,12 @@ module mpas_dmpar
integer, parameter, public :: IO_NODE = 0
integer, parameter, public :: BUFSIZE = 6000

#ifdef _MPI
public :: MPI_COMM_SELF
#else
integer, parameter, public :: MPI_COMM_SELF = 0
#endif

public :: mpas_dmpar_init
public :: mpas_dmpar_finalize
public :: mpas_dmpar_abort
Expand Down
4 changes: 4 additions & 0 deletions src/framework/mpas_io.F
Original file line number Diff line number Diff line change
Expand Up @@ -281,7 +281,11 @@ type (MPAS_IO_Handle_type) function MPAS_io_open(filename, mode, ioformat, ioCon
pio_mode = PIO_64BIT_OFFSET
else if (ioformat == MPAS_IO_NETCDF4) then
pio_iotype = PIO_iotype_netcdf4p
#ifdef USE_PIO2
pio_mode = 0
#else
pio_mode = PIO_64BIT_OFFSET
#endif
end if
end if
Expand Down
2 changes: 2 additions & 0 deletions src/framework/mpas_stream_manager.F
Original file line number Diff line number Diff line change
Expand Up @@ -2678,6 +2678,8 @@ end subroutine MPAS_stream_mgr_write !}}}
!-----------------------------------------------------------------------
subroutine MPAS_stream_mgr_block_write(manager, writeBlock, streamID, timeLevel, mgLevel, forceWriteNow, writeTime, ierr) !{{{
use mpas_dmpar, only : MPI_COMM_SELF
implicit none
type (MPAS_streamManager_type), intent(inout) :: manager
Expand Down

0 comments on commit 70b953b

Please sign in to comment.