Index: /NEMO/branches/2020/dev_r13296_HPC-07_mocavero_mpi3/src/ABL/ablmod.F90
===================================================================
--- /NEMO/branches/2020/dev_r13296_HPC-07_mocavero_mpi3/src/ABL/ablmod.F90	(revision 13629)
+++ /NEMO/branches/2020/dev_r13296_HPC-07_mocavero_mpi3/src/ABL/ablmod.F90	(revision 13630)
@@ -529,6 +529,11 @@
       !                            !<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<
       !
+#if defined key_mpi3
+      CALL lbc_lnk_nc_multi( 'ablmod',  u_abl(:,:,:,nt_a      ), 'T', -1._wp,  v_abl(:,:,:,nt_a)      , 'T', -1._wp                            )
+      CALL lbc_lnk_nc_multi( 'ablmod', tq_abl(:,:,:,nt_a,jp_ta), 'T', 1._wp , tq_abl(:,:,:,nt_a,jp_qa), 'T',  1._wp , kfillmode = jpfillnothing )   ! ++++ this should not be needed...
+#else
       CALL lbc_lnk_multi( 'ablmod',  u_abl(:,:,:,nt_a      ), 'T', -1._wp,  v_abl(:,:,:,nt_a)      , 'T', -1._wp                            )
       CALL lbc_lnk_multi( 'ablmod', tq_abl(:,:,:,nt_a,jp_ta), 'T', 1._wp , tq_abl(:,:,:,nt_a,jp_qa), 'T',  1._wp , kfillmode = jpfillnothing )   ! ++++ this should not be needed...
+#endif
       !
 #if defined key_iomput
@@ -594,5 +599,9 @@
       END_2D
       !
+#if defined key_mpi3
+      CALL lbc_lnk_nc_multi( 'ablmod', zwnd_i(:,:) , 'T', -1.0_wp, zwnd_j(:,:) , 'T', -1.0_wp )
+#else
       CALL lbc_lnk_multi( 'ablmod', zwnd_i(:,:) , 'T', -1.0_wp, zwnd_j(:,:) , 'T', -1.0_wp )
+#endif
       !
       ! ... scalar wind ( = | U10m - U_oce | ) at T-point (masked)
@@ -619,5 +628,9 @@
       END_2D
       !
+#if defined key_mpi3
+      CALL lbc_lnk_nc_multi( 'ablmod', ptaui(:,:), 'U', -1.0_wp, ptauj(:,:), 'V', -1.0_wp )
+#else
       CALL lbc_lnk_multi( 'ablmod', ptaui(:,:), 'U', -1.0_wp, ptauj(:,:), 'V', -1.0_wp )
+#endif
 
       CALL iom_put( "taum_oce", ptaum )
@@ -639,5 +652,9 @@
             &                      * ( 0.5_wp * ( v_abl(ji,jj+1,2,nt_a) + v_abl(ji,jj,2,nt_a) ) - pssv_ice(ji,jj) )
       END_2D
+#if defined key_mpi3
+      CALL lbc_lnk_nc_multi( 'ablmod', ptaui_ice, 'U', -1.0_wp, ptauj_ice, 'V', -1.0_wp )
+#else
       CALL lbc_lnk_multi( 'ablmod', ptaui_ice, 'U', -1.0_wp, ptauj_ice, 'V', -1.0_wp )
+#endif
       !
       IF(sn_cfctl%l_prtctl)   CALL prt_ctl( tab2d_1=ptaui_ice  , clinfo1=' abl_stp: putaui : '   &
@@ -658,5 +675,9 @@
             &         * ( zztmp2 - pssv_ice(ji,jj) )
       END_2D
+#if defined key_mpi3
+      CALL lbc_lnk_nc_multi( 'ablmod', ptaui_ice, 'U', -1.0_wp, ptauj_ice,'V', -1.0_wp )
+#else
       CALL lbc_lnk_multi( 'ablmod', ptaui_ice, 'U', -1.0_wp, ptauj_ice,'V', -1.0_wp )
+#endif
       !
       IF(sn_cfctl%l_prtctl) THEN
@@ -865,7 +886,15 @@
       ! Optional : could add pblh smoothing if pblh is noisy horizontally ...
       IF(ln_smth_pblh) THEN
+#if defined key_mpi3
+         CALL lbc_lnk_nc_multi( 'ablmod', pblh, 'T', 1.0_wp) !, kfillmode = jpfillnothing)
+#else
          CALL lbc_lnk( 'ablmod', pblh, 'T', 1.0_wp) !, kfillmode = jpfillnothing)
+#endif
          CALL smooth_pblh( pblh, msk_abl )
+#if defined key_mpi3
+         CALL lbc_lnk_nc_multi( 'ablmod', pblh, 'T', 1.0_wp) !, kfillmode = jpfillnothing)
+#else
          CALL lbc_lnk( 'ablmod', pblh, 'T', 1.0_wp) !, kfillmode = jpfillnothing)
+#endif
       ENDIF
       !                            !<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<
Index: /NEMO/branches/2020/dev_r13296_HPC-07_mocavero_mpi3/src/ICE/icecor.F90
===================================================================
--- /NEMO/branches/2020/dev_r13296_HPC-07_mocavero_mpi3/src/ICE/icecor.F90	(revision 13629)
+++ /NEMO/branches/2020/dev_r13296_HPC-07_mocavero_mpi3/src/ICE/icecor.F90	(revision 13630)
@@ -113,5 +113,9 @@
             ENDIF
          END_2D
+#if defined key_mpi3
+         CALL lbc_lnk_nc_multi( 'icecor', u_ice, 'U', -1.0_wp, v_ice, 'V', -1.0_wp )
+#else
          CALL lbc_lnk_multi( 'icecor', u_ice, 'U', -1.0_wp, v_ice, 'V', -1.0_wp )
+#endif
       ENDIF
 
Index: /NEMO/branches/2020/dev_r13296_HPC-07_mocavero_mpi3/src/ICE/icedyn.F90
===================================================================
--- /NEMO/branches/2020/dev_r13296_HPC-07_mocavero_mpi3/src/ICE/icedyn.F90	(revision 13629)
+++ /NEMO/branches/2020/dev_r13296_HPC-07_mocavero_mpi3/src/ICE/icedyn.F90	(revision 13630)
@@ -161,5 +161,9 @@
                   &             + e1v(ji,jj) * v_ice(ji,jj) - e1v(ji,jj-1) * v_ice(ji,jj-1) ) * r1_e1e2t(ji,jj)
             END_2D
+#if defined key_mpi3
+            CALL lbc_lnk_nc_multi( 'icedyn', zdivu_i, 'T', 1.0_wp )
+#else
             CALL lbc_lnk( 'icedyn', zdivu_i, 'T', 1.0_wp )
+#endif
             ! output
             CALL iom_put( 'icediv' , zdivu_i )
Index: /NEMO/branches/2020/dev_r13296_HPC-07_mocavero_mpi3/src/ICE/icedyn_adv_pra.F90
===================================================================
--- /NEMO/branches/2020/dev_r13296_HPC-07_mocavero_mpi3/src/ICE/icedyn_adv_pra.F90	(revision 13629)
+++ /NEMO/branches/2020/dev_r13296_HPC-07_mocavero_mpi3/src/ICE/icedyn_adv_pra.F90	(revision 13630)
@@ -158,6 +158,11 @@
          END_3D
       END DO
+#if defined key_mpi3
+      CALL lbc_lnk_nc_multi( 'icedyn_adv_pra', zei_max, 'T', 1. )
+      CALL lbc_lnk_nc_multi( 'icedyn_adv_pra', zes_max, 'T', 1. )
+#else
       CALL lbc_lnk( 'icedyn_adv_pra', zei_max, 'T', 1. )
       CALL lbc_lnk( 'icedyn_adv_pra', zes_max, 'T', 1. )
+#endif
       !
       !
@@ -311,5 +316,9 @@
                &                          - ( zudy(ji,jj) - zudy(ji-1,jj) + zvdx(ji,jj) - zvdx(ji,jj-1) ) * r1_e1e2t(ji,jj) * zdt
          END_2D
+#if defined key_mpi3
+         CALL lbc_lnk_nc_multi( 'icedyn_adv_pra', pato_i, 'T',  1.0_wp )
+#else
          CALL lbc_lnk( 'icedyn_adv_pra', pato_i, 'T',  1.0_wp )
+#endif
          !
          ! --- Ensure non-negative fields --- !
Index: /NEMO/branches/2020/dev_r13296_HPC-07_mocavero_mpi3/src/ICE/icedyn_adv_umx.F90
===================================================================
--- /NEMO/branches/2020/dev_r13296_HPC-07_mocavero_mpi3/src/ICE/icedyn_adv_umx.F90	(revision 13629)
+++ /NEMO/branches/2020/dev_r13296_HPC-07_mocavero_mpi3/src/ICE/icedyn_adv_umx.F90	(revision 13630)
@@ -162,6 +162,11 @@
          END_3D
       END DO
+#if defined key_mpi3
+      CALL lbc_lnk_nc_multi( 'icedyn_adv_pra', zei_max, 'T', 1. )
+      CALL lbc_lnk_nc_multi( 'icedyn_adv_pra', zes_max, 'T', 1. )
+#else
       CALL lbc_lnk( 'icedyn_adv_pra', zei_max, 'T', 1. )
       CALL lbc_lnk( 'icedyn_adv_pra', zes_max, 'T', 1. )
+#endif
       !
       !
@@ -384,5 +389,9 @@
                &                          - ( zudy(ji,jj) - zudy(ji-1,jj) + zvdx(ji,jj) - zvdx(ji,jj-1) ) * r1_e1e2t(ji,jj) * zdt
          END_2D
+#if defined key_mpi3
+         CALL lbc_lnk_nc_multi( 'icedyn_adv_umx', pato_i, 'T',  1.0_wp )
+#else
          CALL lbc_lnk( 'icedyn_adv_umx', pato_i, 'T',  1.0_wp )
+#endif
          !
          !
@@ -518,5 +527,9 @@
             END_2D
          END DO
+#if defined key_mpi3
+         CALL lbc_lnk_nc_multi( 'icedyn_adv_umx', zt_ups, 'T',  1.0_wp )
+#else
          CALL lbc_lnk( 'icedyn_adv_umx', zt_ups, 'T',  1.0_wp )
+#endif
          !
          IF    ( np_limiter == 1 ) THEN
@@ -601,5 +614,9 @@
                END_2D
             END DO
+#if defined key_mpi3
+            CALL lbc_lnk_nc_multi( 'icedyn_adv_umx', zpt, 'T', 1.0_wp )
+#else
             CALL lbc_lnk( 'icedyn_adv_umx', zpt, 'T', 1.0_wp )
+#endif
             !
             DO jl = 1, jpl              !-- flux in y-direction
@@ -625,5 +642,9 @@
                END_2D
             END DO
+#if defined key_mpi3
+            CALL lbc_lnk_nc_multi( 'icedyn_adv_umx', zpt, 'T', 1.0_wp )
+#else
             CALL lbc_lnk( 'icedyn_adv_umx', zpt, 'T', 1.0_wp )
+#endif
             !
             DO jl = 1, jpl              !-- flux in x-direction
@@ -647,5 +668,9 @@
          END_2D
       END DO
+#if defined key_mpi3
+      CALL lbc_lnk_nc_multi( 'icedyn_adv_umx', pt_ups, 'T', 1.0_wp )
+#else
       CALL lbc_lnk( 'icedyn_adv_umx', pt_ups, 'T', 1.0_wp )
+#endif
 
    END SUBROUTINE upstream
@@ -709,5 +734,9 @@
                END_2D
             END DO
+#if defined key_mpi3
+            CALL lbc_lnk_nc_multi( 'icedyn_adv_umx', zpt, 'T', 1.0_wp )
+#else
             CALL lbc_lnk( 'icedyn_adv_umx', zpt, 'T', 1.0_wp )
+#endif
 
             DO jl = 1, jpl              !-- flux in y-direction
@@ -735,5 +764,9 @@
                END_2D
             END DO
+#if defined key_mpi3
+            CALL lbc_lnk_nc_multi( 'icedyn_adv_umx', zpt, 'T', 1.0_wp )
+#else
             CALL lbc_lnk( 'icedyn_adv_umx', zpt, 'T', 1.0_wp )
+#endif
             !
             DO jl = 1, jpl              !-- flux in x-direction
@@ -793,5 +826,9 @@
             END_2D
          END DO
+#if defined key_mpi3
+         CALL lbc_lnk_nc_multi( 'icedyn_adv_umx', zpt, 'T', 1.0_wp )
+#else
          CALL lbc_lnk( 'icedyn_adv_umx', zpt, 'T', 1.0_wp )
+#endif
          !
          !                                                        !--  ultimate interpolation of pt at v-point  --!
@@ -820,5 +857,9 @@
             END_2D
          END DO
+#if defined key_mpi3
+         CALL lbc_lnk_nc_multi( 'icedyn_adv_umx', zpt, 'T', 1.0_wp )
+#else
          CALL lbc_lnk( 'icedyn_adv_umx', zpt, 'T', 1.0_wp )
+#endif
          !
          !                                                        !--  ultimate interpolation of pt at u-point  --!
@@ -873,5 +914,9 @@
          END DO
       END DO
+#if defined key_mpi3
+      CALL lbc_lnk_nc_multi( 'icedyn_adv_umx', ztu2, 'T', 1.0_wp )
+#else
       CALL lbc_lnk( 'icedyn_adv_umx', ztu2, 'T', 1.0_wp )
+#endif
       !
       !                                                     !--  BiLaplacian in i-direction  --!
@@ -887,5 +932,9 @@
          END DO
       END DO
+#if defined key_mpi3
+      CALL lbc_lnk_nc_multi( 'icedyn_adv_umx', ztu4, 'T', 1.0_wp )
+#else
       CALL lbc_lnk( 'icedyn_adv_umx', ztu4, 'T', 1.0_wp )
+#endif
       !
       !
@@ -1013,5 +1062,9 @@
          END_2D
       END DO
+#if defined key_mpi3
+      CALL lbc_lnk_nc_multi( 'icedyn_adv_umx', ztv2, 'T', 1.0_wp )
+#else
       CALL lbc_lnk( 'icedyn_adv_umx', ztv2, 'T', 1.0_wp )
+#endif
       !
       !                                                     !--  BiLaplacian in j-direction  --!
@@ -1024,5 +1077,9 @@
          END_2D
       END DO
+#if defined key_mpi3
+      CALL lbc_lnk_nc_multi( 'icedyn_adv_umx', ztv4, 'T', 1.0_wp )
+#else
       CALL lbc_lnk( 'icedyn_adv_umx', ztv4, 'T', 1.0_wp )
+#endif
       !
       !
@@ -1163,5 +1220,9 @@
             END_2D
          END DO
+#if defined key_mpi3
+         CALL lbc_lnk_nc_multi( 'icedyn_adv_umx', zti_ups, 'T', 1.0_wp, ztj_ups, 'T', 1.0_wp )
+#else
          CALL lbc_lnk_multi( 'icedyn_adv_umx', zti_ups, 'T', 1.0_wp, ztj_ups, 'T', 1.0_wp )
+#endif
 
          DO jl = 1, jpl
@@ -1185,5 +1246,9 @@
             END_2D
          END DO
+#if defined key_mpi3
+         CALL lbc_lnk_nc_multi( 'icedyn_adv_umx', pfu_ho, 'U', -1.0_wp, pfv_ho, 'V', -1.0_wp )   ! lateral boundary cond.
+#else
          CALL lbc_lnk_multi( 'icedyn_adv_umx', pfu_ho, 'U', -1.0_wp, pfv_ho, 'V', -1.0_wp )   ! lateral boundary cond.
+#endif
 
       ENDIF
@@ -1242,5 +1307,9 @@
          END_2D
       END DO
+#if defined key_mpi3
+      CALL lbc_lnk_nc_multi( 'icedyn_adv_umx', zbetup, 'T', 1.0_wp, zbetdo, 'T', 1.0_wp )   ! lateral boundary cond. (unchanged sign)
+#else
       CALL lbc_lnk_multi( 'icedyn_adv_umx', zbetup, 'T', 1.0_wp, zbetdo, 'T', 1.0_wp )   ! lateral boundary cond. (unchanged sign)
+#endif
 
       
@@ -1297,5 +1366,9 @@
          END_2D
       END DO
+#if defined key_mpi3
+      CALL lbc_lnk_nc_multi( 'icedyn_adv_umx', zslpx, 'U', -1.0_wp)   ! lateral boundary cond.
+#else
       CALL lbc_lnk( 'icedyn_adv_umx', zslpx, 'U', -1.0_wp)   ! lateral boundary cond.
+#endif
       
       DO jl = 1, jpl
@@ -1361,5 +1434,9 @@
          END_2D
       END DO
+#if defined key_mpi3
+      CALL lbc_lnk_nc_multi( 'icedyn_adv_umx', pfu_ho, 'U', -1.0_wp)   ! lateral boundary cond.
+#else
       CALL lbc_lnk( 'icedyn_adv_umx', pfu_ho, 'U', -1.0_wp)   ! lateral boundary cond.
+#endif
       !
    END SUBROUTINE limiter_x
@@ -1388,5 +1465,9 @@
          END_2D
       END DO
+#if defined key_mpi3
+      CALL lbc_lnk_nc_multi( 'icedyn_adv_umx', zslpy, 'V', -1.0_wp)   ! lateral boundary cond.
+#else
       CALL lbc_lnk( 'icedyn_adv_umx', zslpy, 'V', -1.0_wp)   ! lateral boundary cond.
+#endif
 
       DO jl = 1, jpl
@@ -1453,5 +1534,9 @@
          END_2D
       END DO
+#if defined key_mpi3
+      CALL lbc_lnk_nc_multi( 'icedyn_adv_umx', pfv_ho, 'V', -1.0_wp)   ! lateral boundary cond.
+#else
       CALL lbc_lnk( 'icedyn_adv_umx', pfv_ho, 'V', -1.0_wp)   ! lateral boundary cond.
+#endif
       !
    END SUBROUTINE limiter_y
Index: /NEMO/branches/2020/dev_r13296_HPC-07_mocavero_mpi3/src/ICE/icedyn_rdgrft.F90
===================================================================
--- /NEMO/branches/2020/dev_r13296_HPC-07_mocavero_mpi3/src/ICE/icedyn_rdgrft.F90	(revision 13629)
+++ /NEMO/branches/2020/dev_r13296_HPC-07_mocavero_mpi3/src/ICE/icedyn_rdgrft.F90	(revision 13630)
@@ -801,5 +801,9 @@
             strength(ji,jj) = zworka(ji,jj)
          END_2D
+#if defined key_mpi3
+         CALL lbc_lnk_nc_multi( 'icedyn_rdgrft', strength, 'T', 1.0_wp )
+#else
          CALL lbc_lnk( 'icedyn_rdgrft', strength, 'T', 1.0_wp )
+#endif
          !
       CASE( 2 )               !--- Temporal smoothing
@@ -820,5 +824,9 @@
             ENDIF
          END_2D
+#if defined key_mpi3
+         CALL lbc_lnk_nc_multi( 'icedyn_rdgrft', strength, 'T', 1.0_wp )
+#else
          CALL lbc_lnk( 'icedyn_rdgrft', strength, 'T', 1.0_wp )
+#endif
          !
       END SELECT
Index: /NEMO/branches/2020/dev_r13296_HPC-07_mocavero_mpi3/src/ICE/icedyn_rhg_evp.F90
===================================================================
--- /NEMO/branches/2020/dev_r13296_HPC-07_mocavero_mpi3/src/ICE/icedyn_rhg_evp.F90	(revision 13629)
+++ /NEMO/branches/2020/dev_r13296_HPC-07_mocavero_mpi3/src/ICE/icedyn_rhg_evp.F90	(revision 13630)
@@ -322,9 +322,5 @@
 
       END_2D
-#if defined key_mpi3
-      CALL lbc_lnk_nc_multi( 'icedyn_rhg_evp', zmf, 'T', 1.0_wp, zdt_m, 'T', 1.0_wp )
-#else
       CALL lbc_lnk_multi( 'icedyn_rhg_evp', zmf, 'T', 1.0_wp, zdt_m, 'T', 1.0_wp )
-#endif
       !
       !                                  !== Landfast ice parameterization ==!
@@ -408,6 +404,9 @@
 
          END_2D
+#if defined key_mpi3
+         CALL lbc_lnk_nc_multi( 'icedyn_rhg_evp', zdelta, 'T', 1.0_wp )
+#else
          CALL lbc_lnk( 'icedyn_rhg_evp', zdelta, 'T', 1.0_wp )
-
+#endif
          ! P/delta at T points
          DO_2D( 1, 1, 1, 1 )
Index: /NEMO/branches/2020/dev_r13296_HPC-07_mocavero_mpi3/src/ICE/icesbc.F90
===================================================================
--- /NEMO/branches/2020/dev_r13296_HPC-07_mocavero_mpi3/src/ICE/icesbc.F90	(revision 13629)
+++ /NEMO/branches/2020/dev_r13296_HPC-07_mocavero_mpi3/src/ICE/icesbc.F90	(revision 13630)
@@ -86,5 +86,9 @@
             vtau_ice(ji,jj) = vtau_ice(ji,jj) * xcplmask(ji,jj,0) + zvtau_ice(ji,jj) * ( 1. - xcplmask(ji,jj,0) )
          END_2D
+#if defined key_mpi3
+         CALL lbc_lnk_nc_multi( 'icesbc', utau_ice, 'U', -1.0_wp, vtau_ice, 'V', -1.0_wp )
+#else
          CALL lbc_lnk_multi( 'icesbc', utau_ice, 'U', -1.0_wp, vtau_ice, 'V', -1.0_wp )
+#endif
       ENDIF
       !
Index: /NEMO/branches/2020/dev_r13296_HPC-07_mocavero_mpi3/src/ICE/icethd.F90
===================================================================
--- /NEMO/branches/2020/dev_r13296_HPC-07_mocavero_mpi3/src/ICE/icethd.F90	(revision 13629)
+++ /NEMO/branches/2020/dev_r13296_HPC-07_mocavero_mpi3/src/ICE/icethd.F90	(revision 13630)
@@ -132,5 +132,9 @@
          END_2D
       ENDIF
+#if defined key_mpi3
+      CALL lbc_lnk_nc_multi( 'icethd', zfric, 'T',  1.0_wp )
+#else
       CALL lbc_lnk( 'icethd', zfric, 'T',  1.0_wp )
+#endif
       !
       !--------------------------------------------------------------------!
Index: /NEMO/branches/2020/dev_r13296_HPC-07_mocavero_mpi3/src/ICE/icethd_do.F90
===================================================================
--- /NEMO/branches/2020/dev_r13296_HPC-07_mocavero_mpi3/src/ICE/icethd_do.F90	(revision 13629)
+++ /NEMO/branches/2020/dev_r13296_HPC-07_mocavero_mpi3/src/ICE/icethd_do.F90	(revision 13630)
@@ -191,5 +191,9 @@
          END_2D
          ! 
+#if defined key_mpi3
+         CALL lbc_lnk_nc_multi( 'icethd_do', zvrel, 'T', 1.0_wp, ht_i_new, 'T', 1.0_wp  )
+#else
          CALL lbc_lnk_multi( 'icethd_do', zvrel, 'T', 1.0_wp, ht_i_new, 'T', 1.0_wp  )
+#endif
 
       ENDIF
Index: /NEMO/branches/2020/dev_r13296_HPC-07_mocavero_mpi3/src/ICE/iceupdate.F90
===================================================================
--- /NEMO/branches/2020/dev_r13296_HPC-07_mocavero_mpi3/src/ICE/iceupdate.F90	(revision 13629)
+++ /NEMO/branches/2020/dev_r13296_HPC-07_mocavero_mpi3/src/ICE/iceupdate.F90	(revision 13630)
@@ -342,5 +342,9 @@
             tmod_io(ji,jj) = zrhoco * SQRT( zmodt )          ! rhoco * |U_ice-U_oce| at T-point
          END_2D
+#if defined key_mpi3
+         CALL lbc_lnk_nc_multi( 'iceupdate', taum, 'T', 1.0_wp, tmod_io, 'T', 1.0_wp )
+#else
          CALL lbc_lnk_multi( 'iceupdate', taum, 'T', 1.0_wp, tmod_io, 'T', 1.0_wp )
+#endif
          !
          utau_oce(:,:) = utau(:,:)                    !* save the air-ocean stresses at ice time-step
@@ -371,5 +375,9 @@
          vtau(ji,jj) = ( 1._wp - zat_v ) * vtau_oce(ji,jj) + zat_v * zvtau_ice
       END_2D
+#if defined key_mpi3
+      CALL lbc_lnk_nc_multi( 'iceupdate', utau, 'U', -1.0_wp, vtau, 'V', -1.0_wp )   ! lateral boundary condition
+#else
       CALL lbc_lnk_multi( 'iceupdate', utau, 'U', -1.0_wp, vtau, 'V', -1.0_wp )   ! lateral boundary condition
+#endif
       !
       IF( ln_timing )   CALL timing_stop('ice_update_tau')
Index: /NEMO/branches/2020/dev_r13296_HPC-07_mocavero_mpi3/src/ICE/icewri.F90
===================================================================
--- /NEMO/branches/2020/dev_r13296_HPC-07_mocavero_mpi3/src/ICE/icewri.F90	(revision 13629)
+++ /NEMO/branches/2020/dev_r13296_HPC-07_mocavero_mpi3/src/ICE/icewri.F90	(revision 13630)
@@ -137,5 +137,9 @@
             z2d(ji,jj) = 0.5_wp * SQRT( z2da * z2da + z2db * z2db )
          END_2D
+#if defined key_mpi3
+         CALL lbc_lnk_nc_multi( 'icewri', z2d, 'T', 1.0_wp )
+#else
          CALL lbc_lnk( 'icewri', z2d, 'T', 1.0_wp )
+#endif
          CALL iom_put( 'icevel', z2d )
 
Index: /NEMO/branches/2020/dev_r13296_HPC-07_mocavero_mpi3/src/NST/agrif_oce_sponge.F90
===================================================================
--- /NEMO/branches/2020/dev_r13296_HPC-07_mocavero_mpi3/src/NST/agrif_oce_sponge.F90	(revision 13629)
+++ /NEMO/branches/2020/dev_r13296_HPC-07_mocavero_mpi3/src/NST/agrif_oce_sponge.F90	(revision 13630)
@@ -290,14 +290,26 @@
       
       IF( .NOT. spongedoneT .AND. .NOT. spongedoneU ) THEN
