Index: codes/icosagcm/branches/SATURN_DYNAMICO/ICOSAGCM/arch/arch-X64_ADA.env
===================================================================
--- codes/icosagcm/branches/SATURN_DYNAMICO/ICOSAGCM/arch/arch-X64_ADA.env	(revision 263)
+++ codes/icosagcm/branches/SATURN_DYNAMICO/ICOSAGCM/arch/arch-X64_ADA.env	(revision 264)
@@ -3,4 +3,4 @@
 module unload hdf5
 
-module load netcdf
-module load hdf5
+module load netcdf/mpi/4.1.3
+module load hdf5/mpi/1.8.9
Index: codes/icosagcm/branches/SATURN_DYNAMICO/ICOSAGCM/arch/arch-X64_ADA.fcm
===================================================================
--- codes/icosagcm/branches/SATURN_DYNAMICO/ICOSAGCM/arch/arch-X64_ADA.fcm	(revision 263)
+++ codes/icosagcm/branches/SATURN_DYNAMICO/ICOSAGCM/arch/arch-X64_ADA.fcm	(revision 264)
@@ -12,5 +12,5 @@
 %MPI_FFLAGS
 %OMP_FFLAGS          -openmp
-%BASE_LD             -i4 -r8 -auto ${MKL_LIBS}
+%BASE_LD             -i4 -r8 -auto ${MKL_LIBS} -L/smplocal/pub/FFTW/3.3.3_dyn/lib -lfftw3 -lmkl_intel_lp64 -lmkl_sequential -lmkl_core -lpthread -Wl,-rpath=/smplocal/pub/NetCDF/4.1.3/mpi/lib:/smplocal/pub/HDF5/1.8.9/par/lib:/smplocal/pub/FFTW/3.3.3_dyn/lib -L../../LMDZ.COMMON/lib -llmdz 
 %MPI_LD
 %OMP_LD              -openmp
Index: codes/icosagcm/branches/SATURN_DYNAMICO/ICOSAGCM/arch/arch-X64_ADA.path
===================================================================
--- codes/icosagcm/branches/SATURN_DYNAMICO/ICOSAGCM/arch/arch-X64_ADA.path	(revision 263)
+++ codes/icosagcm/branches/SATURN_DYNAMICO/ICOSAGCM/arch/arch-X64_ADA.path	(revision 264)
@@ -10,2 +10,6 @@
 #HDF5_LIBDIR="-L $HDF5_LIB_DIR"
 #HDF5_LIB="-lhdf5_hl -lhdf5 -lhdf5 -lz -lcurl"
+
+XIOS_INCDIR="-I../../XIOS/inc"
+XIOS_LIBDIR="-L../../XIOS/lib"
+XIOS_LIB="-lxios -lstdc++"
Index: codes/icosagcm/branches/SATURN_DYNAMICO/ICOSAGCM/compile_dynlmdz_ada
===================================================================
--- codes/icosagcm/branches/SATURN_DYNAMICO/ICOSAGCM/compile_dynlmdz_ada	(revision 264)
+++ codes/icosagcm/branches/SATURN_DYNAMICO/ICOSAGCM/compile_dynlmdz_ada	(revision 264)
@@ -0,0 +1,6 @@
+cd ../LMDZ.COMMON
+rm -rf libo
+./makelmdz_fcm -s 1 -d 128x96x64 -b 20x30 -io none -arch X64_ADA -parallel mpi -p std -j 8 gcm
+cd ../ICOSAGCM
+rm bin/icosa_gcm.exe
+./make_icosa -arch X64_ADA -parallel mpi -job 8 -full -with_xios
Index: codes/icosagcm/branches/SATURN_DYNAMICO/LMDZ.COMMON/arch/arch-X64_ADA.env
===================================================================
--- codes/icosagcm/branches/SATURN_DYNAMICO/LMDZ.COMMON/arch/arch-X64_ADA.env	(revision 264)
+++ codes/icosagcm/branches/SATURN_DYNAMICO/LMDZ.COMMON/arch/arch-X64_ADA.env	(revision 264)
@@ -0,0 +1,6 @@
+module unload compilerwrappers
+module unload netcdf
+module unload hdf5
+
+module load netcdf
+module load hdf5
Index: codes/icosagcm/branches/SATURN_DYNAMICO/LMDZ.COMMON/arch/arch-X64_ADA.fcm
===================================================================
--- codes/icosagcm/branches/SATURN_DYNAMICO/LMDZ.COMMON/arch/arch-X64_ADA.fcm	(revision 263)
+++ codes/icosagcm/branches/SATURN_DYNAMICO/LMDZ.COMMON/arch/arch-X64_ADA.fcm	(revision 264)
@@ -1,4 +1,4 @@
-%COMPILER            mpiifort
-%LINK                mpiifort
+%COMPILER            /smplocal/intel/impi/4.0.3.008/intel64/bin/mpiifort
+%LINK                /smplocal/intel/impi/4.0.3.008/intel64/bin/mpiifort
 %AR                  ar
 %MAKE                gmake
