Merge branch 'prerelease-3.2.1' into czarek
[unres.git] / source / unres / src_MD-M / MD_A-MTS.F
index d3c3cb0..56b3ea8 100644 (file)
@@ -1087,12 +1087,25 @@ c Applying velocity Verlet algorithm - step 1 to coordinates
 c
 c Compute friction and stochastic forces
 c
+#ifdef MPI
       time00=MPI_Wtime()
+#else
+      time00=tcpu()
+#endif
       call friction_force
+#ifdef MPI
       time_fric=time_fric+MPI_Wtime()-time00
       time00=MPI_Wtime()
+#else
+      time_fric=time_fric+tcpu()-time00
+      time00=tcpu()
+#endif
       call stochastic_force(stochforcvec) 
+#ifdef MPI
       time_stoch=time_stoch+MPI_Wtime()-time00
+#else
+      time_stoch=time_stoch+tcpu()-time00
+#endif
 c
 c Compute the acceleration due to friction forces (d_af_work) and stochastic
 c forces (d_as_work)
@@ -1507,11 +1520,13 @@ c        statname=statname(:ilen(statname)-5)//qstr(:ipos-1)//'.stat'
        if (restart1file) then
          if (me.eq.king)
      &     inquire(file=mremd_rst_name,exist=file_exist)
+#ifdef MPI
            write (*,*) me," Before broadcast: file_exist",file_exist
          call MPI_Bcast(file_exist,1,MPI_LOGICAL,king,CG_COMM,
      &          IERR)
          write (*,*) me," After broadcast: file_exist",file_exist
 c        inquire(file=mremd_rst_name,exist=file_exist)
+#endif
         if(me.eq.king.or..not.out1file)
      &   write(iout,*) "Initial state read by master and distributed"
        else