+#if defined key_mpi3
+         CALL lbc_lnk_nc_multi( 'agrif_Sponge', fspu, 'U', 1._wp, fspv, 'V', 1._wp, fspt, 'T', 1._wp, fspf, 'F', 1._wp )
+#else
          CALL lbc_lnk_multi( 'agrif_Sponge', fspu, 'U', 1._wp, fspv, 'V', 1._wp, fspt, 'T', 1._wp, fspf, 'F', 1._wp )
+#endif
          spongedoneT = .TRUE.
          spongedoneU = .TRUE.
       ENDIF
       IF( .NOT. spongedoneT ) THEN
+#if defined key_mpi3
+         CALL lbc_lnk_nc_multi( 'agrif_Sponge', fspu, 'U', 1._wp, fspv, 'V', 1._wp )
+#else
          CALL lbc_lnk_multi( 'agrif_Sponge', fspu, 'U', 1._wp, fspv, 'V', 1._wp )
+#endif
          spongedoneT = .TRUE.
       ENDIF
       IF( .NOT. spongedoneT .AND. .NOT. spongedoneU ) THEN
+#if defined key_mpi3
+         CALL lbc_lnk_nc_multi( 'agrif_Sponge', fspt, 'T', 1._wp, fspf, 'F', 1._wp )
+#else
          CALL lbc_lnk_multi( 'agrif_Sponge', fspt, 'T', 1._wp, fspf, 'F', 1._wp )
+#endif
          spongedoneU = .TRUE.
       ENDIF
@@ -323,5 +335,9 @@
       ztabrampu(:,:) = REAL( mbku_parent(:,:), wp )
       ztabrampv(:,:) = REAL( mbkv_parent(:,:), wp )
+#if defined key_mpi3
+      CALL lbc_lnk_nc_multi( 'Agrif_Sponge', ztabramp, 'T', 1._wp, ztabrampu, 'U', 1._wp, ztabrampv, 'V', 1._wp )
+#else
       CALL lbc_lnk_multi( 'Agrif_Sponge', ztabramp, 'T', 1._wp, ztabrampu, 'U', 1._wp, ztabrampv, 'V', 1._wp )
+#endif
       mbkt_parent(:,:) = NINT( ztabramp (:,:) )
       mbku_parent(:,:) = NINT( ztabrampu(:,:) )
Index: /NEMO/branches/2020/dev_r13296_HPC-07_mocavero_mpi3/src/NST/agrif_user.F90
===================================================================
--- /NEMO/branches/2020/dev_r13296_HPC-07_mocavero_mpi3/src/NST/agrif_user.F90	(revision 13629)
+++ /NEMO/branches/2020/dev_r13296_HPC-07_mocavero_mpi3/src/NST/agrif_user.F90	(revision 13630)
@@ -99,6 +99,11 @@
 
 
+#if defined key_mpi3
+      CALL lbc_lnk_nc_multi( 'agrif_istate', uu(:,:,:  ,Kbb), 'U', -1.0_wp , vv(:,:,:,Kbb), 'V', -1.0_wp )
+      CALL lbc_lnk_nc_multi(       'agrif_istate', ts(:,:,:,:,Kbb), 'T',  1.0_wp )
+#else
       CALL lbc_lnk_multi( 'agrif_istate', uu(:,:,:  ,Kbb), 'U', -1.0_wp , vv(:,:,:,Kbb), 'V', -1.0_wp )
       CALL lbc_lnk(       'agrif_istate', ts(:,:,:,:,Kbb), 'T',  1.0_wp )
+#endif
 
    END SUBROUTINE Agrif_Istate
@@ -273,19 +278,35 @@
       ENDIF
       !
+#if defined key_mpi3
+      CALL lbc_lnk_nc_multi( 'Agrif_Init_Domain', hu0_parent, 'U', 1.0_wp, hv0_parent, 'V', 1.0_wp )
+#else
       CALL lbc_lnk_multi( 'Agrif_Init_Domain', hu0_parent, 'U', 1.0_wp, hv0_parent, 'V', 1.0_wp )
+#endif
       DO_2D( 0, 0, 0, 0 )
          zk(ji,jj) = REAL( mbku_parent(ji,jj), wp )
       END_2D
+#if defined key_mpi3
+      CALL lbc_lnk_nc_multi( 'Agrif_InitValues_cont', zk, 'U', 1.0_wp )
+#else
       CALL lbc_lnk( 'Agrif_InitValues_cont', zk, 'U', 1.0_wp )
+#endif
       mbku_parent(:,:) = MAX( NINT( zk(:,:) ), 1 )
       DO_2D( 0, 0, 0, 0 )
          zk(ji,jj) = REAL( mbkv_parent(ji,jj), wp )
       END_2D
+#if defined key_mpi3
+      CALL lbc_lnk_nc_multi( 'Agrif_InitValues_cont', zk, 'V', 1.0_wp )
+#else
       CALL lbc_lnk( 'Agrif_InitValues_cont', zk, 'V', 1.0_wp )
+#endif
       mbkv_parent(:,:) = MAX( NINT( zk(:,:) ), 1 )   
 
       IF ( ln_init_chfrpar ) THEN 
          CALL Agrif_Init_Variable(sshini_id, procname=agrif_initssh)
+#if defined key_mpi3
+         CALL lbc_lnk_nc_multi( 'Agrif_Init_Domain', ssh(:,:,Kbb), 'T', 1. )
+#else
          CALL lbc_lnk( 'Agrif_Init_Domain', ssh(:,:,Kbb), 'T', 1. )
+#endif
          DO jk = 1, jpk
                e3t(:,:,jk,Kbb) =  e3t_0(:,:,jk) * ( ht_0(:,:) + ssh(:,:,Kbb)  ) &
Index: /NEMO/branches/2020/dev_r13296_HPC-07_mocavero_mpi3/src/OCE/ASM/asminc.F90
===================================================================
--- /NEMO/branches/2020/dev_r13296_HPC-07_mocavero_mpi3/src/OCE/ASM/asminc.F90	(revision 13629)
+++ /NEMO/branches/2020/dev_r13296_HPC-07_mocavero_mpi3/src/OCE/ASM/asminc.F90	(revision 13630)
@@ -421,5 +421,9 @@
                      &            / e3t(ji,jj,jk,Kmm)
                END_2D
+#if defined key_mpi3
+               CALL lbc_lnk_nc_multi( 'asminc', zhdiv, 'T', 1.0_wp )   ! lateral boundary cond. (no sign change)
+#else
                CALL lbc_lnk( 'asminc', zhdiv, 'T', 1.0_wp )   ! lateral boundary cond. (no sign change)
+#endif
                !
                DO_2D( 0, 0, 0, 0 )
Index: /NEMO/branches/2020/dev_r13296_HPC-07_mocavero_mpi3/src/OCE/BDY/bdydyn2d.F90
===================================================================
--- /NEMO/branches/2020/dev_r13296_HPC-07_mocavero_mpi3/src/OCE/BDY/bdydyn2d.F90	(revision 13629)
+++ /NEMO/branches/2020/dev_r13296_HPC-07_mocavero_mpi3/src/OCE/BDY/bdydyn2d.F90	(revision 13630)
@@ -102,8 +102,16 @@
          END DO
          IF( ANY(llsend2) .OR. ANY(llrecv2) ) THEN   ! if need to send/recv in at least one direction
+#if defined key_mpi3
+            CALL lbc_lnk_nc_multi( 'bdydyn2d', pua2d, 'U', -1.0_wp, kfillmode=jpfillnothing ,lsend=llsend2, lrecv=llrecv2 )
+#else
             CALL lbc_lnk( 'bdydyn2d', pua2d, 'U', -1.0_wp, kfillmode=jpfillnothing ,lsend=llsend2, lrecv=llrecv2 )
+#endif
          END IF
          IF( ANY(llsend3) .OR. ANY(llrecv3) ) THEN   ! if need to send/recv in at least one direction
+#if defined key_mpi3
+            CALL lbc_lnk_nc_multi( 'bdydyn2d', pva2d, 'V', -1.0_wp, kfillmode=jpfillnothing ,lsend=llsend3, lrecv=llrecv3 )
+#else
             CALL lbc_lnk( 'bdydyn2d', pva2d, 'V', -1.0_wp, kfillmode=jpfillnothing ,lsend=llsend3, lrecv=llrecv3 )
+#endif
          END IF
          !
@@ -324,5 +332,9 @@
          IF( nn_hls > 1 .AND. ir == 1 ) CYCLE   ! at least 2 halos will be corrected -> no need to correct rim 1 before rim 0
          IF( ANY(llsend1) .OR. ANY(llrecv1) ) THEN   ! if need to send/recv in at least one direction
+#if defined key_mpi3
+            CALL lbc_lnk_nc_multi( 'bdydyn2d', zssh(:,:,1), 'T',  1.0_wp, kfillmode=jpfillnothing ,lsend=llsend1, lrecv=llrecv1 )
+#else
             CALL lbc_lnk( 'bdydyn2d', zssh(:,:,1), 'T',  1.0_wp, kfillmode=jpfillnothing ,lsend=llsend1, lrecv=llrecv1 )
+#endif
          END IF
       END DO
Index: /NEMO/branches/2020/dev_r13296_HPC-07_mocavero_mpi3/src/OCE/BDY/bdydyn3d.F90
===================================================================
--- /NEMO/branches/2020/dev_r13296_HPC-07_mocavero_mpi3/src/OCE/BDY/bdydyn3d.F90	(revision 13629)
+++ /NEMO/branches/2020/dev_r13296_HPC-07_mocavero_mpi3/src/OCE/BDY/bdydyn3d.F90	(revision 13630)
@@ -99,8 +99,16 @@
          !
          IF( ANY(llsend2) .OR. ANY(llrecv2) ) THEN   ! if need to send/recv in at least one direction
+#if defined key_mpi3
+            CALL lbc_lnk_nc_multi( 'bdydyn2d', puu(:,:,:,Kaa), 'U', -1.0_wp, kfillmode=jpfillnothing ,lsend=llsend2, lrecv=llrecv2 )
+#else
             CALL lbc_lnk( 'bdydyn2d', puu(:,:,:,Kaa), 'U', -1.0_wp, kfillmode=jpfillnothing ,lsend=llsend2, lrecv=llrecv2 )
+#endif
          END IF
          IF( ANY(llsend3) .OR. ANY(llrecv3) ) THEN   ! if need to send/recv in at least one direction
+#if defined key_mpi3
+            CALL lbc_lnk_nc_multi( 'bdydyn2d', pvv(:,:,:,Kaa), 'V', -1.0_wp, kfillmode=jpfillnothing ,lsend=llsend3, lrecv=llrecv3 )
+#else
             CALL lbc_lnk( 'bdydyn2d', pvv(:,:,:,Kaa), 'V', -1.0_wp, kfillmode=jpfillnothing ,lsend=llsend3, lrecv=llrecv3 )
+#endif
          END IF
       END DO   ! ir
Index: /NEMO/branches/2020/dev_r13296_HPC-07_mocavero_mpi3/src/OCE/BDY/bdyice.F90
===================================================================
--- /NEMO/branches/2020/dev_r13296_HPC-07_mocavero_mpi3/src/OCE/BDY/bdyice.F90	(revision 13629)
+++ /NEMO/branches/2020/dev_r13296_HPC-07_mocavero_mpi3/src/OCE/BDY/bdyice.F90	(revision 13630)
@@ -94,4 +94,13 @@
          IF( ANY(llsend1) .OR. ANY(llrecv1) ) THEN   ! if need to send/recv in at least one direction
             ! exchange 3d arrays
+#if defined key_mpi3
+            CALL lbc_lnk_nc_multi('bdyice', a_i , 'T', 1._wp, h_i , 'T', 1._wp, h_s , 'T', 1._wp, oa_i, 'T', 1._wp                   &
+               &                       , s_i , 'T', 1._wp, t_su, 'T', 1._wp, v_i , 'T', 1._wp, v_s , 'T', 1._wp, sv_i, 'T', 1._wp &
+               &                       , a_ip, 'T', 1._wp, v_ip, 'T', 1._wp, v_il, 'T', 1._wp                                     &
+               &                       , kfillmode=jpfillnothing ,lsend=llsend1, lrecv=llrecv1 )
+            ! exchange 4d arrays :   third dimension = 1   and then   third dimension = jpk
+            CALL lbc_lnk_nc_multi('bdyice', t_s , 'T', 1._wp, e_s , 'T', 1._wp, kfillmode=jpfillnothing ,lsend=llsend1, lrecv=llrecv1 )
+            CALL lbc_lnk_nc_multi('bdyice', t_i , 'T', 1._wp, e_i , 'T', 1._wp, kfillmode=jpfillnothing ,lsend=llsend1, lrecv=llrecv1 )
+#else
             CALL lbc_lnk_multi('bdyice', a_i , 'T', 1._wp, h_i , 'T', 1._wp, h_s , 'T', 1._wp, oa_i, 'T', 1._wp                   &
                &                       , s_i , 'T', 1._wp, t_su, 'T', 1._wp, v_i , 'T', 1._wp, v_s , 'T', 1._wp, sv_i, 'T', 1._wp &
@@ -101,4 +110,5 @@
             CALL lbc_lnk_multi('bdyice', t_s , 'T', 1._wp, e_s , 'T', 1._wp, kfillmode=jpfillnothing ,lsend=llsend1, lrecv=llrecv1 )
             CALL lbc_lnk_multi('bdyice', t_i , 'T', 1._wp, e_i , 'T', 1._wp, kfillmode=jpfillnothing ,lsend=llsend1, lrecv=llrecv1 )
+#endif
          END IF
       END DO   ! ir
@@ -438,5 +448,9 @@
             END DO
             IF( ANY(llsend2) .OR. ANY(llrecv2) ) THEN   ! if need to send/recv in at least one direction
+#if defined key_mpi3
+               CALL lbc_lnk_nc_multi( 'bdyice', u_ice, 'U', -1.0_wp, kfillmode=jpfillnothing ,lsend=llsend2, lrecv=llrecv2 )
+#else
                CALL lbc_lnk( 'bdyice', u_ice, 'U', -1.0_wp, kfillmode=jpfillnothing ,lsend=llsend2, lrecv=llrecv2 )
+#endif
             END IF
          CASE ( 'V' )
@@ -452,5 +466,9 @@
             END DO
             IF( ANY(llsend3) .OR. ANY(llrecv3) ) THEN   ! if need to send/recv in at least one direction
+#if defined key_mpi3
+               CALL lbc_lnk_nc_multi( 'bdyice', v_ice, 'V', -1.0_wp, kfillmode=jpfillnothing ,lsend=llsend3, lrecv=llrecv3 )
+#else
                CALL lbc_lnk( 'bdyice', v_ice, 'V', -1.0_wp, kfillmode=jpfillnothing ,lsend=llsend3, lrecv=llrecv3 )
+#endif
             END IF
          END SELECT
Index: /NEMO/branches/2020/dev_r13296_HPC-07_mocavero_mpi3/src/OCE/BDY/bdyini.F90
===================================================================
--- /NEMO/branches/2020/dev_r13296_HPC-07_mocavero_mpi3/src/OCE/BDY/bdyini.F90	(revision 13629)
+++ /NEMO/branches/2020/dev_r13296_HPC-07_mocavero_mpi3/src/OCE/BDY/bdyini.F90	(revision 13630)
@@ -638,5 +638,9 @@
          END DO
       END DO
+#if defined key_mpi3
+      CALL lbc_lnk_nc_multi( 'bdyini', zfmask, 'F', 1.0_wp )
+#else
       CALL lbc_lnk( 'bdyini', zfmask, 'F', 1.0_wp )
+#endif
 
       ! Read global 2D mask at T-points: bdytmask
@@ -654,5 +658,9 @@
          END DO
       END DO
+#if defined key_mpi3
+      CALL lbc_lnk_nc_multi( 'bdyini', bdyumask, 'U', 1.0_wp , bdyvmask, 'V', 1.0_wp )   ! Lateral boundary cond. 
+#else
       CALL lbc_lnk_multi( 'bdyini', bdyumask, 'U', 1.0_wp , bdyvmask, 'V', 1.0_wp )   ! Lateral boundary cond. 
+#endif
 
       ! bdy masks are now set to zero on rim 0 points:
@@ -695,5 +703,9 @@
          END DO
       END DO
+#if defined key_mpi3
+      CALL lbc_lnk_nc_multi( 'bdyini', zfmask, 'F', 1.0_wp )
+#else
       CALL lbc_lnk( 'bdyini', zfmask, 'F', 1.0_wp )
+#endif
 
       ! bdy masks are now set to zero on rim1 points:
@@ -871,7 +883,13 @@
             ENDIF 
             SELECT CASE( igrd )
+#if defined key_mpi3
+               CASE( 1 )   ;   CALL lbc_lnk_nc_multi( 'bdyini', ztmp, 'T', 1.0_wp )
+               CASE( 2 )   ;   CALL lbc_lnk_nc_multi( 'bdyini', ztmp, 'U', 1.0_wp )
+               CASE( 3 )   ;   CALL lbc_lnk_nc_multi( 'bdyini', ztmp, 'V', 1.0_wp )
+#else
                CASE( 1 )   ;   CALL lbc_lnk( 'bdyini', ztmp, 'T', 1.0_wp )
                CASE( 2 )   ;   CALL lbc_lnk( 'bdyini', ztmp, 'U', 1.0_wp )
                CASE( 3 )   ;   CALL lbc_lnk( 'bdyini', ztmp, 'V', 1.0_wp )
+#endif
             END SELECT 
             DO ib = ibeg, iend
@@ -919,7 +937,13 @@
             ENDIF
             SELECT CASE( igrd )
+#if defined key_mpi3
+               CASE( 1 )   ;   CALL lbc_lnk_nc_multi( 'bdyini', ztmp, 'T', 1.0_wp )
+               CASE( 2 )   ;   CALL lbc_lnk_nc_multi( 'bdyini', ztmp, 'U', 1.0_wp )
+               CASE( 3 )   ;   CALL lbc_lnk_nc_multi( 'bdyini', ztmp, 'V', 1.0_wp )
+#else
                CASE( 1 )   ;   CALL lbc_lnk( 'bdyini', ztmp, 'T', 1.0_wp )
                CASE( 2 )   ;   CALL lbc_lnk( 'bdyini', ztmp, 'U', 1.0_wp )
                CASE( 3 )   ;   CALL lbc_lnk( 'bdyini', ztmp, 'V', 1.0_wp )
+#endif
             END SELECT 
             DO ib = ibeg, iend
@@ -1007,7 +1031,13 @@
             END DO
             SELECT CASE( igrd )
+#if defined key_mpi3
+               CASE( 1 )   ;   CALL lbc_lnk_nc_multi( 'bdyini', ztmp, 'T', 1.0_wp )
+               CASE( 2 )   ;   CALL lbc_lnk_nc_multi( 'bdyini', ztmp, 'U', 1.0_wp )
+               CASE( 3 )   ;   CALL lbc_lnk_nc_multi( 'bdyini', ztmp, 'V', 1.0_wp )
+#else
                CASE( 1 )   ;   CALL lbc_lnk( 'bdyini', ztmp, 'T', 1.0_wp )
                CASE( 2 )   ;   CALL lbc_lnk( 'bdyini', ztmp, 'U', 1.0_wp )
                CASE( 3 )   ;   CALL lbc_lnk( 'bdyini', ztmp, 'V', 1.0_wp )
+#endif
             END SELECT 
             DO ib = ibeg, iend
Index: /NEMO/branches/2020/dev_r13296_HPC-07_mocavero_mpi3/src/OCE/BDY/bdytra.F90
===================================================================
--- /NEMO/branches/2020/dev_r13296_HPC-07_mocavero_mpi3/src/OCE/BDY/bdytra.F90	(revision 13629)
+++ /NEMO/branches/2020/dev_r13296_HPC-07_mocavero_mpi3/src/OCE/BDY/bdytra.F90	(revision 13630)
@@ -100,5 +100,9 @@
          END DO
          IF( ANY(llsend1) .OR. ANY(llrecv1) ) THEN   ! if need to send/recv in at least one direction
+#if defined key_mpi3
+            CALL lbc_lnk_nc_multi( 'bdytra', pts(:,:,:,jn,Kaa), 'T',  1.0_wp, kfillmode=jpfillnothing ,lsend=llsend1, lrecv=llrecv1 )
+#else
             CALL lbc_lnk( 'bdytra', pts(:,:,:,jn,Kaa), 'T',  1.0_wp, kfillmode=jpfillnothing ,lsend=llsend1, lrecv=llrecv1 )
+#endif
          ENDIF
          !
Index: /NEMO/branches/2020/dev_r13296_HPC-07_mocavero_mpi3/src/OCE/CRS/crsfld.F90
===================================================================
--- /NEMO/branches/2020/dev_r13296_HPC-07_mocavero_mpi3/src/OCE/CRS/crsfld.F90	(revision 13629)
+++ /NEMO/branches/2020/dev_r13296_HPC-07_mocavero_mpi3/src/OCE/CRS/crsfld.F90	(revision 13630)
@@ -156,5 +156,9 @@
                &          + vv(ji,jj  ,jk,Kmm)**2 * e1v(ji,jj  ) * e3v(ji,jj  ,jk,Kmm)   )
          END_3D
+#if defined key_mpi3
+         CALL lbc_lnk_nc_multi( 'crsfld', z3d, 'T', 1.0_wp )
+#else
          CALL lbc_lnk( 'crsfld', z3d, 'T', 1.0_wp )
+#endif
          !
          CALL crs_dom_ope( z3d, 'VOL', 'T', tmask, zt_crs, p_e12=e1e2t, p_e3=ze3t, psgn=1.0_wp )
Index: /NEMO/branches/2020/dev_r13296_HPC-07_mocavero_mpi3/src/OCE/DIA/diaar5.F90
===================================================================
--- /NEMO/branches/2020/dev_r13296_HPC-07_mocavero_mpi3/src/OCE/DIA/diaar5.F90	(revision 13629)
+++ /NEMO/branches/2020/dev_r13296_HPC-07_mocavero_mpi3/src/OCE/DIA/diaar5.F90	(revision 13630)
@@ -325,5 +325,9 @@
          z2d(ji,jj) = z2d(ji,jj) + puflx(ji,jj,jk) 
       END_3D
+#if defined key_mpi3
+       CALL lbc_lnk_nc_multi( 'diaar5', z2d, 'U', -1.0_wp )
+#else
        CALL lbc_lnk( 'diaar5', z2d, 'U', -1.0_wp )
+#endif
        IF( cptr == 'adv' ) THEN
           IF( ktra == jp_tem ) CALL iom_put( 'uadv_heattr' , rho0_rcp * z2d )  ! advective heat transport in i-direction
@@ -339,5 +343,9 @@
           z2d(ji,jj) = z2d(ji,jj) + pvflx(ji,jj,jk) 
        END_3D
+#if defined key_mpi3
+       CALL lbc_lnk_nc_multi( 'diaar5', z2d, 'V', -1.0_wp )
+#else
        CALL lbc_lnk( 'diaar5', z2d, 'V', -1.0_wp )
+#endif
        IF( cptr == 'adv' ) THEN
           IF( ktra == jp_tem ) CALL iom_put( 'vadv_heattr' , rho0_rcp * z2d )  ! advective heat transport in j-direction
Index: /NEMO/branches/2020/dev_r13296_HPC-07_mocavero_mpi3/src/OCE/DIA/diaptr.F90
===================================================================
--- /NEMO/branches/2020/dev_r13296_HPC-07_mocavero_mpi3/src/OCE/DIA/diaptr.F90	(revision 13629)
+++ /NEMO/branches/2020/dev_r13296_HPC-07_mocavero_mpi3/src/OCE/DIA/diaptr.F90	(revision 13630)
@@ -588,5 +588,9 @@
             p_fval(ji,jj) = p_fval(ji,jj-1) + pva(ji,jj) * tmask_i(ji,jj)
          END_2D
+#if defined key_mpi3
+         CALL lbc_lnk_nc_multi( 'diaptr', p_fval, 'U', -1.0_wp )
+#else
          CALL lbc_lnk( 'diaptr', p_fval, 'U', -1.0_wp )
+#endif
       END DO
       ! 
Index: /NEMO/branches/2020/dev_r13296_HPC-07_mocavero_mpi3/src/OCE/DOM/dommsk.F90
===================================================================
--- /NEMO/branches/2020/dev_r13296_HPC-07_mocavero_mpi3/src/OCE/DOM/dommsk.F90	(revision 13629)
+++ /NEMO/branches/2020/dev_r13296_HPC-07_mocavero_mpi3/src/OCE/DOM/dommsk.F90	(revision 13630)
@@ -162,5 +162,9 @@
             &            * tmask(ji,jj+1,jk) * tmask(ji+1,jj+1,jk)
       END_3D
+#if defined key_mpi3
+      CALL lbc_lnk_nc_multi( 'dommsk', umask, 'U', 1.0_wp, vmask, 'V', 1.0_wp, fmask, 'F', 1.0_wp )      ! Lateral boundary conditions
+#else
       CALL lbc_lnk_multi( 'dommsk', umask, 'U', 1.0_wp, vmask, 'V', 1.0_wp, fmask, 'F', 1.0_wp )      ! Lateral boundary conditions
+#endif
  
       ! Ocean/land mask at wu-, wv- and w points    (computed from tmask)
@@ -219,5 +223,9 @@
          END DO
          !
+#if defined key_mpi3
+         CALL lbc_lnk_nc_multi( 'dommsk', fmask, 'F', 1._wp )      ! Lateral boundary conditions on fmask
+#else
          CALL lbc_lnk( 'dommsk', fmask, 'F', 1._wp )      ! Lateral boundary conditions on fmask
+#endif
          !
          ! CAUTION : The fmask may be further modified in dyn_vor_init ( dynvor.F90 ) depending on ln_vorlat
Index: /NEMO/branches/2020/dev_r13296_HPC-07_mocavero_mpi3/src/OCE/DOM/domqco.F90
===================================================================
--- /NEMO/branches/2020/dev_r13296_HPC-07_mocavero_mpi3/src/OCE/DOM/domqco.F90	(revision 13629)
+++ /NEMO/branches/2020/dev_r13296_HPC-07_mocavero_mpi3/src/OCE/DOM/domqco.F90	(revision 13630)
@@ -163,5 +163,9 @@
       !
       IF( .NOT.PRESENT( pr3f ) ) THEN              !- lbc on ratio at u-, v-points only