@@ -8,10 +8,8 @@
 %PROD_FFLAGS         -O2 -ip -fp-model strict -axAVX,SSE4.2
 %DEV_FFLAGS          -p -g -O1 -fpe0 -traceback
-%DEBUG_FFLAGS        -p -g -O0 -fpe-all=0 -traceback -ftrapuv -fp-stack-check -check all -debug
-%C_COMPILER          gcc
-%C_OPTIM             -O3
+%DEBUG_FFLAGS        -g -traceback -check bounds -fp-model strict
 %MPI_FFLAGS
 %OMP_FFLAGS          -openmp
-%BASE_LD             -shared-intel -lmkl_intel_lp64 -lmkl_intel_thread -lmkl_core -liomp5 -lpthread -L/smplocal/pub/FFTW/3.3.3_dyn/lib -lfftw3 -Wl,-rpath=/smplocal/pub/NetCDF/4.1.3/lib:/smplocal/pub/HDF5/1.8.9/seq/lib:/smplocal/pub/FFTW/3.3.3_dyn/lib
+%BASE_LD             -L/smplocal/pub/FFTW/3.3.3_dyn/lib -lfftw3 -shared-intel  -lmkl_intel_lp64 -lmkl_sequential -lmkl_core -lpthread -Wl,-rpath=/smplocal/pub/NetCDF/4.1.3/mpi/lib:/smplocal/pub/HDF5/1.8.9/par/lib:/smplocal/pub/FFTW/3.3.3_dyn/lib
 %MPI_LD
 %OMP_LD              -openmp
Index: codes/icosagcm/branches/SATURN_DYNAMICO/LMDZ.COMMON/arch/arch-X64_ADA.path
===================================================================
--- codes/icosagcm/branches/SATURN_DYNAMICO/LMDZ.COMMON/arch/arch-X64_ADA.path	(revision 263)
+++ codes/icosagcm/branches/SATURN_DYNAMICO/LMDZ.COMMON/arch/arch-X64_ADA.path	(revision 264)
@@ -1,13 +1,17 @@
-NETCDF_LIBDIR="${NETCDF_LDFLAGS:--L/smplocal/pub/NetCDF/4.1.3/lib -lnetcdff -lnetcdf -L/smplocal/pub/HDF5/1.8.9/seq/lib -lhdf5hl_fortran -lhdf5_hl -lhdf5_fortran -lhdf5 -lz}"
-NETCDF_INCDIR="${NETCDF_FFLAGS:--I/smplocal/pub/HDF5/1.8.9/seq/include -I/smplocal/pub/NetCDF/4.1.3/include}"
+NETCDF_LIBDIR="${NETCDF_LDFLAGS:--L/smplocal/pub/NetCDF/4.1.3/mpi/lib -lnetcdff -lnetcdf -L/smplocal/pub/HDF5/1.8.9/par/lib -Bstatic -lhdf5hl_fortran -lhdf5_hl -lhdf5_fortran -lhdf5 -Bdynamic -lz}"
+NETCDF_INCDIR="${NETCDF_FFLAGS:--I/smplocal/pub/HDF5/1.8.9/par/include -I/smplocal/pub/NetCDF/4.1.3/mpi/include}"
+
+#IOIPSL_INCDIR=$WORKDIR/IOIPSL/src
+#IOIPSL_LIBDIR=$WORKDIR/IOIPSL/src
+
 IOIPSL_INCDIR=/smphome/rech/psl/rpsl035/IOIPSL_PLUS/modipsl/lib
 IOIPSL_LIBDIR=/smphome/rech/psl/rpsl035/IOIPSL_PLUS/modipsl/lib
