[mpich-commits] [mpich] MPICH primary repository branch, master, updated. v3.1.2-67-gd19d904
Service Account
noreply at mpich.org
Tue Aug 5 10:11:22 CDT 2014
This is an automated email from the git hooks/post-receive script. It was
generated because a ref change was pushed to the repository containing
the project "MPICH primary repository".
The branch, master has been updated
via d19d9044c7bcaf958385f00944ef3a9d596885c0 (commit)
from 658ff0d92533793bf453fc079e2b96cf576ac1f4 (commit)
Those revisions listed above that are new to this repository have
not appeared on any other notification email; so we list those
revisions in full, below.
- Log -----------------------------------------------------------------
http://git.mpich.org/mpich.git/commitdiff/d19d9044c7bcaf958385f00944ef3a9d596885c0
commit d19d9044c7bcaf958385f00944ef3a9d596885c0
Author: Huiwei Lu <huiweilu at mcs.anl.gov>
Date: Tue Aug 5 09:19:14 2014 -0500
Improves random number generation in shfp_fname.c
The original code uses MPI_Wtime to generate a mostly random double
number, and convert it to int. The integer is then used as a part of a
shared file name. Replaced with rand().
It fixes the warning messages of 'Warning: ieee_inexact is signaling'
signaled by PG Fortran compiler.
Fixes #2071
Signed-off-by: Rob Latham <robl at mcs.anl.gov>
diff --git a/src/mpi/romio/adio/common/shfp_fname.c b/src/mpi/romio/adio/common/shfp_fname.c
index c88fe18..e788d30 100644
--- a/src/mpi/romio/adio/common/shfp_fname.c
+++ b/src/mpi/romio/adio/common/shfp_fname.c
@@ -25,7 +25,6 @@
void ADIOI_Shfp_fname(ADIO_File fd, int rank)
{
- double tm;
int i;
int len;
char *slash, *ptr, tmp[128];
@@ -34,12 +33,8 @@ void ADIOI_Shfp_fname(ADIO_File fd, int rank)
fd->shared_fp_fname = (char *) ADIOI_Malloc(256);
if (!rank) {
- tm = MPI_Wtime();
- while (tm > 1000000000.0) tm -= 1000000000.0;
- i = (int) tm;
- tm = tm - (double) i;
- tm *= 1000000.0;
- i = (int) tm;
+ srand(time(NULL));
+ i = rand();
pid = (int)getpid();
ADIOI_Strncpy(fd->shared_fp_fname, fd->filename, 256);
-----------------------------------------------------------------------
Summary of changes:
src/mpi/romio/adio/common/shfp_fname.c | 9 ++-------
1 files changed, 2 insertions(+), 7 deletions(-)
hooks/post-receive
--
MPICH primary repository
More information about the commits
mailing list