+#if defined key_mpi3
+         CALL lbc_lnk_nc_multi( 'dom_qco_r3c', pr3u, 'U', 1._wp, pr3v, 'V', 1._wp )
+#else
          CALL lbc_lnk_multi( 'dom_qco_r3c', pr3u, 'U', 1._wp, pr3v, 'V', 1._wp )
+#endif
          !
          !
@@ -182,5 +186,9 @@
          ENDIF
          !                                                 ! lbc on ratio at u-,v-,f-points
+#if defined key_mpi3
+         CALL lbc_lnk_nc_multi( 'dom_qco_r3c', pr3u, 'U', 1._wp, pr3v, 'V', 1._wp, pr3f, 'F', 1._wp )
+#else
          CALL lbc_lnk_multi( 'dom_qco_r3c', pr3u, 'U', 1._wp, pr3v, 'V', 1._wp, pr3f, 'F', 1._wp )
+#endif
          !
       ENDIF
Index: /NEMO/branches/2020/dev_r13296_HPC-07_mocavero_mpi3/src/OCE/DOM/domvvl.F90
===================================================================
--- /NEMO/branches/2020/dev_r13296_HPC-07_mocavero_mpi3/src/OCE/DOM/domvvl.F90	(revision 13629)
+++ /NEMO/branches/2020/dev_r13296_HPC-07_mocavero_mpi3/src/OCE/DOM/domvvl.F90	(revision 13630)
@@ -439,9 +439,16 @@
          !                               ! d - thickness diffusion transport: boundary conditions
          !                             (stored for tracer advction and continuity equation)
+#if defined key_mpi3
+         CALL lbc_lnk_nc_multi( 'domvvl', un_td , 'U' , -1._wp, vn_td , 'V' , -1._wp)
+#else
          CALL lbc_lnk_multi( 'domvvl', un_td , 'U' , -1._wp, vn_td , 'V' , -1._wp)
-
+#endif
          ! 4 - Time stepping of baroclinic scale factors
          ! ---------------------------------------------
+#if defined key_mpi3
+         CALL lbc_lnk_nc_multi( 'domvvl', tilde_e3t_a(:,:,:), 'T', 1._wp )
+#else
          CALL lbc_lnk( 'domvvl', tilde_e3t_a(:,:,:), 'T', 1._wp )
+#endif
          tilde_e3t_a(:,:,:) = tilde_e3t_b(:,:,:) + rDt * tmask(:,:,:) * tilde_e3t_a(:,:,:)
 
Index: /NEMO/branches/2020/dev_r13296_HPC-07_mocavero_mpi3/src/OCE/DOM/domwri.F90
===================================================================
--- /NEMO/branches/2020/dev_r13296_HPC-07_mocavero_mpi3/src/OCE/DOM/domwri.F90	(revision 13629)
+++ /NEMO/branches/2020/dev_r13296_HPC-07_mocavero_mpi3/src/OCE/DOM/domwri.F90	(revision 13630)
@@ -229,5 +229,9 @@
          END DO
       END DO
+#if defined key_mpi3
+      CALL lbc_lnk_nc_multi( 'domwri', zx1, 'T', 1.0_wp )
+#else
       CALL lbc_lnk( 'domwri', zx1, 'T', 1.0_wp )
+#endif
       !
       IF( PRESENT( px1 ) )    px1 = zx1
Index: /NEMO/branches/2020/dev_r13296_HPC-07_mocavero_mpi3/src/OCE/DOM/domzgr.F90
===================================================================
--- /NEMO/branches/2020/dev_r13296_HPC-07_mocavero_mpi3/src/OCE/DOM/domzgr.F90	(revision 13629)
+++ /NEMO/branches/2020/dev_r13296_HPC-07_mocavero_mpi3/src/OCE/DOM/domzgr.F90	(revision 13630)
@@ -125,5 +125,9 @@
          zmsk(:,mj0(jpjglo-nn_hls):mj1(jpjglo-nn_hls)  ) = 0._wp   ! last    line of inner global domain at 0
       ENDIF
+#if defined key_mpi3
+      CALL lbc_lnk_nc_multi( 'usrdef_zgr', zmsk, 'T', 1. )             ! set halos
+#else
       CALL lbc_lnk( 'usrdef_zgr', zmsk, 'T', 1. )             ! set halos
+#endif
       k_top(:,:) = k_top(:,:) * NINT( zmsk(:,:) )
       !
@@ -340,4 +344,12 @@
       END_2D
       ! converte into REAL to use lbc_lnk ; impose a min value of 1 as a zero can be set in lbclnk 
+#if defined key_mpi3
+      zk(:,:) = REAL( miku(:,:), wp )   ;   CALL lbc_lnk_nc_multi( 'domzgr', zk, 'U', 1.0_wp )   ;   miku(:,:) = MAX( NINT( zk(:,:) ), 1 )
+      zk(:,:) = REAL( mikv(:,:), wp )   ;   CALL lbc_lnk_nc_multi( 'domzgr', zk, 'V', 1.0_wp )   ;   mikv(:,:) = MAX( NINT( zk(:,:) ), 1 )
+      zk(:,:) = REAL( mikf(:,:), wp )   ;   CALL lbc_lnk_nc_multi( 'domzgr', zk, 'F', 1.0_wp )   ;   mikf(:,:) = MAX( NINT( zk(:,:) ), 1 )
+      !
+      zk(:,:) = REAL( mbku(:,:), wp )   ;   CALL lbc_lnk_nc_multi( 'domzgr', zk, 'U', 1.0_wp )   ;   mbku(:,:) = MAX( NINT( zk(:,:) ), 1 )
+      zk(:,:) = REAL( mbkv(:,:), wp )   ;   CALL lbc_lnk_nc_multi( 'domzgr', zk, 'V', 1.0_wp )   ;   mbkv(:,:) = MAX( NINT( zk(:,:) ), 1 )
+#else
       zk(:,:) = REAL( miku(:,:), wp )   ;   CALL lbc_lnk( 'domzgr', zk, 'U', 1.0_wp )   ;   miku(:,:) = MAX( NINT( zk(:,:) ), 1 )
       zk(:,:) = REAL( mikv(:,:), wp )   ;   CALL lbc_lnk( 'domzgr', zk, 'V', 1.0_wp )   ;   mikv(:,:) = MAX( NINT( zk(:,:) ), 1 )
@@ -346,4 +358,5 @@
       zk(:,:) = REAL( mbku(:,:), wp )   ;   CALL lbc_lnk( 'domzgr', zk, 'U', 1.0_wp )   ;   mbku(:,:) = MAX( NINT( zk(:,:) ), 1 )
       zk(:,:) = REAL( mbkv(:,:), wp )   ;   CALL lbc_lnk( 'domzgr', zk, 'V', 1.0_wp )   ;   mbkv(:,:) = MAX( NINT( zk(:,:) ), 1 )
+#endif
       !
    END SUBROUTINE zgr_top_bot
Index: /NEMO/branches/2020/dev_r13296_HPC-07_mocavero_mpi3/src/OCE/DYN/divhor.F90
===================================================================
--- /NEMO/branches/2020/dev_r13296_HPC-07_mocavero_mpi3/src/OCE/DYN/divhor.F90	(revision 13629)
+++ /NEMO/branches/2020/dev_r13296_HPC-07_mocavero_mpi3/src/OCE/DYN/divhor.F90	(revision 13630)
@@ -94,5 +94,9 @@
       IF( ln_isf )                      CALL isf_hdiv( kt, Kmm, hdiv )           !==  ice shelf         ==!   (update hdiv field)
       !
+#if defined key_mpi3
+      CALL lbc_lnk_nc_multi( 'divhor', hdiv, 'T', 1.0_wp )   !   (no sign change)
+#else
       CALL lbc_lnk( 'divhor', hdiv, 'T', 1.0_wp )   !   (no sign change)
+#endif
       !
       IF( ln_timing )   CALL timing_stop('div_hor')
Index: /NEMO/branches/2020/dev_r13296_HPC-07_mocavero_mpi3/src/OCE/DYN/dynhpg.F90
===================================================================
--- /NEMO/branches/2020/dev_r13296_HPC-07_mocavero_mpi3/src/OCE/DYN/dynhpg.F90	(revision 13629)
+++ /NEMO/branches/2020/dev_r13296_HPC-07_mocavero_mpi3/src/OCE/DYN/dynhpg.F90	(revision 13630)
@@ -448,5 +448,9 @@
           END IF
         END_2D
+#if defined key_mpi3
+        CALL lbc_lnk_nc_multi( 'dynhpg', zcpx, 'U', 1.0_wp, zcpy, 'V', 1.0_wp )
+#else
         CALL lbc_lnk_multi( 'dynhpg', zcpx, 'U', 1.0_wp, zcpy, 'V', 1.0_wp )
+#endif
       END IF
 
@@ -679,5 +683,9 @@
           END IF
         END_2D
+#if defined key_mpi3
+        CALL lbc_lnk_nc_multi( 'dynhpg', zcpx, 'U', 1.0_wp, zcpy, 'V', 1.0_wp )
+#else
         CALL lbc_lnk_multi( 'dynhpg', zcpx, 'U', 1.0_wp, zcpy, 'V', 1.0_wp )
+#endif
       END IF
 
@@ -825,5 +833,9 @@
 
       END_3D
+#if defined key_mpi3
+      CALL lbc_lnk_nc_multi( 'dynhpg', rho_k, 'W', 1.0_wp, rho_i, 'U', 1.0_wp, rho_j, 'V', 1.0_wp )
+#else
       CALL lbc_lnk_multi( 'dynhpg', rho_k, 'W', 1.0_wp, rho_i, 'U', 1.0_wp, rho_j, 'V', 1.0_wp )
+#endif
 
       ! ---------------
@@ -952,5 +964,9 @@
             ENDIF
          END_2D
+#if defined key_mpi3
+         CALL lbc_lnk_nc_multi( 'dynhpg', zcpx, 'U', 1.0_wp, zcpy, 'V', 1.0_wp )
+#else
          CALL lbc_lnk_multi( 'dynhpg', zcpx, 'U', 1.0_wp, zcpy, 'V', 1.0_wp )
+#endif
       ENDIF
 
@@ -1022,5 +1038,9 @@
       END_2D
 
+#if defined key_mpi3
+      CALL lbc_lnk_nc_multi ('dynhpg', zsshu_n, 'U', 1.0_wp, zsshv_n, 'V', 1.0_wp )
+#else
       CALL lbc_lnk_multi ('dynhpg', zsshu_n, 'U', 1.0_wp, zsshv_n, 'V', 1.0_wp )
+#endif
 
       DO_2D( 0, 0, 0, 0 )
Index: /NEMO/branches/2020/dev_r13296_HPC-07_mocavero_mpi3/src/OCE/DYN/dynkeg.F90
===================================================================
--- /NEMO/branches/2020/dev_r13296_HPC-07_mocavero_mpi3/src/OCE/DYN/dynkeg.F90	(revision 13629)
+++ /NEMO/branches/2020/dev_r13296_HPC-07_mocavero_mpi3/src/OCE/DYN/dynkeg.F90	(revision 13630)
@@ -121,5 +121,9 @@
             zhke(ji,jj,jk) = r1_48 * ( zv + zu )
          END_3D
+#if defined key_mpi3
+         CALL lbc_lnk_nc_multi( 'dynkeg', zhke, 'T', 1.0_wp )
+#else
          CALL lbc_lnk( 'dynkeg', zhke, 'T', 1.0_wp )
+#endif
          !
       END SELECT 
Index: /NEMO/branches/2020/dev_r13296_HPC-07_mocavero_mpi3/src/OCE/DYN/dynldf_iso.F90
===================================================================
--- /NEMO/branches/2020/dev_r13296_HPC-07_mocavero_mpi3/src/OCE/DYN/dynldf_iso.F90	(revision 13629)
+++ /NEMO/branches/2020/dev_r13296_HPC-07_mocavero_mpi3/src/OCE/DYN/dynldf_iso.F90	(revision 13630)
@@ -135,5 +135,9 @@
          END_3D
          ! Lateral boundary conditions on the slopes
+#if defined key_mpi3
+         CALL lbc_lnk_nc_multi( 'dynldf_iso', uslp , 'U', -1.0_wp, vslp , 'V', -1.0_wp, wslpi, 'W', -1.0_wp, wslpj, 'W', -1.0_wp )
+#else
          CALL lbc_lnk_multi( 'dynldf_iso', uslp , 'U', -1.0_wp, vslp , 'V', -1.0_wp, wslpi, 'W', -1.0_wp, wslpj, 'W', -1.0_wp )
+#endif
          !
        ENDIF
Index: /NEMO/branches/2020/dev_r13296_HPC-07_mocavero_mpi3/src/OCE/DYN/dynspg_ts.F90
===================================================================
--- /NEMO/branches/2020/dev_r13296_HPC-07_mocavero_mpi3/src/OCE/DYN/dynspg_ts.F90	(revision 13629)
+++ /NEMO/branches/2020/dev_r13296_HPC-07_mocavero_mpi3/src/OCE/DYN/dynspg_ts.F90	(revision 13630)
@@ -520,5 +520,9 @@
          END_2D
          !
+#if defined key_mpi3
+         CALL lbc_lnk_nc_multi( 'dynspg_ts', ssha_e, 'T', 1._wp,  zhU, 'U', -1._wp,  zhV, 'V', -1._wp )
+#else
          CALL lbc_lnk_multi( 'dynspg_ts', ssha_e, 'T', 1._wp,  zhU, 'U', -1._wp,  zhV, 'V', -1._wp )
+#endif
          !
          ! Duplicate sea level across open boundaries (this is only cosmetic if linssh=T)
@@ -659,9 +663,19 @@
          !
          IF( .NOT.ln_linssh ) THEN   !* Update ocean depth (variable volume case only)
+#if defined key_mpi3
+            CALL lbc_lnk_nc_multi( 'dynspg_ts', ua_e , 'U', -1._wp, va_e , 'V', -1._wp  &
+                 &                         , hu_e , 'U',  1._wp, hv_e , 'V',  1._wp  &
+                 &                         , hur_e, 'U',  1._wp, hvr_e, 'V',  1._wp  )
+#else
             CALL lbc_lnk_multi( 'dynspg_ts', ua_e , 'U', -1._wp, va_e , 'V', -1._wp  &
                  &                         , hu_e , 'U',  1._wp, hv_e , 'V',  1._wp  &
                  &                         , hur_e, 'U',  1._wp, hvr_e, 'V',  1._wp  )
+#endif
          ELSE
+#if defined key_mpi3
+            CALL lbc_lnk_nc_multi( 'dynspg_ts', ua_e , 'U', -1._wp, va_e , 'V', -1._wp  )
+#else
             CALL lbc_lnk_multi( 'dynspg_ts', ua_e , 'U', -1._wp, va_e , 'V', -1._wp  )
+#endif
          ENDIF
          !                                                 ! open boundaries
@@ -751,5 +765,9 @@
                &              +   e1e2t(ji,jj+1) * pssh(ji,jj+1,Kaa) )
          END_2D
+#if defined key_mpi3
+         CALL lbc_lnk_nc_multi( 'dynspg_ts', zsshu_a, 'U', 1._wp, zsshv_a, 'V', 1._wp ) ! Boundary conditions
+#else
          CALL lbc_lnk_multi( 'dynspg_ts', zsshu_a, 'U', 1._wp, zsshv_a, 'V', 1._wp ) ! Boundary conditions
+#endif
          !
          DO jk=1,jpkm1
@@ -1114,5 +1132,9 @@
             END_2D
          END SELECT
+#if defined key_mpi3
+         CALL lbc_lnk_nc_multi( 'dynspg_ts', zwz, 'F', 1._wp )
+#else
          CALL lbc_lnk( 'dynspg_ts', zwz, 'F', 1._wp )
+#endif
          !
          ftne(1,:) = 0._wp ; ftnw(1,:) = 0._wp ; ftse(1,:) = 0._wp ; ftsw(1,:) = 0._wp
@@ -1176,5 +1198,9 @@
             END DO
          END DO
+#if defined key_mpi3
+         CALL lbc_lnk_nc_multi( 'dynspg_ts', zhf, 'F', 1._wp )
+#else
          CALL lbc_lnk( 'dynspg_ts', zhf, 'F', 1._wp )
+#endif
          ! JC: TBC. hf should be greater than 0 
          DO_2D( 1, 1, 1, 1 )
Index: /NEMO/branches/2020/dev_r13296_HPC-07_mocavero_mpi3/src/OCE/DYN/dynvor.F90
===================================================================
--- /NEMO/branches/2020/dev_r13296_HPC-07_mocavero_mpi3/src/OCE/DYN/dynvor.F90	(revision 13629)
+++ /NEMO/branches/2020/dev_r13296_HPC-07_mocavero_mpi3/src/OCE/DYN/dynvor.F90	(revision 13630)
@@ -242,5 +242,9 @@
          END DO
 
+#if defined key_mpi3
+         CALL lbc_lnk_nc_multi( 'dynvor', zwz, 'F', 1.0_wp )
+#else
          CALL lbc_lnk( 'dynvor', zwz, 'F', 1.0_wp )
+#endif
 
       CASE ( np_CRV )                           !* Coriolis + relative vorticity
@@ -257,5 +261,9 @@
          END DO
 
+#if defined key_mpi3
+         CALL lbc_lnk_nc_multi( 'dynvor', zwz, 'F', 1.0_wp )
+#else
          CALL lbc_lnk( 'dynvor', zwz, 'F', 1.0_wp )
+#endif
 
       END SELECT
@@ -823,5 +831,9 @@
          END_3D
          !
+#if defined key_mpi3
+         CALL lbc_lnk_nc_multi( 'dynvor', fmask, 'F', 1._wp )      ! Lateral boundary conditions on fmask
+#else
          CALL lbc_lnk( 'dynvor', fmask, 'F', 1._wp )      ! Lateral boundary conditions on fmask
+#endif
          !
       ENDIF
@@ -861,5 +873,9 @@
                dj_e1v_2(ji,jj) = ( e1v(ji,jj) - e1v(ji  ,jj-1) ) * 0.5_wp
             END_2D
+#if defined key_mpi3
+            CALL lbc_lnk_nc_multi( 'dynvor', di_e2u_2, 'T', -1.0_wp , dj_e1v_2, 'T', -1.0_wp )   ! Lateral boundary conditions
+#else
             CALL lbc_lnk_multi( 'dynvor', di_e2u_2, 'T', -1.0_wp , dj_e1v_2, 'T', -1.0_wp )   ! Lateral boundary conditions
+#endif
             !
          CASE DEFAULT                        !* F-point metric term :   pre-compute di(e2u)/(2*e1e2f) and dj(e1v)/(2*e1e2f)
@@ -869,5 +885,9 @@
                dj_e1u_2e1e2f(ji,jj) = ( e1u(ji  ,jj+1) - e1u(ji,jj) )  * 0.5 * r1_e1e2f(ji,jj)
             END_2D
+#if defined key_mpi3
+            CALL lbc_lnk_nc_multi( 'dynvor', di_e2v_2e1e2f, 'F', -1.0_wp , dj_e1u_2e1e2f, 'F', -1.0_wp )   ! Lateral boundary conditions
+#else
             CALL lbc_lnk_multi( 'dynvor', di_e2v_2e1e2f, 'F', -1.0_wp , dj_e1u_2e1e2f, 'F', -1.0_wp )   ! Lateral boundary conditions
+#endif
          END SELECT
          !
Index: /NEMO/branches/2020/dev_r13296_HPC-07_mocavero_mpi3/src/OCE/DYN/sshwzv.F90
===================================================================
--- /NEMO/branches/2020/dev_r13296_HPC-07_mocavero_mpi3/src/OCE/DYN/sshwzv.F90	(revision 13629)
+++ /NEMO/branches/2020/dev_r13296_HPC-07_mocavero_mpi3/src/OCE/DYN/sshwzv.F90	(revision 13630)
@@ -119,5 +119,9 @@
       IF ( .NOT.ln_dynspg_ts ) THEN
          IF( ln_bdy ) THEN
+#if defined key_mpi3
+            CALL lbc_lnk_nc_multi( 'sshwzv', pssh(:,:,Kaa), 'T', 1.0_wp )    ! Not sure that's necessary
+#else
             CALL lbc_lnk( 'sshwzv', pssh(:,:,Kaa), 'T', 1.0_wp )    ! Not sure that's necessary
+#endif
             CALL bdy_ssh( pssh(:,:,Kaa) )             ! Duplicate sea level across open boundaries
          ENDIF
@@ -182,5 +186,9 @@
             END_2D
          END DO
+#if defined key_mpi3
+         CALL lbc_lnk_nc_multi('sshwzv', zhdiv, 'T', 1.0_wp)  ! - ML - Perhaps not necessary: not used for horizontal "connexions"
+#else
          CALL lbc_lnk('sshwzv', zhdiv, 'T', 1.0_wp)  ! - ML - Perhaps not necessary: not used for horizontal "connexions"
+#endif
          !                             ! Is it problematic to have a wrong vertical velocity in boundary cells?
          !                             ! Same question holds for hdiv. Perhaps just for security
@@ -388,5 +396,9 @@
          END_3D
       ENDIF
+#if defined key_mpi3
+      CALL lbc_lnk_nc_multi( 'sshwzv', Cu_adv, 'T', 1.0_wp )
+#else
       CALL lbc_lnk( 'sshwzv', Cu_adv, 'T', 1.0_wp )
+#endif
       !
       CALL iom_put("Courant",Cu_adv)
Index: /NEMO/branches/2020/dev_r13296_HPC-07_mocavero_mpi3/src/OCE/DYN/wet_dry.F90
===================================================================
--- /NEMO/branches/2020/dev_r13296_HPC-07_mocavero_mpi3/src/OCE/DYN/wet_dry.F90	(revision 13629)
+++ /NEMO/branches/2020/dev_r13296_HPC-07_mocavero_mpi3/src/OCE/DYN/wet_dry.F90	(revision 13630)
@@ -241,5 +241,9 @@
             ENDIF
          END_2D
+#if defined key_mpi3
+         CALL lbc_lnk_nc_multi( 'wet_dry', zwdlmtu, 'U', 1.0_wp, zwdlmtv, 'V', 1.0_wp )
+#else
          CALL lbc_lnk_multi( 'wet_dry', zwdlmtu, 'U', 1.0_wp, zwdlmtv, 'V', 1.0_wp )
+#endif
          !
          CALL mpp_max('wet_dry', jflag)   !max over the global domain
@@ -257,6 +261,11 @@
       !
 !!gm TO BE SUPPRESSED ?  these lbc_lnk are useless since zwdlmtu and zwdlmtv are defined everywhere !
+#if defined key_mpi3
+      CALL lbc_lnk_nc_multi( 'wet_dry', puu(:,:,:,Kmm)  , 'U', -1.0_wp, pvv(:,:,:,Kmm)  , 'V', -1.0_wp )
+      CALL lbc_lnk_nc_multi( 'wet_dry', uu_b(:,:,Kmm), 'U', -1.0_wp, vv_b(:,:,Kmm), 'V', -1.0_wp )
+#else
       CALL lbc_lnk_multi( 'wet_dry', puu(:,:,:,Kmm)  , 'U', -1.0_wp, pvv(:,:,:,Kmm)  , 'V', -1.0_wp )
       CALL lbc_lnk_multi( 'wet_dry', uu_b(:,:,Kmm), 'U', -1.0_wp, vv_b(:,:,Kmm), 'V', -1.0_wp )
+#endif
 !!gm
       !
@@ -366,5 +375,9 @@
          END_2D
          !
+#if defined key_mpi3
+         CALL lbc_lnk_nc_multi( 'wet_dry', zwdlmtu, 'U', 1.0_wp, zwdlmtv, 'V', 1.0_wp )
+#else
          CALL lbc_lnk_multi( 'wet_dry', zwdlmtu, 'U', 1.0_wp, zwdlmtv, 'V', 1.0_wp )
+#endif
          !
          CALL mpp_max('wet_dry', jflag)   !max over the global domain
@@ -378,5 +391,9 @@
       !
 !!gm THIS lbc_lnk is useless since it is already done at the end of the jk1-loop
+#if defined key_mpi3
+      CALL lbc_lnk_nc_multi( 'wet_dry', zflxu, 'U', -1.0_wp, zflxv, 'V', -1.0_wp )
+#else
       CALL lbc_lnk_multi( 'wet_dry', zflxu, 'U', -1.0_wp, zflxv, 'V', -1.0_wp )
+#endif
 !!gm end
       !
Index: /NEMO/branches/2020/dev_r13296_HPC-07_mocavero_mpi3/src/OCE/ICB/icbclv.F90
===================================================================
--- /NEMO/branches/2020/dev_r13296_HPC-07_mocavero_mpi3/src/OCE/ICB/icbclv.F90	(revision 13629)
+++ /NEMO/branches/2020/dev_r13296_HPC-07_mocavero_mpi3/src/OCE/ICB/icbclv.F90	(revision 13630)
@@ -173,7 +173,15 @@
       !
       DO jn = 1, nclasses
+#if defined key_mpi3
+         CALL lbc_lnk_nc_multi( 'icbclv', berg_grid%stored_ice(:,:,jn), 'T', 1._wp )
+#else
          CALL lbc_lnk( 'icbclv', berg_grid%stored_ice(:,:,jn), 'T', 1._wp )
+#endif
       END DO
+#if defined key_mpi3
+      CALL lbc_lnk_nc_multi( 'icbclv', berg_grid%stored_heat, 'T', 1._wp )
+#else
       CALL lbc_lnk( 'icbclv', berg_grid%stored_heat, 'T', 1._wp )
+#endif
       !
       IF( nn_verbose_level > 0 .AND. icntmax > 1 )   WRITE(numicb,*) 'icb_clv: icnt=', icnt,' on', narea
Index: /NEMO/branches/2020/dev_r13296_HPC-07_mocavero_mpi3/src/OCE/ICB/icbini.F90
===================================================================
--- /NEMO/branches/2020/dev_r13296_HPC-07_mocavero_mpi3/src/OCE/ICB/icbini.F90	(revision 13629)
+++ /NEMO/branches/2020/dev_r13296_HPC-07_mocavero_mpi3/src/OCE/ICB/icbini.F90	(revision 13630)
@@ -127,6 +127,11 @@
          src_calving     (ji,jj) = nicbpack * mjg(jj) + mig(ji)
       END_2D
+#if defined key_mpi3
+      CALL lbc_lnk_nc_multi( 'icbini', src_calving_hflx, 'T', 1._wp )
+      CALL lbc_lnk_nc_multi( 'icbini', src_calving     , 'T', 1._wp )
+#else
       CALL lbc_lnk( 'icbini', src_calving_hflx, 'T', 1._wp )
       CALL lbc_lnk( 'icbini', src_calving     , 'T', 1._wp )