-XIOS_INCDIR=$LMDGCM/../XIOS/inc
-XIOS_LIBDIR=$LMDGCM/../XIOS/lib
+XIOS_INCDIR="-I../../XIOS/inc"
+XIOS_LIBDIR="-L../../XIOS/lib"
+
 ORCH_INCDIR=$LMDGCM/../../lib
 ORCH_LIBDIR=$LMDGCM/../../lib
-OASIS_INCDIR=$LMDGCM/../../oasis3-mct/BLD/build/lib/psmile.MPI1
-OASIS_LIBDIR=$LMDGCM/../../oasis3-mct/BLD/lib
+OASIS_INCDIR=$LMDGCM/../../prism/X64/build/lib/psmile.$couple
+OASIS_LIBDIR=$LMDGCM/../../prism/X64/lib
 INCA_LIBDIR=$LMDGCM/../INCA/config/lib
 INCA_INCDIR=$LMDGCM/../INCA/config/lib
-
Index: codes/icosagcm/branches/SATURN_DYNAMICO/LMDZ.COMMON/compile_ada
===================================================================
--- codes/icosagcm/branches/SATURN_DYNAMICO/LMDZ.COMMON/compile_ada	(revision 264)
+++ codes/icosagcm/branches/SATURN_DYNAMICO/LMDZ.COMMON/compile_ada	(revision 264)
@@ -0,0 +1,1 @@
+./makelmdz_fcm -s 1 -d 128x96x64 -b 20x30 -io none -arch X64_ADA -parallel mpi -p std -j 8 gcm
Index: codes/icosagcm/branches/SATURN_DYNAMICO/LMDZ.COMMON/libf/dyn3dpar/gcm.F
===================================================================
--- codes/icosagcm/branches/SATURN_DYNAMICO/LMDZ.COMMON/libf/dyn3dpar/gcm.F	(revision 263)
+++ codes/icosagcm/branches/SATURN_DYNAMICO/LMDZ.COMMON/libf/dyn3dpar/gcm.F	(revision 264)
@@ -563,6 +563,6 @@
         t_ops =((1.0*iecri)/day_step) * daysec  
         t_wrt = daysec ! iecri * daysec ! write output every t_wrt
-        CALL inithist(day_ref,annee_ref,time_step,
-     &                  t_ops,t_wrt)
+!        CALL inithist(day_ref,annee_ref,time_step,
+!     &                  t_ops,t_wrt)
         endif
 
@@ -571,6 +571,6 @@
           t_ops = iperiod * time_step ! do operations every t_ops
           t_wrt = periodav * daysec   ! write output every t_wrt
-          CALL initdynav(day_ref,annee_ref,time_step,
-     &                   t_ops,t_wrt)
+!          CALL initdynav(day_ref,annee_ref,time_step,
+!     &                   t_ops,t_wrt)
 !         CALL initdynav_p(dynhistave_file,day_ref,annee_ref,time_step,
 !     .        t_ops, t_wrt, histaveid)
