Fixed issues and followed suggestions from Glenn's review of the PR
parent
a3c37808da
commit
3890b71b54
|
@ -939,7 +939,7 @@ static void InitTests(IOR_test_t *tests, MPI_Comm com)
|
||||||
params->testComm = com;
|
params->testComm = com;
|
||||||
params->nodes = params->numTasks / tasksPerNode;
|
params->nodes = params->numTasks / tasksPerNode;
|
||||||
params->tasksPerNode = tasksPerNode;
|
params->tasksPerNode = tasksPerNode;
|
||||||
params->tasksBlockMapping = QueryNodeMapping(com);
|
params->tasksBlockMapping = QueryNodeMapping(com,false);
|
||||||
if (params->numTasks == 0) {
|
if (params->numTasks == 0) {
|
||||||
params->numTasks = size;
|
params->numTasks = size;
|
||||||
}
|
}
|
||||||
|
@ -1223,7 +1223,7 @@ static void TestIoSys(IOR_test_t *test)
|
||||||
}
|
}
|
||||||
if (rank == 0 && params->reorderTasks == TRUE && verbose >= VERBOSE_1) {
|
if (rank == 0 && params->reorderTasks == TRUE && verbose >= VERBOSE_1) {
|
||||||
fprintf(out_logfile,
|
fprintf(out_logfile,
|
||||||
"Using reorderTasks '-C' (expecting block, not cyclic, task assignment)\n");
|
"Using reorderTasks '-C' (useful to avoid read cache in client)\n");
|
||||||
fflush(out_logfile);
|
fflush(out_logfile);
|
||||||
}
|
}
|
||||||
params->tasksPerNode = CountTasksPerNode(testComm);
|
params->tasksPerNode = CountTasksPerNode(testComm);
|
||||||
|
|
|
@ -1862,7 +1862,7 @@ mdtest_results_t * mdtest_run(int argc, char **argv, MPI_Comm world_com, FILE *
|
||||||
{'l', NULL, "last number of tasks on which the test will run", OPTION_OPTIONAL_ARGUMENT, 'd', & last},
|
{'l', NULL, "last number of tasks on which the test will run", OPTION_OPTIONAL_ARGUMENT, 'd', & last},
|
||||||
{'L', NULL, "files only at leaf level of tree", OPTION_FLAG, 'd', & leaf_only},
|
{'L', NULL, "files only at leaf level of tree", OPTION_FLAG, 'd', & leaf_only},
|
||||||
{'n', NULL, "every process will creat/stat/read/remove # directories and files", OPTION_OPTIONAL_ARGUMENT, 'l', & items},
|
{'n', NULL, "every process will creat/stat/read/remove # directories and files", OPTION_OPTIONAL_ARGUMENT, 'l', & items},
|
||||||
{'N', NULL, "stride # between neighbor tasks for file/dir operation (local=0)", OPTION_OPTIONAL_ARGUMENT, 'd', & nstride},
|
{'N', NULL, "stride # between tasks for file/dir operation (local=0; set to 1 to avoid client cache)", OPTION_OPTIONAL_ARGUMENT, 'd', & nstride},
|
||||||
{'p', NULL, "pre-iteration delay (in seconds)", OPTION_OPTIONAL_ARGUMENT, 'd', & pre_delay},
|
{'p', NULL, "pre-iteration delay (in seconds)", OPTION_OPTIONAL_ARGUMENT, 'd', & pre_delay},
|
||||||
{'R', NULL, "random access to files (only for stat)", OPTION_FLAG, 'd', & randomize},
|
{'R', NULL, "random access to files (only for stat)", OPTION_FLAG, 'd', & randomize},
|
||||||
{0, "random-seed", "random seed for -R", OPTION_OPTIONAL_ARGUMENT, 'd', & random_seed},
|
{0, "random-seed", "random seed for -R", OPTION_OPTIONAL_ARGUMENT, 'd', & random_seed},
|
||||||
|
@ -2065,7 +2065,7 @@ mdtest_results_t * mdtest_run(int argc, char **argv, MPI_Comm world_com, FILE *
|
||||||
VERBOSE(3,-1,"main (before display_freespace): testdirpath is '%s'", testdirpath );
|
VERBOSE(3,-1,"main (before display_freespace): testdirpath is '%s'", testdirpath );
|
||||||
|
|
||||||
if (rank == 0) display_freespace(testdirpath);
|
if (rank == 0) display_freespace(testdirpath);
|
||||||
int tasksBlockMapping = QueryNodeMapping(testComm);
|
int tasksBlockMapping = QueryNodeMapping(testComm, true);
|
||||||
|
|
||||||
/* set the shift to mimic IOR and shift by procs per node */
|
/* set the shift to mimic IOR and shift by procs per node */
|
||||||
if (nstride > 0) {
|
if (nstride > 0) {
|
||||||
|
|
|
@ -471,7 +471,7 @@ option_help * createGlobalOptions(IOR_param_t * params){
|
||||||
{'A', NULL, "refNum -- user supplied reference number to include in the summary", OPTION_OPTIONAL_ARGUMENT, 'd', & params->referenceNumber},
|
{'A', NULL, "refNum -- user supplied reference number to include in the summary", OPTION_OPTIONAL_ARGUMENT, 'd', & params->referenceNumber},
|
||||||
{'b', NULL, "blockSize -- contiguous bytes to write per task (e.g.: 8, 4k, 2m, 1g)", OPTION_OPTIONAL_ARGUMENT, 'l', & params->blockSize},
|
{'b', NULL, "blockSize -- contiguous bytes to write per task (e.g.: 8, 4k, 2m, 1g)", OPTION_OPTIONAL_ARGUMENT, 'l', & params->blockSize},
|
||||||
{'c', NULL, "collective -- collective I/O", OPTION_FLAG, 'd', & params->collective},
|
{'c', NULL, "collective -- collective I/O", OPTION_FLAG, 'd', & params->collective},
|
||||||
{'C', NULL, "reorderTasks -- changes task ordering to n+1 ordering for readback", OPTION_FLAG, 'd', & params->reorderTasks},
|
{'C', NULL, "reorderTasks -- changes task ordering for readback (useful to avoid client cache)", OPTION_FLAG, 'd', & params->reorderTasks},
|
||||||
{'d', NULL, "interTestDelay -- delay between reps in seconds", OPTION_OPTIONAL_ARGUMENT, 'd', & params->interTestDelay},
|
{'d', NULL, "interTestDelay -- delay between reps in seconds", OPTION_OPTIONAL_ARGUMENT, 'd', & params->interTestDelay},
|
||||||
{'D', NULL, "deadlineForStonewalling -- seconds before stopping write or read phase", OPTION_OPTIONAL_ARGUMENT, 'd', & params->deadlineForStonewalling},
|
{'D', NULL, "deadlineForStonewalling -- seconds before stopping write or read phase", OPTION_OPTIONAL_ARGUMENT, 'd', & params->deadlineForStonewalling},
|
||||||
{.help=" -O stoneWallingWearOut=1 -- once the stonewalling timout is over, all process finish to access the amount of data", .arg = OPTION_OPTIONAL_ARGUMENT},
|
{.help=" -O stoneWallingWearOut=1 -- once the stonewalling timout is over, all process finish to access the amount of data", .arg = OPTION_OPTIONAL_ARGUMENT},
|
||||||
|
|
|
@ -229,7 +229,7 @@ void DumpBuffer(void *buffer,
|
||||||
and the value is whether that rank is on the same host as root.
|
and the value is whether that rank is on the same host as root.
|
||||||
Also returns 1 if rank 1 is on same host and 0 otherwise
|
Also returns 1 if rank 1 is on same host and 0 otherwise
|
||||||
*/
|
*/
|
||||||
int QueryNodeMapping(MPI_Comm comm) {
|
int QueryNodeMapping(MPI_Comm comm, int print_nodemap) {
|
||||||
char localhost[MAX_PATHLEN], roothost[MAX_PATHLEN];
|
char localhost[MAX_PATHLEN], roothost[MAX_PATHLEN];
|
||||||
int num_ranks;
|
int num_ranks;
|
||||||
MPI_Comm_size(comm, &num_ranks);
|
MPI_Comm_size(comm, &num_ranks);
|
||||||
|
@ -250,7 +250,7 @@ int QueryNodeMapping(MPI_Comm comm) {
|
||||||
/* then every rank figures out whether it is same host as root and then gathers that */
|
/* then every rank figures out whether it is same host as root and then gathers that */
|
||||||
int same_as_root = strcmp(roothost,localhost) == 0;
|
int same_as_root = strcmp(roothost,localhost) == 0;
|
||||||
MPI_Gather( &same_as_root, 1, MPI_INT, node_map, 1, MPI_INT, 0, comm);
|
MPI_Gather( &same_as_root, 1, MPI_INT, node_map, 1, MPI_INT, 0, comm);
|
||||||
if (rank==0) {
|
if ( print_nodemap && rank==0) {
|
||||||
fprintf( out_logfile, "Nodemap: " );
|
fprintf( out_logfile, "Nodemap: " );
|
||||||
for ( int i = 0; i < num_ranks; i++ ) {
|
for ( int i = 0; i < num_ranks; i++ ) {
|
||||||
fprintf( out_logfile, "%d", node_map[i] );
|
fprintf( out_logfile, "%d", node_map[i] );
|
||||||
|
|
|
@ -56,7 +56,7 @@ void SetHints (MPI_Info *, char *);
|
||||||
void ShowHints (MPI_Info *);
|
void ShowHints (MPI_Info *);
|
||||||
char *HumanReadable(IOR_offset_t value, int base);
|
char *HumanReadable(IOR_offset_t value, int base);
|
||||||
int CountTasksPerNode(MPI_Comm comm);
|
int CountTasksPerNode(MPI_Comm comm);
|
||||||
int QueryNodeMapping(MPI_Comm comm);
|
int QueryNodeMapping(MPI_Comm comm, int print_nodemap);
|
||||||
void DelaySecs(int delay);
|
void DelaySecs(int delay);
|
||||||
void updateParsedOptions(IOR_param_t * options, options_all_t * global_options);
|
void updateParsedOptions(IOR_param_t * options, options_all_t * global_options);
|
||||||
size_t NodeMemoryStringToBytes(char *size_str);
|
size_t NodeMemoryStringToBytes(char *size_str);
|
||||||
|
|
Loading…
Reference in New Issue