+#endif
 
       ! work out interior of processor from exchange array
Index: /NEMO/branches/2020/dev_r13296_HPC-07_mocavero_mpi3/src/OCE/IOM/iom.F90
===================================================================
--- /NEMO/branches/2020/dev_r13296_HPC-07_mocavero_mpi3/src/OCE/IOM/iom.F90	(revision 13629)
+++ /NEMO/branches/2020/dev_r13296_HPC-07_mocavero_mpi3/src/OCE/IOM/iom.F90	(revision 13630)
@@ -1380,6 +1380,11 @@
 !some final adjustments
       ! C1D case : always call lbc_lnk to replicate the central value over the whole 3X3 domain
+#if defined key_mpi3
+      IF( lk_c1d .AND. PRESENT(pv_r2d) )   CALL lbc_lnk_nc_multi( 'iom', pv_r2d,'Z',1.0_wp )
+      IF( lk_c1d .AND. PRESENT(pv_r3d) )   CALL lbc_lnk_nc_multi( 'iom', pv_r3d,'Z',1.0_wp )
+#else
       IF( lk_c1d .AND. PRESENT(pv_r2d) )   CALL lbc_lnk( 'iom', pv_r2d,'Z',1.0_wp )
       IF( lk_c1d .AND. PRESENT(pv_r3d) )   CALL lbc_lnk( 'iom', pv_r3d,'Z',1.0_wp )
+#endif
 
       !--- Apply scale_factor and offset
@@ -2256,5 +2261,9 @@
       !
       z_fld(:,:) = 1._wp
+#if defined key_mpi3
+      CALL lbc_lnk_nc_multi( 'iom', z_fld, cdgrd, -1.0_wp )    ! Working array for location of northfold
+#else
       CALL lbc_lnk( 'iom', z_fld, cdgrd, -1.0_wp )    ! Working array for location of northfold
+#endif
       !
       ! Cell vertices that can be defined
Index: /NEMO/branches/2020/dev_r13296_HPC-07_mocavero_mpi3/src/OCE/ISF/isfcav.F90
===================================================================
--- /NEMO/branches/2020/dev_r13296_HPC-07_mocavero_mpi3/src/OCE/ISF/isfcav.F90	(revision 13629)
+++ /NEMO/branches/2020/dev_r13296_HPC-07_mocavero_mpi3/src/OCE/ISF/isfcav.F90	(revision 13630)
@@ -136,5 +136,9 @@
       !
       ! lbclnk on melt
+#if defined key_mpi3
+      CALL lbc_lnk_nc_multi( 'isfmlt', zqh, 'T', 1.0_wp, pqfwf, 'T', 1.0_wp)
+#else
       CALL lbc_lnk_multi( 'isfmlt', zqh, 'T', 1.0_wp, pqfwf, 'T', 1.0_wp)
+#endif
       !
       ! output fluxes
Index: /NEMO/branches/2020/dev_r13296_HPC-07_mocavero_mpi3/src/OCE/ISF/isfcpl.F90
===================================================================
--- /NEMO/branches/2020/dev_r13296_HPC-07_mocavero_mpi3/src/OCE/ISF/isfcpl.F90	(revision 13629)
+++ /NEMO/branches/2020/dev_r13296_HPC-07_mocavero_mpi3/src/OCE/ISF/isfcpl.F90	(revision 13630)
@@ -212,5 +212,9 @@
          zssmask0(:,:) = zssmask_b(:,:)
          !
+#if defined key_mpi3
+         CALL lbc_lnk_nc_multi( 'iscplrst', zssh, 'T', 1.0_wp, zssmask0, 'T', 1.0_wp )
+#else
          CALL lbc_lnk_multi( 'iscplrst', zssh, 'T', 1.0_wp, zssmask0, 'T', 1.0_wp )
+#endif
          !
       END DO
@@ -367,5 +371,9 @@
          ztmask0(:,:,:) = ztmask1(:,:,:)
          !
+#if defined key_mpi3
+         CALL lbc_lnk_nc_multi( 'iscplrst', zts0(:,:,:,jp_tem), 'T', 1.0_wp, zts0(:,:,:,jp_sal), 'T', 1.0_wp, ztmask0, 'T', 1.0_wp)
+#else
          CALL lbc_lnk_multi( 'iscplrst', zts0(:,:,:,jp_tem), 'T', 1.0_wp, zts0(:,:,:,jp_sal), 'T', 1.0_wp, ztmask0, 'T', 1.0_wp)
+#endif
          !
       END DO  ! nn_drown
@@ -458,5 +466,9 @@
       END_2D
       !
+#if defined key_mpi3
+      CALL lbc_lnk_nc_multi( 'iscpl', risfcpl_vol, 'T', 1.0_wp )
+#else
       CALL lbc_lnk( 'iscpl', risfcpl_vol, 'T', 1.0_wp )
+#endif
       !
       ! 3.0: set total correction (div, tr(:,:,:,:,Krhs), ssh)
@@ -693,6 +705,11 @@
       !
       ! add lbclnk
+#if defined key_mpi3
+      CALL lbc_lnk_nc_multi( 'iscplrst', risfcpl_cons_tsc(:,:,:,jp_tem), 'T', 1.0_wp, risfcpl_cons_tsc(:,:,:,jp_sal), 'T', 1.0_wp, &
+         &                            risfcpl_cons_vol(:,:,:)       , 'T', 1.0_wp)
+#else
       CALL lbc_lnk_multi( 'iscplrst', risfcpl_cons_tsc(:,:,:,jp_tem), 'T', 1.0_wp, risfcpl_cons_tsc(:,:,:,jp_sal), 'T', 1.0_wp, &
          &                            risfcpl_cons_vol(:,:,:)       , 'T', 1.0_wp)
+#endif
       !
       ! ssh correction (for dynspg_ts)
Index: /NEMO/branches/2020/dev_r13296_HPC-07_mocavero_mpi3/src/OCE/ISF/isfpar.F90
===================================================================
--- /NEMO/branches/2020/dev_r13296_HPC-07_mocavero_mpi3/src/OCE/ISF/isfpar.F90	(revision 13629)
+++ /NEMO/branches/2020/dev_r13296_HPC-07_mocavero_mpi3/src/OCE/ISF/isfpar.F90	(revision 13630)
@@ -82,5 +82,9 @@
       !
       ! lbclnk on melt and heat fluxes
+#if defined key_mpi3
+      CALL lbc_lnk_nc_multi( 'isfmlt', zqh, 'T', 1.0_wp, pqfwf, 'T', 1.0_wp)
+#else
       CALL lbc_lnk_multi( 'isfmlt', zqh, 'T', 1.0_wp, pqfwf, 'T', 1.0_wp)
+#endif
       !
       ! output fluxes
Index: /NEMO/branches/2020/dev_r13296_HPC-07_mocavero_mpi3/src/OCE/LBC/halo_mng.F90
===================================================================
--- /NEMO/branches/2020/dev_r13296_HPC-07_mocavero_mpi3/src/OCE/LBC/halo_mng.F90	(revision 13629)
+++ /NEMO/branches/2020/dev_r13296_HPC-07_mocavero_mpi3/src/OCE/LBC/halo_mng.F90	(revision 13630)
@@ -92,5 +92,9 @@
 				zpta = pta(offset+1 : offset+jpi, offset+1 : offset+jpj)
 			END IF
+#if defined key_mpi3
+			CALL lbc_lnk_nc_multi( 'halo_mng_resize_2D', zpta, cdna, psgn, pfillval=fillval)
+#else
 			CALL lbc_lnk( 'halo_mng_resize_2D', zpta, cdna, psgn, pfillval=fillval)
+#endif
 			DEALLOCATE(pta)
 			pta => zpta
@@ -122,5 +126,9 @@
 				zpta = pta(offset+1 : offset+jpi, offset+1 : offset+jpj, :)
 			END IF
+#if defined key_mpi3
+			CALL lbc_lnk_nc_multi( 'halo_mng_resize_3D', zpta, cdna, psgn, pfillval=fillval)
+#else
 			CALL lbc_lnk( 'halo_mng_resize_3D', zpta, cdna, psgn, pfillval=fillval)
+#endif
 			DEALLOCATE(pta)
 			pta => zpta
@@ -153,5 +161,9 @@
 				zpta = pta(offset+1 : offset+jpi, offset+1 : offset+jpj, :, :)
 			END IF
+#if defined key_mpi3
+			CALL lbc_lnk_nc_multi( 'halo_mng_resize_4D', zpta(:,:,:,fjpt), cdna, psgn, pfillval=fillval)
+#else
 			CALL lbc_lnk( 'halo_mng_resize_4D', zpta(:,:,:,fjpt), cdna, psgn, pfillval=fillval)
+#endif
 			DEALLOCATE(pta)
 			pta => zpta
@@ -185,5 +197,9 @@
 				zpta = pta(offset+1 : offset+jpi, offset+1 : offset+jpj, :, :, :)
 			END IF
+#if defined key_mpi3
+			CALL lbc_lnk_nc_multi( 'halo_mng_resize_5D', zpta(:,:,:,:,fjpt), cdna, psgn, pfillval=fillval)
+#else
 			CALL lbc_lnk( 'halo_mng_resize_5D', zpta(:,:,:,:,fjpt), cdna, psgn, pfillval=fillval)
+#endif
 			DEALLOCATE(pta)
 			pta => zpta
Index: /NEMO/branches/2020/dev_r13296_HPC-07_mocavero_mpi3/src/OCE/LBC/lbc_lnk_nc_generic.h90
===================================================================
--- /NEMO/branches/2020/dev_r13296_HPC-07_mocavero_mpi3/src/OCE/LBC/lbc_lnk_nc_generic.h90	(revision 13629)
+++ /NEMO/branches/2020/dev_r13296_HPC-07_mocavero_mpi3/src/OCE/LBC/lbc_lnk_nc_generic.h90	(revision 13630)
@@ -36,16 +36,20 @@
 
    SUBROUTINE ROUTINE_MULTI_NC( cdname                                                                             &
-      &                    , pt1, cdna1, psgn1, pt2 , cdna2 , psgn2 , pt3 , cdna3 , psgn3 , pt4, cdna4, psgn4   &
-      &                    , pt5, cdna5, psgn5, pt6 , cdna6 , psgn6 , pt7 , cdna7 , psgn7 , pt8, cdna8, psgn8   &
-      &                    , pt9, cdna9, psgn9, pt10, cdna10, psgn10, pt11, cdna11, psgn11                      &
+      &                    , pt1 , cdna1 , psgn1 , pt2 , cdna2 , psgn2 , pt3 , cdna3 , psgn3 , pt4 , cdna4 , psgn4   &
+      &                    , pt5 , cdna5 , psgn5 , pt6 , cdna6 , psgn6 , pt7 , cdna7 , psgn7 , pt8 , cdna8 , psgn8   &
+      &                    , pt9 , cdna9 , psgn9 , pt10, cdna10, psgn10, pt11, cdna11, psgn11, pt12, cdna12, psgn12  &
+      &                    , pt13, cdna13, psgn13, pt14, cdna14, psgn14, pt15, cdna15, psgn15, pt16, cdna16, psgn16  &
       &                    , kfillmode, pfillval, lsend, lrecv, ncsten )
       !!---------------------------------------------------------------------
       CHARACTER(len=*)   ,                   INTENT(in   ) :: cdname  ! name of the calling subroutine
       ARRAY_TYPE(:,:,:,:)          , TARGET, INTENT(inout) :: pt1     ! arrays on which the lbc is applied
-      ARRAY_TYPE(:,:,:,:), OPTIONAL, TARGET, INTENT(inout) :: pt2  , pt3  , pt4  , pt5  , pt6  , pt7  , pt8  , pt9  , pt10  , pt11
+      ARRAY_TYPE(:,:,:,:), OPTIONAL, TARGET, INTENT(inout) :: pt2  , pt3  , pt4  , pt5  , pt6  , pt7  , pt8  , pt9  , &
+         &                                                    pt10  , pt11  , pt12  , pt13  , pt14  , pt15  , pt16
       CHARACTER(len=1)                     , INTENT(in   ) :: cdna1   ! nature of pt2D. array grid-points
-      CHARACTER(len=1)   , OPTIONAL        , INTENT(in   ) :: cdna2, cdna3, cdna4, cdna5, cdna6, cdna7, cdna8, cdna9, cdna10, cdna11
+      CHARACTER(len=1)   , OPTIONAL        , INTENT(in   ) :: cdna2, cdna3, cdna4, cdna5, cdna6, cdna7, cdna8, cdna9, &
+         &                                                    cdna10, cdna11, cdna12, cdna13, cdna14, cdna15, cdna16
       REAL(wp)                             , INTENT(in   ) :: psgn1   ! sign used across the north fold
-      REAL(wp)           , OPTIONAL        , INTENT(in   ) :: psgn2, psgn3, psgn4, psgn5, psgn6, psgn7, psgn8, psgn9, psgn10, psgn11
+      REAL(wp)           , OPTIONAL        , INTENT(in   ) :: psgn2, psgn3, psgn4, psgn5, psgn6, psgn7, psgn8, psgn9, &
+         &                                                    psgn10, psgn11, psgn12, psgn13, psgn14, psgn15, psgn16
       INTEGER            , OPTIONAL        , INTENT(in   ) :: kfillmode   ! filling method for halo over land (default = constant)
       REAL(wp)           , OPTIONAL        , INTENT(in   ) :: pfillval    ! background value (used at closed boundaries)
@@ -75,4 +79,9 @@
       IF( PRESENT(psgn10) )   CALL ROUTINE_NC_LOAD( pt10, cdna10, psgn10, ptab_ptr, cdna_ptr, psgn_ptr, kfld )
       IF( PRESENT(psgn11) )   CALL ROUTINE_NC_LOAD( pt11, cdna11, psgn11, ptab_ptr, cdna_ptr, psgn_ptr, kfld )
+      IF( PRESENT(psgn11) )   CALL ROUTINE_NC_LOAD( pt12, cdna12, psgn12, ptab_ptr, cdna_ptr, psgn_ptr, kfld )
+      IF( PRESENT(psgn11) )   CALL ROUTINE_NC_LOAD( pt13, cdna13, psgn13, ptab_ptr, cdna_ptr, psgn_ptr, kfld )
+      IF( PRESENT(psgn11) )   CALL ROUTINE_NC_LOAD( pt14, cdna14, psgn14, ptab_ptr, cdna_ptr, psgn_ptr, kfld )
+      IF( PRESENT(psgn11) )   CALL ROUTINE_NC_LOAD( pt15, cdna15, psgn15, ptab_ptr, cdna_ptr, psgn_ptr, kfld )
+      IF( PRESENT(psgn11) )   CALL ROUTINE_NC_LOAD( pt16, cdna16, psgn16, ptab_ptr, cdna_ptr, psgn_ptr, kfld )
       !
       CALL lbc_lnk_nc    ( cdname,               ptab_ptr, cdna_ptr, psgn_ptr, kfld, kfillmode, pfillval, lsend, lrecv, ncsten )
Index: /NEMO/branches/2020/dev_r13296_HPC-07_mocavero_mpi3/src/OCE/LDF/ldfc1d_c2d.F90
===================================================================
--- /NEMO/branches/2020/dev_r13296_HPC-07_mocavero_mpi3/src/OCE/LDF/ldfc1d_c2d.F90	(revision 13629)
+++ /NEMO/branches/2020/dev_r13296_HPC-07_mocavero_mpi3/src/OCE/LDF/ldfc1d_c2d.F90	(revision 13630)
@@ -85,5 +85,9 @@
             pah2(ji,jj,jk) = pahs2(ji,jj) * (  zratio + zc * ( 1._wp + TANH( - ( zdep2 - zh ) * zw) )  )
          END_3D
+#if defined key_mpi3
+         CALL lbc_lnk_nc_multi( 'ldfc1d_c2d', pah2, 'F', 1.0_wp )   ! Lateral boundary conditions
+#else
          CALL lbc_lnk( 'ldfc1d_c2d', pah2, 'F', 1.0_wp )   ! Lateral boundary conditions
+#endif
          !
       CASE( 'TRA' )                     ! U- and V-points (zdep1 & 2 are an approximation in zps-coord.)
@@ -95,5 +99,9 @@
          END_3D
          ! Lateral boundary conditions
+#if defined key_mpi3
+         CALL lbc_lnk_nc_multi( 'ldfc1d_c2d', pah1, 'U', 1.0_wp , pah2, 'V', 1.0_wp )   
+#else
          CALL lbc_lnk_multi( 'ldfc1d_c2d', pah1, 'U', 1.0_wp , pah2, 'V', 1.0_wp )   
+#endif
          !
       CASE DEFAULT                        ! error
Index: /NEMO/branches/2020/dev_r13296_HPC-07_mocavero_mpi3/src/OCE/LDF/ldfdyn.F90
===================================================================
--- /NEMO/branches/2020/dev_r13296_HPC-07_mocavero_mpi3/src/OCE/LDF/ldfdyn.F90	(revision 13629)
+++ /NEMO/branches/2020/dev_r13296_HPC-07_mocavero_mpi3/src/OCE/LDF/ldfdyn.F90	(revision 13630)
@@ -398,5 +398,9 @@
          ENDIF
          !
+#if defined key_mpi3
+         CALL lbc_lnk_nc_multi( 'ldfdyn', ahmt, 'T', 1.0_wp,  ahmf, 'F', 1.0_wp )
+#else
          CALL lbc_lnk_multi( 'ldfdyn', ahmt, 'T', 1.0_wp,  ahmf, 'F', 1.0_wp )
+#endif
          !
          !
@@ -430,5 +434,9 @@
             END DO
             !
+#if defined key_mpi3
+            CALL lbc_lnk_nc_multi( 'ldfdyn', dtensq, 'T', 1.0_wp )  ! lbc_lnk on dshesq not needed
+#else
             CALL lbc_lnk_multi( 'ldfdyn', dtensq, 'T', 1.0_wp )  ! lbc_lnk on dshesq not needed
+#endif
             !
             DO jk = 1, jpkm1
@@ -481,5 +489,9 @@
          ENDIF
          !
+#if defined key_mpi3
+         CALL lbc_lnk_nc_multi( 'ldfdyn', ahmt, 'T', 1.0_wp , ahmf, 'F', 1.0_wp )
+#else
          CALL lbc_lnk_multi( 'ldfdyn', ahmt, 'T', 1.0_wp , ahmf, 'F', 1.0_wp )
+#endif
          !
       END SELECT
Index: /NEMO/branches/2020/dev_r13296_HPC-07_mocavero_mpi3/src/OCE/LDF/ldfslp.F90
===================================================================
--- /NEMO/branches/2020/dev_r13296_HPC-07_mocavero_mpi3/src/OCE/LDF/ldfslp.F90	(revision 13629)
+++ /NEMO/branches/2020/dev_r13296_HPC-07_mocavero_mpi3/src/OCE/LDF/ldfslp.F90	(revision 13630)
@@ -348,5 +348,9 @@
       ! IV. Lateral boundary conditions
       ! ===============================
+#if defined key_mpi3
+      CALL lbc_lnk_nc_multi( 'ldfslp', uslp , 'U', -1.0_wp , vslp , 'V', -1.0_wp , wslpi, 'W', -1.0_wp, wslpj, 'W', -1.0_wp )
+#else
       CALL lbc_lnk_multi( 'ldfslp', uslp , 'U', -1.0_wp , vslp , 'V', -1.0_wp , wslpi, 'W', -1.0_wp, wslpj, 'W', -1.0_wp )
+#endif
 
       IF(sn_cfctl%l_prtctl) THEN
@@ -580,5 +584,9 @@
       wslp2(:,:,1) = 0._wp                ! force the surface wslp to zero
 
+#if defined key_mpi3
+      CALL lbc_lnk_nc_multi( 'ldfslp', wslp2, 'W', 1.0_wp )      ! lateral boundary confition on wslp2 only   ==>>> gm : necessary ? to be checked
+#else
       CALL lbc_lnk( 'ldfslp', wslp2, 'W', 1.0_wp )      ! lateral boundary confition on wslp2 only   ==>>> gm : necessary ? to be checked
+#endif
       !
       IF( ln_timing )   CALL timing_stop('ldf_slp_triad')
@@ -689,5 +697,9 @@
       END_2D
       !!gm this lbc_lnk should be useless....
+#if defined key_mpi3
+      CALL lbc_lnk_nc_multi( 'ldfslp', uslpml , 'U', -1.0_wp , vslpml , 'V', -1.0_wp , wslpiml, 'W', -1.0_wp , wslpjml, 'W', -1.0_wp ) 
+#else
       CALL lbc_lnk_multi( 'ldfslp', uslpml , 'U', -1.0_wp , vslpml , 'V', -1.0_wp , wslpiml, 'W', -1.0_wp , wslpjml, 'W', -1.0_wp ) 
+#endif
       !
    END SUBROUTINE ldf_slp_mxl
Index: /NEMO/branches/2020/dev_r13296_HPC-07_mocavero_mpi3/src/OCE/LDF/ldftra.F90
===================================================================
--- /NEMO/branches/2020/dev_r13296_HPC-07_mocavero_mpi3/src/OCE/LDF/ldftra.F90	(revision 13629)
+++ /NEMO/branches/2020/dev_r13296_HPC-07_mocavero_mpi3/src/OCE/LDF/ldftra.F90	(revision 13630)
@@ -691,5 +691,9 @@
          zaeiw(ji,jj) = MIN( zzaei , paei0 )                                  ! Max value = paei0
       END_2D
+#if defined key_mpi3
+      CALL lbc_lnk_nc_multi( 'ldftra', zaeiw(:,:), 'W', 1.0_wp )       ! lateral boundary condition
+#else
       CALL lbc_lnk( 'ldftra', zaeiw(:,:), 'W', 1.0_wp )       ! lateral boundary condition
+#endif
       !               
       DO_2D( 0, 0, 0, 0 )                       !== aei at u- and v-points  ==!
@@ -697,5 +701,9 @@
          paeiv(ji,jj,1) = 0.5_wp * ( zaeiw(ji,jj) + zaeiw(ji  ,jj+1) ) * vmask(ji,jj,1)
       END_2D
+#if defined key_mpi3
+      CALL lbc_lnk_nc_multi( 'ldftra', paeiu(:,:,1), 'U', 1.0_wp , paeiv(:,:,1), 'V', 1.0_wp )      ! lateral boundary condition
+#else
       CALL lbc_lnk_multi( 'ldftra', paeiu(:,:,1), 'U', 1.0_wp , paeiv(:,:,1), 'V', 1.0_wp )      ! lateral boundary condition
+#endif
 
       DO jk = 2, jpkm1                          !==  deeper values equal the surface one  ==!
@@ -793,5 +801,9 @@
 !!gm     to be redesigned....   
       !                                                  !==  eiv stream function: output  ==!
+#if defined key_mpi3
+      CALL lbc_lnk_nc_multi( 'ldftra', psi_uw, 'U', -1.0_wp , psi_vw, 'V', -1.0_wp )
+#else
       CALL lbc_lnk_multi( 'ldftra', psi_uw, 'U', -1.0_wp , psi_vw, 'V', -1.0_wp )
+#endif
       !
 !!gm      CALL iom_put( "psi_eiv_uw", psi_uw )                 ! output
@@ -816,5 +828,9 @@
             &              + psi_uw(ji,jj,jk) - psi_uw(ji-1,jj  ,jk)  ) / e1e2t(ji,jj)
       END_3D
+#if defined key_mpi3
+      CALL lbc_lnk_nc_multi( 'ldftra', zw3d, 'T', 1.0_wp )      ! lateral boundary condition
+#else
       CALL lbc_lnk( 'ldftra', zw3d, 'T', 1.0_wp )      ! lateral boundary condition
+#endif
       CALL iom_put( "woce_eiv", zw3d )
       !
@@ -844,6 +860,11 @@
            zw2d(ji,jj) = zw2d(ji,jj) + zw3d(ji,jj,jk)
         END_3D
+#if defined key_mpi3
+        CALL lbc_lnk_nc_multi( 'ldftra', zw2d, 'U', -1.0_wp )
+        CALL lbc_lnk_nc_multi( 'ldftra', zw3d, 'U', -1.0_wp )
+#else
         CALL lbc_lnk( 'ldftra', zw2d, 'U', -1.0_wp )
         CALL lbc_lnk( 'ldftra', zw3d, 'U', -1.0_wp )
+#endif
         CALL iom_put( "ueiv_heattr"  , zztmp * zw2d )                  ! heat transport in i-direction
         CALL iom_put( "ueiv_heattr3d", zztmp * zw3d )                  ! heat transport in i-direction
@@ -865,5 +886,9 @@
          zw2d(ji,jj) = zw2d(ji,jj) + zw3d(ji,jj,jk)
       END_3D
+#if defined key_mpi3
+      CALL lbc_lnk_nc_multi( 'ldftra', zw2d, 'V', -1.0_wp )
+#else
       CALL lbc_lnk( 'ldftra', zw2d, 'V', -1.0_wp )
+#endif
       CALL iom_put( "veiv_heattr", zztmp * zw2d )                  !  heat transport in j-direction
       CALL iom_put( "veiv_heattr", zztmp * zw3d )                  !  heat transport in j-direction
@@ -880,6 +905,11 @@
            zw2d(ji,jj) = zw2d(ji,jj) + zw3d(ji,jj,jk)
         END_3D
+#if defined key_mpi3
+        CALL lbc_lnk_nc_multi( 'ldftra', zw2d, 'U', -1.0_wp )
+        CALL lbc_lnk_nc_multi( 'ldftra', zw3d, 'U', -1.0_wp )
+#else
         CALL lbc_lnk( 'ldftra', zw2d, 'U', -1.0_wp )
         CALL lbc_lnk( 'ldftra', zw3d, 'U', -1.0_wp )
+#endif
         CALL iom_put( "ueiv_salttr", zztmp * zw2d )                  ! salt transport in i-direction
         CALL iom_put( "ueiv_salttr3d", zztmp * zw3d )                ! salt transport in i-direction
@@ -892,5 +922,9 @@
          zw2d(ji,jj) = zw2d(ji,jj) + zw3d(ji,jj,jk)
       END_3D
+#if defined key_mpi3
+      CALL lbc_lnk_nc_multi( 'ldftra', zw2d, 'V', -1.0_wp )
+#else
       CALL lbc_lnk( 'ldftra', zw2d, 'V', -1.0_wp )