Index: codes/icosagcm/branches/SATURN_DYNAMICO/LMDZ.COMMON/libf/dyn3dpar/init_gcm_lmdz.F
===================================================================
--- codes/icosagcm/branches/SATURN_DYNAMICO/LMDZ.COMMON/libf/dyn3dpar/init_gcm_lmdz.F	(revision 263)
+++ codes/icosagcm/branches/SATURN_DYNAMICO/LMDZ.COMMON/libf/dyn3dpar/init_gcm_lmdz.F	(revision 264)
@@ -5,5 +5,6 @@
 c
       SUBROUTINE init_gcm_lmdz(nbp,nproc,distrib_icosa,latfi,lonfi,
-     &                         airefi)
+     &				airefi)
+!     &                         airefi,day_length)
 
 #ifdef CPP_IOIPSL
@@ -47,4 +48,5 @@
       REAL, INTENT(IN) :: lonfi(nbp)
       REAL, INTENT(IN) :: airefi(nbp)
+!      INTEGER, INTENT(IN) :: day_length
 
       REAL :: zcufi(nbp)
@@ -515,4 +517,11 @@
 !         zcvfi(nbp)=1.
 
+!	 PRINT*,'daysec=',daysec
+!	 PRINT*,'day_length=',day_length
+!	 IF (daysec /= day_length) THEN
+!		PRINT*,'daysec different de day_length'
+!		daysec=day_length
+!	 ENDIF
+
 !         CALL iniphysiq(klon_glo,llm,daysec,day_ini,dtphys/nsplit_phys, 
 !     &                latfi,lonfi,airefi,zcufi,zcvfi,rad,g,r,cpp, 
@@ -588,6 +597,6 @@
         t_ops =((1.0*iecri)/day_step) * daysec  
         t_wrt = daysec ! iecri * daysec ! write output every t_wrt
-        CALL inithist(day_ref,annee_ref,time_step,
-     &                  t_ops,t_wrt)
+!        CALL inithist(day_ref,annee_ref,time_step,
+!     &                  t_ops,t_wrt)
         endif
 
@@ -596,6 +605,6 @@
           t_ops = iperiod * time_step ! do operations every t_ops
           t_wrt = periodav * daysec   ! write output every t_wrt
-          CALL initdynav(day_ref,annee_ref,time_step,
-     &                   t_ops,t_wrt)
+!          CALL initdynav(day_ref,annee_ref,time_step,
+!     &                   t_ops,t_wrt)
 !         CALL initdynav_p(dynhistave_file,day_ref,annee_ref,time_step,
 !     .        t_ops, t_wrt, histaveid)
Index: codes/icosagcm/branches/SATURN_DYNAMICO/LMDZ.COMMON/libf/phystd/mod_phys_lmdz_para.F90
===================================================================
--- codes/icosagcm/branches/SATURN_DYNAMICO/LMDZ.COMMON/libf/phystd/mod_phys_lmdz_para.F90	(revision 263)
+++ codes/icosagcm/branches/SATURN_DYNAMICO/LMDZ.COMMON/libf/phystd/mod_phys_lmdz_para.F90	(revision 264)
@@ -34,5 +34,5 @@
        is_master=.FALSE.
      ENDIF
-     CALL Test_transfert
+     !CALL Test_transfert
 !$OMP END PARALLEL    
      IF (is_using_mpi .OR. is_using_omp) THEN
Index: codes/icosagcm/branches/SATURN_DYNAMICO/LMDZ.COMMON/makelmdz_fcm
===================================================================
--- codes/icosagcm/branches/SATURN_DYNAMICO/LMDZ.COMMON/makelmdz_fcm	(revision 263)
+++ codes/icosagcm/branches/SATURN_DYNAMICO/LMDZ.COMMON/makelmdz_fcm	(revision 264)
@@ -218,5 +218,7 @@
 rm -f arch.path
 ln -s arch/arch-${arch}.path ./arch.path
+ln -s arch/arch-${arch}.env ./arch.env
 source arch.path
+source arch.env
 
 ########################################################################
Index: codes/icosagcm/branches/SATURN_DYNAMICO/TEST/icosa.xml
===================================================================
--- codes/icosagcm/branches/SATURN_DYNAMICO/TEST/icosa.xml	(revision 263)
+++ codes/icosagcm/branches/SATURN_DYNAMICO/TEST/icosa.xml	(revision 264)
@@ -9,4 +9,6 @@
        
        <field_group axis_ref="lev"> 
+         <field id="ulon" />
+         <field id="ulat" />
          <field id="mass" />
          <field id="dmass"/>
Index: codes/icosagcm/branches/SATURN_DYNAMICO/TEST/iodef.xml
===================================================================
--- codes/icosagcm/branches/SATURN_DYNAMICO/TEST/iodef.xml	(revision 263)
+++ codes/icosagcm/branches/SATURN_DYNAMICO/TEST/iodef.xml	(revision 264)
@@ -8,5 +8,5 @@
       <variable_definition>
         <variable_group id="buffer">
-            buffer_size = 800000000
+            buffer_size = 8000000
             buffer_server_factor_size = 2 
          </variable_group>
Index: codes/icosagcm/branches/SATURN_DYNAMICO/TEST/launch.ada
===================================================================
--- codes/icosagcm/branches/SATURN_DYNAMICO/TEST/launch.ada	(revision 264)
+++ codes/icosagcm/branches/SATURN_DYNAMICO/TEST/launch.ada	(revision 264)
@@ -0,0 +1,26 @@
+module unload netcdf
+module unload hdf5
+
+module load netcdf/mpi/4.1.3
+module load hdf5/mpi/1.8.9
+
+# @ output  =  LOG.$(jobid)
+# @ error = $(output)
+# @ job_type = parallel
+# Nombre de processus demandes (ici 8)
+# @ total_tasks = 16
+# Nombre de threads demandes
+# @ parallel_threads = 1
+### Memoire (si moins de 64 coeurs: maximum 7.0gb par processus MPI; par ex. pour 4 threads par processus, on peut aller jusqu'Ã as_limit=28gb)
+### Memoire (si plus de 64 coeurs: maximum 3.5gb par processus MPI; par ex. pour 4 threads par processus, on peut aller jusqu'Ã as_limit=14gb)
+# @ as_limit =4gb
+# @ wall_clock_limit=00:30:00
+# @ queue
+
+set -x
+ls -al
+#export OMP_STACKSIZE=7GB
+
+date
+poe ./icosa_gcm.exe -labelio yes > LOG 2>&1 
+date
Index: codes/icosagcm/branches/SATURN_DYNAMICO/TEST/lmdz_physics.xml
===================================================================
--- codes/icosagcm/branches/SATURN_DYNAMICO/TEST/lmdz_physics.xml	(revision 263)
+++ codes/icosagcm/branches/SATURN_DYNAMICO/TEST/lmdz_physics.xml	(revision 264)
@@ -2,5 +2,5 @@
     
 
-   <field_definition level="1" enabled=".TRUE." operation="instant" domain_ref="horiz_domain">
+   <field_definition level="1" enabled=".TRUE." operation="instant" domain_ref="horiz_domain" prec="8">
      
      <field id="phisinit" long_name="Geopotential at the surface" operation="once"/>
Index: codes/icosagcm/branches/SATURN_DYNAMICO/XIOS/arch/arch-X64_ADA.env
===================================================================
--- codes/icosagcm/branches/SATURN_DYNAMICO/XIOS/arch/arch-X64_ADA.env	(revision 263)
+++ codes/icosagcm/branches/SATURN_DYNAMICO/XIOS/arch/arch-X64_ADA.env	(revision 264)
@@ -1,4 +1,4 @@
 module unload netcdf
 module unload hdf5
-#module load netcdf/mpi/4.1.3
-#module load hdf5/mpi/1.8.9
+module load netcdf/mpi/4.1.3
+module load hdf5/mpi/1.8.9
Index: codes/icosagcm/branches/SATURN_DYNAMICO/XIOS/compile_ada
===================================================================
--- codes/icosagcm/branches/SATURN_DYNAMICO/XIOS/compile_ada	(revision 264)
+++ codes/icosagcm/branches/SATURN_DYNAMICO/XIOS/compile_ada	(revision 264)
@@ -0,0 +1,1 @@
+./make_xios --arch X64_ADA --j 8 --full