+#endif
       CALL iom_put( "veiv_salttr", zztmp * zw2d )                  !  salt transport in j-direction
       CALL iom_put( "veiv_salttr", zztmp * zw3d )                  !  salt transport in j-direction
Index: /NEMO/branches/2020/dev_r13296_HPC-07_mocavero_mpi3/src/OCE/SBC/cpl_oasis3.F90
===================================================================
--- /NEMO/branches/2020/dev_r13296_HPC-07_mocavero_mpi3/src/OCE/SBC/cpl_oasis3.F90	(revision 13629)
+++ /NEMO/branches/2020/dev_r13296_HPC-07_mocavero_mpi3/src/OCE/SBC/cpl_oasis3.F90	(revision 13630)
@@ -418,5 +418,9 @@
          !--- we must call lbc_lnk to fill the halos that where not received.
          IF( .NOT. ll_1st ) THEN
+#if defined key_mpi3
+            CALL lbc_lnk_nc_multi( 'cpl_oasis3', pdata(:,:,jc), srcv(kid)%clgrid, srcv(kid)%nsgn )   
+#else
             CALL lbc_lnk( 'cpl_oasis3', pdata(:,:,jc), srcv(kid)%clgrid, srcv(kid)%nsgn )   
+#endif
          ENDIF
  
Index: /NEMO/branches/2020/dev_r13296_HPC-07_mocavero_mpi3/src/OCE/SBC/sbc_oce.F90
===================================================================
--- /NEMO/branches/2020/dev_r13296_HPC-07_mocavero_mpi3/src/OCE/SBC/sbc_oce.F90	(revision 13629)
+++ /NEMO/branches/2020/dev_r13296_HPC-07_mocavero_mpi3/src/OCE/SBC/sbc_oce.F90	(revision 13630)
@@ -224,5 +224,9 @@
          wndm(ji,jj) = SQRT ( ztau * zcoef ) * tmask(ji,jj,1)
       END_2D
+#if defined key_mpi3
+      CALL lbc_lnk_nc_multi( 'sbc_oce', wndm(:,:) , 'T', 1.0_wp )
+#else
       CALL lbc_lnk( 'sbc_oce', wndm(:,:) , 'T', 1.0_wp )
+#endif
       !
    END SUBROUTINE sbc_tau2wnd
Index: /NEMO/branches/2020/dev_r13296_HPC-07_mocavero_mpi3/src/OCE/SBC/sbcblk.F90
===================================================================
--- /NEMO/branches/2020/dev_r13296_HPC-07_mocavero_mpi3/src/OCE/SBC/sbcblk.F90	(revision 13629)
+++ /NEMO/branches/2020/dev_r13296_HPC-07_mocavero_mpi3/src/OCE/SBC/sbcblk.F90	(revision 13630)
@@ -757,7 +757,15 @@
 
          IF( ln_crt_fbk ) THEN
+#if defined key_mpi3
+            CALL lbc_lnk_nc_multi( 'sbcblk', utau, 'U', -1., vtau, 'V', -1., taum, 'T', -1. )
+#else
             CALL lbc_lnk_multi( 'sbcblk', utau, 'U', -1., vtau, 'V', -1., taum, 'T', -1. )
+#endif
          ELSE
+#if defined key_mpi3
+            CALL lbc_lnk_nc_multi( 'sbcblk', utau, 'U', -1., vtau, 'V', -1. )
+#else
             CALL lbc_lnk_multi( 'sbcblk', utau, 'U', -1., vtau, 'V', -1. )
+#endif
          ENDIF
 
@@ -981,5 +989,9 @@
             pvtaui(ji,jj) = zztmp2 * ( pvtaui(ji,jj) + pvtaui(ji  ,jj+1) )
          END_2D
+#if defined key_mpi3
+         CALL lbc_lnk_nc_multi( 'sbcblk', putaui, 'U', -1._wp, pvtaui, 'V', -1._wp )
+#else
          CALL lbc_lnk_multi( 'sbcblk', putaui, 'U', -1._wp, pvtaui, 'V', -1._wp )
+#endif
          !
          IF(sn_cfctl%l_prtctl)  CALL prt_ctl( tab2d_1=putaui  , clinfo1=' blk_ice: putaui : '   &
@@ -1459,5 +1471,9 @@
          !
       END_2D
+#if defined key_mpi3
+      CALL lbc_lnk_nc_multi( 'sbcblk', pcd, 'T',  1.0_wp, pch, 'T', 1.0_wp )
+#else
       CALL lbc_lnk_multi( 'sbcblk', pcd, 'T',  1.0_wp, pch, 'T', 1.0_wp )
+#endif
       !
    END SUBROUTINE Cdn10_Lupkes2015
Index: /NEMO/branches/2020/dev_r13296_HPC-07_mocavero_mpi3/src/OCE/SBC/sbccpl.F90
===================================================================
--- /NEMO/branches/2020/dev_r13296_HPC-07_mocavero_mpi3/src/OCE/SBC/sbccpl.F90	(revision 13629)
+++ /NEMO/branches/2020/dev_r13296_HPC-07_mocavero_mpi3/src/OCE/SBC/sbccpl.F90	(revision 13630)
@@ -1199,5 +1199,9 @@
                   frcv(jpr_oty1)%z3(ji,jj,1) = 0.5 * ( frcv(jpr_oty1)%z3(ji  ,jj+1,1) + frcv(jpr_oty1)%z3(ji,jj,1) )
                END_2D
+#if defined key_mpi3
+               CALL lbc_lnk_nc_multi( 'sbccpl', frcv(jpr_otx1)%z3(:,:,1), 'U',  -1.0_wp, frcv(jpr_oty1)%z3(:,:,1), 'V',  -1.0_wp )
+#else
                CALL lbc_lnk_multi( 'sbccpl', frcv(jpr_otx1)%z3(:,:,1), 'U',  -1.0_wp, frcv(jpr_oty1)%z3(:,:,1), 'V',  -1.0_wp )
+#endif
             ENDIF
             llnewtx = .TRUE.
@@ -1224,5 +1228,9 @@
                frcv(jpr_taum)%z3(ji,jj,1) = 0.5 * SQRT( zzx * zzx + zzy * zzy )
             END_2D
+#if defined key_mpi3
+            CALL lbc_lnk_nc_multi( 'sbccpl', frcv(jpr_taum)%z3(:,:,1), 'T', 1.0_wp )
+#else
             CALL lbc_lnk( 'sbccpl', frcv(jpr_taum)%z3(:,:,1), 'T', 1.0_wp )
+#endif
             llnewtau = .TRUE.
          ELSE
@@ -1593,5 +1601,9 @@
                p_tauj(ji,jj) = zztmp2 * ( frcv(jpr_ity1)%z3(ji  ,jj+1,1) + frcv(jpr_ity1)%z3(ji,jj,1) )
             END_2D
+#if defined key_mpi3
+            CALL lbc_lnk_nc_multi( 'sbccpl', p_taui, 'U',  -1., p_tauj, 'V',  -1. )
+#else
             CALL lbc_lnk_multi( 'sbccpl', p_taui, 'U',  -1., p_tauj, 'V',  -1. )
+#endif
          END SELECT
          
@@ -2483,5 +2495,9 @@
                   zity1(ji,jj) = 0.5 * ( v_ice(ji,jj  )     + v_ice(ji  ,jj-1  )     ) *  fr_i(ji,jj)
                END_2D
+#if defined key_mpi3
+               CALL lbc_lnk_nc_multi( 'sbccpl', zitx1, 'T', -1.0_wp, zity1, 'T', -1.0_wp )
+#else
                CALL lbc_lnk_multi( 'sbccpl', zitx1, 'T', -1.0_wp, zity1, 'T', -1.0_wp )
+#endif
             CASE( 'mixed oce-ice'        )      ! Ocean and Ice on C-grid ==> T
                DO_2D( 0, 0, 0, 0 )
@@ -2492,5 +2508,9 @@
                END_2D
             END SELECT
+#if defined key_mpi3
+            CALL lbc_lnk_nc_multi( 'sbccpl', zotx1, ssnd(jps_ocx1)%clgrid, -1.0_wp,  zoty1, ssnd(jps_ocy1)%clgrid, -1.0_wp )
+#else
             CALL lbc_lnk_multi( 'sbccpl', zotx1, ssnd(jps_ocx1)%clgrid, -1.0_wp,  zoty1, ssnd(jps_ocy1)%clgrid, -1.0_wp )
+#endif
             !
          ENDIF
@@ -2560,5 +2580,9 @@
                 zity1(ji,jj) = 0.5 * ( v_ice(ji,jj  ) + v_ice(ji  ,jj-1  ) ) *  fr_i(ji,jj) 
              END_2D
+#if defined key_mpi3
+             CALL lbc_lnk_nc_multi( 'sbccpl', zitx1, 'T', -1.0_wp,  zity1, 'T', -1.0_wp ) 
+#else
              CALL lbc_lnk_multi( 'sbccpl', zitx1, 'T', -1.0_wp,  zity1, 'T', -1.0_wp ) 
+#endif
           CASE( 'mixed oce-ice'        )      ! Ocean and Ice on C-grid ==> T  
              DO_2D( 0, 0, 0, 0 )
@@ -2569,5 +2593,9 @@
              END_2D
           END SELECT
+#if defined key_mpi3
+         CALL lbc_lnk_nc_multi( 'sbccpl', zotx1, ssnd(jps_ocxw)%clgrid, -1.0_wp, zoty1, ssnd(jps_ocyw)%clgrid, -1.0_wp ) 
+#else
          CALL lbc_lnk_multi( 'sbccpl', zotx1, ssnd(jps_ocxw)%clgrid, -1.0_wp, zoty1, ssnd(jps_ocyw)%clgrid, -1.0_wp ) 
+#endif
          ! 
          ! 
Index: /NEMO/branches/2020/dev_r13296_HPC-07_mocavero_mpi3/src/OCE/SBC/sbcflx.F90
===================================================================
--- /NEMO/branches/2020/dev_r13296_HPC-07_mocavero_mpi3/src/OCE/SBC/sbcflx.F90	(revision 13629)
+++ /NEMO/branches/2020/dev_r13296_HPC-07_mocavero_mpi3/src/OCE/SBC/sbcflx.F90	(revision 13630)
@@ -145,6 +145,11 @@
          !
          ! clem: without these lbc calls, it seems that the northfold is not ok (true in 3.6, not sure in 4.x) 
+#if defined key_mpi3
+         CALL lbc_lnk_nc_multi( 'sbcflx', utau, 'U', -1._wp, vtau, 'V', -1._wp, &
+            &                           qns, 'T',  1._wp, emp , 'T',  1._wp, qsr, 'T', 1._wp ) !! sfx, 'T', 1._wp  )
+#else
          CALL lbc_lnk_multi( 'sbcflx', utau, 'U', -1._wp, vtau, 'V', -1._wp, &
             &                           qns, 'T',  1._wp, emp , 'T',  1._wp, qsr, 'T', 1._wp ) !! sfx, 'T', 1._wp  )
+#endif
          !
          IF( nitend-nit000 <= 100 .AND. lwp ) THEN                ! control print (if less than 100 time-step asked)
@@ -172,5 +177,9 @@
       END_2D
       !
+#if defined key_mpi3
+      CALL lbc_lnk_nc_multi( 'sbcflx', taum, 'T', 1._wp, wndm, 'T', 1._wp )
+#else
       CALL lbc_lnk_multi( 'sbcflx', taum, 'T', 1._wp, wndm, 'T', 1._wp )
+#endif
       !
    END SUBROUTINE sbc_flx
Index: /NEMO/branches/2020/dev_r13296_HPC-07_mocavero_mpi3/src/OCE/SBC/sbcfwb.F90
===================================================================
--- /NEMO/branches/2020/dev_r13296_HPC-07_mocavero_mpi3/src/OCE/SBC/sbcfwb.F90	(revision 13629)
+++ /NEMO/branches/2020/dev_r13296_HPC-07_mocavero_mpi3/src/OCE/SBC/sbcfwb.F90	(revision 13630)
@@ -180,5 +180,9 @@
             !
 !!gm   ===>>>>  lbc_lnk should be useless as all the computation is done over the whole domain !
+#if defined key_mpi3
+            CALL lbc_lnk_nc_multi( 'sbcfwb', zerp_cor, 'T', 1.0_wp )
+#else
             CALL lbc_lnk( 'sbcfwb', zerp_cor, 'T', 1.0_wp )
+#endif
             !
             emp(:,:) = emp(:,:) + zerp_cor(:,:)
Index: /NEMO/branches/2020/dev_r13296_HPC-07_mocavero_mpi3/src/OCE/SBC/sbcice_cice.F90
===================================================================
--- /NEMO/branches/2020/dev_r13296_HPC-07_mocavero_mpi3/src/OCE/SBC/sbcice_cice.F90	(revision 13629)
+++ /NEMO/branches/2020/dev_r13296_HPC-07_mocavero_mpi3/src/OCE/SBC/sbcice_cice.F90	(revision 13630)
@@ -222,5 +222,9 @@
       END_2D
 
+#if defined key_mpi3
+      CALL lbc_lnk_nc_multi( 'sbcice_cice', fr_iu , 'U', 1.0_wp,  fr_iv , 'V', 1.0_wp )
+#else
       CALL lbc_lnk_multi( 'sbcice_cice', fr_iu , 'U', 1.0_wp,  fr_iv , 'V', 1.0_wp )
+#endif
 
       ! set the snow+ice mass
@@ -506,5 +510,9 @@
          ss_iou(ji,jj) = 0.5 * ( ztmp1(ji,jj-1) + ztmp1(ji,jj) ) * umask(ji,jj,1)
       END_2D
+#if defined key_mpi3
+      CALL lbc_lnk_nc_multi( 'sbcice_cice', ss_iou , 'U', -1.0_wp )
+#else
       CALL lbc_lnk( 'sbcice_cice', ss_iou , 'U', -1.0_wp )
+#endif
 
 ! y comp of ocean-ice stress 
@@ -516,5 +524,9 @@
          ss_iov(ji,jj) = 0.5 * ( ztmp1(ji-1,jj) + ztmp1(ji,jj) ) * vmask(ji,jj,1)
       END_2D
+#if defined key_mpi3
+      CALL lbc_lnk_nc_multi( 'sbcice_cice', ss_iov , 'V', -1.0_wp )
+#else
       CALL lbc_lnk( 'sbcice_cice', ss_iov , 'V', -1.0_wp )
+#endif
 
 ! x and y comps of surface stress
@@ -569,5 +581,9 @@
       fmmflx(:,:) = ztmp1(:,:) !!Joakim edit
       
+#if defined key_mpi3
+      CALL lbc_lnk_nc_multi( 'sbcice_cice', emp , 'T', 1.0_wp, sfx , 'T', 1.0_wp )
+#else
       CALL lbc_lnk_multi( 'sbcice_cice', emp , 'T', 1.0_wp, sfx , 'T', 1.0_wp )
+#endif
 
 ! Solar penetrative radiation and non solar surface heat flux
@@ -595,5 +611,9 @@
 #endif
       qsr(:,:)=qsr(:,:)+ztmp1(:,:)
+#if defined key_mpi3
+      CALL lbc_lnk_nc_multi( 'sbcice_cice', qsr , 'T', 1.0_wp )
+#else
       CALL lbc_lnk( 'sbcice_cice', qsr , 'T', 1.0_wp )
+#endif
 
       DO_2D( 1, 1, 1, 1 )
@@ -608,5 +628,9 @@
       qns(:,:)=qns(:,:)+nfrzmlt(:,:)+ztmp1(:,:)
 
+#if defined key_mpi3
+      CALL lbc_lnk_nc_multi( 'sbcice_cice', qns , 'T', 1.0_wp )
+#else
       CALL lbc_lnk( 'sbcice_cice', qns , 'T', 1.0_wp )
+#endif
 
 ! Prepare for the following CICE time-step
@@ -626,5 +650,9 @@
       END_2D
 
+#if defined key_mpi3
+      CALL lbc_lnk_nc_multi( 'sbcice_cice', fr_iu , 'U', 1.0_wp, fr_iv , 'V', 1.0_wp )
+#else
       CALL lbc_lnk_multi( 'sbcice_cice', fr_iu , 'U', 1.0_wp, fr_iv , 'V', 1.0_wp )
+#endif
 
       ! set the snow+ice mass
@@ -848,5 +876,9 @@
 !     A. Ensure all haloes are filled in NEMO field (pn)
 
+#if defined key_mpi3
+      CALL lbc_lnk_nc_multi( 'sbcice_cice', pn , cd_type, psgn )
+#else
       CALL lbc_lnk( 'sbcice_cice', pn , cd_type, psgn )
+#endif
 
 #if defined key_nemocice_decomp
@@ -1023,5 +1055,9 @@
 !     D. Ensure all haloes are filled in pn
 
+#if defined key_mpi3
+      CALL lbc_lnk_nc_multi( 'sbcice_cice', pn , cd_type, psgn )
+#else
       CALL lbc_lnk( 'sbcice_cice', pn , cd_type, psgn )
+#endif
 
    END SUBROUTINE cice2nemo
Index: /NEMO/branches/2020/dev_r13296_HPC-07_mocavero_mpi3/src/OCE/SBC/sbcmod.F90
===================================================================
--- /NEMO/branches/2020/dev_r13296_HPC-07_mocavero_mpi3/src/OCE/SBC/sbcmod.F90	(revision 13629)
+++ /NEMO/branches/2020/dev_r13296_HPC-07_mocavero_mpi3/src/OCE/SBC/sbcmod.F90	(revision 13630)
@@ -464,5 +464,9 @@
          ! A lbc_lnk is therefore needed to ensure reproducibility and restartability.
          ! see ticket #2113 for discussion about this lbc_lnk.
+#if defined key_mpi3
+         IF( .NOT. ln_passive_mode ) CALL lbc_lnk_nc_multi( 'sbcmod', emp, 'T', 1.0_wp ) ! ensure restartability with icebergs
+#else
          IF( .NOT. ln_passive_mode ) CALL lbc_lnk( 'sbcmod', emp, 'T', 1.0_wp ) ! ensure restartability with icebergs
+#endif
       ENDIF
 
Index: /NEMO/branches/2020/dev_r13296_HPC-07_mocavero_mpi3/src/OCE/SBC/sbcwave.F90
===================================================================
--- /NEMO/branches/2020/dev_r13296_HPC-07_mocavero_mpi3/src/OCE/SBC/sbcwave.F90	(revision 13629)
+++ /NEMO/branches/2020/dev_r13296_HPC-07_mocavero_mpi3/src/OCE/SBC/sbcwave.F90	(revision 13630)
@@ -212,5 +212,9 @@
       END_3D
       !
+#if defined key_mpi3
+      CALL lbc_lnk_nc_multi( 'sbcwave', ze3divh, 'T', 1.0_wp )
+#else
       CALL lbc_lnk( 'sbcwave', ze3divh, 'T', 1.0_wp )
+#endif
       !
       IF( ln_linssh ) THEN   ;   ik = 1   ! none zero velocity through the sea surface
@@ -271,5 +275,9 @@
             taum(ji,jj) = SQRT( tauw_x(ji,jj)*tauw_x(ji,jj) + tauw_y(ji,jj)*tauw_y(ji,jj) )
          END_2D
+#if defined key_mpi3
+         CALL lbc_lnk_nc_multi( 'sbcwave', utau(:,:), 'U', -1.0_wp , vtau(:,:), 'V', -1.0_wp , taum(:,:) , 'T', -1.0_wp )
+#else
          CALL lbc_lnk_multi( 'sbcwave', utau(:,:), 'U', -1.0_wp , vtau(:,:), 'V', -1.0_wp , taum(:,:) , 'T', -1.0_wp )
+#endif
       ENDIF
       !
Index: /NEMO/branches/2020/dev_r13296_HPC-07_mocavero_mpi3/src/OCE/STO/stopar.F90
===================================================================
--- /NEMO/branches/2020/dev_r13296_HPC-07_mocavero_mpi3/src/OCE/STO/stopar.F90	(revision 13629)
+++ /NEMO/branches/2020/dev_r13296_HPC-07_mocavero_mpi3/src/OCE/STO/stopar.F90	(revision 13630)
@@ -174,5 +174,9 @@
           ! Apply horizontal Laplacian filter to w
           DO jflt = 1, sto2d_flt(jsto)
+#if defined key_mpi3
+            CALL lbc_lnk_nc_multi( 'stopar', sto2d(:,:,jsto), sto2d_typ(jsto), sto2d_sgn(jsto) )
+#else
             CALL lbc_lnk( 'stopar', sto2d(:,:,jsto), sto2d_typ(jsto), sto2d_sgn(jsto) )
+#endif
             CALL sto_par_flt( sto2d(:,:,jsto) )
           END DO
@@ -197,5 +201,9 @@
 
         ! Lateral boundary conditions on sto2d
+#if defined key_mpi3
+        CALL lbc_lnk_nc_multi( 'stopar', sto2d(:,:,jsto), sto2d_typ(jsto), sto2d_sgn(jsto) )
+#else
         CALL lbc_lnk( 'stopar', sto2d(:,:,jsto), sto2d_typ(jsto), sto2d_sgn(jsto) )
+#endif
       END DO
       !
@@ -212,5 +220,9 @@
              ! Apply horizontal Laplacian filter to w
              DO jflt = 1, sto3d_flt(jsto)
+#if defined key_mpi3
+               CALL lbc_lnk_nc_multi( 'stopar', sto3d(:,:,jk,jsto), sto3d_typ(jsto), sto3d_sgn(jsto) )
+#else
                CALL lbc_lnk( 'stopar', sto3d(:,:,jk,jsto), sto3d_typ(jsto), sto3d_sgn(jsto) )
+#endif
                CALL sto_par_flt( sto3d(:,:,jk,jsto) )
              END DO
@@ -235,5 +247,9 @@
          END DO
          ! Lateral boundary conditions on sto3d
+#if defined key_mpi3
+         CALL lbc_lnk_nc_multi( 'stopar', sto3d(:,:,:,jsto), sto3d_typ(jsto), sto3d_sgn(jsto) )
+#else
          CALL lbc_lnk( 'stopar', sto3d(:,:,:,jsto), sto3d_typ(jsto), sto3d_sgn(jsto) )
+#endif
       END DO
       !
@@ -642,5 +658,9 @@
          ! Apply horizontal Laplacian filter to w
          DO jflt = 1, sto2d_flt(jsto)
+#if defined key_mpi3
+            CALL lbc_lnk_nc_multi( 'stopar', sto2d(:,:,jsto), sto2d_typ(jsto), sto2d_sgn(jsto) )
+#else
             CALL lbc_lnk( 'stopar', sto2d(:,:,jsto), sto2d_typ(jsto), sto2d_sgn(jsto) )
+#endif
             CALL sto_par_flt( sto2d(:,:,jsto) )
          END DO
@@ -659,5 +679,9 @@
             ! Apply horizontal Laplacian filter to w
             DO jflt = 1, sto3d_flt(jsto)
+#if defined key_mpi3
+               CALL lbc_lnk_nc_multi( 'stopar', sto3d(:,:,jk,jsto), sto3d_typ(jsto), sto3d_sgn(jsto) )
+#else
                CALL lbc_lnk( 'stopar', sto3d(:,:,jk,jsto), sto3d_typ(jsto), sto3d_sgn(jsto) )
+#endif
                CALL sto_par_flt( sto3d(:,:,jk,jsto) )
             END DO
Index: /NEMO/branches/2020/dev_r13296_HPC-07_mocavero_mpi3/src/OCE/STO/stopts.F90
===================================================================
--- /NEMO/branches/2020/dev_r13296_HPC-07_mocavero_mpi3/src/OCE/STO/stopts.F90	(revision 13629)
+++ /NEMO/branches/2020/dev_r13296_HPC-07_mocavero_mpi3/src/OCE/STO/stopts.F90	(revision 13630)
@@ -54,5 +54,9 @@
 
       DO jts = 1, jpts
+#if defined key_mpi3
+        CALL lbc_lnk_nc_multi( 'stopts', pts(:,:,:,jts), 'T' , 1._wp )
+#else
         CALL lbc_lnk( 'stopts', pts(:,:,:,jts), 'T' , 1._wp )
+#endif
       ENDDO
 
@@ -119,5 +123,9 @@
       DO jdof = 1, nn_sto_eos
          DO jts = 1, jpts
+#if defined key_mpi3
+            CALL lbc_lnk_nc_multi( 'stopts', pts_ran(:,:,:,jts,jdof), 'T' , 1._wp )
+#else
             CALL lbc_lnk( 'stopts', pts_ran(:,:,:,jts,jdof), 'T' , 1._wp )
+#endif
          END DO
       END DO
Index: /NEMO/branches/2020/dev_r13296_HPC-07_mocavero_mpi3/src/OCE/TRA/traadv_cen.F90
===================================================================
--- /NEMO/branches/2020/dev_r13296_HPC-07_mocavero_mpi3/src/OCE/TRA/traadv_cen.F90	(revision 13629)
+++ /NEMO/branches/2020/dev_r13296_HPC-07_mocavero_mpi3/src/OCE/TRA/traadv_cen.F90	(revision 13630)
@@ -116,5 +116,9 @@
                ztv(ji,jj,jk) = ( pt(ji  ,jj+1,jk,jn,Kmm) - pt(ji,jj,jk,jn,Kmm) ) * vmask(ji,jj,jk)
             END_3D
+#if defined key_mpi3
+            CALL lbc_lnk_nc_multi( 'traadv_cen', ztu, 'U', -1.0_wp , ztv, 'V', -1.0_wp )   ! Lateral boundary cond.
+#else
             CALL lbc_lnk_multi( 'traadv_cen', ztu, 'U', -1.0_wp , ztv, 'V', -1.0_wp )   ! Lateral boundary cond.
+#endif
             !
             DO_3D( 0, 0, 0, 0, 1, jpkm1 )           ! Horizontal advective fluxes
@@ -128,5 +132,9 @@
                zwy(ji,jj,jk) =  0.5_wp * pV(ji,jj,jk) * zC4t_v
             END_3D
+#if defined key_mpi3
+            CALL lbc_lnk_nc_multi( 'traadv_cen', zwx, 'U', -1. , zwy, 'V', -1. )
+#else
             CALL lbc_lnk_multi( 'traadv_cen', zwx, 'U', -1. , zwy, 'V', -1. )
+#endif
             !
          CASE DEFAULT
Index: /NEMO/branches/2020/dev_r13296_HPC-07_mocavero_mpi3/src/OCE/TRA/traadv_mus.F90
===================================================================
--- /NEMO/branches/2020/dev_r13296_HPC-07_mocavero_mpi3/src/OCE/TRA/traadv_mus.F90	(revision 13629)
+++ /NEMO/branches/2020/dev_r13296_HPC-07_mocavero_mpi3/src/OCE/TRA/traadv_mus.F90	(revision 13630)
@@ -137,5 +137,9 @@
          END_3D
          ! lateral boundary conditions   (changed sign)
+#if defined key_mpi3
+         CALL lbc_lnk_nc_multi( 'traadv_mus', zwx, 'U', -1.0_wp , zwy, 'V', -1.0_wp )
+#else
          CALL lbc_lnk_multi( 'traadv_mus', zwx, 'U', -1.0_wp , zwy, 'V', -1.0_wp )
+#endif
          !                                !-- Slopes of tracer
          zslpx(:,:,jpk) = 0._wp                 ! bottom values
@@ -173,5 +177,9 @@
             zwy(ji,jj,jk) = pV(ji,jj,jk) * ( zalpha * zzwx + (1.-zalpha) * zzwy )
          END_3D
+#if defined key_mpi3
+         CALL lbc_lnk_nc_multi( 'traadv_mus', zwx, 'U', -1.0_wp , zwy, 'V', -1.0_wp )   ! lateral boundary conditions   (changed sign)
+#else
          CALL lbc_lnk_multi( 'traadv_mus', zwx, 'U', -1.0_wp , zwy, 'V', -1.0_wp )   ! lateral boundary conditions   (changed sign)
+#endif
          !
          DO_3D( 0, 0, 0, 0, 1, jpkm1 )    !-- Tracer advective trend
Index: /NEMO/branches/2020/dev_r13296_HPC-07_mocavero_mpi3/src/OCE/TRA/traadv_qck.F90
===================================================================
--- /NEMO/branches/2020/dev_r13296_HPC-07_mocavero_mpi3/src/OCE/TRA/traadv_qck.F90	(revision 13629)
+++ /NEMO/branches/2020/dev_r13296_HPC-07_mocavero_mpi3/src/OCE/TRA/traadv_qck.F90	(revision 13630)
@@ -146,5 +146,9 @@
             zfd(ji,jj,jk) = pt(ji+1,jj,jk,jn,Kbb)        ! Downstream in the x-direction for the tracer
          END_3D
+#if defined key_mpi3
+         CALL lbc_lnk_nc_multi( 'traadv_qck', zfc(:,:,:), 'T', 1.0_wp , zfd(:,:,:), 'T', 1.0_wp )   ! Lateral boundary conditions 
+#else
          CALL lbc_lnk_multi( 'traadv_qck', zfc(:,:,:), 'T', 1.0_wp , zfd(:,:,:), 'T', 1.0_wp )   ! Lateral boundary conditions 
+#endif
          
          !
@@ -164,5 +168,9 @@
          END_3D
          !--- Lateral boundary conditions 
+#if defined key_mpi3
+         CALL lbc_lnk_nc_multi( 'traadv_qck', zfu(:,:,:), 'T', 1.0_wp , zfd(:,:,:), 'T', 1.0_wp, zfc(:,:,:), 'T', 1.0_wp,  zwx(:,:,:), 'T', 1.0_wp )
+#else
          CALL lbc_lnk_multi( 'traadv_qck', zfu(:,:,:), 'T', 1.0_wp , zfd(:,:,:), 'T', 1.0_wp, zfc(:,:,:), 'T', 1.0_wp,  zwx(:,:,:), 'T', 1.0_wp )
+#endif
 
          !--- QUICKEST scheme
@@ -173,5 +181,9 @@
             zfu(ji,jj,jk) = tmask(ji-1,jj,jk) + tmask(ji,jj,jk) + tmask(ji+1,jj,jk) - 2.
          END_3D
+#if defined key_mpi3
+         CALL lbc_lnk_nc_multi( 'traadv_qck', zfu(:,:,:), 'T', 1.0_wp )      ! Lateral boundary conditions 
+#else
          CALL lbc_lnk( 'traadv_qck', zfu(:,:,:), 'T', 1.0_wp )      ! Lateral boundary conditions 
+#endif
 
          !
@@ -189,5 +201,9 @@
          END DO
          !
+#if defined key_mpi3
+         CALL lbc_lnk_nc_multi( 'traadv_qck', zwx(:,:,:), 'T', 1.0_wp ) ! Lateral boundary conditions
+#else
          CALL lbc_lnk( 'traadv_qck', zwx(:,:,:), 'T', 1.0_wp ) ! Lateral boundary conditions
+#endif
          !
          ! Computation of the trend
@@ -240,5 +256,9 @@
             END_2D
          END DO
+#if defined key_mpi3
+         CALL lbc_lnk_nc_multi( 'traadv_qck', zfc(:,:,:), 'T', 1.0_wp , zfd(:,:,:), 'T', 1.0_wp )   ! Lateral boundary conditions 
+#else
          CALL lbc_lnk_multi( 'traadv_qck', zfc(:,:,:), 'T', 1.0_wp , zfd(:,:,:), 'T', 1.0_wp )   ! Lateral boundary conditions 
+#endif
 
          
@@ -261,5 +281,9 @@
 
          !--- Lateral boundary conditions 
+#if defined key_mpi3
+         CALL lbc_lnk_nc_multi( 'traadv_qck', zfu(:,:,:), 'T', 1.0_wp , zfd(:,:,:), 'T', 1.0_wp, zfc(:,:,:), 'T', 1.0_wp, zwy(:,:,:), 'T', 1.0_wp )
+#else
          CALL lbc_lnk_multi( 'traadv_qck', zfu(:,:,:), 'T', 1.0_wp , zfd(:,:,:), 'T', 1.0_wp, zfc(:,:,:), 'T', 1.0_wp, zwy(:,:,:), 'T', 1.0_wp )
+#endif
 
          !--- QUICKEST scheme
@@ -270,5 +294,9 @@
             zfu(ji,jj,jk) = tmask(ji,jj-1,jk) + tmask(ji,jj,jk) + tmask(ji,jj+1,jk) - 2.
          END_3D
+#if defined key_mpi3
+         CALL lbc_lnk_nc_multi( 'traadv_qck', zfu(:,:,:), 'T', 1.0_wp )    !--- Lateral boundary conditions 
+#else
          CALL lbc_lnk( 'traadv_qck', zfu(:,:,:), 'T', 1.0_wp )    !--- Lateral boundary conditions 
+#endif
          !
          ! Tracer flux on the x-direction
@@ -285,5 +313,9 @@
          END DO
          !
+#if defined key_mpi3
+         CALL lbc_lnk_nc_multi( 'traadv_qck', zwy(:,:,:), 'T', 1.0_wp ) ! Lateral boundary conditions
+#else
          CALL lbc_lnk( 'traadv_qck', zwy(:,:,:), 'T', 1.0_wp ) ! Lateral boundary conditions
+#endif
          !
          ! Computation of the trend
Index: /NEMO/branches/2020/dev_r13296_HPC-07_mocavero_mpi3/src/OCE/TRA/traadv_ubs.F90
===================================================================
--- /NEMO/branches/2020/dev_r13296_HPC-07_mocavero_mpi3/src/OCE/TRA/traadv_ubs.F90	(revision 13629)
+++ /NEMO/branches/2020/dev_r13296_HPC-07_mocavero_mpi3/src/OCE/TRA/traadv_ubs.F90	(revision 13630)
@@ -138,5 +138,9 @@
             !                                    
          END DO         
+#if defined key_mpi3
+         CALL lbc_lnk_nc_multi( 'traadv_ubs', zltu, 'T', 1.0_wp )   ;    CALL lbc_lnk_nc_multi( 'traadv_ubs', zltv, 'T', 1.0_wp )   ! Lateral boundary cond. (unchanged sgn)
+#else
          CALL lbc_lnk( 'traadv_ubs', zltu, 'T', 1.0_wp )   ;    CALL lbc_lnk( 'traadv_ubs', zltv, 'T', 1.0_wp )   ! Lateral boundary cond. (unchanged sgn)
+#endif
          !    
          DO_3D( 1, 0, 1, 0, 1, jpkm1 )   !==  Horizontal advective fluxes  ==!     (UBS)
@@ -209,5 +213,9 @@
                zti(ji,jj,jk)    = ( pt(ji,jj,jk,jn,Kbb) + p2dt * ( ztak + zltu(ji,jj,jk) ) ) * tmask(ji,jj,jk)
             END_3D
+#if defined key_mpi3
+            CALL lbc_lnk_nc_multi( 'traadv_ubs', zti, 'T', 1.0_wp )      ! Lateral boundary conditions on zti, zsi   (unchanged sign)
+#else
             CALL lbc_lnk( 'traadv_ubs', zti, 'T', 1.0_wp )      ! Lateral boundary conditions on zti, zsi   (unchanged sign)
+#endif
             !
             !                          !*  anti-diffusive flux : high order minus low order
Index: /NEMO/branches/2020/dev_r13296_HPC-07_mocavero_mpi3/src/OCE/TRA/traatf_qco.F90
===================================================================
--- /NEMO/branches/2020/dev_r13296_HPC-07_mocavero_mpi3/src/OCE/TRA/traatf_qco.F90	(revision 13629)
+++ /NEMO/branches/2020/dev_r13296_HPC-07_mocavero_mpi3/src/OCE/TRA/traatf_qco.F90	(revision 13630)
@@ -149,7 +149,13 @@
          ENDIF
          !
+#if defined key_mpi3
+         CALL lbc_lnk_nc_multi( 'traatfqco', pts(:,:,:,jp_tem,Kbb) , 'T', 1., pts(:,:,:,jp_sal,Kbb) , 'T', 1., &
+                  &                    pts(:,:,:,jp_tem,Kmm) , 'T', 1., pts(:,:,:,jp_sal,Kmm) , 'T', 1., &
+                  &                    pts(:,:,:,jp_tem,Kaa), 'T', 1., pts(:,:,:,jp_sal,Kaa), 'T', 1.  )
+#else
          CALL lbc_lnk_multi( 'traatfqco', pts(:,:,:,jp_tem,Kbb) , 'T', 1., pts(:,:,:,jp_sal,Kbb) , 'T', 1., &
                   &                    pts(:,:,:,jp_tem,Kmm) , 'T', 1., pts(:,:,:,jp_sal,Kmm) , 'T', 1., &
                   &                    pts(:,:,:,jp_tem,Kaa), 'T', 1., pts(:,:,:,jp_sal,Kaa), 'T', 1.  )
+#endif
          !
       ENDIF
Index: /NEMO/branches/2020/dev_r13296_HPC-07_mocavero_mpi3/src/OCE/TRA/trabbc.F90
===================================================================
--- /NEMO/branches/2020/dev_r13296_HPC-07_mocavero_mpi3/src/OCE/TRA/trabbc.F90	(revision 13629)
+++ /NEMO/branches/2020/dev_r13296_HPC-07_mocavero_mpi3/src/OCE/TRA/trabbc.F90	(revision 13630)
@@ -96,5 +96,9 @@
       END_2D
       !
+#if defined key_mpi3
+      CALL lbc_lnk_nc_multi( 'trabbc', pts(:,:,:,jp_tem,Krhs) , 'T', 1.0_wp )
+#else
       CALL lbc_lnk( 'trabbc', pts(:,:,:,jp_tem,Krhs) , 'T', 1.0_wp )
+#endif
       !
       IF( l_trdtra ) THEN        ! Send the trend for diagnostics
Index: /NEMO/branches/2020/dev_r13296_HPC-07_mocavero_mpi3/src/OCE/TRA/trabbl.F90
===================================================================
--- /NEMO/branches/2020/dev_r13296_HPC-07_mocavero_mpi3/src/OCE/TRA/trabbl.F90	(revision 13629)
+++ /NEMO/branches/2020/dev_r13296_HPC-07_mocavero_mpi3/src/OCE/TRA/trabbl.F90	(revision 13630)
@@ -126,5 +126,9 @@
             &          tab3d_2=pts(:,:,:,jp_sal,Krhs), clinfo2=           ' Sa: ', mask2=tmask, clinfo3='tra' )
          ! lateral boundary conditions ; just need for outputs
+#if defined key_mpi3
+         CALL lbc_lnk_nc_multi( 'trabbl', ahu_bbl, 'U', 1.0_wp , ahv_bbl, 'V', 1.0_wp )
+#else
          CALL lbc_lnk_multi( 'trabbl', ahu_bbl, 'U', 1.0_wp , ahv_bbl, 'V', 1.0_wp )
+#endif
          CALL iom_put( "ahu_bbl", ahu_bbl )   ! bbl diffusive flux i-coef
          CALL iom_put( "ahv_bbl", ahv_bbl )   ! bbl diffusive flux j-coef
@@ -139,5 +143,9 @@
             &          tab3d_2=pts(:,:,:,jp_sal,Krhs), clinfo2=           ' Sa: ', mask2=tmask, clinfo3='tra' )
          ! lateral boundary conditions ; just need for outputs
+#if defined key_mpi3
+         CALL lbc_lnk_nc_multi( 'trabbl', utr_bbl, 'U', 1.0_wp , vtr_bbl, 'V', 1.0_wp )
+#else
          CALL lbc_lnk_multi( 'trabbl', utr_bbl, 'U', 1.0_wp , vtr_bbl, 'V', 1.0_wp )
+#endif
          CALL iom_put( "uoce_bbl", utr_bbl )  ! bbl i-transport
          CALL iom_put( "voce_bbl", vtr_bbl )  ! bbl j-transport
@@ -517,5 +525,9 @@
       ! converte into REAL to use lbc_lnk ; impose a min value of 1 as a zero can be set in lbclnk
       zmbku(:,:) = REAL( mbku_d(:,:), wp )   ;     zmbkv(:,:) = REAL( mbkv_d(:,:), wp )  
+#if defined key_mpi3
+      CALL lbc_lnk_nc_multi( 'trabbl', zmbku,'U',1.0_wp, zmbkv,'V',1.0_wp) 
+#else
       CALL lbc_lnk_multi( 'trabbl', zmbku,'U',1.0_wp, zmbkv,'V',1.0_wp) 
+#endif
       mbku_d(:,:) = MAX( INT( zmbku(:,:) ), 1 ) ;  mbkv_d(:,:) = MAX( NINT( zmbkv(:,:) ), 1 )
       !
@@ -536,5 +548,9 @@
          e3v_bbl_0(ji,jj) = MIN( e3v_0(ji,jj,mbkt(ji  ,jj+1)), e3v_0(ji,jj,mbkt(ji,jj)) )
       END_2D
+#if defined key_mpi3
+      CALL lbc_lnk_nc_multi( 'trabbl', e3u_bbl_0, 'U', 1.0_wp , e3v_bbl_0, 'V', 1.0_wp )      ! lateral boundary conditions
+#else
       CALL lbc_lnk_multi( 'trabbl', e3u_bbl_0, 'U', 1.0_wp , e3v_bbl_0, 'V', 1.0_wp )      ! lateral boundary conditions
+#endif
       !
       !                             !* masked diffusive flux coefficients
Index: /NEMO/branches/2020/dev_r13296_HPC-07_mocavero_mpi3/src/OCE/TRA/traldf_lap_blp.F90
===================================================================
--- /NEMO/branches/2020/dev_r13296_HPC-07_mocavero_mpi3/src/OCE/TRA/traldf_lap_blp.F90	(revision 13629)
+++ /NEMO/branches/2020/dev_r13296_HPC-07_mocavero_mpi3/src/OCE/TRA/traldf_lap_blp.F90	(revision 13630)
@@ -200,5 +200,9 @@
       END SELECT
       !
+#if defined key_mpi3
+      CALL lbc_lnk_nc_multi( 'traldf_lap_blp', zlap(:,:,:,:) , 'T', 1.0_wp )     ! Lateral boundary conditions (unchanged sign)
+#else
       CALL lbc_lnk( 'traldf_lap_blp', zlap(:,:,:,:) , 'T', 1.0_wp )     ! Lateral boundary conditions (unchanged sign)
+#endif
       !                                               ! Partial top/bottom cell: GRADh( zlap )  
       IF( ln_isfcav .AND. ln_zps ) THEN   ;   CALL zps_hde_isf( kt, Kmm, kjpt, zlap, zglu, zglv, zgui, zgvi )  ! both top & bottom
Index: /NEMO/branches/2020/dev_r13296_HPC-07_mocavero_mpi3/src/OCE/TRA/tramle.F90
===================================================================
--- /NEMO/branches/2020/dev_r13296_HPC-07_mocavero_mpi3/src/OCE/TRA/tramle.F90	(revision 13629)
+++ /NEMO/branches/2020/dev_r13296_HPC-07_mocavero_mpi3/src/OCE/TRA/tramle.F90	(revision 13630)
@@ -289,5 +289,9 @@
                rfv(ji,jj) = SQRT(  zfv * zfv + z1_t2 )
             END_2D
+#if defined key_mpi3
+            CALL lbc_lnk_nc_multi( 'tramle', rfu, 'U', 1.0_wp , rfv, 'V', 1.0_wp )
+#else
             CALL lbc_lnk_multi( 'tramle', rfu, 'U', 1.0_wp , rfv, 'V', 1.0_wp )
+#endif
             !
          ELSEIF( nn_mle == 1 ) THEN           ! MLE array allocation & initialisation
Index: /NEMO/branches/2020/dev_r13296_HPC-07_mocavero_mpi3/src/OCE/TRA/tranpc.F90
===================================================================
--- /NEMO/branches/2020/dev_r13296_HPC-07_mocavero_mpi3/src/OCE/TRA/tranpc.F90	(revision 13629)
+++ /NEMO/branches/2020/dev_r13296_HPC-07_mocavero_mpi3/src/OCE/TRA/tranpc.F90	(revision 13630)
@@ -310,5 +310,9 @@
          ENDIF
          !
+#if defined key_mpi3
+         CALL lbc_lnk_nc_multi( 'tranpc', pts(:,:,:,jp_tem,Kaa), 'T', 1.0_wp, pts(:,:,:,jp_sal,Kaa), 'T', 1.0_wp )
+#else
          CALL lbc_lnk_multi( 'tranpc', pts(:,:,:,jp_tem,Kaa), 'T', 1.0_wp, pts(:,:,:,jp_sal,Kaa), 'T', 1.0_wp )
+#endif
          !
          IF( lwp .AND. l_LB_debug ) THEN
Index: /NEMO/branches/2020/dev_r13296_HPC-07_mocavero_mpi3/src/OCE/TRA/traqsr.F90
===================================================================
--- /NEMO/branches/2020/dev_r13296_HPC-07_mocavero_mpi3/src/OCE/TRA/traqsr.F90	(revision 13629)
+++ /NEMO/branches/2020/dev_r13296_HPC-07_mocavero_mpi3/src/OCE/TRA/traqsr.F90	(revision 13630)
@@ -279,5 +279,9 @@
          ENDIF
       END_2D
+#if defined key_mpi3
+      CALL lbc_lnk_nc_multi( 'traqsr', fraqsr_1lev(:,:), 'T', 1._wp )
+#else
       CALL lbc_lnk( 'traqsr', fraqsr_1lev(:,:), 'T', 1._wp )
+#endif
       !
       IF( iom_use('qsr3d') ) THEN      ! output the shortwave Radiation distribution
Index: /NEMO/branches/2020/dev_r13296_HPC-07_mocavero_mpi3/src/OCE/TRA/trazdf.F90
===================================================================
--- /NEMO/branches/2020/dev_r13296_HPC-07_mocavero_mpi3/src/OCE/TRA/trazdf.F90	(revision 13629)
+++ /NEMO/branches/2020/dev_r13296_HPC-07_mocavero_mpi3/src/OCE/TRA/trazdf.F90	(revision 13630)
@@ -95,5 +95,9 @@
          END DO
 !!gm this should be moved in trdtra.F90 and done on all trends
+#if defined key_mpi3
+         CALL lbc_lnk_nc_multi( 'trazdf', ztrdt, 'T', 1.0_wp , ztrds, 'T', 1.0_wp )
+#else
          CALL lbc_lnk_multi( 'trazdf', ztrdt, 'T', 1.0_wp , ztrds, 'T', 1.0_wp )
+#endif
 !!gm
          CALL trd_tra( kt, Kmm, Krhs, 'TRA', jp_tem, jptra_zdf, ztrdt )
Index: /NEMO/branches/2020/dev_r13296_HPC-07_mocavero_mpi3/src/OCE/TRA/zpshde.F90
===================================================================
--- /NEMO/branches/2020/dev_r13296_HPC-07_mocavero_mpi3/src/OCE/TRA/zpshde.F90	(revision 13629)
+++ /NEMO/branches/2020/dev_r13296_HPC-07_mocavero_mpi3/src/OCE/TRA/zpshde.F90	(revision 13630)
@@ -146,5 +146,9 @@
       END DO
       !
+#if defined key_mpi3
+      CALL lbc_lnk_nc_multi( 'zpshde', pgtu(:,:,:), 'U', -1.0_wp , pgtv(:,:,:), 'V', -1.0_wp )   ! Lateral boundary cond.
+#else
       CALL lbc_lnk_multi( 'zpshde', pgtu(:,:,:), 'U', -1.0_wp , pgtv(:,:,:), 'V', -1.0_wp )   ! Lateral boundary cond.
+#endif
       !                
       IF( PRESENT( prd ) ) THEN    !==  horizontal derivative of density anomalies (rd)  ==!    (optional part)
@@ -179,5 +183,9 @@
             ENDIF
          END_2D
+#if defined key_mpi3
+         CALL lbc_lnk_nc_multi( 'zpshde', pgru , 'U', -1.0_wp , pgrv , 'V', -1.0_wp )   ! Lateral boundary conditions
+#else
          CALL lbc_lnk_multi( 'zpshde', pgru , 'U', -1.0_wp , pgrv , 'V', -1.0_wp )   ! Lateral boundary conditions
+#endif
          !
       END IF
@@ -302,5 +310,9 @@
       END DO
       !
+#if defined key_mpi3
+      CALL lbc_lnk_nc_multi( 'zpshde', pgtu(:,:,:), 'U', -1.0_wp , pgtv(:,:,:), 'V', -1.0_wp )   ! Lateral boundary cond.
+#else
       CALL lbc_lnk_multi( 'zpshde', pgtu(:,:,:), 'U', -1.0_wp , pgtv(:,:,:), 'V', -1.0_wp )   ! Lateral boundary cond.
+#endif
 
       ! horizontal derivative of density anomalies (rd)
@@ -344,5 +356,9 @@
          END_2D
 
+#if defined key_mpi3
+         CALL lbc_lnk_nc_multi( 'zpshde', pgru , 'U', -1.0_wp , pgrv , 'V', -1.0_wp )   ! Lateral boundary conditions
+#else
          CALL lbc_lnk_multi( 'zpshde', pgru , 'U', -1.0_wp , pgrv , 'V', -1.0_wp )   ! Lateral boundary conditions
+#endif
          !
       END IF
@@ -395,5 +411,9 @@
          !
       END DO
+#if defined key_mpi3
+      CALL lbc_lnk_nc_multi( 'zpshde', pgtui(:,:,:), 'U', -1.0_wp , pgtvi(:,:,:), 'V', -1.0_wp )   ! Lateral boundary cond.
+#else
       CALL lbc_lnk_multi( 'zpshde', pgtui(:,:,:), 'U', -1.0_wp , pgtvi(:,:,:), 'V', -1.0_wp )   ! Lateral boundary cond.
+#endif
 
       IF( PRESENT( prd ) ) THEN    !==  horizontal derivative of density anomalies (rd)  ==!    (optional part)
@@ -434,5 +454,9 @@
 
          END_2D
+#if defined key_mpi3
+         CALL lbc_lnk_nc_multi( 'zpshde', pgrui, 'U', -1.0_wp , pgrvi, 'V', -1.0_wp )   ! Lateral boundary conditions
+#else
          CALL lbc_lnk_multi( 'zpshde', pgrui, 'U', -1.0_wp , pgrvi, 'V', -1.0_wp )   ! Lateral boundary conditions
+#endif
          !
       END IF  
Index: /NEMO/branches/2020/dev_r13296_HPC-07_mocavero_mpi3/src/OCE/TRD/trddyn.F90
===================================================================
--- /NEMO/branches/2020/dev_r13296_HPC-07_mocavero_mpi3/src/OCE/TRD/trddyn.F90	(revision 13629)
+++ /NEMO/branches/2020/dev_r13296_HPC-07_mocavero_mpi3/src/OCE/TRD/trddyn.F90	(revision 13630)
@@ -128,5 +128,9 @@
                                  z3dy(ji,jj,jk) = vv(ji,jj,jk,Kmm) * ( vv(ji,jj+1,jk,Kmm) - vv(ji,jj-1,jk,Kmm) ) / ( 2._wp * e2v(ji,jj) )
                               END_3D
+#if defined key_mpi3
+                              CALL lbc_lnk_nc_multi( 'trddyn', z3dx, 'U', -1.0_wp, z3dy, 'V', -1.0_wp )
+#else
                               CALL lbc_lnk_multi( 'trddyn', z3dx, 'U', -1.0_wp, z3dy, 'V', -1.0_wp )
+#endif
                               CALL iom_put( "utrd_udx", z3dx  )
                               CALL iom_put( "vtrd_vdy", z3dy  )
Index: /NEMO/branches/2020/dev_r13296_HPC-07_mocavero_mpi3/src/OCE/TRD/trdken.F90
===================================================================
--- /NEMO/branches/2020/dev_r13296_HPC-07_mocavero_mpi3/src/OCE/TRD/trdken.F90	(revision 13629)
+++ /NEMO/branches/2020/dev_r13296_HPC-07_mocavero_mpi3/src/OCE/TRD/trdken.F90	(revision 13630)
@@ -90,5 +90,9 @@
       !!----------------------------------------------------------------------
       !
+#if defined key_mpi3
+      CALL lbc_lnk_nc_multi( 'trdken', putrd, 'U', -1.0_wp , pvtrd, 'V', -1.0_wp )      ! lateral boundary conditions
+#else
       CALL lbc_lnk_multi( 'trdken', putrd, 'U', -1.0_wp , pvtrd, 'V', -1.0_wp )      ! lateral boundary conditions
+#endif
       !
       nkstp = kt
Index: /NEMO/branches/2020/dev_r13296_HPC-07_mocavero_mpi3/src/OCE/TRD/trdmxl.F90
===================================================================
--- /NEMO/branches/2020/dev_r13296_HPC-07_mocavero_mpi3/src/OCE/TRD/trdmxl.F90	(revision 13629)
+++ /NEMO/branches/2020/dev_r13296_HPC-07_mocavero_mpi3/src/OCE/TRD/trdmxl.F90	(revision 13630)
@@ -472,7 +472,13 @@
          !-- Lateral boundary conditions
          !         ... temperature ...                    ... salinity ...
+#if defined key_mpi3
+         CALL lbc_lnk_nc_multi( 'trdmxl', ztmltot , 'T', 1.0_wp, zsmltot , 'T', 1.0_wp, &
+                  &          ztmlres , 'T', 1.0_wp, zsmlres , 'T', 1.0_wp, &
+                  &          ztmlatf , 'T', 1.0_wp, zsmlatf , 'T', 1.0_wp )
+#else
          CALL lbc_lnk_multi( 'trdmxl', ztmltot , 'T', 1.0_wp, zsmltot , 'T', 1.0_wp, &
                   &          ztmlres , 'T', 1.0_wp, zsmlres , 'T', 1.0_wp, &
                   &          ztmlatf , 'T', 1.0_wp, zsmlatf , 'T', 1.0_wp )
+#endif
 
 
@@ -523,8 +529,15 @@
          !-- Lateral boundary conditions
          !         ... temperature ...                    ... salinity ...
+#if defined key_mpi3
+         CALL lbc_lnk_nc_multi( 'trdmxl', ztmltot2, 'T', 1.0_wp, zsmltot2, 'T', 1.0_wp, &
+                  &          ztmlres2, 'T', 1.0_wp, zsmlres2, 'T', 1.0_wp )
+         !
+         CALL lbc_lnk_nc_multi( 'trdmxl', ztmltrd2(:,:,:), 'T', 1.0_wp, zsmltrd2(:,:,:), 'T', 1.0_wp ) ! /  in the NetCDF trends file
+#else
          CALL lbc_lnk_multi( 'trdmxl', ztmltot2, 'T', 1.0_wp, zsmltot2, 'T', 1.0_wp, &
                   &          ztmlres2, 'T', 1.0_wp, zsmlres2, 'T', 1.0_wp )
          !
          CALL lbc_lnk_multi( 'trdmxl', ztmltrd2(:,:,:), 'T', 1.0_wp, zsmltrd2(:,:,:), 'T', 1.0_wp ) ! /  in the NetCDF trends file
+#endif
          
          ! III.3 Time evolution array swap
Index: /NEMO/branches/2020/dev_r13296_HPC-07_mocavero_mpi3/src/OCE/TRD/trdvor.F90
===================================================================
--- /NEMO/branches/2020/dev_r13296_HPC-07_mocavero_mpi3/src/OCE/TRD/trdvor.F90	(revision 13629)
+++ /NEMO/branches/2020/dev_r13296_HPC-07_mocavero_mpi3/src/OCE/TRD/trdvor.F90	(revision 13630)
@@ -162,5 +162,9 @@
 
       zudpvor(:,:) = 0._wp                 ;   zvdpvor(:,:) = 0._wp                    ! Initialisation
+#if defined key_mpi3
+      CALL lbc_lnk_nc_multi( 'trdvor', putrdvor, 'U', -1.0_wp , pvtrdvor, 'V', -1.0_wp )      ! lateral boundary condition
+#else
       CALL lbc_lnk_multi( 'trdvor', putrdvor, 'U', -1.0_wp , pvtrdvor, 'V', -1.0_wp )      ! lateral boundary condition
+#endif
       
 
@@ -251,5 +255,9 @@
       zvdpvor(:,:) = 0._wp
       !                            ! lateral boundary condition on input momentum trends
+#if defined key_mpi3
+      CALL lbc_lnk_nc_multi( 'trdvor', putrdvor, 'U', -1.0_wp , pvtrdvor, 'V', -1.0_wp )
+#else
       CALL lbc_lnk_multi( 'trdvor', putrdvor, 'U', -1.0_wp , pvtrdvor, 'V', -1.0_wp )
+#endif
 
       !  =====================================
@@ -400,5 +408,9 @@
 
          ! Boundary conditions
+#if defined key_mpi3
+         CALL lbc_lnk_nc_multi( 'trdvor', vor_avrtot, 'F', 1.0_wp , vor_avrres, 'F', 1.0_wp )
+#else
          CALL lbc_lnk_multi( 'trdvor', vor_avrtot, 'F', 1.0_wp , vor_avrres, 'F', 1.0_wp )
+#endif
 
 
Index: /NEMO/branches/2020/dev_r13296_HPC-07_mocavero_mpi3/src/OCE/USR/usrdef_fmask.F90
===================================================================
--- /NEMO/branches/2020/dev_r13296_HPC-07_mocavero_mpi3/src/OCE/USR/usrdef_fmask.F90	(revision 13629)
+++ /NEMO/branches/2020/dev_r13296_HPC-07_mocavero_mpi3/src/OCE/USR/usrdef_fmask.F90	(revision 13630)
@@ -153,5 +153,9 @@
       ENDIF
       !
+#if defined key_mpi3
+      CALL lbc_lnk_nc_multi( 'usrdef_fmask', pfmsk, 'F', 1._wp )      ! Lateral boundary conditions on fmask
+#else
       CALL lbc_lnk( 'usrdef_fmask', pfmsk, 'F', 1._wp )      ! Lateral boundary conditions on fmask
+#endif
       !
    END SUBROUTINE usr_def_fmask
Index: /NEMO/branches/2020/dev_r13296_HPC-07_mocavero_mpi3/src/OCE/USR/usrdef_sbc.F90
===================================================================
--- /NEMO/branches/2020/dev_r13296_HPC-07_mocavero_mpi3/src/OCE/USR/usrdef_sbc.F90	(revision 13629)
+++ /NEMO/branches/2020/dev_r13296_HPC-07_mocavero_mpi3/src/OCE/USR/usrdef_sbc.F90	(revision 13630)
@@ -181,5 +181,9 @@
          wndm(ji,jj) = SQRT( zmod * zcoef )
       END_2D
+#if defined key_mpi3
+      CALL lbc_lnk_nc_multi( 'usrdef_sbc', taum(:,:), 'T', 1.0_wp , wndm(:,:), 'T', 1.0_wp )
+#else
       CALL lbc_lnk_multi( 'usrdef_sbc', taum(:,:), 'T', 1.0_wp , wndm(:,:), 'T', 1.0_wp )
+#endif
 
       ! ---------------------------------- !
Index: /NEMO/branches/2020/dev_r13296_HPC-07_mocavero_mpi3/src/OCE/ZDF/zdfosm.F90
===================================================================
--- /NEMO/branches/2020/dev_r13296_HPC-07_mocavero_mpi3/src/OCE/ZDF/zdfosm.F90	(revision 13629)
+++ /NEMO/branches/2020/dev_r13296_HPC-07_mocavero_mpi3/src/OCE/ZDF/zdfosm.F90	(revision 13630)
@@ -1223,5 +1223,9 @@
 
        ! Lateral boundary conditions on zvicos (sign unchanged), needed to caclulate viscosities on u and v grids
+#if defined key_mpi3
+       CALL lbc_lnk_nc_multi( 'zdfosm', zviscos(:,:,:), 'W', 1.0_wp )
+#else
        CALL lbc_lnk( 'zdfosm', zviscos(:,:,:), 'W', 1.0_wp )
+#endif
 
        ! GN 25/8: need to change tmask --> wmask
@@ -1232,6 +1236,11 @@
      END_3D
       ! Lateral boundary conditions on ghamu and ghamv, currently on W-grid  (sign unchanged), needed to caclulate gham[uv] on u and v grids
+#if defined key_mpi3
+     CALL lbc_lnk_nc_multi( 'zdfosm', p_avt, 'W', 1.0_wp , p_avm, 'W', 1.0_wp,   &
+      &                  ghamu, 'W', 1.0_wp , ghamv, 'W', 1.0_wp )
+#else
      CALL lbc_lnk_multi( 'zdfosm', p_avt, 'W', 1.0_wp , p_avm, 'W', 1.0_wp,   &
       &                  ghamu, 'W', 1.0_wp , ghamv, 'W', 1.0_wp )
+#endif
        DO_3D( 0, 0, 0, 0, 2, jpkm1 )
             ghamu(ji,jj,jk) = ( ghamu(ji,jj,jk) + ghamu(ji+1,jj,jk) ) &
@@ -1246,6 +1255,11 @@
         ! Lateral boundary conditions on final outputs for gham[ts],  on W-grid  (sign unchanged)
         ! Lateral boundary conditions on final outputs for gham[uv],  on [UV]-grid  (sign unchanged)
+#if defined key_mpi3
+        CALL lbc_lnk_nc_multi( 'zdfosm', ghamt, 'W', 1.0_wp , ghams, 'W', 1.0_wp,   &
+         &                  ghamu, 'U', 1.0_wp , ghamv, 'V', 1.0_wp )
+#else
         CALL lbc_lnk_multi( 'zdfosm', ghamt, 'W', 1.0_wp , ghams, 'W', 1.0_wp,   &
          &                  ghamu, 'U', 1.0_wp , ghamv, 'V', 1.0_wp )
+#endif
 
        IF(ln_dia_osm) THEN
@@ -1287,5 +1301,9 @@
       END IF
       ! Lateral boundary conditions on p_avt  (sign unchanged)
+#if defined key_mpi3
+      CALL lbc_lnk_nc_multi( 'zdfosm', p_avt(:,:,:), 'W', 1.0_wp )
+#else
       CALL lbc_lnk( 'zdfosm', p_avt(:,:,:), 'W', 1.0_wp )
+#endif
       !
    END SUBROUTINE zdf_osm
Index: /NEMO/branches/2020/dev_r13296_HPC-07_mocavero_mpi3/src/OCE/ZDF/zdfphy.F90
===================================================================
--- /NEMO/branches/2020/dev_r13296_HPC-07_mocavero_mpi3/src/OCE/ZDF/zdfphy.F90	(revision 13629)
+++ /NEMO/branches/2020/dev_r13296_HPC-07_mocavero_mpi3/src/OCE/ZDF/zdfphy.F90	(revision 13630)
@@ -313,14 +313,29 @@
       !                                         !* Lateral boundary conditions (sign unchanged)
       IF( l_zdfsh2 ) THEN
+#if defined key_mpi3
+         CALL lbc_lnk_nc_multi( 'zdfphy', avm_k, 'W', 1.0_wp , avt_k, 'W', 1.0_wp,   &
+            &                avm  , 'W', 1.0_wp , avt  , 'W', 1.0_wp , avs , 'W', 1.0_wp )
+#else
          CALL lbc_lnk_multi( 'zdfphy', avm_k, 'W', 1.0_wp , avt_k, 'W', 1.0_wp,   &
             &                avm  , 'W', 1.0_wp , avt  , 'W', 1.0_wp , avs , 'W', 1.0_wp )
+#endif
       ELSE
+#if defined key_mpi3
+         CALL lbc_lnk_nc_multi( 'zdfphy', avm  , 'W', 1.0_wp , avt  , 'W', 1.0_wp , avs , 'W', 1.0_wp )
+#else
          CALL lbc_lnk_multi( 'zdfphy', avm  , 'W', 1.0_wp , avt  , 'W', 1.0_wp , avs , 'W', 1.0_wp )
+#endif
       ENDIF
       !
       IF( l_zdfdrg ) THEN     ! drag  have been updated (non-linear cases)
+#if defined key_mpi3
+         IF( ln_isfcav ) THEN   ;  CALL lbc_lnk_nc_multi( 'zdfphy', rCdU_top, 'T', 1.0_wp , rCdU_bot, 'T', 1.0_wp )   ! top & bot drag
+         ELSE                   ;  CALL lbc_lnk_nc_multi      ( 'zdfphy', rCdU_bot, 'T', 1.0_wp )                       ! bottom drag only
+         ENDIF
+#else
          IF( ln_isfcav ) THEN   ;  CALL lbc_lnk_multi( 'zdfphy', rCdU_top, 'T', 1.0_wp , rCdU_bot, 'T', 1.0_wp )   ! top & bot drag
          ELSE                   ;  CALL lbc_lnk      ( 'zdfphy', rCdU_bot, 'T', 1.0_wp )                       ! bottom drag only
          ENDIF
+#endif
       ENDIF
       !
Index: /NEMO/branches/2020/dev_r13296_HPC-07_mocavero_mpi3/src/OCE/module_example
===================================================================
--- /NEMO/branches/2020/dev_r13296_HPC-07_mocavero_mpi3/src/OCE/module_example	(revision 13629)
+++ /NEMO/branches/2020/dev_r13296_HPC-07_mocavero_mpi3/src/OCE/module_example	(revision 13630)
@@ -127,5 +127,9 @@
       END SELECT
       !
+#if defined key_mpi3
+      CALL lbc_lnk_nc_multi( 'module_example', avm, 'T', 1. )              ! Lateral boundary conditions (unchanged sign)
+#else
       CALL lbc_lnk( 'module_example', avm, 'T', 1. )              ! Lateral boundary conditions (unchanged sign)
+#endif
       !
    END SUBROUTINE exa_mpl
Index: /NEMO/branches/2020/dev_r13296_HPC-07_mocavero_mpi3/src/OCE/stpMLF.F90
===================================================================
--- /NEMO/branches/2020/dev_r13296_HPC-07_mocavero_mpi3/src/OCE/stpMLF.F90	(revision 13629)
+++ /NEMO/branches/2020/dev_r13296_HPC-07_mocavero_mpi3/src/OCE/stpMLF.F90	(revision 13630)
@@ -457,6 +457,11 @@
 #endif
       !                                        ! local domain boundaries  (T-point, unchanged sign)
+#if defined key_mpi3
+      CALL lbc_lnk_nc_multi( 'finalize_sbc', puu(:,:,:,       Kaa), 'U', -1., pvv(:,:,:       ,Kaa), 'V', -1.   &
+                       &                , pts(:,:,:,jp_tem,Kaa), 'T',  1., pts(:,:,:,jp_sal,Kaa), 'T',  1. )     !* local domain boundaries
+#else
       CALL lbc_lnk_multi( 'finalize_sbc', puu(:,:,:,       Kaa), 'U', -1., pvv(:,:,:       ,Kaa), 'V', -1.   &
                        &                , pts(:,:,:,jp_tem,Kaa), 'T',  1., pts(:,:,:,jp_sal,Kaa), 'T',  1. )     !* local domain boundaries
+#endif
       !
       !                                        !* BDY open boundaries
Index: /NEMO/branches/2020/dev_r13296_HPC-07_mocavero_mpi3/src/SWE/asminc.F90
===================================================================
--- /NEMO/branches/2020/dev_r13296_HPC-07_mocavero_mpi3/src/SWE/asminc.F90	(revision 13629)
+++ /NEMO/branches/2020/dev_r13296_HPC-07_mocavero_mpi3/src/SWE/asminc.F90	(revision 13630)
@@ -423,5 +423,9 @@
                      &            / e3t(ji,jj,jk,Kmm)
                END_2D
+#if defined key_mpi3
+               CALL lbc_lnk_nc_multi( 'asminc', zhdiv, 'T', 1. )   ! lateral boundary cond. (no sign change)
+#else
                CALL lbc_lnk( 'asminc', zhdiv, 'T', 1. )   ! lateral boundary cond. (no sign change)
+#endif
                !
                DO_2D( 0, 0, 0, 0 )
Index: /NEMO/branches/2020/dev_r13296_HPC-07_mocavero_mpi3/src/SWE/diawri.F90
===================================================================
--- /NEMO/branches/2020/dev_r13296_HPC-07_mocavero_mpi3/src/SWE/diawri.F90	(revision 13629)
+++ /NEMO/branches/2020/dev_r13296_HPC-07_mocavero_mpi3/src/SWE/diawri.F90	(revision 13630)
@@ -184,5 +184,9 @@
                &                  + e3t(ji+1,jj,1,Kmm) * e1e2t(ji+1,jj)  ) * r1_e1e2u(ji,jj)
          END_2D
+#if defined key_mpi3
+         CALL lbc_lnk_nc_multi( 'diawri', z2d, 'U', 1._wp )
+#else
          CALL lbc_lnk( 'diawri', z2d, 'U', 1._wp )
+#endif
          CALL iom_put( "hu", z2d ) 
       ENDIF
@@ -194,5 +198,9 @@
               &                    + e3t(ji,jj  ,1,Kmm) * e1e2t(ji,jj  )   ) * r1_e1e2v(ji,jj)
          END_2D
+#if defined key_mpi3
+         CALL lbc_lnk_nc_multi( 'diawri', z2d, 'V', 1._wp )
+#else
          CALL lbc_lnk( 'diawri', z2d, 'V', 1._wp )
+#endif
          CALL iom_put( "hv", z2d )    
       ENDIF             
@@ -205,5 +213,9 @@
          END_2D
          z2d(:,:) = z2d(:,:) * ssfmask(:,:)
+#if defined key_mpi3
+         CALL lbc_lnk_nc_multi( 'diawri', z2d, 'F', 1._wp )
+#else
          CALL lbc_lnk( 'diawri', z2d, 'F', 1._wp )
+#endif
          CALL iom_put( "hf", z2d )   
       ENDIF              
@@ -224,5 +236,9 @@
             !
          END_2D
+#if defined key_mpi3
+         CALL lbc_lnk_nc_multi( 'diawri', z2d, 'T', 1. )
+#else
          CALL lbc_lnk( 'diawri', z2d, 'T', 1. )
+#endif
          CALL iom_put( "taubot", z2d )           
       ENDIF
@@ -243,5 +259,9 @@
          END_2D
          !
+#if defined key_mpi3
+         CALL lbc_lnk_nc_multi( 'diawri', z2d, 'T', 1. )
+#else
          CALL lbc_lnk( 'diawri', z2d, 'T', 1. )
+#endif
          IF ( iom_use("sKE" ) )  CALL iom_put( "sKE" , z2d )   
                            
@@ -259,5 +279,9 @@
          END_2D
          !
+#if defined key_mpi3
+         CALL lbc_lnk_nc_multi( 'diawri', z2d, 'F', 1. )
+#else
          CALL lbc_lnk( 'diawri', z2d, 'F', 1. )
+#endif
          CALL iom_put( "sKEf", z2d )                     
       ENDIF
@@ -277,5 +301,9 @@
             &              - e1u(ji  ,jj+1) * uu(ji  ,jj+1,1,Kmm) + e1u(ji,jj) * uu(ji,jj,1,Kmm)  ) * r1_e1e2f(ji,jj)
          END_2D
+#if defined key_mpi3
+         CALL lbc_lnk_nc_multi( 'diawri', z2d, 'F', 1. )
+#else
          CALL lbc_lnk( 'diawri', z2d, 'F', 1. )
+#endif
          CALL iom_put( "relvor", z2d )                  ! relative vorticity ( zeta ) 
          !
@@ -290,5 +318,9 @@
             z2d(ji,jj) = ze3 * z2d(ji,jj) 
          END_2D
+#if defined key_mpi3
+         CALL lbc_lnk_nc_multi( 'diawri', z2d, 'F', 1. )
+#else
          CALL lbc_lnk( 'diawri', z2d, 'F', 1. )
+#endif
          CALL iom_put( "relpotvor", z2d )                  ! relative potential vorticity (zeta/h)
          !
@@ -301,5 +333,9 @@
             z2d(ji,jj) = ze3 * ff_f(ji,jj) + z2d(ji,jj) 
          END_2D
+#if defined key_mpi3
+         CALL lbc_lnk_nc_multi( 'diawri', z2d, 'F', 1. )
+#else
          CALL lbc_lnk( 'diawri', z2d, 'F', 1. )
+#endif
          CALL iom_put( "abspotvor", z2d )                  ! absolute potential vorticity ( q )
          !
@@ -307,5 +343,9 @@
             z2d(ji,jj) = 0.5_wp * z2d(ji,jj)  * z2d(ji,jj) 
          END_2D
+#if defined key_mpi3
+         CALL lbc_lnk_nc_multi( 'diawri', z2d, 'F', 1. )
+#else
          CALL lbc_lnk( 'diawri', z2d, 'F', 1. )
+#endif
          CALL iom_put( "Ens", z2d )                        ! potential enstrophy ( 1/2*q2 )
          !
Index: /NEMO/branches/2020/dev_r13296_HPC-07_mocavero_mpi3/src/SWE/dommsk.F90
===================================================================
--- /NEMO/branches/2020/dev_r13296_HPC-07_mocavero_mpi3/src/SWE/dommsk.F90	(revision 13629)
+++ /NEMO/branches/2020/dev_r13296_HPC-07_mocavero_mpi3/src/SWE/dommsk.F90	(revision 13630)
@@ -141,5 +141,9 @@
       ! the following call is mandatory
       ! it masks boundaries (bathy=0) where needed depending on the configuration (closed, periodic...)  
+#if defined key_mpi3
+      CALL lbc_lnk_nc_multi( 'dommsk', tmask  , 'T', 1._wp )      ! Lateral boundary conditions
+#else
       CALL lbc_lnk( 'dommsk', tmask  , 'T', 1._wp )      ! Lateral boundary conditions
+#endif
 
      ! Mask corrections for bdy (read in mppini2)
@@ -173,5 +177,9 @@
          END DO
       END DO
+#if defined key_mpi3
+      CALL lbc_lnk_nc_multi( 'dommsk', umask, 'U', 1., vmask, 'V', 1., fmask, 'F', 1. )      ! Lateral boundary conditions
+#else
       CALL lbc_lnk_multi( 'dommsk', umask, 'U', 1., vmask, 'V', 1., fmask, 'F', 1. )      ! Lateral boundary conditions
+#endif
  
       ! Ocean/land mask at wu-, wv- and w points    (computed from tmask)
@@ -198,5 +206,9 @@
             &                   tmask(ji,jj  ,1), tmask(ji+1,jj  ,1)   )
       END_2D
+#if defined key_mpi3
+      CALL lbc_lnk_nc_multi( 'dommsk', ssfmask, 'F', 1._wp )   
+#else
       CALL lbc_lnk( 'dommsk', ssfmask, 'F', 1._wp )   
+#endif
 
 !!an
@@ -279,5 +291,9 @@
          DEALLOCATE( zwf )
          !
+#if defined key_mpi3
+         CALL lbc_lnk_nc_multi( 'dommsk', fmask, 'F', 1._wp )      ! Lateral boundary conditions on fmask
+#else
          CALL lbc_lnk( 'dommsk', fmask, 'F', 1._wp )      ! Lateral boundary conditions on fmask
+#endif
          !
          ! CAUTION : The fmask may be further modified in dyn_vor_init ( dynvor.F90 ) depending on ln_vorlat
Index: /NEMO/branches/2020/dev_r13296_HPC-07_mocavero_mpi3/src/SWE/domvvl.F90
===================================================================
--- /NEMO/branches/2020/dev_r13296_HPC-07_mocavero_mpi3/src/SWE/domvvl.F90	(revision 13629)
+++ /NEMO/branches/2020/dev_r13296_HPC-07_mocavero_mpi3/src/SWE/domvvl.F90	(revision 13630)
@@ -520,9 +520,17 @@
          !                       ! d - thickness diffusion transport: boundary conditions
          !                             (stored for tracer advction and continuity equation)
+#if defined key_mpi3
+         CALL lbc_lnk_nc_multi( 'domvvl', un_td , 'U' , -1._wp, vn_td , 'V' , -1._wp)
+#else
          CALL lbc_lnk_multi( 'domvvl', un_td , 'U' , -1._wp, vn_td , 'V' , -1._wp)
+#endif
 
          ! 4 - Time stepping of baroclinic scale factors
          ! ---------------------------------------------
+#if defined key_mpi3
+         CALL lbc_lnk_nc_multi( 'domvvl', tilde_e3t_a(:,:,:), 'T', 1._wp )
+#else
          CALL lbc_lnk( 'domvvl', tilde_e3t_a(:,:,:), 'T', 1._wp )
+#endif
          tilde_e3t_a(:,:,:) = tilde_e3t_b(:,:,:) + rDt * tmask(:,:,:) * tilde_e3t_a(:,:,:)
 
@@ -1016,5 +1024,9 @@
                &                   + e1e2t(ji+1,jj) * pssh(ji+1,jj)  ) * r1_hu_0(ji,jj) * r1_e1e2u(ji,jj)
          END_2D
+#if defined key_mpi3
+         CALL lbc_lnk_nc_multi( 'domvvl', zc3(:,:), 'U', 1._wp )
+#else
          CALL lbc_lnk( 'domvvl', zc3(:,:), 'U', 1._wp )
+#endif
          !
          DO jk = 1, jpkm1
@@ -1027,5 +1039,9 @@
                &                   + e1e2t(ji,jj+1) * pssh(ji,jj+1)  ) * r1_hv_0(ji,jj) * r1_e1e2v(ji,jj)
          END_2D
+#if defined key_mpi3
+         CALL lbc_lnk_nc_multi( 'domvvl', zc3(:,:), 'V', 1._wp )
+#else
          CALL lbc_lnk( 'domvvl', zc3(:,:), 'V', 1._wp )
+#endif
          !
          DO jk = 1, jpkm1
@@ -1040,5 +1056,9 @@
                &                    + e1e2t(ji+1,jj+1) * pssh(ji+1,jj+1)  ) * r1_hf_0(ji,jj) * r1_e1e2f(ji,jj)
          END_2D
+#if defined key_mpi3
+         CALL lbc_lnk_nc_multi( 'domvvl', zc3(:,:), 'F', 1._wp )
+#else
          CALL lbc_lnk( 'domvvl', zc3(:,:), 'F', 1._wp )
+#endif
          !
          DO jk = 1, jpkm1                    ! Horizontal interpolation of e3f from ssh
@@ -1059,5 +1079,9 @@
                &                   + e1e2t(ji+1,jj) * pssh(ji+1,jj)  ) * r1_hu_0(ji,jj) * r1_e1e2u(ji,jj)
          END_2D
+#if defined key_mpi3
+         CALL lbc_lnk_nc_multi( 'domvvl', zc3(:,:), 'U', 1._wp )
+#else
          CALL lbc_lnk( 'domvvl', zc3(:,:), 'U', 1._wp )
+#endif
          !
          DO jk = 1, jpk
@@ -1070,5 +1094,9 @@
                &                   + e1e2t(ji,jj+1) * pssh(ji,jj+1)  ) * r1_hv_0(ji,jj) * r1_e1e2v(ji,jj)
          END_2D
+#if defined key_mpi3
+         CALL lbc_lnk_nc_multi( 'domvvl', zc3(:,:), 'V', 1._wp )
+#else
          CALL lbc_lnk( 'domvvl', zc3(:,:), 'V', 1._wp )
+#endif
           !
          DO jk = 1, jpk
Index: /NEMO/branches/2020/dev_r13296_HPC-07_mocavero_mpi3/src/SWE/dynatf.F90
===================================================================
--- /NEMO/branches/2020/dev_r13296_HPC-07_mocavero_mpi3/src/SWE/dynatf.F90	(revision 13629)
+++ /NEMO/branches/2020/dev_r13296_HPC-07_mocavero_mpi3/src/SWE/dynatf.F90	(revision 13630)
@@ -165,5 +165,9 @@
 # endif
       !
+#if defined key_mpi3
+      CALL lbc_lnk_nc_multi( 'dynatf', puu(:,:,:,Kaa), 'U', -1., pvv(:,:,:,Kaa), 'V', -1. )     !* local domain boundaries
+#else
       CALL lbc_lnk_multi( 'dynatf', puu(:,:,:,Kaa), 'U', -1., pvv(:,:,:,Kaa), 'V', -1. )     !* local domain boundaries
+#endif
       !
       !                                !* BDY open boundaries
Index: /NEMO/branches/2020/dev_r13296_HPC-07_mocavero_mpi3/src/SWE/dynkeg.F90
===================================================================
--- /NEMO/branches/2020/dev_r13296_HPC-07_mocavero_mpi3/src/SWE/dynkeg.F90	(revision 13629)
+++ /NEMO/branches/2020/dev_r13296_HPC-07_mocavero_mpi3/src/SWE/dynkeg.F90	(revision 13630)
@@ -133,5 +133,9 @@
             zhke(ji,jj,jk) = r1_48 * ( zv + zu )
          END_3D
+#if defined key_mpi3
+         CALL lbc_lnk_nc_multi( 'dynkeg', zhke, 'T', 1. )
+#else
          CALL lbc_lnk( 'dynkeg', zhke, 'T', 1. )
+#endif
          !
       END SELECT 
Index: /NEMO/branches/2020/dev_r13296_HPC-07_mocavero_mpi3/src/SWE/dynldf_lap_blp.F90
===================================================================
--- /NEMO/branches/2020/dev_r13296_HPC-07_mocavero_mpi3/src/SWE/dynldf_lap_blp.F90	(revision 13629)
+++ /NEMO/branches/2020/dev_r13296_HPC-07_mocavero_mpi3/src/SWE/dynldf_lap_blp.F90	(revision 13630)
@@ -232,5 +232,9 @@
       CALL dyn_ldf_lap( kt, Kbb, Kmm, pu, pv, zulap, zvlap, 1 )   ! rotated laplacian applied to pt (output in zlap,Kbb)
       !
+#if defined key_mpi3
+      CALL lbc_lnk_nc_multi( 'dynldf_lap_blp', zulap, 'U', -1., zvlap, 'V', -1. )             ! Lateral boundary conditions
+#else
       CALL lbc_lnk_multi( 'dynldf_lap_blp', zulap, 'U', -1., zvlap, 'V', -1. )             ! Lateral boundary conditions
+#endif
       !
       CALL dyn_ldf_lap( kt, Kbb, Kmm, zulap, zvlap, pu_rhs, pv_rhs, 2 )   ! rotated laplacian applied to zlap (output in pt(:,:,:,:,Krhs))
Index: /NEMO/branches/2020/dev_r13296_HPC-07_mocavero_mpi3/src/SWE/dynvor.F90
===================================================================
--- /NEMO/branches/2020/dev_r13296_HPC-07_mocavero_mpi3/src/SWE/dynvor.F90	(revision 13629)
+++ /NEMO/branches/2020/dev_r13296_HPC-07_mocavero_mpi3/src/SWE/dynvor.F90	(revision 13630)
@@ -242,5 +242,9 @@
             ENDIF
          END DO
+#if defined key_mpi3
+         CALL lbc_lnk_nc_multi( 'dynvor', zwz, 'F', 1. )
+#else
          CALL lbc_lnk( 'dynvor', zwz, 'F', 1. )
+#endif
          !
       END SELECT
@@ -599,5 +603,9 @@
       END DO                                           !   End of slab
          !
+#if defined key_mpi3
+      CALL lbc_lnk_nc_multi( 'dynvor', zwz, 'F', 1. )
+#else
       CALL lbc_lnk( 'dynvor', zwz, 'F', 1. )
+#endif
 
       DO jk = 1, jpkm1                                 ! Horizontal slab
@@ -720,5 +728,9 @@
       END DO
       !
+#if defined key_mpi3
+      CALL lbc_lnk_nc_multi( 'dynvor', zwz, 'F', 1. )
+#else
       CALL lbc_lnk( 'dynvor', zwz, 'F', 1. )
+#endif
       !
       DO jk = 1, jpkm1                                 ! Horizontal slab
@@ -812,5 +824,9 @@
          END_3D
          !
+#if defined key_mpi3
+         CALL lbc_lnk_nc_multi( 'dynvor', fmask, 'F', 1._wp )      ! Lateral boundary conditions on fmask
+#else
          CALL lbc_lnk( 'dynvor', fmask, 'F', 1._wp )      ! Lateral boundary conditions on fmask
+#endif
          !
       ENDIF
@@ -850,5 +866,9 @@
                dj_e1v_2(ji,jj) = ( e1v(ji,jj) - e1v(ji  ,jj-1) ) * 0.5_wp
             END_2D
+#if defined key_mpi3
+            CALL lbc_lnk_nc_multi( 'dynvor', di_e2u_2, 'T', -1. , dj_e1v_2, 'T', -1. )   ! Lateral boundary conditions
+#else
             CALL lbc_lnk_multi( 'dynvor', di_e2u_2, 'T', -1. , dj_e1v_2, 'T', -1. )   ! Lateral boundary conditions
+#endif
             !
          CASE DEFAULT                        !* F-point metric term :   pre-compute di(e2u)/(2*e1e2f) and dj(e1v)/(2*e1e2f)
@@ -858,5 +878,9 @@
                dj_e1u_2e1e2f(ji,jj) = ( e1u(ji  ,jj+1) - e1u(ji,jj) )  * 0.5 * r1_e1e2f(ji,jj)
             END_2D
+#if defined key_mpi3
+            CALL lbc_lnk_nc_multi( 'dynvor', di_e2v_2e1e2f, 'F', -1. , dj_e1u_2e1e2f, 'F', -1. )   ! Lateral boundary conditions
+#else
             CALL lbc_lnk_multi( 'dynvor', di_e2v_2e1e2f, 'F', -1. , dj_e1u_2e1e2f, 'F', -1. )   ! Lateral boundary conditions
+#endif
          END SELECT
          !
Index: /NEMO/branches/2020/dev_r13296_HPC-07_mocavero_mpi3/src/SWE/ldfdyn.F90
===================================================================
--- /NEMO/branches/2020/dev_r13296_HPC-07_mocavero_mpi3/src/SWE/ldfdyn.F90	(revision 13629)
+++ /NEMO/branches/2020/dev_r13296_HPC-07_mocavero_mpi3/src/SWE/ldfdyn.F90	(revision 13630)
@@ -426,5 +426,9 @@
          ENDIF
          !
+#if defined key_mpi3
+         CALL lbc_lnk_nc_multi( 'ldfdyn', ahmt, 'T', 1.,  ahmf, 'F', 1. )
+#else
          CALL lbc_lnk_multi( 'ldfdyn', ahmt, 'T', 1.,  ahmf, 'F', 1. )
+#endif
          !
          !
@@ -458,5 +462,9 @@
             END DO
             !
+#if defined key_mpi3
+            CALL lbc_lnk_nc_multi( 'ldfdyn', dtensq, 'T', 1. )  ! lbc_lnk on dshesq not needed
+#else
             CALL lbc_lnk_multi( 'ldfdyn', dtensq, 'T', 1. )  ! lbc_lnk on dshesq not needed
+#endif
             !
             DO jk = 1, jpkm1
@@ -509,5 +517,9 @@
          ENDIF
          !
+#if defined key_mpi3
+         CALL lbc_lnk_nc_multi( 'ldfdyn', ahmt, 'T', 1. , ahmf, 'F', 1. )
+#else
          CALL lbc_lnk_multi( 'ldfdyn', ahmt, 'T', 1. , ahmf, 'F', 1. )
+#endif
          !
       END SELECT
Index: /NEMO/branches/2020/dev_r13296_HPC-07_mocavero_mpi3/src/SWE/sbcice_cice.F90
===================================================================
--- /NEMO/branches/2020/dev_r13296_HPC-07_mocavero_mpi3/src/SWE/sbcice_cice.F90	(revision 13629)
+++ /NEMO/branches/2020/dev_r13296_HPC-07_mocavero_mpi3/src/SWE/sbcice_cice.F90	(revision 13630)
@@ -224,5 +224,9 @@
       END_2D
 
+#if defined key_mpi3
+      CALL lbc_lnk_nc_multi( 'sbcice_cice', fr_iu , 'U', 1.,  fr_iv , 'V', 1. )
+#else
       CALL lbc_lnk_multi( 'sbcice_cice', fr_iu , 'U', 1.,  fr_iv , 'V', 1. )
+#endif
 
       ! set the snow+ice mass
@@ -510,5 +514,9 @@
          ss_iou(ji,jj) = 0.5 * ( ztmp1(ji,jj-1) + ztmp1(ji,jj) ) * umask(ji,jj,1)
       END_2D
+#if defined key_mpi3
+      CALL lbc_lnk_nc_multi( 'sbcice_cice', ss_iou , 'U', -1. )
+#else
       CALL lbc_lnk( 'sbcice_cice', ss_iou , 'U', -1. )
+#endif
 
 ! y comp of ocean-ice stress 
@@ -520,5 +528,9 @@
          ss_iov(ji,jj) = 0.5 * ( ztmp1(ji-1,jj) + ztmp1(ji,jj) ) * vmask(ji,jj,1)
       END_2D
+#if defined key_mpi3
+      CALL lbc_lnk_nc_multi( 'sbcice_cice', ss_iov , 'V', -1. )
+#else
       CALL lbc_lnk( 'sbcice_cice', ss_iov , 'V', -1. )
+#endif
 
 ! x and y comps of surface stress
@@ -573,5 +585,9 @@
       fmmflx(:,:) = ztmp1(:,:) !!Joakim edit
       
+#if defined key_mpi3
+      CALL lbc_lnk_nc_multi( 'sbcice_cice', emp , 'T', 1., sfx , 'T', 1. )
+#else
       CALL lbc_lnk_multi( 'sbcice_cice', emp , 'T', 1., sfx , 'T', 1. )
+#endif
 
 ! Solar penetrative radiation and non solar surface heat flux
@@ -599,5 +615,9 @@
 #endif
       qsr(:,:)=qsr(:,:)+ztmp1(:,:)
+#if defined key_mpi3
+      CALL lbc_lnk_nc_multi( 'sbcice_cice', qsr , 'T', 1. )
+#else
       CALL lbc_lnk( 'sbcice_cice', qsr , 'T', 1. )
+#endif
 
       DO_2D( 1, 1, 1, 1 )
@@ -612,5 +632,9 @@
       qns(:,:)=qns(:,:)+nfrzmlt(:,:)+ztmp1(:,:)
 
+#if defined key_mpi3
+      CALL lbc_lnk_nc_multi( 'sbcice_cice', qns , 'T', 1. )
+#else
       CALL lbc_lnk( 'sbcice_cice', qns , 'T', 1. )
+#endif
 
 ! Prepare for the following CICE time-step
@@ -630,5 +654,9 @@
       END_2D
 
+#if defined key_mpi3
+      CALL lbc_lnk_nc_multi( 'sbcice_cice', fr_iu , 'U', 1., fr_iv , 'V', 1. )
+#else
       CALL lbc_lnk_multi( 'sbcice_cice', fr_iu , 'U', 1., fr_iv , 'V', 1. )
+#endif
 
       ! set the snow+ice mass
@@ -852,5 +880,9 @@
 !     A. Ensure all haloes are filled in NEMO field (pn)
 
+#if defined key_mpi3
+      CALL lbc_lnk_nc_multi( 'sbcice_cice', pn , cd_type, psgn )
+#else
       CALL lbc_lnk( 'sbcice_cice', pn , cd_type, psgn )
+#endif
 
 #if defined key_nemocice_decomp
@@ -1027,5 +1059,9 @@
 !     D. Ensure all haloes are filled in pn
 
+#if defined key_mpi3
+      CALL lbc_lnk_nc_multi( 'sbcice_cice', pn , cd_type, psgn )
+#else
       CALL lbc_lnk( 'sbcice_cice', pn , cd_type, psgn )
+#endif
 
    END SUBROUTINE cice2nemo
Index: /NEMO/branches/2020/dev_r13296_HPC-07_mocavero_mpi3/src/SWE/step.F90
===================================================================
--- /NEMO/branches/2020/dev_r13296_HPC-07_mocavero_mpi3/src/SWE/step.F90	(revision 13629)
+++ /NEMO/branches/2020/dev_r13296_HPC-07_mocavero_mpi3/src/SWE/step.F90	(revision 13630)
@@ -237,6 +237,11 @@
 
 
+#if defined key_mpi3
+      CALL lbc_lnk_nc_multi( 'stp', uu(:,:,:,Nnn), 'U', -1., vv(:,:,:,Nnn), 'V', -1.,   &   !* local domain boundaries
+         &                       uu(:,:,:,Naa), 'U', -1., vv(:,:,:,Naa), 'V', -1.    )     
+#else
       CALL lbc_lnk_multi( 'stp', uu(:,:,:,Nnn), 'U', -1., vv(:,:,:,Nnn), 'V', -1.,   &   !* local domain boundaries
          &                       uu(:,:,:,Naa), 'U', -1., vv(:,:,:,Naa), 'V', -1.    )     
+#endif
 
 !!an         
Index: /NEMO/branches/2020/dev_r13296_HPC-07_mocavero_mpi3/src/SWE/stepLF.F90
===================================================================
--- /NEMO/branches/2020/dev_r13296_HPC-07_mocavero_mpi3/src/SWE/stepLF.F90	(revision 13629)
+++ /NEMO/branches/2020/dev_r13296_HPC-07_mocavero_mpi3/src/SWE/stepLF.F90	(revision 13630)
@@ -248,6 +248,11 @@
 
 
+#if defined key_mpi3
+      CALL lbc_lnk_nc_multi( 'stp', uu(:,:,:,Nnn), 'U', -1., vv(:,:,:,Nnn), 'V', -1.,   &   !* local domain boundaries
+         &                       uu(:,:,:,Naa), 'U', -1., vv(:,:,:,Naa), 'V', -1.    )     
+#else
       CALL lbc_lnk_multi( 'stp', uu(:,:,:,Nnn), 'U', -1., vv(:,:,:,Nnn), 'V', -1.,   &   !* local domain boundaries
          &                       uu(:,:,:,Naa), 'U', -1., vv(:,:,:,Naa), 'V', -1.    )     
+#endif
 
 !!an         
Index: /NEMO/branches/2020/dev_r13296_HPC-07_mocavero_mpi3/src/SWE/stpRK3.F90
===================================================================
--- /NEMO/branches/2020/dev_r13296_HPC-07_mocavero_mpi3/src/SWE/stpRK3.F90	(revision 13629)
+++ /NEMO/branches/2020/dev_r13296_HPC-07_mocavero_mpi3/src/SWE/stpRK3.F90	(revision 13630)
@@ -308,6 +308,11 @@
 
 
+#if defined key_mpi3
+      CALL lbc_lnk_nc_multi( 'stp_RK3', uu(:,:,:,Nnn), 'U', -1., vv(:,:,:,Nnn), 'V', -1.,   &   !* local domain boundaries
+         &                       uu(:,:,:,Naa), 'U', -1., vv(:,:,:,Naa), 'V', -1.    )     
+#else
       CALL lbc_lnk_multi( 'stp_RK3', uu(:,:,:,Nnn), 'U', -1., vv(:,:,:,Nnn), 'V', -1.,   &   !* local domain boundaries
          &                       uu(:,:,:,Naa), 'U', -1., vv(:,:,:,Naa), 'V', -1.    )     
+#endif
 
 !!an         
Index: /NEMO/branches/2020/dev_r13296_HPC-07_mocavero_mpi3/src/TOP/PISCES/P2Z/p2zbio.F90
===================================================================
--- /NEMO/branches/2020/dev_r13296_HPC-07_mocavero_mpi3/src/TOP/PISCES/P2Z/p2zbio.F90	(revision 13629)
+++ /NEMO/branches/2020/dev_r13296_HPC-07_mocavero_mpi3/src/TOP/PISCES/P2Z/p2zbio.F90	(revision 13630)
@@ -339,6 +339,11 @@
       !
       IF( lk_iomput ) THEN
+#if defined key_mpi3
+         CALL lbc_lnk_nc_multi( 'p2zbio', zw2d(:,:,:),'T', 1.0_wp )
+         CALL lbc_lnk_nc_multi( 'p2zbio', zw3d(:,:,:,1),'T', 1.0_wp, zw3d(:,:,:,2),'T', 1.0_wp, zw3d(:,:,:,3),'T', 1.0_wp )
+#else
          CALL lbc_lnk( 'p2zbio', zw2d(:,:,:),'T', 1.0_wp )
          CALL lbc_lnk_multi( 'p2zbio', zw3d(:,:,:,1),'T', 1.0_wp, zw3d(:,:,:,2),'T', 1.0_wp, zw3d(:,:,:,3),'T', 1.0_wp )
+#endif
          ! Save diagnostics
          CALL iom_put( "TNO3PHY", zw2d(:,:,1) )
Index: /NEMO/branches/2020/dev_r13296_HPC-07_mocavero_mpi3/src/TOP/PISCES/P2Z/p2zexp.F90
===================================================================
--- /NEMO/branches/2020/dev_r13296_HPC-07_mocavero_mpi3/src/TOP/PISCES/P2Z/p2zexp.F90	(revision 13629)
+++ /NEMO/branches/2020/dev_r13296_HPC-07_mocavero_mpi3/src/TOP/PISCES/P2Z/p2zexp.F90	(revision 13630)
@@ -107,5 +107,9 @@
       END_2D
 
+#if defined key_mpi3
+      CALL lbc_lnk_nc_multi( 'p2zexp', sedpocn, 'T', 1.0_wp )
+#else
       CALL lbc_lnk( 'p2zexp', sedpocn, 'T', 1.0_wp )
+#endif
  
       ! Oa & Ek: diagnostics depending on jpdia2d !          left as example
@@ -210,5 +214,9 @@
          END IF
       END_2D
+#if defined key_mpi3
+      CALL lbc_lnk_nc_multi( 'p2zexp', cmask , 'T', 1.0_wp )      ! lateral boundary conditions on cmask   (sign unchanged)
+#else
       CALL lbc_lnk( 'p2zexp', cmask , 'T', 1.0_wp )      ! lateral boundary conditions on cmask   (sign unchanged)
+#endif
       areacot = glob_sum( 'p2zexp', e1e2t(:,:) * cmask(:,:) )
       !
Index: /NEMO/branches/2020/dev_r13296_HPC-07_mocavero_mpi3/src/TOP/PISCES/P4Z/p4zbc.F90
===================================================================
--- /NEMO/branches/2020/dev_r13296_HPC-07_mocavero_mpi3/src/TOP/PISCES/P4Z/p4zbc.F90	(revision 13629)
+++ /NEMO/branches/2020/dev_r13296_HPC-07_mocavero_mpi3/src/TOP/PISCES/P4Z/p4zbc.F90	(revision 13630)
@@ -311,5 +311,9 @@
          END_3D
          !
+#if defined key_mpi3
+         CALL lbc_lnk_nc_multi( 'p4zbc', zcmask , 'T', 1.0_wp )      ! lateral boundary conditions on cmask   (sign unchanged)
+#else
          CALL lbc_lnk( 'p4zbc', zcmask , 'T', 1.0_wp )      ! lateral boundary conditions on cmask   (sign unchanged)
+#endif
          !
          DO_3D( 1, 1, 1, 1, 1, jpk )
Index: /NEMO/branches/2020/dev_r13296_HPC-07_mocavero_mpi3/src/TOP/TRP/trcatf.F90
===================================================================
--- /NEMO/branches/2020/dev_r13296_HPC-07_mocavero_mpi3/src/TOP/TRP/trcatf.F90	(revision 13629)
+++ /NEMO/branches/2020/dev_r13296_HPC-07_mocavero_mpi3/src/TOP/TRP/trcatf.F90	(revision 13630)
@@ -102,5 +102,9 @@
 #endif
       ! Update after tracer on domain lateral boundaries
+#if defined key_mpi3
+      CALL lbc_lnk_nc_multi( 'trcatf', ptr(:,:,:,:,Kaa), 'T', 1. )   
+#else
       CALL lbc_lnk( 'trcatf', ptr(:,:,:,:,Kaa), 'T', 1. )   
+#endif
 
       IF( ln_bdy )  CALL trc_bdy( kt, Kbb, Kmm, Kaa )
@@ -168,5 +172,9 @@
          ENDIF
          !
+#if defined key_mpi3
+         CALL lbc_lnk_nc_multi( 'trcatf', ptr(:,:,:,:,Kmm), 'T', 1._wp, ptr(:,:,:,:,Kaa), 'T', 1._wp, ptr(:,:,:,:,Kaa), 'T', 1._wp )
+#else
          CALL lbc_lnk_multi( 'trcatf', ptr(:,:,:,:,Kmm), 'T', 1._wp, ptr(:,:,:,:,Kaa), 'T', 1._wp, ptr(:,:,:,:,Kaa), 'T', 1._wp )
+#endif
       ENDIF
       !
Index: /NEMO/branches/2020/dev_r13296_HPC-07_mocavero_mpi3/src/TOP/TRP/trcsbc.F90
===================================================================
--- /NEMO/branches/2020/dev_r13296_HPC-07_mocavero_mpi3/src/TOP/TRP/trcsbc.F90	(revision 13629)
+++ /NEMO/branches/2020/dev_r13296_HPC-07_mocavero_mpi3/src/TOP/TRP/trcsbc.F90	(revision 13630)
@@ -155,5 +155,9 @@
       END SELECT
       !
+#if defined key_mpi3
+      CALL lbc_lnk_nc_multi( 'trcsbc', sbc_trc(:,:,:), 'T', 1.0_wp )
+#else
       CALL lbc_lnk( 'trcsbc', sbc_trc(:,:,:), 'T', 1.0_wp )
+#endif
       !                                       Concentration dilution effect on tracers due to evaporation & precipitation 
       DO jn = 1, jptra
Index: /NEMO/branches/2020/dev_r13296_HPC-07_mocavero_mpi3/src/TOP/TRP/trdmxl_trc.F90
===================================================================
--- /NEMO/branches/2020/dev_r13296_HPC-07_mocavero_mpi3/src/TOP/TRP/trdmxl_trc.F90	(revision 13629)
+++ /NEMO/branches/2020/dev_r13296_HPC-07_mocavero_mpi3/src/TOP/TRP/trdmxl_trc.F90	(revision 13630)
@@ -284,5 +284,9 @@
             IF( ln_trdtrc(jn) ) THEN
                DO jl = 1, jpltrd_trc
+#if defined key_mpi3
+                  CALL lbc_lnk_nc_multi( 'trdmxl_trc', tmltrd_trc(:,:,jl,jn), 'T', 1. )        ! lateral boundary conditions
+#else
                   CALL lbc_lnk( 'trdmxl_trc', tmltrd_trc(:,:,jl,jn), 'T', 1. )        ! lateral boundary conditions
+#endif
                END DO
             ENDIF
@@ -419,6 +423,11 @@
          !-- Lateral boundary conditions
                IF ( cn_cfg .NE. 'gyre' ) THEN
+#if defined key_mpi3
+                  CALL lbc_lnk_nc_multi( 'trdmxl_trc', ztmltot(:,:,jn) , 'T', 1. , ztmlres(:,:,jn) , 'T', 1., &
+                     &                ztmlatf(:,:,jn) , 'T', 1. , ztmlrad(:,:,jn) , 'T', 1. )
+#else
                   CALL lbc_lnk_multi( 'trdmxl_trc', ztmltot(:,:,jn) , 'T', 1. , ztmlres(:,:,jn) , 'T', 1., &
                      &                ztmlatf(:,:,jn) , 'T', 1. , ztmlrad(:,:,jn) , 'T', 1. )
+#endif
                ENDIF
 
@@ -470,7 +479,15 @@
          !-- Lateral boundary conditions 
                IF ( cn_cfg .NE. 'gyre' ) THEN            ! other than GYRE configuration    
+#if defined key_mpi3
+                  CALL lbc_lnk_nc_multi( 'trdmxl_trc', ztmltot2(:,:,jn), 'T', 1., ztmlres2(:,:,jn), 'T', 1. )
+#else
                   CALL lbc_lnk_multi( 'trdmxl_trc', ztmltot2(:,:,jn), 'T', 1., ztmlres2(:,:,jn), 'T', 1. )
+#endif
                   DO jl = 1, jpltrd_trc
+#if defined key_mpi3
+                     CALL lbc_lnk_nc_multi( 'trdmxl_trc', ztmltrd2(:,:,jl,jn), 'T', 1. )       ! will be output in the NetCDF trends file
+#else
                      CALL lbc_lnk( 'trdmxl_trc', ztmltrd2(:,:,jl,jn), 'T', 1. )       ! will be output in the NetCDF trends file
+#endif
                   END DO
                ENDIF
Index: /NEMO/branches/2020/dev_r13296_HPC-07_mocavero_mpi3/src/TOP/trcbdy.F90
===================================================================
--- /NEMO/branches/2020/dev_r13296_HPC-07_mocavero_mpi3/src/TOP/trcbdy.F90	(revision 13629)
+++ /NEMO/branches/2020/dev_r13296_HPC-07_mocavero_mpi3/src/TOP/trcbdy.F90	(revision 13630)
@@ -103,5 +103,9 @@
          END DO
          IF( ANY(llsend1) .OR. ANY(llrecv1) ) THEN   ! if need to send/recv in at least one direction
+#if defined key_mpi3
+            CALL lbc_lnk_nc_multi( 'trcbdy', tr(:,:,:,:,Krhs), 'T',  1.0_wp, kfillmode=jpfillnothing ,lsend=llsend1, lrecv=llrecv1 )
+#else
             CALL lbc_lnk( 'trcbdy', tr(:,:,:,:,Krhs), 'T',  1.0_wp, kfillmode=jpfillnothing ,lsend=llsend1, lrecv=llrecv1 )
+#endif
          ENDIF
          !
