From f1b8174e4ba3474b82dd07a99253601ffbb1b84d Mon Sep 17 00:00:00 2001 From: "Glenn K. Lockwood" Date: Fri, 21 Sep 2018 19:04:31 -0400 Subject: [PATCH 01/50] cleaned up README to reflect the current state of the repo --- README.md | 42 +++++++++++++++++++++--------------------- 1 file changed, 21 insertions(+), 21 deletions(-) diff --git a/README.md b/README.md index 81a1fa3..c1c73a8 100755 --- a/README.md +++ b/README.md @@ -1,31 +1,31 @@ # HPC IO Benchmark Repository [![Build Status](https://travis-ci.org/hpc/ior.svg?branch=master)](https://travis-ci.org/hpc/ior) -This repo now contains both IOR and mdtest. -See also NOTES.txt +This repository contains the IOR and mdtest parallel I/O benchmarks. The +[official IOR/mdtest documention][] can be found in the `docs/` subdirectory or +on Read the Docs. -# Building +## Building -0. If "configure" is missing from the top level directory, you - probably retrieved this code directly from the repository. - Run "./bootstrap". +1. If `configure` is missing from the top level directory, you probably + retrieved this code directly from the repository. Run `./bootstrap` + to generate the configure script. Alternatively, download an + [official IOR release][] which includes the configure script. - If your versions of the autotools are not new enough to run - this script, download and official tarball in which the - configure script is already provided. +1. Run `./configure`. For a full list of configuration options, use + `./configure --help`. -1. Run "./configure" +2. Run `make` - See "./configure --help" for configuration options. +3. Optionally, run `make install`. The installation prefix + can be changed via `./configure --prefix=...`. -2. Run "make" +## Testing -3. Optionally, run "make install". The installation prefix - can be changed as an option to the "configure" script. +* Run `make check` to invoke the unit tests. +* More comprehensive functionality tests are included in `testing/`. These + scripts will launch IOR and mdtest via MPI. +* Docker scripts are also provided in `testing/docker/` to test various + distributions at once. -# Testing - - Run "make check" to invoke the unit test framework of Automake. - - * To run basic functionality tests that we use for continuous integration, see ./testing/ - * There are docker scripts provided to test various distributions at once. - * See ./testing/docker/ +[official IOR release]: https://github.com/hpc/ior/releases +[official IOR/mdtest documention]: http://ior.readthedocs.org/ From 13fd0c6c167c32920d9e4be635bdc05dc7e14334 Mon Sep 17 00:00:00 2001 From: "Glenn K. Lockwood" Date: Fri, 21 Sep 2018 19:23:59 -0400 Subject: [PATCH 02/50] populate sphinx doc versions automatically --- doc/sphinx/conf.py | 16 ++++++++++++++-- 1 file changed, 14 insertions(+), 2 deletions(-) diff --git a/doc/sphinx/conf.py b/doc/sphinx/conf.py index 05e5807..8bee2a4 100644 --- a/doc/sphinx/conf.py +++ b/doc/sphinx/conf.py @@ -67,15 +67,27 @@ master_doc = 'index' project = u'IOR' copyright = u'2017, IOR' author = u'IOR' + # The version info for the project you're documenting, acts as replacement for # |version| and |release|, also used in various other places throughout the # built documents. # # The short X.Y version. -version = u'3.1.0' +version = u'3.2' # The full version, including alpha/beta/rc tags. -release = u'0' +release = u'3.2.0' + +for line in open(os.path.join('..', '..', 'META', 'r')): + key, value = line.split(None, 1) + if key == "Package:": + project = value + elif key == "Version:": + version = value.rsplit('.', 1)[0] + release = value +# We don't use the release field +# elif key == "Release:": +# release = value # The language for content autogenerated by Sphinx. Refer to documentation # for a list of supported languages. From 32f256f4ef9dba1cd2cab9b5a79457925d537aa8 Mon Sep 17 00:00:00 2001 From: "Glenn K. Lockwood" Date: Fri, 21 Sep 2018 19:28:50 -0400 Subject: [PATCH 03/50] bugfix --- doc/sphinx/conf.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/doc/sphinx/conf.py b/doc/sphinx/conf.py index 8bee2a4..9def583 100644 --- a/doc/sphinx/conf.py +++ b/doc/sphinx/conf.py @@ -78,7 +78,7 @@ version = u'3.2' # The full version, including alpha/beta/rc tags. release = u'3.2.0' -for line in open(os.path.join('..', '..', 'META', 'r')): +for line in open(os.path.join('..', '..', 'META'), 'r'): key, value = line.split(None, 1) if key == "Package:": project = value From 11d63f067ae5156f8f571116624638a0a40faaa8 Mon Sep 17 00:00:00 2001 From: "Glenn K. Lockwood" Date: Fri, 21 Sep 2018 21:09:22 -0400 Subject: [PATCH 04/50] updated formatting --- doc/sphinx/conf.py | 4 +- doc/sphinx/userDoc/compatibility.rst | 9 +- doc/sphinx/userDoc/install.rst | 2 + doc/sphinx/userDoc/options.rst | 372 +++++++++++++-------------- doc/sphinx/userDoc/scripts.rst | 82 ++++++ doc/sphinx/userDoc/skripts.rst | 72 ------ 6 files changed, 269 insertions(+), 272 deletions(-) create mode 100644 doc/sphinx/userDoc/scripts.rst delete mode 100644 doc/sphinx/userDoc/skripts.rst diff --git a/doc/sphinx/conf.py b/doc/sphinx/conf.py index 9def583..90628fd 100644 --- a/doc/sphinx/conf.py +++ b/doc/sphinx/conf.py @@ -74,7 +74,7 @@ author = u'IOR' # built documents. # # The short X.Y version. -version = u'3.2' +version = u'3.2.0' # The full version, including alpha/beta/rc tags. release = u'3.2.0' @@ -83,7 +83,7 @@ for line in open(os.path.join('..', '..', 'META'), 'r'): if key == "Package:": project = value elif key == "Version:": - version = value.rsplit('.', 1)[0] + version = value release = value # We don't use the release field # elif key == "Release:": diff --git a/doc/sphinx/userDoc/compatibility.rst b/doc/sphinx/userDoc/compatibility.rst index 6b87d68..0c925e2 100644 --- a/doc/sphinx/userDoc/compatibility.rst +++ b/doc/sphinx/userDoc/compatibility.rst @@ -1,10 +1,11 @@ .. _compatibility: -Compatibility -============= +Version Compatibility +===================== -IOR has a long history. Here are some hints about compatibility with older -versions. +IOR has a long history and only IOR version 3 is currently supported. However, +there are many forks of IOR based on earlier versions, and the following +incompatibilities are known to exist between major versions. 1) IOR version 1 (c. 1996-2002) and IOR version 2 (c. 2003-present) are incompatible. Input decks from one will not work on the other. As version diff --git a/doc/sphinx/userDoc/install.rst b/doc/sphinx/userDoc/install.rst index 48948ac..4bfa684 100644 --- a/doc/sphinx/userDoc/install.rst +++ b/doc/sphinx/userDoc/install.rst @@ -1,3 +1,5 @@ +.. _install: + Install ======= diff --git a/doc/sphinx/userDoc/options.rst b/doc/sphinx/userDoc/options.rst index 8b44126..6d307b6 100644 --- a/doc/sphinx/userDoc/options.rst +++ b/doc/sphinx/userDoc/options.rst @@ -16,7 +16,9 @@ normal parameters override each other, so the last one executed. Command line options -------------------- -These options are to be used on the command line. E.g., 'IOR -a POSIX -b 4K'. + +These options are to be used on the command line (e.g., ``./ior -a POSIX -b 4K``). + -a S api -- API for I/O [POSIX|MPIIO|HDF5|HDFS|S3|S3_EMC|NCMPI|RADOS] -A N refNum -- user reference number to include in long summary -b N blockSize -- contiguous bytes to write per task (e.g.: 8, 4k, 2m, 1g) @@ -69,283 +71,265 @@ These options are to be used on the command line. E.g., 'IOR -a POSIX -b 4K'. -Z reorderTasksRandom -- changes task ordering to random ordering for readback -NOTES: * S is a string, N is an integer number. - * For transfer and block sizes, the case-insensitive K, M, and G - suffices are recognized. I.e., '4k' or '4K' is accepted as 4096. +* S is a string, N is an integer number. + +* For transfer and block sizes, the case-insensitive K, M, and G + suffices are recognized. I.e., '4k' or '4K' is accepted as 4096. Directive Options ------------------ -For each of the general settings, note the default is shown in brackets. -IMPORTANT NOTE: For all true/false options below [1]=true, [0]=false -IMPORTANT NOTE: Contrary to appearance, the script options below are NOT case sensitive +For all true/false options below, [1]=true, [0]=false. All options are case-insensitive. -GENERAL: +GENERAL ^^^^^^^^^^^^^^ - * refNum - user supplied reference number, included in - long summary [0] - * api - must be set to one of POSIX, MPIIO, HDF5, HDFS, S3, - S3_EMC, or NCMPI, depending on test [POSIX] + * ``refNum`` - user supplied reference number, included in long summary + (default: 0) - * testFile - name of the output file [testFile] - NOTE: with filePerProc set, the tasks can round - robin across multiple file names '-o S@S@S' + * ``api`` - must be set to one of POSIX, MPIIO, HDF5, HDFS, S3, S3_EMC, NCMPI, + IME, MMAP, or RAODS depending on test (default: ``POSIX``) - * hintsFileName - name of the hints file [] + * ``testFile`` - name of the output file [testFile]. With ``filePerProc`` set, + the tasks can round robin across multiple file names via ``-o S@S@S``. + If only a single file name is specified in this case, IOR appends the MPI + rank to the end of each file generated (e.g., ``testFile.00000059``) + (default: ``testFile``) - * repetitions - number of times to run each test [1] + * ``hintsFileName`` - name of the hints file (default: none) - * multiFile - creates multiple files for single-shared-file or - file-per-process modes; i.e. each iteration creates - a new file [0=FALSE] + * ``repetitions`` - number of times to run each test (default: 1) - * reorderTasksConstant - reorders tasks by a constant node offset for writing/reading neighbor's - data from different nodes [0=FALSE] + * ``multiFile`` - creates multiple files for single-shared-file or + file-per-process modes for each iteration (default: 0) - * taskPerNodeOffset - for read tests. Use with -C & -Z options. [1] - With reorderTasks, constant N. With reordertasksrandom, >= N + * ``reorderTasksConstant`` - reorders tasks by a constant node offset for + writing/reading neighbor's data from different nodes (default: 0) - * reorderTasksRandom - reorders tasks to random ordering for readback [0=FALSE] + * ``taskPerNodeOffset`` - for read tests. Use with ``-C`` and ``-Z`` options. + With ``reorderTasks``, constant N. With ``reordertasksrandom``, >= N + (default: 1) - * reorderTasksRandomSeed - random seed for reordertasksrandom option. [0] - >0, same seed for all iterations. <0, different seed for each iteration + * ``reorderTasksRandom`` - reorders tasks to random ordering for read tests + (default: 0) - * quitOnError - upon error encountered on checkWrite or checkRead, - display current error and then stop execution; - if not set, count errors and continue [0=FALSE] + * ``reorderTasksRandomSeed`` - random seed for ``reordertasksrandom`` option. (default: 0) + * When > 0, use the same seed for all iterations + * When < 0, different seed for each iteration - * numTasks - number of tasks that should participate in the test - [0] - NOTE: 0 denotes all tasks + * ``quitOnError`` - upon error encountered on ``checkWrite`` or ``checkRead``, + display current error and then stop execution. Otherwise, count errors and + continue (default: 0) - * interTestDelay - this is the time in seconds to delay before - beginning a write or read in a series of tests [0] - NOTE: it does not delay before a check write or - check read + * ``numTasks`` - number of tasks that should participate in the test. 0 + denotes all tasks. (default: 0) - * outlierThreshold - gives warning if any task is more than this number - of seconds from the mean of all participating tasks. - If so, the task is identified, its time (start, - elapsed create, elapsed transfer, elapsed close, or - end) is reported, as is the mean and standard - deviation for all tasks. The default for this is 0, - which turns it off. If set to a positive value, for - example 3, any task not within 3 seconds of the mean - displays its times. [0] + * ``interTestDelay`` - time (in seconds) to delay before beginning a write or + read phase in a series of tests This does not delay before check-write or + check-read phases. (default: 0) - * intraTestBarriers - use barrier between open, write/read, and close [0=FALSE] + * ``outlierThreshold`` - gives warning if any task is more than this number of + seconds from the mean of all participating tasks. The warning includes the + offending task, its timers (start, elapsed create, elapsed transfer, elapsed + close, end), and the mean and standard deviation for all tasks. When zero, + disable this feature. (default: 0) - * uniqueDir - create and use unique directory for each - file-per-process [0=FALSE] + * ``intraTestBarriers`` - use barrier between open, write/read, and close + phases (default: 0) - * writeFile - writes file(s), first deleting any existing file [1=TRUE] - NOTE: the defaults for writeFile and readFile are - set such that if there is not at least one of - the following -w, -r, -W, or -R, it is assumed - that -w and -r are expected and are - consequently used -- this is only true with - the command line, and may be overridden in - a script + * ``uniqueDir`` - create and use unique directory for each file-per-process + (default: 0) - * readFile - reads existing file(s) (from current or previous - run) [1=TRUE] - NOTE: see writeFile notes + * ``writeFile`` - write file(s), first deleting any existing file. + The defaults for ``writeFile`` and ``readFile`` are set such that if there + is not at least one of ``-w``, ``-r``, ``-W``, or ``-R``, ``-w`` and ``-r`` + are enabled. If either ``writeFile`` or ``readFile`` are explicitly + enabled, though, its complement is *not* also implicitly enabled. - * filePerProc - accesses a single file for each processor; default - is a single file accessed by all processors [0=FALSE] + * ``readFile`` - reads existing file(s) as specified by the ``testFile`` + option. The defaults for ``writeFile`` and ``readFile`` are set such that + if there is not at least one of ``-w``, ``-r``, ``-W``, or ``-R``, ``-w`` + and ``-r`` are enabled. If either ``writeFile`` or ``readFile`` are + explicitly enabled, though, its complement is *not* also implicitly enabled. - * checkWrite - read data back and check for errors against known - pattern; can be used independently of writeFile [0=FALSE] - NOTES: - data checking is not timed and does not - affect other performance timings - - all errors tallied and returned as program - exit code, unless quitOnError set + * ``filePerProc`` - have each MPI process perform I/O to a unique file + (default: 0) - * checkRead - reread data and check for errors between reads; can - be used independently of readFile [0=FALSE] - NOTE: see checkWrite notes + * ``checkWrite`` - read data back and check for errors against known pattern. + Can be used independently of ``writeFile``. Data checking is not timed and + does not affect other performance timings. All errors detected are tallied + and returned as the program exit code unless ``quitOnError`` is set. + (default: 0) - * keepFile - stops removal of test file(s) on program exit [0=FALSE] + * ``checkRead`` - re-read data and check for errors between reads. Can be + used independently of ``readFile``. Data checking is not timed and does not + affect other performance timings. All errors detected are tallied and + returned as the program exit code unless ``quitOnError`` is set. + (default: 0) - * keepFileWithError - ensures that with any error found in data-checking, - the error-filled file(s) will not be deleted [0=FALSE] + * ``keepFile`` - do not remove test file(s) on program exit (default: 0) - * useExistingTestFile - do not remove test file before write access [0=FALSE] + * ``keepFileWithError`` - do not delete any files containing errors if + detected during read-check or write-check phases. (default: 0) - * segmentCount - number of segments in file [1] - NOTES: - a segment is a contiguous chunk of data - accessed by multiple clients each writing/ - reading their own contiguous data; - comprised of blocks accessed by multiple - clients - - with HDF5 this repeats the pattern of an - entire shared dataset + * ``useExistingTestFile`` - do not remove test file(s) before write phase + (default: 0) - * blockSize - size (in bytes) of a contiguous chunk of data - accessed by a single client; it is comprised of one - or more transfers [1048576] + * ``segmentCount`` - number of segments in file, where a segment is a + contiguous chunk of data accessed by multiple clients each writing/reading + their own contiguous data (blocks). The exact semantics of segments + depend on the API used; for example, HDF5 repeats the pattern of an entire + shared dataset. (default: 1) - * transferSize - size (in bytes) of a single data buffer to be - transferred in a single I/O call [262144] + * ``blockSize`` - size (in bytes) of a contiguous chunk of data accessed by a + single client. It is comprised of one or more transfers (default: 1048576) - * verbose - output information [0] - NOTE: this can be set to levels 0-5 on the command - line; repeating the -v flag will increase - verbosity level + * ``transferSize`` - size (in bytes) of a single data buffer to be transferred + in a single I/O call (default: 262144) - * setTimeStampSignature - set value for time stamp signature [0] - NOTE: used to rerun tests with the exact data - pattern by setting data signature to contain - positive integer value as timestamp to be - written in data file; if set to 0, is - disabled + * ``verbose`` - output more information about what IOR is doing. Can be set + to levels 0-5; repeating the -v flag will increase verbosity level. + (default: 0) - * showHelp - display options and help [0=FALSE] + * ``setTimeStampSignature`` - Value to use for the time stamp signature. Used + to rerun tests with the exact data pattern by setting data signature to + contain positive integer value as timestamp to be written in data file; if + set to 0, is disabled (default: 0) - * storeFileOffset - use file offset as stored signature when writing - file [0=FALSE] - NOTE: this will affect performance measurements + * ``showHelp`` - display options and help (default: 0) - * memoryPerNode - Allocate memory on each node to simulate real - application memory usage. Accepts a percentage of - node memory (e.g. "50%") on machines that support - sysconf(_SC_PHYS_PAGES) or a size. Allocation will - be split between tasks that share the node. + * ``storeFileOffset`` - use file offset as stored signature when writing file. + This will affect performance measurements (default: 0) - * memoryPerTask - Allocate secified amount of memory per task to - simulate real application memory usage. + * ``memoryPerNode`` - allocate memory on each node to simulate real + application memory usage or restrict page cache size. Accepts a percentage + of node memory (e.g. ``50%``) on systems that support + ``sysconf(_SC_PHYS_PAGES)`` or a size. Allocation will be split between + tasks that share the node. (default: 0) - * maxTimeDuration - max time in minutes to run tests [0] - NOTES: * setting this to zero (0) unsets this option - * this option allows the current read/write - to complete without interruption + * ``memoryPerTask`` - allocate specified amount of memory (in bytes) per task + to simulate real application memory usage. (default: 0) - * deadlineForStonewalling - seconds before stopping write or read phase [0] - NOTES: - used for measuring the amount of data moved - in a fixed time. After the barrier, each - task starts its own timer, begins moving - data, and the stops moving data at a pre- - arranged time. Instead of measuring the - amount of time to move a fixed amount of - data, this option measures the amount of - data moved in a fixed amount of time. The - objective is to prevent tasks slow to - complete from skewing the performance. - - setting this to zero (0) unsets this option - - this option is incompatible w/data checking + * ``maxTimeDuration`` - max time (in minutes) to run all tests. Any current + read/write phase is not interrupted; only future I/O phases are cancelled + once this time is exceeded. Value of zero unsets disables. (default: 0) - * randomOffset - access is to random, not sequential, offsets within a file [0=FALSE] - NOTES: - this option is currently incompatible with: - -checkRead - -storeFileOffset - -MPIIO collective or useFileView - -HDF5 or NCMPI - * summaryAlways - Always print the long summary for each test. - Useful for long runs that may be interrupted, preventing - the final long summary for ALL tests to be printed. + * ``deadlineForStonewalling`` - seconds before stopping write or read phase. + Used for measuring the amount of data moved in a fixed time. After the + barrier, each task starts its own timer, begins moving data, and the stops + moving data at a pre-arranged time. Instead of measuring the amount of time + to move a fixed amount of data, this option measures the amount of data + moved in a fixed amount of time. The objective is to prevent straggling + tasks slow from skewing the performance. This option is incompatible with + read-check and write-check modes. Value of zero unsets this option. + (default: 0) + * ``randomOffset`` - randomize access offsets within test file(s). Currently + incompatible with ``checkRead``, ``storeFileOffset``, MPIIO ``collective`` + and ``useFileView``, and HDF5 and NCMPI APIs. (default: 0) + + * ``summaryAlways`` - Always print the long summary for each test even if the job is interrupted. (default: 0) POSIX-ONLY ^^^^^^^^^^ - * useO_DIRECT - use O_DIRECT for POSIX, bypassing I/O buffers [0] - * singleXferAttempt - will not continue to retry transfer entire buffer - until it is transferred [0=FALSE] - NOTE: when performing a write() or read() in POSIX, - there is no guarantee that the entire - requested size of the buffer will be - transferred; this flag keeps the retrying a - single transfer until it completes or returns - an error + * ``useO_DIRECT`` - use direct I/ for POSIX, bypassing I/O buffers (default: 0) - * fsyncPerWrite - perform fsync after each POSIX write [0=FALSE] - * fsync - perform fsync after POSIX write close [0=FALSE] + * ``singleXferAttempt`` - do not continue to retry transfer entire buffer + until it is transferred. When performing a write() or read() in POSIX, + there is no guarantee that the entire requested size of the buffer will be + transferred; this flag keeps the retrying a single transfer until it + completes or returns an error (default: 0) + + * ``fsyncPerWrite`` - perform fsync after each POSIX write (default: 0) + + * ``fsync`` - perform fsync after POSIX file close (default: 0) MPIIO-ONLY ^^^^^^^^^^ - * preallocate - preallocate the entire file before writing [0=FALSE] - * useFileView - use an MPI datatype for setting the file view option - to use individual file pointer [0=FALSE] - NOTE: default IOR uses explicit file pointers + * ``preallocate`` - preallocate the entire file before writing (default: 0) - * useSharedFilePointer - use a shared file pointer [0=FALSE] (not working) - NOTE: default IOR uses explicit file pointers + * ``useFileView`` - use an MPI datatype for setting the file view option to + use individual file pointer. Default IOR uses explicit file pointers. + (default: 0) - * useStridedDatatype - create a datatype (max=2GB) for strided access; akin - to MULTIBLOCK_REGION_SIZE [0] (not working) + * ``useSharedFilePointer`` - use a shared file pointer. Default IOR uses + explicit file pointers. (default: 0) + + * ``useStridedDatatype`` - create a datatype (max=2GB) for strided access; + akin to ``MULTIBLOCK_REGION_SIZE`` (default: 0) HDF5-ONLY ^^^^^^^^^ - * individualDataSets - within a single file each task will access its own - dataset [0=FALSE] (not working) - NOTE: default IOR creates a dataset the size of - numTasks * blockSize to be accessed by all - tasks - * noFill - no pre-filling of data in HDF5 file creation [0=FALSE] + * ``individualDataSets`` - within a single file, each task will access its own + dataset. Default IOR creates a dataset the size of ``numTasks * blockSize`` + to be accessed by all tasks (default: 0) - * setAlignment - HDF5 alignment in bytes (e.g.: 8, 4k, 2m, 1g) [1] + * ``noFill`` - do not pre-fill data in HDF5 file creation (default: 0) + + * ``setAlignment`` - set the HDF5 alignment in bytes (e.g.: 8, 4k, 2m, 1g) (default: 1) * collectiveMetadata - enable HDF5 collective metadata (available since HDF5-1.10.0) MPIIO-, HDF5-, AND NCMPI-ONLY ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ - * collective - uses collective operations for access [0=FALSE] - * showHints - show hint/value pairs attached to open file [0=FALSE] - NOTE: not available in NCMPI + * ``collective`` - uses collective operations for access (default: 0) + + * ``showHints`` - show hint/value pairs attached to open file. Not available + for NCMPI. (default: 0) LUSTRE-SPECIFIC ^^^^^^^^^^^^^^^^^ - * lustreStripeCount - set the lustre stripe count for the test file(s) [0] - * lustreStripeSize - set the lustre stripe size for the test file(s) [0] + * ``lustreStripeCount`` - set the Lustre stripe count for the test file(s) (default: 0) - * lustreStartOST - set the starting OST for the test file(s) [-1] + * ``lustreStripeSize`` - set the Lustre stripe size for the test file(s) (default: 0) - * lustreIgnoreLocks - disable lustre range locking [0] + * ``lustreStartOST`` - set the starting OST for the test file(s) (default: -1) + + * ``lustreIgnoreLocks`` - disable Lustre range locking (default: 0) GPFS-SPECIFIC ^^^^^^^^^^^^^^ - * gpfsHintAccess - use gpfs_fcntl hints to pre-declare accesses - - * gpfsReleaseToken - immediately after opening or creating file, release - all locks. Might help mitigate lock-revocation - traffic when many proceses write/read to same file. + * ``gpfsHintAccess`` - use ``gpfs_fcntl`` hints to pre-declare accesses (default: 0) + * ``gpfsReleaseToken`` - release all locks immediately after opening or + creating file. Might help mitigate lock-revocation traffic when many + proceses write/read to same file. (default: 0) Verbosity levels ---------------------- -The verbosity of output for IOR can be set with -v. Increasing the number of --v instances on a command line sets the verbosity higher. +---------------- + +The verbosity of output for IOR can be set with ``-v``. Increasing the number +of ``-v`` instances on a command line sets the verbosity higher. Here is an overview of the information shown for different verbosity levels: -0) default; only bare essentials shown -1) max clock deviation, participating tasks, free space, access pattern, - commence/verify access notification w/time -2) rank/hostname, machine name, timer used, individual repetition - performance results, timestamp used for data signature -3) full test details, transfer block/offset compared, individual data - checking errors, environment variables, task writing/reading file name, - all test operation times -4) task id and offset for each transfer -5) each 8-byte data signature comparison (WARNING: more data to STDOUT - than stored in file, use carefully) +====== =================================== +Level Behavior +====== =================================== + 0 default; only bare essentials shown + 1 max clock deviation, participating tasks, free space, access pattern, commence/verify access notification with time + 2 rank/hostname, machine name, timer used, individual repetition performance results, timestamp used for data signature + 3 full test details, transfer block/offset compared, individual data checking errors, environment variables, task writing/reading file name, all test operation times + 4 task id and offset for each transfer + 5 each 8-byte data signature comparison (WARNING: more data to STDOUT than stored in file, use carefully) +====== =================================== Incompressible notes -------------------------- +-------------------- Please note that incompressibility is a factor of how large a block compression -algorithm uses. The incompressible buffer is filled only once before write times, -so if the compression algorithm takes in blocks larger than the transfer size, -there will be compression. Below are some baselines that I established for -zip, gzip, and bzip. +algorithm uses. The incompressible buffer is filled only once before write +times, so if the compression algorithm takes in blocks larger than the transfer +size, there will be compression. Below are some baselines for zip, gzip, and +bzip. 1) zip: For zipped files, a transfer size of 1k is sufficient. @@ -355,5 +339,5 @@ zip, gzip, and bzip. To avoid compression a transfer size of greater than the bzip block size is required (default = 900KB). I suggest a transfer size of greather than 1MB to avoid bzip2 compression. -Be aware of the block size your compression algorithm will look at, and adjust the transfer size -accordingly. +Be aware of the block size your compression algorithm will look at, and adjust +the transfer size accordingly. diff --git a/doc/sphinx/userDoc/scripts.rst b/doc/sphinx/userDoc/scripts.rst new file mode 100644 index 0000000..14e00e0 --- /dev/null +++ b/doc/sphinx/userDoc/scripts.rst @@ -0,0 +1,82 @@ +Scripting +========= + +IOR can use an input script with the command line using the ``-f`` option. +**Any options on the command line set before the '-f' option is given will be +considered the default settings for running the script.** For example, :: + + mpirun ./ior -W -f script + +will run all tests in the script with an implicit ``-W``. The script itself can +override these settings and may be set to run many different tests of IOR under +a single execution, and it is important to note that **any command-line options +specified after ``-f`` will not be applied to the runs dictated by the script.** +For example, :: + + mpirun ./ior -f script -W + +will *not* run any tests with the implicit ``-W`` since that argument does not +get applied until after the ``-f`` option (and its constituent runs) are complete. + +Input scripts are specified using the long-form option names that correspond to +each command-line option. In addition to long-form options, + + * ``IOR START`` and ``IOR END`` mark the beginning and end of the script + * ``RUN`` dispatches the test using all of the options specified before it + * All previous set parameter stay set for the next test. They are not reset + to the default! For default the must be rest manually. + * White space is ignored in script, as are comments starting with ``#``. + * Not all test parameters need be set. + +An example of a script: :: + + IOR START + api=[POSIX|MPIIO|HDF5|HDFS|S3|S3_EMC|NCMPI|RADOS] + testFile=testFile + hintsFileName=hintsFile + repetitions=8 + multiFile=0 + interTestDelay=5 + readFile=1 + writeFile=1 + filePerProc=0 + checkWrite=0 + checkRead=0 + keepFile=1 + quitOnError=0 + segmentCount=1 + blockSize=32k + outlierThreshold=0 + setAlignment=1 + transferSize=32 + singleXferAttempt=0 + individualDataSets=0 + verbose=0 + numTasks=32 + collective=1 + preallocate=0 + useFileView=0 + keepFileWithError=0 + setTimeStampSignature=0 + useSharedFilePointer=0 + useStridedDatatype=0 + uniqueDir=0 + fsync=0 + storeFileOffset=0 + maxTimeDuration=60 + deadlineForStonewalling=0 + useExistingTestFile=0 + useO_DIRECT=0 + showHints=0 + showHelp=0 + RUN + # additional tests are optional + transferSize=64 + blockSize=64k + segmentcount=2 + RUN + transferSize=4K + blockSize=1M + segmentcount=1024 + RUN + IOR STOP diff --git a/doc/sphinx/userDoc/skripts.rst b/doc/sphinx/userDoc/skripts.rst deleted file mode 100644 index 964f1ac..0000000 --- a/doc/sphinx/userDoc/skripts.rst +++ /dev/null @@ -1,72 +0,0 @@ -Scripting -========= - -IOR can use a script with the command line. Any options on the command line set -before the script will be considered the default settings for running the script. -(I.e.,'$ ./IOR -W -f script' will have all tests in the script run with the -W -option as default.) -The script itself can override these settings and may be set to run -run many different tests of IOR under a single execution. -The command line is: :: - - ./IOR -f script - -In IOR/scripts, there are scripts of test cases for simulating I/O behavior of -various application codes. Details are included in each script as necessary. - -Syntax: - * IOR START / IOR END: marks the beginning and end of the script - * RUN: Delimiter for next Test - * All previous set parameter stay set for the next test. They are not reset - to the default! For default the musst be rest manually. - * White space is ignored in script, as are comments starting with '#'. - * Not all test parameters need be set. - -An example of a script: :: - - IOR START - api=[POSIX|MPIIO|HDF5|HDFS|S3|S3_EMC|NCMPI|RADOS] - testFile=testFile - hintsFileName=hintsFile - repetitions=8 - multiFile=0 - interTestDelay=5 - readFile=1 - writeFile=1 - filePerProc=0 - checkWrite=0 - checkRead=0 - keepFile=1 - quitOnError=0 - segmentCount=1 - blockSize=32k - outlierThreshold=0 - setAlignment=1 - transferSize=32 - singleXferAttempt=0 - individualDataSets=0 - verbose=0 - numTasks=32 - collective=1 - preallocate=0 - useFileView=0 - keepFileWithError=0 - setTimeStampSignature=0 - useSharedFilePointer=0 - useStridedDatatype=0 - uniqueDir=0 - fsync=0 - storeFileOffset=0 - maxTimeDuration=60 - deadlineForStonewalling=0 - useExistingTestFile=0 - useO_DIRECT=0 - showHints=0 - showHelp=0 - RUN - # additional tests are optional - - RUN - - RUN - IOR STOP From 2333c23bedf4b57e1f105022ef35008097c59e6f Mon Sep 17 00:00:00 2001 From: "Glenn K. Lockwood" Date: Fri, 21 Sep 2018 21:09:39 -0400 Subject: [PATCH 05/50] clean up intro --- doc/sphinx/intro.rst | 34 +++++++++++++++------------------- 1 file changed, 15 insertions(+), 19 deletions(-) diff --git a/doc/sphinx/intro.rst b/doc/sphinx/intro.rst index 3964bbc..11cf138 100644 --- a/doc/sphinx/intro.rst +++ b/doc/sphinx/intro.rst @@ -1,26 +1,22 @@ Introduction ============ -Welcome to the IOR documentation. +IOR is a parallel IO benchmark that can be used to test the performance of +parallel storage systems using various interfaces and access patterns. The +IOR repository also includes the mdtest benchmark which specifically tests +the peak metadata rates of storage systems under different directory +structures. Both benchmarks use a common parallel I/O abstraction backend +and rely on MPI for synchronization. -**I**\ nterleaved **o**\ r **R**\ andom is a parallel IO benchmark. -IOR can be used for testing performance of parallel file systems using various -interfaces and access patterns. IOR uses MPI for process synchronization. -This documentation provides information for versions 3 and higher, for other -versions check :ref:`compatibility` +This documentation consists of two parts. -This documentation consists of tow parts. +**User documentation** includes installation instructions (:ref:`install`), a +beginner's tutorial (:ref:`first-steps`), and information about IOR's +runtime :ref:`options`. -The first part is a user documentation were you find instructions on compilation, a -beginners tutorial (:ref:`first-steps`) as well as information about all -available :ref:`options`. +**Developer documentation** consists of code documentation generated with +Doxygen and some notes about the contiguous integration with Travis. -The second part is the developer documentation. It currently only consists of a -auto generated Doxygen and some notes about the contiguous integration with travis. -As there are quite some people how needs to modify or extend IOR to there needs -it would be great to have documentation on what and how to alter IOR without -breaking other stuff. Currently there is neither a documentation on the overall -concept of the code nor on implementation details. If you are getting your -hands dirty in code anyways or have deeper understanding of IOR, you are more -then welcome to comment the code directly, which will result in better Doxygen -output or add your insight to this sphinx documentation. +Many aspects of both IOR/mdtest user and developer documentation are incomplete, +and contributors are encouraged to comment the code directly or expand upon this +documentation. From d0237d6d6658ce97f47f94d0f3695f205bb18412 Mon Sep 17 00:00:00 2001 From: "Glenn K. Lockwood" Date: Fri, 21 Sep 2018 21:09:57 -0400 Subject: [PATCH 06/50] skript -> script --- doc/sphinx/index.rst | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/doc/sphinx/index.rst b/doc/sphinx/index.rst index de693ac..b2532bf 100644 --- a/doc/sphinx/index.rst +++ b/doc/sphinx/index.rst @@ -13,7 +13,7 @@ userDoc/install First Steps userDoc/options - userDoc/skripts + userDoc/scripts userDoc/compatibility FAQ From 57f47db37f975e4b7f6786581de3ff0fa63c629a Mon Sep 17 00:00:00 2001 From: "Glenn K. Lockwood" Date: Fri, 21 Sep 2018 21:10:52 -0400 Subject: [PATCH 07/50] odds and ends --- doc/sphinx/README.md | 5 +++++ doc/sphinx/changes.rst | 4 ++-- doc/sphinx/conf.py | 8 ++++---- 3 files changed, 11 insertions(+), 6 deletions(-) create mode 100644 doc/sphinx/README.md diff --git a/doc/sphinx/README.md b/doc/sphinx/README.md new file mode 100644 index 0000000..2ec8323 --- /dev/null +++ b/doc/sphinx/README.md @@ -0,0 +1,5 @@ +To build the documentation in this directory, + + sphinx-build . _build_html + +The output will be saved as html in `_build_html/`. diff --git a/doc/sphinx/changes.rst b/doc/sphinx/changes.rst index 3632a7d..c224e64 100644 --- a/doc/sphinx/changes.rst +++ b/doc/sphinx/changes.rst @@ -1,4 +1,4 @@ Changes in IOR -***************** +************** -.. .. include:: ../../ChangeLog +.. .. include:: ../../NEWS diff --git a/doc/sphinx/conf.py b/doc/sphinx/conf.py index 90628fd..688303e 100644 --- a/doc/sphinx/conf.py +++ b/doc/sphinx/conf.py @@ -64,9 +64,9 @@ source_suffix = '.rst' master_doc = 'index' # General information about the project. -project = u'IOR' -copyright = u'2017, IOR' -author = u'IOR' +project = u'ior' +copyright = u'2018, The Regents of the University of California' +author = u'The IOR Developer Community' # The version info for the project you're documenting, acts as replacement for @@ -197,7 +197,7 @@ man_pages = [ # dir menu entry, description, category) texinfo_documents = [ (master_doc, 'IOR', u'IOR Documentation', - author, 'IOR', 'One line description of project.', + author, 'IOR', 'IOR/mdtest Parallel I/O Benchmarks', 'Miscellaneous'), ] From aa3f045c92d8bd887a78f5b4b5261b2b17b50317 Mon Sep 17 00:00:00 2001 From: "Glenn K. Lockwood" Date: Fri, 21 Sep 2018 21:12:23 -0400 Subject: [PATCH 08/50] fix spelling mistake --- doc/sphinx/devDoc/CI.rst | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/doc/sphinx/devDoc/CI.rst b/doc/sphinx/devDoc/CI.rst index 39cbf9e..43f1b5c 100644 --- a/doc/sphinx/devDoc/CI.rst +++ b/doc/sphinx/devDoc/CI.rst @@ -1,8 +1,8 @@ -Continues Integration -===================== +Continuous Integration +====================== -Continues Integration is used for basic sanity checking. Travis-CI provides free -CI for open source github projects and is configured via a .travis.yml. +Continuous Integration is used for basic sanity checking. Travis-CI provides free +CI for open source github projects and is configured via a ``.travis.yml``. For now this is set up to compile IOR on a ubuntu 14.04 machine with gcc 4.8, openmpi and hdf5 for the backends. This is a pretty basic check and should be From 2241f77a5d8edbabbd5aa95942765076974317d0 Mon Sep 17 00:00:00 2001 From: "Glenn K. Lockwood" Date: Fri, 21 Sep 2018 21:18:28 -0400 Subject: [PATCH 09/50] got NEWS importing correctly --- doc/sphinx/changes.rst | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/doc/sphinx/changes.rst b/doc/sphinx/changes.rst index c224e64..c11d45e 100644 --- a/doc/sphinx/changes.rst +++ b/doc/sphinx/changes.rst @@ -1,4 +1,4 @@ Changes in IOR ************** -.. .. include:: ../../NEWS +.. include:: ../../NEWS From 0bb96e96841484e3cd9226aa9337c75264b282b8 Mon Sep 17 00:00:00 2001 From: "Glenn K. Lockwood" Date: Sat, 22 Dec 2018 20:57:44 -0800 Subject: [PATCH 10/50] added docs for release process --- doc/sphinx/devDoc/release.rst | 37 +++++++++++++++++++++++++++++++++++ doc/sphinx/index.rst | 1 + 2 files changed, 38 insertions(+) create mode 100644 doc/sphinx/devDoc/release.rst diff --git a/doc/sphinx/devDoc/release.rst b/doc/sphinx/devDoc/release.rst new file mode 100644 index 0000000..3abe6d8 --- /dev/null +++ b/doc/sphinx/devDoc/release.rst @@ -0,0 +1,37 @@ +Release Process +=============== + +To build a new version of IOR, + + $ docker run -it ubuntu bash + $ apt-get update + $ apt-get install -y git automake autoconf make gcc mpich + $ git clone -b rc https://github.com/hpc/ior + $ cd ior + $ ./travis-build.sh + +To create a new release candidate from RC, + +1. Disable the `check-news` option in `AM_INIT_AUTOMAKE` inside configure.ac +2. Append "rcX" to the `Version:` field in META +3. Build a release package as described above + +To create a new minor release of IOR, + +1. Build the rc branch as described above +2. Create a release on GitHub which creates the appropriate tag +3. Upload the source distributions generated by travis-build.sh + +To create a micro branch of IOR (e.g., if a release needs a hotfix), + +1. Check out the relevant release tagged in the rc branch (e.g., `3.2.0`) +2. Create a branch with the major.minor name (e.g., `v3.2`) from that tag +3. Update the `Version:` in META +4. Apply hotfix(es) to that major.minor branch +5. Create the major.minor.micro release on GitHub + +To initiate a feature freeze, + +1. Merge the `master` branch into the `rc` branch +2. Update the `Version:` field in META _of the master branch_ to be the _next_ + release version, not the one whose features have just been frozen diff --git a/doc/sphinx/index.rst b/doc/sphinx/index.rst index b2532bf..fe3abb7 100644 --- a/doc/sphinx/index.rst +++ b/doc/sphinx/index.rst @@ -24,6 +24,7 @@ devDoc/doxygen devDoc/CI + devDoc/release .. toctree:: :hidden: From 23106d17dbb74674da297d8ecda35c67d6ac77f8 Mon Sep 17 00:00:00 2001 From: "Glenn K. Lockwood" Date: Sat, 22 Dec 2018 21:09:04 -0800 Subject: [PATCH 11/50] forgot to RST-ify this --- doc/sphinx/devDoc/release.rst | 17 +++++++++-------- 1 file changed, 9 insertions(+), 8 deletions(-) diff --git a/doc/sphinx/devDoc/release.rst b/doc/sphinx/devDoc/release.rst index 3abe6d8..1e39a35 100644 --- a/doc/sphinx/devDoc/release.rst +++ b/doc/sphinx/devDoc/release.rst @@ -1,7 +1,7 @@ Release Process =============== -To build a new version of IOR, +To build a new version of IOR:: $ docker run -it ubuntu bash $ apt-get update @@ -12,8 +12,9 @@ To build a new version of IOR, To create a new release candidate from RC, -1. Disable the `check-news` option in `AM_INIT_AUTOMAKE` inside configure.ac -2. Append "rcX" to the `Version:` field in META +1. Disable the ``check-news`` option in ``AM_INIT_AUTOMAKE`` inside configure.ac +2. Append "rcX" to the ``Version:`` field in META where X is the release + candidate number 3. Build a release package as described above To create a new minor release of IOR, @@ -24,14 +25,14 @@ To create a new minor release of IOR, To create a micro branch of IOR (e.g., if a release needs a hotfix), -1. Check out the relevant release tagged in the rc branch (e.g., `3.2.0`) -2. Create a branch with the major.minor name (e.g., `v3.2`) from that tag -3. Update the `Version:` in META +1. Check out the relevant release tagged in the rc branch (e.g., ``3.2.0``) +2. Create a branch with the major.minor name (e.g., ``3.2``) from that tag +3. Update the ``Version:`` in META 4. Apply hotfix(es) to that major.minor branch 5. Create the major.minor.micro release on GitHub To initiate a feature freeze, -1. Merge the `master` branch into the `rc` branch -2. Update the `Version:` field in META _of the master branch_ to be the _next_ +1. Merge the master branch into the rc branch +2. Update the ``Version:`` field in META `of the master branch` to be the `next` release version, not the one whose features have just been frozen From 6cae44b512ce9eae77bccf2e1b5a24e45ce80637 Mon Sep 17 00:00:00 2001 From: Osamu Tatebe Date: Fri, 21 Jun 2019 21:05:41 +0900 Subject: [PATCH 12/50] abstract I/O interface for Gfarm file system --- configure.ac | 20 ++- src/Makefile.am | 5 + src/aiori-Gfarm.c | 316 ++++++++++++++++++++++++++++++++++++++++++++++ src/aiori.c | 3 + src/aiori.h | 1 + 5 files changed, 344 insertions(+), 1 deletion(-) create mode 100644 src/aiori-Gfarm.c diff --git a/configure.ac b/configure.ac index 80e8533..7d8e4a7 100755 --- a/configure.ac +++ b/configure.ac @@ -185,7 +185,25 @@ AM_COND_IF([USE_RADOS_AIORI],[ AC_DEFINE([USE_RADOS_AIORI], [], [Build RADOS backend AIORI]) ]) - +# Gfarm support +AC_MSG_CHECKING([for Gfarm file system]) +AC_ARG_WITH([gfarm], + [AS_HELP_STRING([--with-gfarm=GFARM_ROOT], + [support IO with libgfarm backend @<:@default=no@:>@])], + [], [with_gfarm=no]) +AC_MSG_RESULT([$with_gfarm]) +AM_CONDITIONAL([USE_GFARM_AIORI], [test x$with_gfarm != xno]) +if test x$with_gfarm != xno; then + AC_DEFINE([USE_GFARM_AIORI], [], [Build Gfarm backend AIORI]) + case x$with_gfarm in + xyes) ;; + *) + CPPFLAGS="$CPPFLAGS -I$with_gfarm/include" + LDFLAGS="$LDFLAGS -L$with_gfarm/lib" ;; + esac + AC_CHECK_LIB([gfarm], [gfarm_initialize],, [AC_MSG_ERROR([libgfarm not found])]) + AC_CHECK_MEMBERS([struct stat.st_mtim.tv_nsec]) +fi # aws4c is needed for the S3 backend (see --with-S3, below). # Version 0.5.2 of aws4c is available at https://github.com/jti-lanl/aws4c.git diff --git a/src/Makefile.am b/src/Makefile.am index 51fb873..74dcd31 100755 --- a/src/Makefile.am +++ b/src/Makefile.am @@ -70,6 +70,11 @@ extraSOURCES += aiori-RADOS.c extraLDADD += -lrados endif +if USE_GFARM_AIORI +extraSOURCES += aiori-Gfarm.c +extraLDADD += -lgfarm +endif + if USE_S3_AIORI extraSOURCES += aiori-S3.c if AWS4C_DIR diff --git a/src/aiori-Gfarm.c b/src/aiori-Gfarm.c new file mode 100644 index 0000000..cc835f1 --- /dev/null +++ b/src/aiori-Gfarm.c @@ -0,0 +1,316 @@ +#include +#include +#include +#include +#include +#undef PACKAGE_NAME +#undef PACKAGE_STRING +#undef PACKAGE_TARNAME +#undef PACKAGE_VERSION +#include "ior.h" +#include "aiori.h" + +struct gfarm_file { + GFS_File gf; +}; + +void +Gfarm_initialize() +{ + gfarm_initialize(NULL, NULL); +} + +void +Gfarm_finalize() +{ + gfarm_terminate(); +} + +void * +Gfarm_create(char *fn, IOR_param_t *param) +{ + GFS_File gf; + struct gfarm_file *fp; + gfarm_error_t e; + + if (param->dryRun) + return (NULL); + + e = gfs_pio_create(fn, GFARM_FILE_RDWR, 0664, &gf); + if (e != GFARM_ERR_NO_ERROR) + ERR("gfs_pio_create failed"); + GFARM_MALLOC(fp); + if (fp == NULL) + ERR("no memory"); + fp->gf = gf; + return (fp); +} + +void * +Gfarm_open(char *fn, IOR_param_t *param) +{ + GFS_File gf; + struct gfarm_file *fp; + gfarm_error_t e; + + if (param->dryRun) + return (NULL); + + e = gfs_pio_open(fn, GFARM_FILE_RDWR, &gf); + if (e != GFARM_ERR_NO_ERROR) + ERR("gfs_pio_open failed"); + GFARM_MALLOC(fp); + if (fp == NULL) + ERR("no memory"); + fp->gf = gf; + return (fp); +} + +IOR_offset_t +Gfarm_xfer(int access, void *fd, IOR_size_t *buffer, IOR_offset_t len, + IOR_param_t *param) +{ + struct gfarm_file *fp = fd; + IOR_offset_t rem = len; + gfarm_off_t off; + gfarm_error_t e; +#define MAX_SZ (1024 * 1024 * 1024) + int sz, n; + char *buf = (char *)buffer; + + if (param->dryRun) + return (len); + + if (len > MAX_SZ) + sz = MAX_SZ; + else + sz = len; + + e = gfs_pio_seek(fp->gf, param->offset, GFARM_SEEK_SET, &off); + if (e != GFARM_ERR_NO_ERROR) + ERR("gfs_pio_seek failed"); + while (rem > 0) { + if (access == WRITE) + e = gfs_pio_write(fp->gf, buf, sz, &n); + else + e = gfs_pio_read(fp->gf, buf, sz, &n); + if (e != GFARM_ERR_NO_ERROR) + ERR("xfer failed"); + if (n == 0) + ERR("EOF encountered"); + rem -= n; + buf += n; + } + return (len); +} + +void +Gfarm_close(void *fd, IOR_param_t *param) +{ + struct gfarm_file *fp = fd; + + if(param->dryRun) + return; + + if (gfs_pio_close(fp->gf) != GFARM_ERR_NO_ERROR) + ERR("gfs_pio_close failed"); + free(fp); +} + +void +Gfarm_delete(char *fn, IOR_param_t *param) +{ + gfarm_error_t e; + + if (param->dryRun) + return; + + e = gfs_unlink(fn); + if (e != GFARM_ERR_NO_ERROR) + errno = gfarm_error_to_errno(e); +} + +char * +Gfarm_version() +{ + return ((char *)gfarm_version()); +} + +void +Gfarm_fsync(void *fd, IOR_param_t *param) +{ + struct gfarm_file *fp = fd; + + if(param->dryRun) + return; + + if (gfs_pio_sync(fp->gf) != GFARM_ERR_NO_ERROR) + ERR("gfs_pio_sync failed"); +} + +IOR_offset_t +Gfarm_get_file_size(IOR_param_t *param, MPI_Comm comm, char *fn) +{ + struct gfs_stat st; + IOR_offset_t size, sum, min, max; + + if (param->dryRun) + return (0); + + if (gfs_stat(fn, &st) != GFARM_ERR_NO_ERROR) + ERR("gfs_stat failed"); + size = st.st_size; + gfs_stat_free(&st); + + if (param->filePerProc == TRUE) { + MPI_CHECK(MPI_Allreduce(&size, &sum, 1, MPI_LONG_LONG_INT, + MPI_SUM, comm), "cannot total data moved"); + size = sum; + } else { + MPI_CHECK(MPI_Allreduce(&size, &min, 1, MPI_LONG_LONG_INT, + MPI_MIN, comm), "cannot total data moved"); + MPI_CHECK(MPI_Allreduce(&size, &max, 1, MPI_LONG_LONG_INT, + MPI_MAX, comm), "cannot total data moved"); + if (min != max) { + if (rank == 0) + WARN("inconsistent file size by different " + "tasks"); + /* incorrect, but now consistent across tasks */ + size = min; + } + } + return (size); +} + +int +Gfarm_statfs(const char *fn, ior_aiori_statfs_t *st, IOR_param_t *param) +{ + gfarm_off_t used, avail, files; + gfarm_error_t e; + int bsize = 4096; + + if (param->dryRun) + return (0); + + e = gfs_statfs_by_path(fn, &used, &avail, &files); + if (e != GFARM_ERR_NO_ERROR) { + errno = gfarm_error_to_errno(e); + return (-1); + } + st->f_bsize = bsize; + st->f_blocks = (used + avail) / bsize; + st->f_bfree = avail / bsize; + st->f_files = 2 * files; /* XXX */ + st->f_ffree = files; /* XXX */ + return (0); +} + +int +Gfarm_mkdir(const char *fn, mode_t mode, IOR_param_t *param) +{ + gfarm_error_t e; + + if (param->dryRun) + return (0); + + e = gfs_mkdir(fn, mode); + if (e == GFARM_ERR_NO_ERROR) + return (0); + errno = gfarm_error_to_errno(e); + return (-1); +} + +int +Gfarm_rmdir(const char *fn, IOR_param_t *param) +{ + gfarm_error_t e; + + if (param->dryRun) + return (0); + + e = gfs_rmdir(fn); + if (e == GFARM_ERR_NO_ERROR) + return (0); + errno = gfarm_error_to_errno(e); + return (-1); +} + +int +Gfarm_access(const char *fn, int mode, IOR_param_t *param) +{ + struct gfs_stat st; + gfarm_error_t e; + + if (param->dryRun) + return (0); + + e = gfs_stat(fn, &st); + if (e != GFARM_ERR_NO_ERROR) { + errno = gfarm_error_to_errno(e); + return (-1); + } + gfs_stat_free(&st); + return (0); +} + +/* XXX FIXME */ +#define GFS_DEV ((dev_t)-1) +#define GFS_BLKSIZE 8192 +#define STAT_BLKSIZ 512 /* for st_blocks */ + +int +Gfarm_stat(const char *fn, struct stat *buf, IOR_param_t *param) +{ + struct gfs_stat st; + gfarm_error_t e; + + if (param->dryRun) + return (0); + + e = gfs_stat(fn, &st); + if (e != GFARM_ERR_NO_ERROR) { + errno = gfarm_error_to_errno(e); + return (-1); + } + buf->st_dev = GFS_DEV; + buf->st_ino = st.st_ino; + buf->st_mode = st.st_mode; + buf->st_nlink = st.st_nlink; + buf->st_uid = getuid(); /* XXX */ + buf->st_gid = getgid(); /* XXX */ + buf->st_size = st.st_size; + buf->st_blksize = GFS_BLKSIZE; + buf->st_blocks = (st.st_size + STAT_BLKSIZ - 1) / STAT_BLKSIZ; + buf->st_atime = st.st_atimespec.tv_sec; + buf->st_mtime = st.st_mtimespec.tv_sec; + buf->st_ctime = st.st_ctimespec.tv_sec; +#if defined(HAVE_STRUCT_STAT_ST_MTIM_TV_NSEC) + buf->st_atim.tv_nsec = st.st_atimespec.tv_nsec; + buf->st_mtim.tv_nsec = st.st_mtimespec.tv_nsec; + buf->st_ctim.tv_nsec = st.st_ctimespec.tv_nsec; +#endif + gfs_stat_free(&st); + return (0); +} + +ior_aiori_t gfarm_aiori = { + .name = "Gfarm", + .name_legacy = NULL, + .create = Gfarm_create, + .open = Gfarm_open, + .xfer = Gfarm_xfer, + .close = Gfarm_close, + .delete = Gfarm_delete, + .get_version = Gfarm_version, + .fsync = Gfarm_fsync, + .get_file_size = Gfarm_get_file_size, + .statfs = Gfarm_statfs, + .mkdir = Gfarm_mkdir, + .rmdir = Gfarm_rmdir, + .access = Gfarm_access, + .stat = Gfarm_stat, + .initialize = Gfarm_initialize, + .finalize = Gfarm_finalize, + .get_options = NULL, + .enable_mdtest = true, +}; diff --git a/src/aiori.c b/src/aiori.c index 52001c8..41773d9 100644 --- a/src/aiori.c +++ b/src/aiori.c @@ -68,6 +68,9 @@ ior_aiori_t *available_aiori[] = { #endif #ifdef USE_RADOS_AIORI &rados_aiori, +#endif +#ifdef USE_GFARM_AIORI + &gfarm_aiori, #endif NULL }; diff --git a/src/aiori.h b/src/aiori.h index c2074c2..56717fe 100755 --- a/src/aiori.h +++ b/src/aiori.h @@ -105,6 +105,7 @@ extern ior_aiori_t s3_aiori; extern ior_aiori_t s3_plus_aiori; extern ior_aiori_t s3_emc_aiori; extern ior_aiori_t rados_aiori; +extern ior_aiori_t gfarm_aiori; void aiori_initialize(IOR_test_t * tests); void aiori_finalize(IOR_test_t * tests); From a822363ee0d92beba47f359271f370608163cd07 Mon Sep 17 00:00:00 2001 From: Osamu Tatebe Date: Sat, 22 Jun 2019 10:48:41 +0900 Subject: [PATCH 13/50] style fix --- configure.ac | 4 ++-- src/aiori-Gfarm.c | 10 +++++----- 2 files changed, 7 insertions(+), 7 deletions(-) diff --git a/configure.ac b/configure.ac index 7d8e4a7..af400ab 100755 --- a/configure.ac +++ b/configure.ac @@ -189,8 +189,8 @@ AM_COND_IF([USE_RADOS_AIORI],[ AC_MSG_CHECKING([for Gfarm file system]) AC_ARG_WITH([gfarm], [AS_HELP_STRING([--with-gfarm=GFARM_ROOT], - [support IO with libgfarm backend @<:@default=no@:>@])], - [], [with_gfarm=no]) + [support IO with Gfarm backend @<:@default=no@:>@])], + [], [with_gfarm=no]) AC_MSG_RESULT([$with_gfarm]) AM_CONDITIONAL([USE_GFARM_AIORI], [test x$with_gfarm != xno]) if test x$with_gfarm != xno; then diff --git a/src/aiori-Gfarm.c b/src/aiori-Gfarm.c index cc835f1..a7af0ea 100644 --- a/src/aiori-Gfarm.c +++ b/src/aiori-Gfarm.c @@ -77,7 +77,7 @@ Gfarm_xfer(int access, void *fd, IOR_size_t *buffer, IOR_offset_t len, #define MAX_SZ (1024 * 1024 * 1024) int sz, n; char *buf = (char *)buffer; - + if (param->dryRun) return (len); @@ -109,7 +109,7 @@ Gfarm_close(void *fd, IOR_param_t *param) { struct gfarm_file *fp = fd; - if(param->dryRun) + if (param->dryRun) return; if (gfs_pio_close(fp->gf) != GFARM_ERR_NO_ERROR) @@ -141,7 +141,7 @@ Gfarm_fsync(void *fd, IOR_param_t *param) { struct gfarm_file *fp = fd; - if(param->dryRun) + if (param->dryRun) return; if (gfs_pio_sync(fp->gf) != GFARM_ERR_NO_ERROR) @@ -213,7 +213,7 @@ Gfarm_mkdir(const char *fn, mode_t mode, IOR_param_t *param) if (param->dryRun) return (0); - e = gfs_mkdir(fn, mode); + e = gfs_mkdir(fn, mode); if (e == GFARM_ERR_NO_ERROR) return (0); errno = gfarm_error_to_errno(e); @@ -228,7 +228,7 @@ Gfarm_rmdir(const char *fn, IOR_param_t *param) if (param->dryRun) return (0); - e = gfs_rmdir(fn); + e = gfs_rmdir(fn); if (e == GFARM_ERR_NO_ERROR) return (0); errno = gfarm_error_to_errno(e); From 3eb0f86640d0fd18def2cd49d4c6c148bd4f7c0f Mon Sep 17 00:00:00 2001 From: Wei-keng Liao Date: Fri, 28 Jun 2019 17:40:35 -0500 Subject: [PATCH 14/50] Function ncmpi_get_file_info was first introduced in PnetCDF version 1.2.0. Check PnetCDF library version, so printing MPI-IO hints can be enabled for NCMPI. --- doc/USER_GUIDE | 2 +- src/aiori-NCMPI.c | 87 +++++++++++++++++++++-------------------------- 2 files changed, 40 insertions(+), 49 deletions(-) diff --git a/doc/USER_GUIDE b/doc/USER_GUIDE index 6a6cf18..b8888b9 100755 --- a/doc/USER_GUIDE +++ b/doc/USER_GUIDE @@ -342,7 +342,7 @@ MPIIO-, HDF5-, AND NCMPI-ONLY: * collective - uses collective operations for access [0=FALSE] * showHints - show hint/value pairs attached to open file [0=FALSE] - NOTE: not available in NCMPI + NOTE: available in NCMPI only if PnetCDF is 1.2.0 or later LUSTRE-SPECIFIC: ================ diff --git a/src/aiori-NCMPI.c b/src/aiori-NCMPI.c index 0f391dc..3607466 100755 --- a/src/aiori-NCMPI.c +++ b/src/aiori-NCMPI.c @@ -89,7 +89,7 @@ static void *NCMPI_Create(char *testFileName, IOR_param_t * param) int fd_mode; MPI_Info mpiHints = MPI_INFO_NULL; - /* Wei-keng Liao: read and set MPI file hints from hintsFile */ + /* read and set MPI file hints from hintsFile */ SetHints(&mpiHints, param->hintsFileName); if (rank == 0 && param->showHints) { fprintf(stdout, "\nhints passed to MPI_File_open() {\n"); @@ -105,22 +105,23 @@ static void *NCMPI_Create(char *testFileName, IOR_param_t * param) NCMPI_CHECK(ncmpi_create(testComm, testFileName, fd_mode, mpiHints, fd), "cannot create file"); - /* Wei-keng Liao: print the MPI file hints currently used */ -/* WEL - add when ncmpi_get_file_info() is in current parallel-netcdf release - if (rank == 0 && param->showHints) { - MPI_CHECK(ncmpi_get_file_info(*fd, &mpiHints), - "cannot get file info"); - fprintf(stdout, "\nhints returned from opened file {\n"); - ShowHints(&mpiHints); - fprintf(stdout, "}\n"); - } -*/ + /* free up the mpiHints object */ + if (mpiHints != MPI_INFO_NULL) + MPI_CHECK(MPI_Info_free(&mpiHints), "cannot free file info"); - /* Wei-keng Liao: free up the mpiHints object */ -/* WEL - this needs future fix from next release of PnetCDF - if (mpiHints != MPI_INFO_NULL) - MPI_CHECK(MPI_Info_free(&mpiHints), "cannot free file info"); -*/ +#if defined(PNETCDF_VERSION_MAJOR) && (PNETCDF_VERSION_MAJOR > 1 || PNETCDF_VERSION_MINOR >= 2) + /* ncmpi_get_file_info is first available in 1.2.0 */ + if (rank == 0 && param->showHints) { + MPI_Info info_used; + MPI_CHECK(ncmpi_get_file_info(*fd, &info_used), + "cannot inquire file info"); + /* print the MPI file hints currently used */ + fprintf(stdout, "\nhints returned from opened file {\n"); + ShowHints(&info_used); + fprintf(stdout, "}\n"); + MPI_CHECK(MPI_Info_free(&info_used), "cannot free file info"); + } +#endif return (fd); } @@ -134,7 +135,7 @@ static void *NCMPI_Open(char *testFileName, IOR_param_t * param) int fd_mode; MPI_Info mpiHints = MPI_INFO_NULL; - /* Wei-keng Liao: read and set MPI file hints from hintsFile */ + /* read and set MPI file hints from hintsFile */ SetHints(&mpiHints, param->hintsFileName); if (rank == 0 && param->showHints) { fprintf(stdout, "\nhints passed to MPI_File_open() {\n"); @@ -150,22 +151,23 @@ static void *NCMPI_Open(char *testFileName, IOR_param_t * param) NCMPI_CHECK(ncmpi_open(testComm, testFileName, fd_mode, mpiHints, fd), "cannot open file"); - /* Wei-keng Liao: print the MPI file hints currently used */ -/* WEL - add when ncmpi_get_file_info() is in current parallel-netcdf release - if (rank == 0 && param->showHints) { - MPI_CHECK(ncmpi_get_file_info(*fd, &mpiHints), - "cannot get file info"); - fprintf(stdout, "\nhints returned from opened file {\n"); - ShowHints(&mpiHints); - fprintf(stdout, "}\n"); - } -*/ + /* free up the mpiHints object */ + if (mpiHints != MPI_INFO_NULL) + MPI_CHECK(MPI_Info_free(&mpiHints), "cannot free file info"); - /* Wei-keng Liao: free up the mpiHints object */ -/* WEL - this needs future fix from next release of PnetCDF - if (mpiHints != MPI_INFO_NULL) - MPI_CHECK(MPI_Info_free(&mpiHints), "cannot free file info"); -*/ +#if defined(PNETCDF_VERSION_MAJOR) && (PNETCDF_VERSION_MAJOR > 1 || PNETCDF_VERSION_MINOR >= 2) + /* ncmpi_get_file_info is first available in 1.2.0 */ + if (rank == 0 && param->showHints) { + MPI_Info info_used; + MPI_CHECK(ncmpi_get_file_info(*fd, &info_used), + "cannot inquire file info"); + /* print the MPI file hints currently used */ + fprintf(stdout, "\nhints returned from opened file {\n"); + ShowHints(&info_used); + fprintf(stdout, "}\n"); + MPI_CHECK(MPI_Info_free(&info_used), "cannot free file info"); + } +#endif return (fd); } @@ -183,17 +185,6 @@ static IOR_offset_t NCMPI_Xfer(int access, void *fd, IOR_size_t * buffer, IOR_offset_t segmentPosition; int segmentNum, transferNum; - /* Wei-keng Liao: In ior.c line 1979 says "block size must be a multiple - of transfer size." Hence, length should always == param->transferSize - below. I leave it here to double check. - */ - if (length != param->transferSize) { - char errMsg[256]; - sprintf(errMsg, "length(%lld) != param->transferSize(%lld)\n", - length, param->transferSize); - NCMPI_CHECK(-1, errMsg); - } - /* determine by offset if need to start data set */ if (param->filePerProc == TRUE) { segmentPosition = (IOR_offset_t) 0; @@ -224,7 +215,7 @@ static IOR_offset_t NCMPI_Xfer(int access, void *fd, IOR_size_t * buffer, int numTransfers = param->blockSize / param->transferSize; - /* Wei-keng Liao: change 1D array to 3D array of dimensions: + /* reshape 1D array to 3D array: [segmentCount*numTasksWorld][numTransfers][transferSize] Requirement: none of these dimensions should be > 4G, */ @@ -264,13 +255,13 @@ static IOR_offset_t NCMPI_Xfer(int access, void *fd, IOR_size_t * buffer, var_id = param->var_id; - /* Wei-keng Liao: calculate the segment number */ + /* calculate the segment number */ segmentNum = param->offset / (param->numTasks * param->blockSize); - /* Wei-keng Liao: calculate the transfer number in each block */ + /* calculate the transfer number in each block */ transferNum = param->offset % param->blockSize / param->transferSize; - /* Wei-keng Liao: read/write the 3rd dim of the dataset, each is of + /* read/write the 3rd dim of the dataset, each is of amount param->transferSize */ bufSize[0] = 1; bufSize[1] = 1; @@ -381,7 +372,7 @@ static int GetFileMode(IOR_param_t * param) fprintf(stdout, "O_DIRECT not implemented in NCMPI\n"); } - /* Wei-keng Liao: to enable > 4GB file size */ + /* to enable > 4GB file size */ fd_mode |= NC_64BIT_OFFSET; return (fd_mode); From 76f6bb6e421275f1a42b8e804a21c2f1ee78a7c1 Mon Sep 17 00:00:00 2001 From: "Julian M. Kunkel" Date: Wed, 24 Jul 2019 00:29:58 +0100 Subject: [PATCH 15/50] Abort when invalid options are set. --- src/option.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/option.c b/src/option.c index 99f696c..b1833c1 100644 --- a/src/option.c +++ b/src/option.c @@ -381,12 +381,12 @@ int option_parse(int argc, char ** argv, options_all_t * opt_all){ if( requiredArgsSeen != requiredArgsNeeded ){ printf("Error: Missing some required arguments\n\n"); - printhelp = -1; + printhelp = 1; } if(error != 0){ printf("Invalid options\n"); - printhelp = -1; + printhelp = 1; } if(printhelp == 1){ From 7981fc70b12cc21b63dfba99b6b751596df0f49e Mon Sep 17 00:00:00 2001 From: John Bent Date: Thu, 25 Jul 2019 19:18:52 -0600 Subject: [PATCH 16/50] Changed the behavior of shift in mdtest to mimic that in IOR so that it shifts by _entire nodes_ not by ranks. --- src/mdtest.c | 10 ++++++++-- 1 file changed, 8 insertions(+), 2 deletions(-) diff --git a/src/mdtest.c b/src/mdtest.c index 8613e3b..2d15c9f 100644 --- a/src/mdtest.c +++ b/src/mdtest.c @@ -1362,7 +1362,7 @@ void print_help (void) { "\t-p: pre-iteration delay (in seconds)\n" "\t-r: only remove files or directories left behind by previous runs\n" "\t-R: randomly stat files (optional argument for random seed)\n" - "\t-s: stride between the number of tasks for each test\n" + "\t-s: stride between the number of nodes for each test\n" "\t-S: shared file access (file only, no directories)\n" "\t-t: time unique working directory overhead\n" "\t-T: only stat files/dirs\n" @@ -2191,7 +2191,8 @@ mdtest_results_t * mdtest_run(int argc, char **argv, MPI_Comm world_com, FILE * pid = getpid(); uid = getuid(); - nodeCount = size / CountTasksPerNode(testComm); + tasksPerNode = CountTasksPerNode(testComm); + nodeCount = size / tasksPerNode; if (rank == 0) { fprintf(out_logfile, "-- started at %s --\n\n", PrintTimestamp()); @@ -2267,6 +2268,11 @@ mdtest_results_t * mdtest_run(int argc, char **argv, MPI_Comm world_com, FILE * fflush( out_logfile ); } + /* set the shift to mimic IOR and shift by procs per node */ + if (nstride > 0) { + nstride *= tasksPerNode; + } + /* setup total number of items and number of items per dir */ if (depth <= 0) { num_dirs_in_tree = 1; From 524d053be1dd789cd4ba241011f9039def364d96 Mon Sep 17 00:00:00 2001 From: John Bent Date: Fri, 26 Jul 2019 08:55:24 -0600 Subject: [PATCH 17/50] Making shift work in mdtest as well as it works in IOR and on a per-node basis. Also added printing the nodemap so we can check the allocation. --- src/mdtest.c | 16 +++++++++++----- src/utilities.c | 38 ++++++++++++++++++++++++++++++++++++++ src/utilities.h | 1 + 3 files changed, 50 insertions(+), 5 deletions(-) diff --git a/src/mdtest.c b/src/mdtest.c index 2d15c9f..cbb0de8 100644 --- a/src/mdtest.c +++ b/src/mdtest.c @@ -2268,11 +2268,6 @@ mdtest_results_t * mdtest_run(int argc, char **argv, MPI_Comm world_com, FILE * fflush( out_logfile ); } - /* set the shift to mimic IOR and shift by procs per node */ - if (nstride > 0) { - nstride *= tasksPerNode; - } - /* setup total number of items and number of items per dir */ if (depth <= 0) { num_dirs_in_tree = 1; @@ -2381,6 +2376,17 @@ mdtest_results_t * mdtest_run(int argc, char **argv, MPI_Comm world_com, FILE * } if (rank == 0) display_freespace(testdirpath); + int packedByNode = QueryNodeMapping(testComm); + + /* set the shift to mimic IOR and shift by procs per node */ + if (nstride > 0) { + if ( packedByNode ) { + nstride *= tasksPerNode; + } + if (rank == 0) { + fprintf(out_logfile, "Shifting ranks by %d for each phase.\n", nstride); + } + } if (verbose >= 3 && rank == 0) { fprintf(out_logfile, "V-3: main (after display_freespace): testdirpath is \"%s\"\n", testdirpath ); diff --git a/src/utilities.c b/src/utilities.c index c0c7c61..493eb89 100755 --- a/src/utilities.c +++ b/src/utilities.c @@ -213,12 +213,50 @@ void DumpBuffer(void *buffer, return; } /* DumpBuffer() */ +/* a function that prints an int array where each index corresponds to a rank + 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 +*/ +int QueryNodeMapping(MPI_Comm comm) { + char localhost[MAX_PATHLEN], roothost[MAX_PATHLEN]; + int num_ranks; + MPI_Comm_size(comm, &num_ranks); + int *node_map = (int*)malloc(sizeof(int) * num_ranks); + if ( ! node_map ) { + FAIL("malloc"); + } + if (gethostname(localhost, MAX_PATHLEN) != 0) { + FAIL("gethostname()"); + } + if (rank==0) { + strncpy(roothost,localhost,MAX_PATHLEN); + } + + /* have rank 0 broadcast out its hostname */ + MPI_Bcast(roothost, MAX_PATHLEN, MPI_CHAR, 0, comm); + //printf("Rank %d received root host as %s\n", rank, roothost); + /* then every rank figures out whether it is same host as root and then gathers that */ + int same_as_root = strcmp(roothost,localhost) == 0; + MPI_Gather( &same_as_root, 1, MPI_INT, node_map, 1, MPI_INT, 0, comm); + if (rank==0) { + fprintf( out_logfile, "Nodemap: " ); + for ( int i = 0; i < num_ranks; i++ ) { + fprintf( out_logfile, "%d", node_map[i] ); + } + fprintf( out_logfile, "\n" ); + } + int ret = node_map[1] == 1; + free(node_map); + return ret; +} + #if MPI_VERSION >= 3 int CountTasksPerNode(MPI_Comm comm) { /* modern MPI provides a simple way to get the local process count */ MPI_Comm shared_comm; int count; + MPI_Comm_split_type (comm, MPI_COMM_TYPE_SHARED, 0, MPI_INFO_NULL, &shared_comm); MPI_Comm_size (shared_comm, &count); MPI_Comm_free (&shared_comm); diff --git a/src/utilities.h b/src/utilities.h index b646174..d811261 100755 --- a/src/utilities.h +++ b/src/utilities.h @@ -65,6 +65,7 @@ void SetHints (MPI_Info *, char *); void ShowHints (MPI_Info *); char *HumanReadable(IOR_offset_t value, int base); int CountTasksPerNode(MPI_Comm comm); +int QueryNodeMapping(MPI_Comm comm); void DelaySecs(int delay); void updateParsedOptions(IOR_param_t * options, options_all_t * global_options); size_t NodeMemoryStringToBytes(char *size_str); From 945487f7437f56a6e85c9b726a744af1be83c789 Mon Sep 17 00:00:00 2001 From: John Bent Date: Sat, 27 Jul 2019 09:20:20 -0600 Subject: [PATCH 18/50] Better debug message when stat fails --- src/mdtest.c | 18 ++++++------------ 1 file changed, 6 insertions(+), 12 deletions(-) diff --git a/src/mdtest.c b/src/mdtest.c index cbb0de8..d9f28db 100644 --- a/src/mdtest.c +++ b/src/mdtest.c @@ -635,19 +635,13 @@ void mdtest_stat(const int random, const int dirs, const long dir_iter, const ch } if (-1 == backend->stat (item, &buf, ¶m)) { - if (dirs) { - if ( verbose >= 3 ) { - fprintf( out_logfile, "V-3: Stat'ing directory \"%s\"\n", item ); - fflush( out_logfile ); - } - FAIL("unable to stat directory"); - } else { - if ( verbose >= 3 ) { - fprintf( out_logfile, "V-3: Stat'ing file \"%s\"\n", item ); - fflush( out_logfile ); - } - FAIL("unable to stat file"); + char msg_buf[4096]; + if ( verbose >=3 ) { + fprintf( out_logfile, "V-3: Stat'ing %s \"%s\"\n", dirs ? "directory" : "file", item ); + fflush( out_logfile ); } + snprintf(msg_buf, 4096, "unable to stat %s %s", dirs ? "directory" : "file", item); + FAIL("unable to stat directory"); } } } From 9d6480d46e5658a269b6bf7e7022f5ad55fba203 Mon Sep 17 00:00:00 2001 From: John Bent Date: Sat, 27 Jul 2019 11:30:07 -0600 Subject: [PATCH 19/50] Fixed bug in the nstride calculation where only 0 was computing it correctly. Had to bcast it out --- src/mdtest.c | 16 +++++++++++++++- src/utilities.c | 1 + 2 files changed, 16 insertions(+), 1 deletion(-) diff --git a/src/mdtest.c b/src/mdtest.c index d9f28db..072dc29 100644 --- a/src/mdtest.c +++ b/src/mdtest.c @@ -494,6 +494,7 @@ void create_remove_items(int currDepth, const int dirs, const int create, const if (collective) { collective_helper(dirs, create, temp_path, 0, progress); } else { + printf("DEBUG %5d rank %d gonna create %s\n", __LINE__, rank, temp_path); create_remove_items_helper(dirs, create, temp_path, 0, progress); } } @@ -522,6 +523,7 @@ void create_remove_items(int currDepth, const int dirs, const int create, const if (collective) { collective_helper(dirs, create, temp_path, currDir*items_per_dir, progress); } else { + printf("DEBUG %5d rank %d gonna create %s\n", __LINE__, rank, temp_path); create_remove_items_helper(dirs, create, temp_path, currDir*items_per_dir, progress); } } @@ -641,7 +643,7 @@ void mdtest_stat(const int random, const int dirs, const long dir_iter, const ch fflush( out_logfile ); } snprintf(msg_buf, 4096, "unable to stat %s %s", dirs ? "directory" : "file", item); - FAIL("unable to stat directory"); + FAIL(msg_buf); } } } @@ -792,6 +794,7 @@ void collective_create_remove(const int create, const int dirs, const int ntasks sprintf(rm_name, "mdtest.%d.", (i+(3*nstride))%ntasks); } if (unique_dir_per_task) { + printf("DEBUG %5d Rank %d i %d nstride %d ntasks %d", __LINE__, rank, i, nstride, ntasks); sprintf(unique_mk_dir, "%s/mdtest_tree.%d.0", testdir, (i+(0*nstride))%ntasks); sprintf(unique_chdir_dir, "%s/mdtest_tree.%d.0", testdir, @@ -1085,6 +1088,8 @@ void file_test(const int iteration, const int ntasks, const char *path, rank_pro char temp_path[MAX_PATHLEN]; MPI_Comm_size(testComm, &size); + printf("DEBUG %5d Rank %d file_test on %s\n", __LINE__, rank, path); + if (( rank == 0 ) && ( verbose >= 1 )) { fprintf( out_logfile, "V-1: Entering file_test...\n" ); fflush( out_logfile ); @@ -1099,7 +1104,9 @@ void file_test(const int iteration, const int ntasks, const char *path, rank_pro prep_testdir(iteration, dir_iter); if (unique_dir_per_task) { + printf("DEBUG %5d Rank %d operating on %s\n", __LINE__, rank, temp_path); unique_dir_access(MK_UNI_DIR, temp_path); + printf("DEBUG %5d Rank %d operating on %s\n", __LINE__, rank, temp_path); if (!time_unique_dir_overhead) { offset_timers(t, 0); } @@ -1107,6 +1114,8 @@ void file_test(const int iteration, const int ntasks, const char *path, rank_pro sprintf( temp_path, "%s/%s", testdir, path ); } + + if (verbose >= 3 && rank == 0) { fprintf(out_logfile, "V-3: file_test: create path is \"%s\"\n", temp_path ); fflush( out_logfile ); @@ -1250,6 +1259,7 @@ void file_test(const int iteration, const int ntasks, const char *path, rank_pro collective_create_remove(0, 0, ntasks, temp_path, progress); } } else { + printf("DEBUG %5d rank %d gonna create %s\n", __LINE__, rank, temp_path); create_remove_items(0, 0, 0, 0, temp_path, 0, progress); } } @@ -1942,12 +1952,15 @@ static void mdtest_iteration(int i, int j, MPI_Group testgroup, mdtest_results_t sprintf(rm_name, "mdtest.%d.", (rank+(3*nstride))%i); } if (unique_dir_per_task) { + printf("DEBUG %5d Rank %d i %d nstride %d\n", __LINE__, rank, i, nstride); sprintf(unique_mk_dir, "mdtest_tree.%d.0", (rank+(0*nstride))%i); sprintf(unique_chdir_dir, "mdtest_tree.%d.0", (rank+(1*nstride))%i); sprintf(unique_stat_dir, "mdtest_tree.%d.0", (rank+(2*nstride))%i); sprintf(unique_read_dir, "mdtest_tree.%d.0", (rank+(3*nstride))%i); sprintf(unique_rm_dir, "mdtest_tree.%d.0", (rank+(4*nstride))%i); unique_rm_uni_dir[0] = 0; + printf("DEBUG %5d Rank %d mk_dir %s chdir %s stat_dir %s read_dir %s rm_dir %s\n", __LINE__, + rank, unique_mk_dir,unique_chdir_dir,unique_stat_dir,unique_read_dir,unique_rm_dir); } if (verbose >= 3 && rank == 0) { @@ -1965,6 +1978,7 @@ static void mdtest_iteration(int i, int j, MPI_Group testgroup, mdtest_results_t if (pre_delay) { DelaySecs(pre_delay); } + printf("DEBUG %5d Rank %d gonna file_test on %s\n", __LINE__, rank, unique_mk_dir); file_test(j, i, unique_mk_dir, progress); } } diff --git a/src/utilities.c b/src/utilities.c index 493eb89..5a3168c 100755 --- a/src/utilities.c +++ b/src/utilities.c @@ -246,6 +246,7 @@ int QueryNodeMapping(MPI_Comm comm) { fprintf( out_logfile, "\n" ); } int ret = node_map[1] == 1; + MPI_Bcast(&ret, 1, MPI_INT, 0, comm); free(node_map); return ret; } From f6491fcd37d9365fd0b2d502d4d3a79b5af755a0 Mon Sep 17 00:00:00 2001 From: John Bent Date: Sat, 27 Jul 2019 13:22:15 -0600 Subject: [PATCH 20/50] Cleaned up the verbose messages by creating a macro and a function --- src/mdtest.c | 546 ++++++++++++++------------------------------------- 1 file changed, 147 insertions(+), 399 deletions(-) diff --git a/src/mdtest.c b/src/mdtest.c index 072dc29..bfeeda1 100644 --- a/src/mdtest.c +++ b/src/mdtest.c @@ -36,6 +36,7 @@ #include #include #include +#include #include "option.h" #include "utilities.h" @@ -173,16 +174,30 @@ typedef struct{ /* for making/removing unique directory && stating/deleting subdirectory */ enum {MK_UNI_DIR, STAT_SUB_DIR, READ_SUB_DIR, RM_SUB_DIR, RM_UNI_DIR}; +/* a helper function for passing debug and verbose messages. + use the MACRO as it will insert __LINE__ for you. + Pass the verbose level for root to print, then the verbose level for anyone to print. + Pass -1 to suppress the print for anyone. + Then do the standard printf stuff. This function adds the newline for you. +*/ +#define VERBOSE(root,any,...) VerboseMessage(root,any,__LINE__,__VA_ARGS__) +void VerboseMessage (int root_level, int any_level, int line, char * format, ...) { + if ((rank==0 && verbose >= root_level) || (any_level > 0 && verbose >= any_level)) { + char buffer[1024]; + va_list args; + va_start (args, format); + vsnprintf (buffer, 1024, format, args); + va_end (args); + fprintf( out_logfile, "V-%d: Rank %3d Line %5d %s\n", root_level, rank, line, buffer ); + } +} void offset_timers(double * t, int tcount) { double toffset; int i; - if (( rank == 0 ) && ( verbose >= 1 )) { - fprintf( out_logfile, "V-1: Entering offset_timers...\n" ); - fflush( out_logfile ); - } + VERBOSE(1,-1,"V-1: Entering offset_timers..." ); toffset = GetTimeStamp() - t[tcount]; for (i = 0; i < tcount+1; i++) { @@ -196,10 +211,7 @@ void parse_dirpath(char *dirpath_arg) { int i = 0; - if (( rank == 0 ) && ( verbose >= 1 )) { - fprintf( out_logfile, "V-1: Entering parse_dirpath...\n" ); - fflush( out_logfile ); - } + VERBOSE(1,-1, "Entering parse_dirpath..." ); tmp = dirpath_arg; @@ -240,10 +252,7 @@ static void prep_testdir(int j, int dir_iter){ */ void unique_dir_access(int opt, char *to) { - if (( rank == 0 ) && ( verbose >= 1 )) { - fprintf( out_logfile, "V-1: Entering unique_dir_access...\n" ); - fflush( out_logfile ); - } + VERBOSE(1,-1,"Entering unique_dir_access..." ); if (opt == MK_UNI_DIR) { MPI_Barrier(testComm); @@ -263,20 +272,13 @@ static void create_remove_dirs (const char *path, bool create, uint64_t itemNum) char curr_item[MAX_PATHLEN]; const char *operation = create ? "create" : "remove"; - if (( rank == 0 ) && - ( verbose >= 3 ) && - (itemNum % ITEM_COUNT==0 && (itemNum != 0))) { - - fprintf(out_logfile, "V-3: %s dir: "LLU"\n", operation, itemNum); - fflush(out_logfile); + if ( (itemNum % ITEM_COUNT==0 && (itemNum != 0))) { + VERBOSE(3,5,"dir: "LLU"", operation, itemNum); } //create dirs sprintf(curr_item, "%s/dir.%s%" PRIu64, path, create ? mk_name : rm_name, itemNum); - if (verbose >= 5 || (rank == 0 && verbose >= 3)) { - fprintf(out_logfile, "V-3: create_remove_items_helper (dirs %s): curr_item is \"%s\"\n", operation, curr_item); - fflush(out_logfile); - } + VERBOSE(3,5,"create_remove_items_helper (dirs %s): curr_item is \"%s\"", operation, curr_item); if (create) { if (backend->mkdir(curr_item, DIRMODE, ¶m) == -1) { @@ -292,20 +294,13 @@ static void create_remove_dirs (const char *path, bool create, uint64_t itemNum) static void remove_file (const char *path, uint64_t itemNum) { char curr_item[MAX_PATHLEN]; - if (( rank == 0 ) && - ( verbose >= 3 ) && - (itemNum % ITEM_COUNT==0 && (itemNum != 0))) { - - fprintf(out_logfile, "V-3: remove file: "LLU"\n", itemNum); - fflush(out_logfile); + if ( (itemNum % ITEM_COUNT==0 && (itemNum != 0))) { + VERBOSE(3,5,"remove file: "LLU"\n", itemNum); } //remove files sprintf(curr_item, "%s/file.%s"LLU"", path, rm_name, itemNum); - if (verbose >= 5 || (rank == 0 && verbose >= 3)) { - fprintf(out_logfile, "V-3: create_remove_items_helper (non-dirs remove): curr_item is \"%s\"\n", curr_item); - fflush(out_logfile); - } + VERBOSE(3,5,"create_remove_items_helper (non-dirs remove): curr_item is \"%s\"", curr_item); if (!(shared_file && rank != 0)) { backend->delete (curr_item, ¶m); } @@ -315,28 +310,18 @@ static void create_file (const char *path, uint64_t itemNum) { char curr_item[MAX_PATHLEN]; void *aiori_fh; - if (( rank == 0 ) && - ( verbose >= 3 ) && - (itemNum % ITEM_COUNT==0 && (itemNum != 0))) { - - fprintf(out_logfile, "V-3: create file: "LLU"\n", itemNum); - fflush(out_logfile); + if ( (itemNum % ITEM_COUNT==0 && (itemNum != 0))) { + VERBOSE(3,5,"create file: "LLU"", itemNum); } //create files sprintf(curr_item, "%s/file.%s"LLU"", path, mk_name, itemNum); - if ((rank == 0 && verbose >= 3) || verbose >= 5) { - fprintf(out_logfile, "V-3: create_remove_items_helper (non-dirs create): curr_item is \"%s\"\n", curr_item); - fflush(out_logfile); - } + VERBOSE(3,5,"create_remove_items_helper (non-dirs create): curr_item is \"%s\"", curr_item); if (collective_creates) { param.openFlags = IOR_WRONLY; - if (verbose >= 5 || (rank == 0 && verbose >= 3)) { - fprintf(out_logfile, "V-3: create_remove_items_helper (collective): open...\n" ); - fflush( out_logfile ); - } + VERBOSE(3,5,"create_remove_items_helper (collective): open..." ); if (make_node) aiori_fh = backend->mknod (curr_item); @@ -353,10 +338,7 @@ static void create_file (const char *path, uint64_t itemNum) { param.openFlags = IOR_CREAT | IOR_WRONLY; param.filePerProc = !shared_file; - if (verbose >= 5 || (rank == 0 && verbose >= 3)) { - fprintf(out_logfile, "V-3: create_remove_items_helper (non-collective, shared): open...\n" ); - fflush( out_logfile ); - } + VERBOSE(3,5,"create_remove_items_helper (non-collective, shared): open..." ); if (make_node) aiori_fh = backend->mknod (curr_item); @@ -368,10 +350,7 @@ static void create_file (const char *path, uint64_t itemNum) { } if (write_bytes > 0) { - if (verbose >= 5 || (rank == 0 && verbose >= 3)) { - fprintf(out_logfile, "V-3: create_remove_items_helper: write...\n" ); - fflush( out_logfile ); - } + VERBOSE(3,5,"create_remove_items_helper: write..." ); /* * According to Bill Loewe, writes are only done one time, so they are always at @@ -384,10 +363,7 @@ static void create_file (const char *path, uint64_t itemNum) { } } - if (verbose >= 5 || (rank == 0 && verbose >= 3)) { - fprintf(out_logfile, "V-3: create_remove_items_helper: close...\n" ); - fflush( out_logfile ); - } + VERBOSE(3,5,"create_remove_items_helper: close..." ); if (!make_node) backend->close (aiori_fh, ¶m); @@ -397,10 +373,7 @@ static void create_file (const char *path, uint64_t itemNum) { void create_remove_items_helper(const int dirs, const int create, const char *path, uint64_t itemNum, rank_progress_t * progress) { - if (( rank == 0 ) && ( verbose >= 1 )) { - fprintf( out_logfile, "V-1: Entering create_remove_items_helper...\n" ); - fflush( out_logfile ); - } + VERBOSE(1,-1,"Entering create_remove_items_helper..." ); for (uint64_t i = progress->items_start; i < progress->items_per_dir ; ++i) { if (!dirs) { @@ -426,10 +399,7 @@ void create_remove_items_helper(const int dirs, const int create, const char *pa void collective_helper(const int dirs, const int create, const char* path, uint64_t itemNum, rank_progress_t * progress) { char curr_item[MAX_PATHLEN]; - if (( rank == 0 ) && ( verbose >= 1 )) { - fprintf( out_logfile, "V-1: Entering collective_helper...\n" ); - fflush( out_logfile ); - } + VERBOSE(1,-1,"Entering collective_helper..." ); for (uint64_t i = progress->items_start ; i < progress->items_per_dir ; ++i) { if (dirs) { create_remove_dirs (path, create, itemNum + i); @@ -437,10 +407,7 @@ void collective_helper(const int dirs, const int create, const char* path, uint6 } sprintf(curr_item, "%s/file.%s"LLU"", path, create ? mk_name : rm_name, itemNum+i); - if (verbose >= 5 || (rank == 0 && verbose >= 3)) { - fprintf(out_logfile, "V-3: create file: %s\n", curr_item); - fflush(out_logfile); - } + VERBOSE(3,5,"create file: %s", curr_item); if (create) { void *aiori_fh; @@ -474,19 +441,13 @@ void create_remove_items(int currDepth, const int dirs, const int create, const unsigned long long currDir = dirNum; - if (( rank == 0 ) && ( verbose >= 1 )) { - fprintf( out_logfile, "V-1: Entering create_remove_items, currDepth = %d...\n", currDepth ); - fflush( out_logfile ); - } + VERBOSE(1,-1,"Entering create_remove_items, currDepth = %d...", currDepth ); memset(dir, 0, MAX_PATHLEN); strcpy(temp_path, path); - if (verbose >= 5 || (rank == 0 && verbose >= 3)) { - fprintf(out_logfile, "V-3: create_remove_items (start): temp_path is \"%s\"\n", temp_path ); - fflush(out_logfile); - } + VERBOSE(3,5,"create_remove_items (start): temp_path is \"%s\"", temp_path ); if (currDepth == 0) { /* create items at this depth */ @@ -513,10 +474,7 @@ void create_remove_items(int currDepth, const int dirs, const int create, const strcat(temp_path, "/"); strcat(temp_path, dir); - if (verbose >= 5 || (rank == 0 && verbose >= 3)) { - fprintf(out_logfile, "V-3: create_remove_items (for loop): temp_path is \"%s\"\n", temp_path ); - fflush(out_logfile); - } + VERBOSE(3,5,"create_remove_items (for loop): temp_path is \"%s\"", temp_path ); /* create the items in this branch */ if (!leaf_only || (leaf_only && currDepth == depth)) { @@ -553,10 +511,7 @@ void mdtest_stat(const int random, const int dirs, const long dir_iter, const ch uint64_t parent_dir, item_num = 0; char item[MAX_PATHLEN], temp[MAX_PATHLEN]; - if (( rank == 0 ) && ( verbose >= 1 )) { - fprintf( out_logfile, "V-1: Entering mdtest_stat...\n" ); - fflush( out_logfile ); - } + VERBOSE(1,-1,"Entering mdtest_stat..." ); uint64_t stop_items = items; @@ -592,15 +547,13 @@ void mdtest_stat(const int random, const int dirs, const long dir_iter, const ch /* create name of file/dir to stat */ if (dirs) { - if ((verbose >= 5 || (rank == 0 && verbose >= 3)) && (i%ITEM_COUNT == 0) && (i != 0)) { - fprintf(out_logfile, "V-3: stat dir: "LLU"\n", i); - fflush(out_logfile); + if ((i%ITEM_COUNT == 0) && (i != 0)) { + VERBOSE(3,5,"stat dir: "LLU"", i); } sprintf(item, "dir.%s"LLU"", stat_name, item_num); } else { - if ((verbose >= 5 || (rank == 0 && verbose >= 3)) && (i%ITEM_COUNT == 0) && (i != 0)) { - fprintf(out_logfile, "V-3: stat file: "LLU"\n", i); - fflush(out_logfile); + if ((i%ITEM_COUNT == 0) && (i != 0)) { + VERBOSE(3,5,"stat file: "LLU"", i); } sprintf(item, "file.%s"LLU"", stat_name, item_num); } @@ -627,21 +580,9 @@ void mdtest_stat(const int random, const int dirs, const long dir_iter, const ch strcpy( item, temp ); /* below temp used to be hiername */ - if (verbose >= 5 || (rank == 0 && verbose >= 3)) { - if (dirs) { - fprintf(out_logfile, "V-3: mdtest_stat dir : %s\n", item); - } else { - fprintf(out_logfile, "V-3: mdtest_stat file: %s\n", item); - } - fflush(out_logfile); - } - + VERBOSE(3,5,"mdtest_stat %4s: %s", (dirs ? "dir" : "file"), item); if (-1 == backend->stat (item, &buf, ¶m)) { char msg_buf[4096]; - if ( verbose >=3 ) { - fprintf( out_logfile, "V-3: Stat'ing %s \"%s\"\n", dirs ? "directory" : "file", item ); - fflush( out_logfile ); - } snprintf(msg_buf, 4096, "unable to stat %s %s", dirs ? "directory" : "file", item); FAIL(msg_buf); } @@ -655,10 +596,7 @@ void mdtest_read(int random, int dirs, const long dir_iter, char *path) { char item[MAX_PATHLEN], temp[MAX_PATHLEN]; void *aiori_fh; - if (( rank == 0 ) && ( verbose >= 1 )) { - fprintf( out_logfile, "V-1: Entering mdtest_read...\n" ); - fflush( out_logfile ); - } + VERBOSE(1,-1,"Entering mdtest_read..." ); /* allocate read buffer */ if (read_bytes > 0) { @@ -703,9 +641,8 @@ void mdtest_read(int random, int dirs, const long dir_iter, char *path) { /* create name of file to read */ if (!dirs) { - if ((verbose >= 5 || (rank == 0 && verbose >= 3)) && (i%ITEM_COUNT == 0) && (i != 0)) { - fprintf(out_logfile, "V-3: read file: "LLU"\n", i); - fflush(out_logfile); + if ((i%ITEM_COUNT == 0) && (i != 0)) { + VERBOSE(3,5,"read file: "LLU"", i); } sprintf(item, "file.%s"LLU"", read_name, item_num); } @@ -732,12 +669,7 @@ void mdtest_read(int random, int dirs, const long dir_iter, char *path) { strcpy( item, temp ); /* below temp used to be hiername */ - if (verbose >= 5 || (rank == 0 && verbose >= 3)) { - if (!dirs) { - fprintf(out_logfile, "V-3: mdtest_read file: %s\n", item); - } - fflush(out_logfile); - } + VERBOSE(3,5,"mdtest_read file: %s", item); /* open file for reading */ param.openFlags = O_RDONLY; @@ -763,10 +695,7 @@ void mdtest_read(int random, int dirs, const long dir_iter, char *path) { void collective_create_remove(const int create, const int dirs, const int ntasks, const char *path, rank_progress_t * progress) { char temp[MAX_PATHLEN]; - if (( rank == 0 ) && ( verbose >= 1 )) { - fprintf( out_logfile, "V-1: Entering collective_create_remove...\n" ); - fflush( out_logfile ); - } + VERBOSE(1,-1,"Entering collective_create_remove on %s", path ); /* rank 0 does all of the creates and removes for all of the ranks */ for (int i = 0 ; i < ntasks ; ++i) { @@ -794,7 +723,7 @@ void collective_create_remove(const int create, const int dirs, const int ntasks sprintf(rm_name, "mdtest.%d.", (i+(3*nstride))%ntasks); } if (unique_dir_per_task) { - printf("DEBUG %5d Rank %d i %d nstride %d ntasks %d", __LINE__, rank, i, nstride, ntasks); + VERBOSE(3,5,"i %d nstride %d ntasks %d", i, nstride, ntasks); sprintf(unique_mk_dir, "%s/mdtest_tree.%d.0", testdir, (i+(0*nstride))%ntasks); sprintf(unique_chdir_dir, "%s/mdtest_tree.%d.0", testdir, @@ -809,10 +738,7 @@ void collective_create_remove(const int create, const int dirs, const int ntasks } /* Now that everything is set up as it should be, do the create or remove */ - if (verbose >= 5 || (rank == 0 && verbose >= 3)) { - fprintf(out_logfile, "V-3: collective_create_remove (create_remove_items): temp is \"%s\"\n", temp); - fflush( out_logfile ); - } + VERBOSE(3,5,"collective_create_remove (create_remove_items): temp is \"%s\"", temp); create_remove_items(0, dirs, create, 1, temp, 0, progress); } @@ -851,10 +777,7 @@ void directory_test(const int iteration, const int ntasks, const char *path, ran MPI_Comm_size(testComm, &size); - if (( rank == 0 ) && ( verbose >= 1 )) { - fprintf( out_logfile, "V-1: Entering directory_test...\n" ); - fflush( out_logfile ); - } + VERBOSE(1,-1,"Entering directory_test on %s", path ); MPI_Barrier(testComm); t[0] = GetTimeStamp(); @@ -872,10 +795,7 @@ void directory_test(const int iteration, const int ntasks, const char *path, ran sprintf( temp_path, "%s/%s", testdir, path ); } - if (verbose >= 3 && rank == 0) { - fprintf(out_logfile, "V-3: directory_test: create path is \"%s\"\n", temp_path ); - fflush( out_logfile ); - } + VERBOSE(3,-1,"directory_test: create path is \"%s\"", temp_path ); /* "touch" the files */ if (collective_creates) { @@ -907,10 +827,7 @@ void directory_test(const int iteration, const int ntasks, const char *path, ran sprintf( temp_path, "%s/%s", testdir, path ); } - if (verbose >= 3 && rank == 0) { - fprintf(out_logfile, "V-3: directory_test: stat path is \"%s\"\n", temp_path ); - fflush( out_logfile ); - } + VERBOSE(3,5,"stat path is \"%s\"", temp_path ); /* stat directories */ if (random_seed > 0) { @@ -939,10 +856,7 @@ void directory_test(const int iteration, const int ntasks, const char *path, ran sprintf( temp_path, "%s/%s", testdir, path ); } - if (verbose >= 3 && rank == 0) { - fprintf(out_logfile, "V-3: directory_test: read path is \"%s\"\n", temp_path ); - fflush( out_logfile ); - } + VERBOSE(3,5,"directory_test: read path is \"%s\"", temp_path ); /* read directories */ if (random_seed > 0) { @@ -970,10 +884,7 @@ void directory_test(const int iteration, const int ntasks, const char *path, ran sprintf( temp_path, "%s/%s", testdir, path ); } - if (verbose >= 3 && rank == 0) { - fprintf(out_logfile, "V-3: directory_test: remove directories path is \"%s\"\n", temp_path ); - fflush( out_logfile ); - } + VERBOSE(3,5,"directory_test: remove directories path is \"%s\"", temp_path ); /* remove directories */ if (collective_creates) { @@ -998,10 +909,7 @@ void directory_test(const int iteration, const int ntasks, const char *path, ran sprintf( temp_path, "%s/%s", testdir, path ); } - if (verbose >= 3 && rank == 0) { - fprintf(out_logfile, "V-3: directory_test: remove unique directories path is \"%s\"\n", temp_path ); - fflush( out_logfile ); - } + VERBOSE(3,5,"directory_test: remove unique directories path is \"%s\"\n", temp_path ); } if (unique_dir_per_task && !time_unique_dir_overhead) { @@ -1034,30 +942,21 @@ void directory_test(const int iteration, const int ntasks, const char *path, ran summary_table[iteration].stonewall_last_item[3] = items; } - if (verbose >= 1 && rank == 0) { - fprintf(out_logfile, "V-1: Directory creation: %14.3f sec, %14.3f ops/sec\n", - t[1] - t[0], summary_table[iteration].rate[0]); - fprintf(out_logfile, "V-1: Directory stat : %14.3f sec, %14.3f ops/sec\n", - t[2] - t[1], summary_table[iteration].rate[1]); -/* N/A - fprintf(out_logfile, "V-1: Directory read : %14.3f sec, %14.3f ops/sec\n", - t[3] - t[2], summary_table[iteration].rate[2]); -*/ - fprintf(out_logfile, "V-1: Directory removal : %14.3f sec, %14.3f ops/sec\n", - t[4] - t[3], summary_table[iteration].rate[3]); - fflush(out_logfile); - } + VERBOSE(1,-1," Directory creation: %14.3f sec, %14.3f ops/sec\n", t[1] - t[0], summary_table[iteration].rate[0]); + VERBOSE(1,-1," Directory stat : %14.3f sec, %14.3f ops/sec\n", t[2] - t[1], summary_table[iteration].rate[1]); + /* N/A + VERBOSE(1,-1," Directory read : %14.3f sec, %14.3f ops/sec\n", t[3] - t[2], summary_table[iteration].rate[2]); + */ + VERBOSE(1,-1," Directory removal : %14.3f sec, %14.3f ops/sec\n", t[4] - t[3], summary_table[iteration].rate[3]); } /* Returns if the stonewall was hit */ int updateStoneWallIterations(int iteration, rank_progress_t * progress, double tstart){ int hit = 0; - if (verbose >= 1 ) { - fprintf( out_logfile, "V-1: rank %d stonewall hit with %lld items\n", rank, (long long) progress->items_done ); - fflush( out_logfile ); - } uint64_t done = progress->items_done; long long unsigned max_iter = 0; + + VERBOSE(1,1,"stonewall hit with %lld items", (long long) progress->items_done ); MPI_Allreduce(& progress->items_done, & max_iter, 1, MPI_LONG_LONG_INT, MPI_MAX, testComm); summary_table[iteration].stonewall_time[MDTEST_FILE_CREATE_NUM] = GetTimeStamp() - tstart; @@ -1088,12 +987,7 @@ void file_test(const int iteration, const int ntasks, const char *path, rank_pro char temp_path[MAX_PATHLEN]; MPI_Comm_size(testComm, &size); - printf("DEBUG %5d Rank %d file_test on %s\n", __LINE__, rank, path); - - if (( rank == 0 ) && ( verbose >= 1 )) { - fprintf( out_logfile, "V-1: Entering file_test...\n" ); - fflush( out_logfile ); - } + VERBOSE(3,5,"Entering file_test on %s", path); MPI_Barrier(testComm); t[0] = GetTimeStamp(); @@ -1104,9 +998,8 @@ void file_test(const int iteration, const int ntasks, const char *path, rank_pro prep_testdir(iteration, dir_iter); if (unique_dir_per_task) { - printf("DEBUG %5d Rank %d operating on %s\n", __LINE__, rank, temp_path); unique_dir_access(MK_UNI_DIR, temp_path); - printf("DEBUG %5d Rank %d operating on %s\n", __LINE__, rank, temp_path); + VERBOSE(5,5,"operating on %s", temp_path); if (!time_unique_dir_overhead) { offset_timers(t, 0); } @@ -1116,10 +1009,7 @@ void file_test(const int iteration, const int ntasks, const char *path, rank_pro - if (verbose >= 3 && rank == 0) { - fprintf(out_logfile, "V-3: file_test: create path is \"%s\"\n", temp_path ); - fflush( out_logfile ); - } + VERBOSE(3,-1,"file_test: create path is \"%s\"", temp_path ); /* "touch" the files */ if (collective_creates) { @@ -1136,9 +1026,7 @@ void file_test(const int iteration, const int ntasks, const char *path, rank_pro if (hit){ progress->stone_wall_timer_seconds = 0; - if (verbose > 1){ - printf("stonewall rank %d: %lld of %lld \n", rank, (long long) progress->items_start, (long long) progress->items_per_dir); - } + VERBOSE(1,1,"stonewall: %lld of %lld", (long long) progress->items_start, (long long) progress->items_per_dir); create_remove_items(0, 0, 1, 0, temp_path, 0, progress); // now reset the values progress->stone_wall_timer_seconds = stone_wall_timer_seconds; @@ -1163,8 +1051,8 @@ void file_test(const int iteration, const int ntasks, const char *path, rank_pro if (rank == 0) { if(expected_items == -1){ fprintf(out_logfile, "WARNING: could not read stonewall status file\n"); - }else if(verbose >= 1){ - fprintf(out_logfile, "Read stonewall status; items: "LLU"\n", items); + }else { + VERBOSE(1,1, "Read stonewall status; items: "LLU"\n", items); } } } @@ -1188,10 +1076,7 @@ void file_test(const int iteration, const int ntasks, const char *path, rank_pro sprintf( temp_path, "%s/%s", testdir, path ); } - if (verbose >= 3 && rank == 0) { - fprintf(out_logfile, "V-3: file_test: stat path is \"%s\"\n", temp_path ); - fflush( out_logfile ); - } + VERBOSE(3,5,"file_test: stat path is \"%s\"", temp_path ); /* stat files */ mdtest_stat((random_seed > 0 ? 1 : 0), 0, dir_iter, temp_path, progress); @@ -1216,10 +1101,7 @@ void file_test(const int iteration, const int ntasks, const char *path, rank_pro sprintf( temp_path, "%s/%s", testdir, path ); } - if (verbose >= 3 && rank == 0) { - fprintf(out_logfile, "V-3: file_test: read path is \"%s\"\n", temp_path ); - fflush( out_logfile ); - } + VERBOSE(3,5,"file_test: read path is \"%s\"", temp_path ); /* read files */ if (random_seed > 0) { @@ -1249,17 +1131,14 @@ void file_test(const int iteration, const int ntasks, const char *path, rank_pro sprintf( temp_path, "%s/%s", testdir, path ); } - if (verbose >= 3 && rank == 0) { - fprintf(out_logfile, "V-3: file_test: rm directories path is \"%s\"\n", temp_path ); - fflush( out_logfile ); - } + VERBOSE(3,5,"file_test: rm directories path is \"%s\"", temp_path ); if (collective_creates) { if (rank == 0) { collective_create_remove(0, 0, ntasks, temp_path, progress); } } else { - printf("DEBUG %5d rank %d gonna create %s\n", __LINE__, rank, temp_path); + VERBOSE(3,5,"gonna create %s", temp_path); create_remove_items(0, 0, 0, 0, temp_path, 0, progress); } } @@ -1276,10 +1155,7 @@ void file_test(const int iteration, const int ntasks, const char *path, rank_pro strcpy( temp_path, path ); } - if (verbose >= 3 && rank == 0) { - fprintf(out_logfile, "V-3: file_test: rm unique directories path is \"%s\"\n", temp_path ); - fflush( out_logfile ); - } + VERBOSE(3,5,"file_test: rm unique directories path is \"%s\"", temp_path ); } if (unique_dir_per_task && !time_unique_dir_overhead) { @@ -1316,17 +1192,10 @@ void file_test(const int iteration, const int ntasks, const char *path, rank_pro summary_table[iteration].stonewall_last_item[7] = items; } - if (verbose >= 1 && rank == 0) { - fprintf(out_logfile, "V-1: File creation : %14.3f sec, %14.3f ops/sec\n", - t[1] - t[0], summary_table[iteration].rate[4]); - fprintf(out_logfile, "V-1: File stat : %14.3f sec, %14.3f ops/sec\n", - t[2] - t[1], summary_table[iteration].rate[5]); - fprintf(out_logfile, "V-1: File read : %14.3f sec, %14.3f ops/sec\n", - t[3] - t[2], summary_table[iteration].rate[6]); - fprintf(out_logfile, "V-1: File removal : %14.3f sec, %14.3f ops/sec\n", - t[4] - t[3], summary_table[iteration].rate[7]); - fflush(out_logfile); - } + VERBOSE(1,-1," File creation : %14.3f sec, %14.3f ops/sec", t[1] - t[0], summary_table[iteration].rate[4]); + VERBOSE(1,-1," File stat : %14.3f sec, %14.3f ops/sec", t[2] - t[1], summary_table[iteration].rate[5]); + VERBOSE(1,-1," File read : %14.3f sec, %14.3f ops/sec", t[3] - t[2], summary_table[iteration].rate[6]); + VERBOSE(1,-1," File removal : %14.3f sec, %14.3f ops/sec", t[4] - t[3], summary_table[iteration].rate[7]); } void print_help (void) { @@ -1398,10 +1267,7 @@ void summarize_results(int iterations) { double all[iterations * size * tableSize]; - if (( rank == 0 ) && ( verbose >= 1 )) { - fprintf( out_logfile, "V-1: Entering summarize_results...\n" ); - fflush( out_logfile ); - } + VERBOSE(1,-1,"Entering summarize_results..." ); MPI_Barrier(testComm); for(int i=0; i < iterations; i++){ @@ -1544,16 +1410,10 @@ void valid_tests() { if (!create_only && !stat_only && !read_only && !remove_only) { create_only = stat_only = read_only = remove_only = 1; - if (( rank == 0 ) && ( verbose >= 1 )) { - fprintf( out_logfile, "V-1: main: Setting create/stat/read/remove_only to True\n" ); - fflush( out_logfile ); - } + VERBOSE(1,-1,"main: Setting create/stat/read/remove_only to True" ); } - if (( rank == 0 ) && ( verbose >= 1 )) { - fprintf( out_logfile, "V-1: Entering valid_tests...\n" ); - fflush( out_logfile ); - } + VERBOSE(1,-1,"Entering valid_tests..." ); /* if dirs_only and files_only were both left unset, set both now */ if (!dirs_only && !files_only) { @@ -1645,10 +1505,7 @@ void show_file_system_size(char *file_system) { ior_aiori_statfs_t stat_buf; int ret; - if (( rank == 0 ) && ( verbose >= 1 )) { - fprintf( out_logfile, "V-1: Entering show_file_system_size...\n" ); - fflush( out_logfile ); - } + VERBOSE(1,-1,"Entering show_file_system_size..." ); ret = backend->statfs (file_system, &stat_buf, ¶m); if (0 != ret) { @@ -1699,15 +1556,7 @@ void display_freespace(char *testdirpath) int directoryFound = 0; - if (( rank == 0 ) && ( verbose >= 1 )) { - fprintf( out_logfile, "V-1: Entering display_freespace...\n" ); - fflush( out_logfile ); - } - - if (verbose >= 3 && rank == 0) { - fprintf(out_logfile, "V-3: testdirpath is \"%s\"\n", testdirpath ); - fflush( out_logfile ); - } + VERBOSE(3,5,"Entering display_freespace on %s...", testdirpath ); strcpy(dirpath, testdirpath); @@ -1726,17 +1575,9 @@ void display_freespace(char *testdirpath) strcpy(dirpath, "."); } - if (verbose >= 3 && rank == 0) { - fprintf(out_logfile, "V-3: Before show_file_system_size, dirpath is \"%s\"\n", dirpath ); - fflush( out_logfile ); - } - + VERBOSE(3,5,"Before show_file_system_size, dirpath is \"%s\"", dirpath ); show_file_system_size(dirpath); - - if (verbose >= 3 && rank == 0) { - fprintf(out_logfile, "V-3: After show_file_system_size, dirpath is \"%s\"\n", dirpath ); - fflush( out_logfile ); - } + VERBOSE(3,5, "After show_file_system_size, dirpath is \"%s\"\n", dirpath ); return; } @@ -1748,20 +1589,13 @@ void create_remove_directory_tree(int create, char dir[MAX_PATHLEN]; - if (( rank == 0 ) && ( verbose >= 1 )) { - fprintf( out_logfile, "V-1: Entering create_remove_directory_tree, currDepth = %d...\n", currDepth ); - fflush( out_logfile ); - } + VERBOSE(1,5,"Entering create_remove_directory_tree on %s, currDepth = %d...", path, currDepth ); if (currDepth == 0) { sprintf(dir, "%s/%s.%d/", path, base_tree_name, dirNum); if (create) { - if (rank == 0 && verbose >= 2) { - fprintf(out_logfile, "V-2: Making directory \"%s\"\n", dir); - fflush(out_logfile); - } - + VERBOSE(2,5,"Making directory \"%s\"", dir); if (-1 == backend->mkdir (dir, DIRMODE, ¶m)) { fprintf(out_logfile, "error could not create directory \"%s\"\n", dir); } @@ -1770,11 +1604,7 @@ void create_remove_directory_tree(int create, create_remove_directory_tree(create, ++currDepth, dir, ++dirNum, progress); if (!create) { - if (rank == 0 && verbose >= 2) { - fprintf(out_logfile, "V-2: Remove directory \"%s\"\n", dir); - fflush(out_logfile); - } - + VERBOSE(2,5,"Remove directory \"%s\"", dir); if (-1 == backend->rmdir(dir, ¶m)) { FAIL("Unable to remove directory"); } @@ -1790,11 +1620,7 @@ void create_remove_directory_tree(int create, strcat(temp_path, dir); if (create) { - if (rank == 0 && verbose >= 2) { - fprintf(out_logfile, "V-2: Making directory \"%s\"\n", temp_path); - fflush(out_logfile); - } - + VERBOSE(2,5,"Making directory \"%s\"", temp_path); if (-1 == backend->mkdir(temp_path, DIRMODE, ¶m)) { FAIL("Unable to create directory"); } @@ -1805,11 +1631,7 @@ void create_remove_directory_tree(int create, currDepth--; if (!create) { - if (rank == 0 && verbose >= 2) { - fprintf(out_logfile, "V-2: Remove directory \"%s\"\n", temp_path); - fflush(out_logfile); - } - + VERBOSE(2,5,"Remove directory \"%s\"", temp_path); if (-1 == backend->rmdir(temp_path, ¶m)) { FAIL("Unable to remove directory"); } @@ -1833,18 +1655,12 @@ static void mdtest_iteration(int i, int j, MPI_Group testgroup, mdtest_results_t double startCreate, endCreate; int k; - if (rank == 0 && verbose >= 1) { - fprintf(out_logfile, "V-1: main: * iteration %d *\n", j+1); - fflush(out_logfile); - } + VERBOSE(1,-1,"main: * iteration %d *", j+1); for (int dir_iter = 0; dir_iter < directory_loops; dir_iter ++){ prep_testdir(j, dir_iter); - if (verbose >= 2 && rank == 0) { - fprintf(out_logfile, "V-2: main (for j loop): making testdir, \"%s\"\n", testdir ); - fflush( out_logfile ); - } + VERBOSE(2,5,"main (for j loop): making testdir, \"%s\"", testdir ); if ((rank < path_count) && backend->access(testdir, F_OK, ¶m) != 0) { if (backend->mkdir(testdir, DIRMODE, ¶m) != 0) { FAIL("Unable to create test directory"); @@ -1869,13 +1685,7 @@ static void mdtest_iteration(int i, int j, MPI_Group testgroup, mdtest_results_t for (k=0; k= 3 && rank == 0) { - fprintf(out_logfile, - "V-3: main (create hierarchical directory loop-collective): Calling create_remove_directory_tree with \"%s\"\n", - testdir ); - fflush( out_logfile ); - } - + VERBOSE(3,5,"main (create hierarchical directory loop-collective): Calling create_remove_directory_tree with \"%s\"", testdir ); /* * Let's pass in the path to the directory we most recently made so that we can use * full paths in the other calls. @@ -1887,13 +1697,7 @@ static void mdtest_iteration(int i, int j, MPI_Group testgroup, mdtest_results_t } } } else if (!collective_creates) { - if (verbose >= 3 && rank == 0) { - fprintf(out_logfile, - "V-3: main (create hierarchical directory loop-!collective_creates): Calling create_remove_directory_tree with \"%s\"\n", - testdir ); - fflush( out_logfile ); - } - + VERBOSE(3,5,"main (create hierarchical directory loop-!collective_creates): Calling create_remove_directory_tree with \"%s\"", testdir ); /* * Let's pass in the path to the directory we most recently made so that we can use * full paths in the other calls. @@ -1902,12 +1706,7 @@ static void mdtest_iteration(int i, int j, MPI_Group testgroup, mdtest_results_t } } else { if (rank == 0) { - if (verbose >= 3 && rank == 0) { - fprintf(out_logfile, - "V-3: main (create hierarchical directory loop-!unque_dir_per_task): Calling create_remove_directory_tree with \"%s\"\n", - testdir ); - fflush( out_logfile ); - } + VERBOSE(3,5,"main (create hierarchical directory loop-!unque_dir_per_task): Calling create_remove_directory_tree with \"%s\"", testdir ); /* * Let's pass in the path to the directory we most recently made so that we can use @@ -1924,11 +1723,7 @@ static void mdtest_iteration(int i, int j, MPI_Group testgroup, mdtest_results_t summary_table->time[8] = (endCreate - startCreate); summary_table->items[8] = num_dirs_in_tree; summary_table->stonewall_last_item[8] = num_dirs_in_tree; - if (verbose >= 1 && rank == 0) { - fprintf(out_logfile, "V-1: main: Tree creation : %14.3f sec, %14.3f ops/sec\n", - (endCreate - startCreate), summary_table->rate[8]); - fflush(out_logfile); - } + VERBOSE(1,-1,"V-1: main: Tree creation : %14.3f sec, %14.3f ops/sec", (endCreate - startCreate), summary_table->rate[8]); } sprintf(unique_mk_dir, "%s.0", base_tree_name); sprintf(unique_chdir_dir, "%s.0", base_tree_name); @@ -1938,10 +1733,7 @@ static void mdtest_iteration(int i, int j, MPI_Group testgroup, mdtest_results_t unique_rm_uni_dir[0] = 0; if (!unique_dir_per_task) { - if (verbose >= 3 && rank == 0) { - fprintf(out_logfile, "V-3: main: Using unique_mk_dir, \"%s\"\n", unique_mk_dir ); - fflush( out_logfile ); - } + VERBOSE(3,-1,"V-3: main: Using unique_mk_dir, \"%s\"", unique_mk_dir ); } if (rank < i) { @@ -1963,10 +1755,7 @@ static void mdtest_iteration(int i, int j, MPI_Group testgroup, mdtest_results_t rank, unique_mk_dir,unique_chdir_dir,unique_stat_dir,unique_read_dir,unique_rm_dir); } - if (verbose >= 3 && rank == 0) { - fprintf(out_logfile, "V-3: main: Copied unique_mk_dir, \"%s\", to topdir\n", unique_mk_dir ); - fflush( out_logfile ); - } + VERBOSE(3,-1,"V-3: main: Copied unique_mk_dir, \"%s\", to topdir", unique_mk_dir ); if (dirs_only && !shared_file) { if (pre_delay) { @@ -1985,10 +1774,7 @@ static void mdtest_iteration(int i, int j, MPI_Group testgroup, mdtest_results_t /* remove directory structure */ if (!unique_dir_per_task) { - if (verbose >= 3 && rank == 0) { - fprintf(out_logfile, "V-3: main: Using testdir, \"%s\"\n", testdir ); - fflush( out_logfile ); - } + VERBOSE(3,-1,"main: Using testdir, \"%s\"", testdir ); } MPI_Barrier(testComm); @@ -2006,12 +1792,7 @@ static void mdtest_iteration(int i, int j, MPI_Group testgroup, mdtest_results_t for (k=0; k= 3 && rank == 0) { - fprintf(out_logfile, - "V-3: main (remove hierarchical directory loop-collective): Calling create_remove_directory_tree with \"%s\"\n", - testdir ); - fflush( out_logfile ); - } + VERBOSE(3,-1,"main (remove hierarchical directory loop-collective): Calling create_remove_directory_tree with \"%s\"", testdir ); /* * Let's pass in the path to the directory we most recently made so that we can use @@ -2024,12 +1805,7 @@ static void mdtest_iteration(int i, int j, MPI_Group testgroup, mdtest_results_t } } } else if (!collective_creates) { - if (verbose >= 3 && rank == 0) { - fprintf(out_logfile, - "V-3: main (remove hierarchical directory loop-!collective): Calling create_remove_directory_tree with \"%s\"\n", - testdir ); - fflush( out_logfile ); - } + VERBOSE(3,-1,"main (remove hierarchical directory loop-!collective): Calling create_remove_directory_tree with \"%s\"", testdir ); /* * Let's pass in the path to the directory we most recently made so that we can use @@ -2039,12 +1815,7 @@ static void mdtest_iteration(int i, int j, MPI_Group testgroup, mdtest_results_t } } else { if (rank == 0) { - if (verbose >= 3 && rank == 0) { - fprintf(out_logfile, - "V-3: main (remove hierarchical directory loop-!unique_dir_per_task): Calling create_remove_directory_tree with \"%s\"\n", - testdir ); - fflush( out_logfile ); - } + VERBOSE(3,-1,"V-3: main (remove hierarchical directory loop-!unique_dir_per_task): Calling create_remove_directory_tree with \"%s\"", testdir ); /* * Let's pass in the path to the directory we most recently made so that we can use @@ -2061,16 +1832,8 @@ static void mdtest_iteration(int i, int j, MPI_Group testgroup, mdtest_results_t summary_table->time[9] = endCreate - startCreate; summary_table->items[9] = num_dirs_in_tree; summary_table->stonewall_last_item[8] = num_dirs_in_tree; - if (verbose >= 1 && rank == 0) { - fprintf(out_logfile, "V-1: main Tree removal : %14.3f sec, %14.3f ops/sec\n", - (endCreate - startCreate), summary_table->rate[9]); - fflush(out_logfile); - } - - if (( rank == 0 ) && ( verbose >=2 )) { - fprintf( out_logfile, "V-2: main (at end of for j loop): Removing testdir of \"%s\"\n", testdir ); - fflush( out_logfile ); - } + VERBOSE(1,-1,"main Tree removal : %14.3f sec, %14.3f ops/sec", (endCreate - startCreate), summary_table->rate[9]); + VERBOSE(2,-1,"main (at end of for j loop): Removing testdir of \"%s\"\n", testdir ); for (int dir_iter = 0; dir_iter < directory_loops; dir_iter ++){ prep_testdir(j, dir_iter); @@ -2204,8 +1967,7 @@ mdtest_results_t * mdtest_run(int argc, char **argv, MPI_Comm world_com, FILE * if (rank == 0) { fprintf(out_logfile, "-- started at %s --\n\n", PrintTimestamp()); - fprintf(out_logfile, "mdtest-%s was launched with %d total task(s) on %d node(s)\n", - RELEASE_VERS, size, nodeCount); + fprintf(out_logfile, "mdtest-%s was launched with %d total task(s) on %d node(s)\n", RELEASE_VERS, size, nodeCount); fflush(out_logfile); } @@ -2239,42 +2001,39 @@ mdtest_results_t * mdtest_run(int argc, char **argv, MPI_Comm world_com, FILE * } valid_tests(); - if (( rank == 0 ) && ( verbose >= 1 )) { - // option_print_current(options); - fprintf (out_logfile, "api : %s\n", param.api); - fprintf( out_logfile, "barriers : %s\n", ( barriers ? "True" : "False" )); - fprintf( out_logfile, "collective_creates : %s\n", ( collective_creates ? "True" : "False" )); - fprintf( out_logfile, "create_only : %s\n", ( create_only ? "True" : "False" )); - fprintf( out_logfile, "dirpath(s):\n" ); - for ( i = 0; i < path_count; i++ ) { - fprintf( out_logfile, "\t%s\n", filenames[i] ); - } - fprintf( out_logfile, "dirs_only : %s\n", ( dirs_only ? "True" : "False" )); - fprintf( out_logfile, "read_bytes : "LLU"\n", read_bytes ); - fprintf( out_logfile, "read_only : %s\n", ( read_only ? "True" : "False" )); - fprintf( out_logfile, "first : %d\n", first ); - fprintf( out_logfile, "files_only : %s\n", ( files_only ? "True" : "False" )); - fprintf( out_logfile, "iterations : %d\n", iterations ); - fprintf( out_logfile, "items_per_dir : "LLU"\n", items_per_dir ); - fprintf( out_logfile, "last : %d\n", last ); - fprintf( out_logfile, "leaf_only : %s\n", ( leaf_only ? "True" : "False" )); - fprintf( out_logfile, "items : "LLU"\n", items ); - fprintf( out_logfile, "nstride : %d\n", nstride ); - fprintf( out_logfile, "pre_delay : %d\n", pre_delay ); - fprintf( out_logfile, "remove_only : %s\n", ( leaf_only ? "True" : "False" )); - fprintf( out_logfile, "random_seed : %d\n", random_seed ); - fprintf( out_logfile, "stride : %d\n", stride ); - fprintf( out_logfile, "shared_file : %s\n", ( shared_file ? "True" : "False" )); - fprintf( out_logfile, "time_unique_dir_overhead: %s\n", ( time_unique_dir_overhead ? "True" : "False" )); - fprintf( out_logfile, "stone_wall_timer_seconds: %d\n", stone_wall_timer_seconds); - fprintf( out_logfile, "stat_only : %s\n", ( stat_only ? "True" : "False" )); - fprintf( out_logfile, "unique_dir_per_task : %s\n", ( unique_dir_per_task ? "True" : "False" )); - fprintf( out_logfile, "write_bytes : "LLU"\n", write_bytes ); - fprintf( out_logfile, "sync_file : %s\n", ( sync_file ? "True" : "False" )); - fprintf( out_logfile, "depth : %d\n", depth ); - fprintf( out_logfile, "make_node : %d\n", make_node ); - fflush( out_logfile ); + // option_print_current(options); + VERBOSE(1,-1, "api : %s", param.api); + VERBOSE(1,-1, "barriers : %s", ( barriers ? "True" : "False" )); + VERBOSE(1,-1, "collective_creates : %s", ( collective_creates ? "True" : "False" )); + VERBOSE(1,-1, "create_only : %s", ( create_only ? "True" : "False" )); + VERBOSE(1,-1, "dirpath(s):" ); + for ( i = 0; i < path_count; i++ ) { + VERBOSE(1,-1, "\t%s", filenames[i] ); } + VERBOSE(1,-1, "dirs_only : %s", ( dirs_only ? "True" : "False" )); + VERBOSE(1,-1, "read_bytes : "LLU"", read_bytes ); + VERBOSE(1,-1, "read_only : %s", ( read_only ? "True" : "False" )); + VERBOSE(1,-1, "first : %d", first ); + VERBOSE(1,-1, "files_only : %s", ( files_only ? "True" : "False" )); + VERBOSE(1,-1, "iterations : %d", iterations ); + VERBOSE(1,-1, "items_per_dir : "LLU"", items_per_dir ); + VERBOSE(1,-1, "last : %d", last ); + VERBOSE(1,-1, "leaf_only : %s", ( leaf_only ? "True" : "False" )); + VERBOSE(1,-1, "items : "LLU"", items ); + VERBOSE(1,-1, "nstride : %d", nstride ); + VERBOSE(1,-1, "pre_delay : %d", pre_delay ); + VERBOSE(1,-1, "remove_only : %s", ( leaf_only ? "True" : "False" )); + VERBOSE(1,-1, "random_seed : %d", random_seed ); + VERBOSE(1,-1, "stride : %d", stride ); + VERBOSE(1,-1, "shared_file : %s", ( shared_file ? "True" : "False" )); + VERBOSE(1,-1, "time_unique_dir_overhead: %s", ( time_unique_dir_overhead ? "True" : "False" )); + VERBOSE(1,-1, "stone_wall_timer_seconds: %d", stone_wall_timer_seconds); + VERBOSE(1,-1, "stat_only : %s", ( stat_only ? "True" : "False" )); + VERBOSE(1,-1, "unique_dir_per_task : %s", ( unique_dir_per_task ? "True" : "False" )); + VERBOSE(1,-1, "write_bytes : "LLU"", write_bytes ); + VERBOSE(1,-1, "sync_file : %s", ( sync_file ? "True" : "False" )); + VERBOSE(1,-1, "depth : %d", depth ); + VERBOSE(1,-1, "make_node : %d", make_node ); /* setup total number of items and number of items per dir */ if (depth <= 0) { @@ -2378,10 +2137,7 @@ mdtest_results_t * mdtest_run(int argc, char **argv, MPI_Comm world_com, FILE * } /* display disk usage */ - if (verbose >= 3 && rank == 0) { - fprintf(out_logfile, "V-3: main (before display_freespace): testdirpath is \"%s\"\n", testdirpath ); - fflush( out_logfile ); - } + VERBOSE(3,-1,"main (before display_freespace): testdirpath is \"%s\"", testdirpath ); if (rank == 0) display_freespace(testdirpath); int packedByNode = QueryNodeMapping(testComm); @@ -2396,10 +2152,7 @@ mdtest_results_t * mdtest_run(int argc, char **argv, MPI_Comm world_com, FILE * } } - if (verbose >= 3 && rank == 0) { - fprintf(out_logfile, "V-3: main (after display_freespace): testdirpath is \"%s\"\n", testdirpath ); - fflush( out_logfile ); - } + VERBOSE(3,-1,"main (after display_freespace): testdirpath is \"%s\"", testdirpath ); if (rank == 0) { if (random_seed > 0) { @@ -2468,11 +2221,9 @@ mdtest_results_t * mdtest_run(int argc, char **argv, MPI_Comm world_com, FILE * fprintf(out_logfile, "\n%d tasks, "LLU" directories\n", i, items_all); } } - if (rank == 0 && verbose >= 1) { - fprintf(out_logfile, "\n"); - fprintf(out_logfile, " Operation Duration Rate\n"); - fprintf(out_logfile, " --------- -------- ----\n"); - } + VERBOSE(1,-1,""); + VERBOSE(1,-1," Operation Duration Rate"); + VERBOSE(1,-1," --------- -------- ----"); for (j = 0; j < iterations; j++) { // keep track of the current status for stonewalling @@ -2484,10 +2235,7 @@ mdtest_results_t * mdtest_run(int argc, char **argv, MPI_Comm world_com, FILE * } } - if (rank == 0) { - fprintf(out_logfile, "\n-- finished at %s --\n", PrintTimestamp()); - fflush(out_logfile); - } + VERBOSE(0,-1,"-- finished at %s --\n", PrintTimestamp()); if (random_seed > 0) { free(rand_array); From e767ef3de980698677450452bd4933a621d4c1c0 Mon Sep 17 00:00:00 2001 From: John Bent Date: Sat, 27 Jul 2019 13:26:39 -0600 Subject: [PATCH 21/50] Remove extraneous print_help function that was causing people to have to edit the same string in two different locations --- src/mdtest.c | 62 ---------------------------------------------------- 1 file changed, 62 deletions(-) diff --git a/src/mdtest.c b/src/mdtest.c index bfeeda1..368acf1 100644 --- a/src/mdtest.c +++ b/src/mdtest.c @@ -455,7 +455,6 @@ void create_remove_items(int currDepth, const int dirs, const int create, const if (collective) { collective_helper(dirs, create, temp_path, 0, progress); } else { - printf("DEBUG %5d rank %d gonna create %s\n", __LINE__, rank, temp_path); create_remove_items_helper(dirs, create, temp_path, 0, progress); } } @@ -481,7 +480,6 @@ void create_remove_items(int currDepth, const int dirs, const int create, const if (collective) { collective_helper(dirs, create, temp_path, currDir*items_per_dir, progress); } else { - printf("DEBUG %5d rank %d gonna create %s\n", __LINE__, rank, temp_path); create_remove_items_helper(dirs, create, temp_path, currDir*items_per_dir, progress); } } @@ -1198,66 +1196,6 @@ void file_test(const int iteration, const int ntasks, const char *path, rank_pro VERBOSE(1,-1," File removal : %14.3f sec, %14.3f ops/sec", t[4] - t[3], summary_table[iteration].rate[7]); } -void print_help (void) { - int j; - - char APIs[1024]; - char APIs_legacy[1024]; - aiori_supported_apis(APIs, APIs_legacy, MDTEST); - char apiStr[1024]; - sprintf(apiStr, "API for I/O [%s]", APIs); - - fprintf(out_logfile, - "Usage: mdtest [-b branching_factor] [-B] [-c] [-C] [-d testdir] [-D] [-e number_of_bytes_to_read]\n" - " [-E] [-f first] [-F] [-h] [-i iterations] [-I items_per_dir] [-k] [-l last] [-L]\n" - " [-n number_of_items] [-N stride_length] [-p seconds] [-r]\n" - " [-R[seed]] [-s stride] [-S] [-t] [-T] [-u] [-v] [-a API]\n" - " [-V verbosity_value] [-w number_of_bytes_to_write] [-W seconds] [-y] [-z depth] -Z\n" - "\t-a: %s\n" - "\t-b: branching factor of hierarchical directory structure\n" - "\t-B: no barriers between phases\n" - "\t-c: collective creates: task 0 does all creates\n" - "\t-C: only create files/dirs\n" - "\t-d: the directory in which the tests will run\n" - "\t-D: perform test on directories only (no files)\n" - "\t-e: bytes to read from each file\n" - "\t-E: only read files/dir\n" - "\t-f: first number of tasks on which the test will run\n" - "\t-F: perform test on files only (no directories)\n" - "\t-h: prints this help message\n" - "\t-i: number of iterations the test will run\n" - "\t-I: number of items per directory in tree\n" - "\t-k: use mknod\n" - "\t-l: last number of tasks on which the test will run\n" - "\t-L: files only at leaf level of tree\n" - "\t-n: every process will creat/stat/read/remove # directories and files\n" - "\t-N: stride # between neighbor tasks for file/dir operation (local=0)\n" - "\t-p: pre-iteration delay (in seconds)\n" - "\t-r: only remove files or directories left behind by previous runs\n" - "\t-R: randomly stat files (optional argument for random seed)\n" - "\t-s: stride between the number of nodes for each test\n" - "\t-S: shared file access (file only, no directories)\n" - "\t-t: time unique working directory overhead\n" - "\t-T: only stat files/dirs\n" - "\t-u: unique working directory for each task\n" - "\t-v: verbosity (each instance of option increments by one)\n" - "\t-V: verbosity value\n" - "\t-w: bytes to write to each file after it is created\n" - "\t-W: number in seconds; stonewall timer, write as many seconds and ensure all processes did the same number of operations (currently only stops during create phase)\n" - "\t-x: StoneWallingStatusFile; contains the number of iterations of the creation phase, can be used to split phases across runs\n" - "\t-y: sync file after writing\n" - "\t-z: depth of hierarchical directory structure\n" - "\t-Z: print time instead of rate\n", - apiStr - ); - - MPI_Initialized(&j); - if (j) { - MPI_Finalize(); - } - exit(0); -} - void summarize_results(int iterations) { char access[MAX_PATHLEN]; int i, j, k; From d69957e55b52137d62692872596c755d7fbe727f Mon Sep 17 00:00:00 2001 From: John Bent Date: Sat, 27 Jul 2019 14:31:49 -0600 Subject: [PATCH 22/50] Final changes cleaning up the output messages --- src/mdtest.c | 105 ++++++++++++++++++++++----------------------------- 1 file changed, 46 insertions(+), 59 deletions(-) diff --git a/src/mdtest.c b/src/mdtest.c index 368acf1..75558c1 100644 --- a/src/mdtest.c +++ b/src/mdtest.c @@ -188,7 +188,14 @@ void VerboseMessage (int root_level, int any_level, int line, char * format, ... va_start (args, format); vsnprintf (buffer, 1024, format, args); va_end (args); - fprintf( out_logfile, "V-%d: Rank %3d Line %5d %s\n", root_level, rank, line, buffer ); + if (root_level == 0 && any_level == -1) { + /* No header when it is just the standard output */ + fprintf( out_logfile, "%s\n", buffer ); + } else { + /* add a header when the verbose is greater than 0 */ + fprintf( out_logfile, "V-%d: Rank %3d Line %5d %s\n", root_level, rank, line, buffer ); + } + fflush(out_logfile); } } @@ -211,7 +218,7 @@ void parse_dirpath(char *dirpath_arg) { int i = 0; - VERBOSE(1,-1, "Entering parse_dirpath..." ); + VERBOSE(1,-1, "Entering parse_dirpath on %s...", dirpath_arg ); tmp = dirpath_arg; @@ -252,8 +259,6 @@ static void prep_testdir(int j, int dir_iter){ */ void unique_dir_access(int opt, char *to) { - VERBOSE(1,-1,"Entering unique_dir_access..." ); - if (opt == MK_UNI_DIR) { MPI_Barrier(testComm); sprintf( to, "%s/%s", testdir, unique_chdir_dir ); @@ -266,6 +271,7 @@ void unique_dir_access(int opt, char *to) { } else if (opt == RM_UNI_DIR) { sprintf( to, "%s/%s", testdir, unique_rm_uni_dir ); } + VERBOSE(1,-1,"Entering unique_dir_access, set it to %s", to ); } static void create_remove_dirs (const char *path, bool create, uint64_t itemNum) { @@ -373,7 +379,7 @@ static void create_file (const char *path, uint64_t itemNum) { void create_remove_items_helper(const int dirs, const int create, const char *path, uint64_t itemNum, rank_progress_t * progress) { - VERBOSE(1,-1,"Entering create_remove_items_helper..." ); + VERBOSE(1,-1,"Entering create_remove_items_helper on %s", path ); for (uint64_t i = progress->items_start; i < progress->items_per_dir ; ++i) { if (!dirs) { @@ -399,7 +405,7 @@ void create_remove_items_helper(const int dirs, const int create, const char *pa void collective_helper(const int dirs, const int create, const char* path, uint64_t itemNum, rank_progress_t * progress) { char curr_item[MAX_PATHLEN]; - VERBOSE(1,-1,"Entering collective_helper..." ); + VERBOSE(1,-1,"Entering collective_helper on %s", path ); for (uint64_t i = progress->items_start ; i < progress->items_per_dir ; ++i) { if (dirs) { create_remove_dirs (path, create, itemNum + i); @@ -441,7 +447,7 @@ void create_remove_items(int currDepth, const int dirs, const int create, const unsigned long long currDir = dirNum; - VERBOSE(1,-1,"Entering create_remove_items, currDepth = %d...", currDepth ); + VERBOSE(1,-1,"Entering create_remove_items on %s, currDepth = %d...", path, currDepth ); memset(dir, 0, MAX_PATHLEN); @@ -509,7 +515,7 @@ void mdtest_stat(const int random, const int dirs, const long dir_iter, const ch uint64_t parent_dir, item_num = 0; char item[MAX_PATHLEN], temp[MAX_PATHLEN]; - VERBOSE(1,-1,"Entering mdtest_stat..." ); + VERBOSE(1,-1,"Entering mdtest_stat on %s", path ); uint64_t stop_items = items; @@ -594,7 +600,7 @@ void mdtest_read(int random, int dirs, const long dir_iter, char *path) { char item[MAX_PATHLEN], temp[MAX_PATHLEN]; void *aiori_fh; - VERBOSE(1,-1,"Entering mdtest_read..." ); + VERBOSE(1,-1,"Entering mdtest_read on %s", path ); /* allocate read buffer */ if (read_bytes > 0) { @@ -940,12 +946,12 @@ void directory_test(const int iteration, const int ntasks, const char *path, ran summary_table[iteration].stonewall_last_item[3] = items; } - VERBOSE(1,-1," Directory creation: %14.3f sec, %14.3f ops/sec\n", t[1] - t[0], summary_table[iteration].rate[0]); - VERBOSE(1,-1," Directory stat : %14.3f sec, %14.3f ops/sec\n", t[2] - t[1], summary_table[iteration].rate[1]); + VERBOSE(1,-1," Directory creation: %14.3f sec, %14.3f ops/sec", t[1] - t[0], summary_table[iteration].rate[0]); + VERBOSE(1,-1," Directory stat : %14.3f sec, %14.3f ops/sec", t[2] - t[1], summary_table[iteration].rate[1]); /* N/A - VERBOSE(1,-1," Directory read : %14.3f sec, %14.3f ops/sec\n", t[3] - t[2], summary_table[iteration].rate[2]); + VERBOSE(1,-1," Directory read : %14.3f sec, %14.3f ops/sec", t[3] - t[2], summary_table[iteration].rate[2]); */ - VERBOSE(1,-1," Directory removal : %14.3f sec, %14.3f ops/sec\n", t[4] - t[3], summary_table[iteration].rate[3]); + VERBOSE(1,-1," Directory removal : %14.3f sec, %14.3f ops/sec", t[4] - t[3], summary_table[iteration].rate[3]); } /* Returns if the stonewall was hit */ @@ -967,10 +973,7 @@ int updateStoneWallIterations(int iteration, rank_progress_t * progress, double if(items != (sum_accessed / size)){ summary_table[iteration].stonewall_item_sum[MDTEST_FILE_CREATE_NUM] = sum_accessed; summary_table[iteration].stonewall_item_min[MDTEST_FILE_CREATE_NUM] = min_accessed * size; - if (rank == 0){ - fprintf( out_logfile, "Continue stonewall hit min: %lld max: %lld avg: %.1f \n", min_accessed, max_iter, ((double) sum_accessed) / size); - fflush( out_logfile ); - } + VERBOSE(0,-1, "Continue stonewall hit min: %lld max: %lld avg: %.1f \n", min_accessed, max_iter, ((double) sum_accessed) / size); hit = 1; } progress->items_start = done; @@ -1218,12 +1221,9 @@ void summarize_results(int iterations) { if (rank == 0) { - fprintf(out_logfile, "\nSUMMARY %s: (of %d iterations)\n", print_time ? "time": "rate", iterations); - fprintf(out_logfile, - " Operation Max Min Mean Std Dev\n"); - fprintf(out_logfile, - " --------- --- --- ---- -------\n"); - fflush(out_logfile); + VERBOSE(0,-1,"\nSUMMARY %s: (of %d iterations)", print_time ? "time": "rate", iterations); + VERBOSE(0,-1," Operation Max Min Mean Std Dev"); + VERBOSE(0,-1," --------- --- --- ---- -------"); /* if files only access, skip entries 0-3 (the dir tests) */ if (files_only && !dirs_only) { @@ -1342,8 +1342,7 @@ void summarize_results(int iterations) { void valid_tests() { if (((stone_wall_timer_seconds > 0) && (branch_factor > 1)) || ! barriers) { - fprintf(out_logfile, "Error, stone wall timer does only work with a branch factor <= 1 and with barriers\n"); - MPI_Abort(testComm, 1); + FAIL( "Error, stone wall timer does only work with a branch factor <= 1 and with barriers\n"); } if (!create_only && !stat_only && !read_only && !remove_only) { @@ -1443,7 +1442,7 @@ void show_file_system_size(char *file_system) { ior_aiori_statfs_t stat_buf; int ret; - VERBOSE(1,-1,"Entering show_file_system_size..." ); + VERBOSE(1,-1,"Entering show_file_system_size on %s", file_system ); ret = backend->statfs (file_system, &stat_buf, ¶m); if (0 != ret) { @@ -1475,14 +1474,10 @@ void show_file_system_size(char *file_system) { /* show results */ - fprintf(out_logfile, "Path: %s\n", real_path); - fprintf(out_logfile, "FS: %.1f %s Used FS: %2.1f%% ", - total_file_system_size_hr, file_system_unit_str, - used_file_system_percentage); - fprintf(out_logfile, "Inodes: %.1f %s Used Inodes: %2.1f%%\n", - (double)total_inodes / (double)inode_unit_val, - inode_unit_str, used_inode_percentage); - fflush(out_logfile); + VERBOSE(0,-1,"Path: %s", real_path); + VERBOSE(0,-1,"FS: %.1f %s Used FS: %2.1f%% Inodes: %.1f %s Used Inodes: %2.1f%%\n", + total_file_system_size_hr, file_system_unit_str, used_file_system_percentage, + (double)total_inodes / (double)inode_unit_val, inode_unit_str, used_inode_percentage); return; } @@ -1682,15 +1677,14 @@ static void mdtest_iteration(int i, int j, MPI_Group testgroup, mdtest_results_t sprintf(rm_name, "mdtest.%d.", (rank+(3*nstride))%i); } if (unique_dir_per_task) { - printf("DEBUG %5d Rank %d i %d nstride %d\n", __LINE__, rank, i, nstride); + VERBOSE(3,5,"i %d nstride %d", i, nstride); sprintf(unique_mk_dir, "mdtest_tree.%d.0", (rank+(0*nstride))%i); sprintf(unique_chdir_dir, "mdtest_tree.%d.0", (rank+(1*nstride))%i); sprintf(unique_stat_dir, "mdtest_tree.%d.0", (rank+(2*nstride))%i); sprintf(unique_read_dir, "mdtest_tree.%d.0", (rank+(3*nstride))%i); sprintf(unique_rm_dir, "mdtest_tree.%d.0", (rank+(4*nstride))%i); unique_rm_uni_dir[0] = 0; - printf("DEBUG %5d Rank %d mk_dir %s chdir %s stat_dir %s read_dir %s rm_dir %s\n", __LINE__, - rank, unique_mk_dir,unique_chdir_dir,unique_stat_dir,unique_read_dir,unique_rm_dir); + VERBOSE(5,5,"mk_dir %s chdir %s stat_dir %s read_dir %s rm_dir %s\n", unique_mk_dir,unique_chdir_dir,unique_stat_dir,unique_read_dir,unique_rm_dir); } VERBOSE(3,-1,"V-3: main: Copied unique_mk_dir, \"%s\", to topdir", unique_mk_dir ); @@ -1705,7 +1699,7 @@ static void mdtest_iteration(int i, int j, MPI_Group testgroup, mdtest_results_t if (pre_delay) { DelaySecs(pre_delay); } - printf("DEBUG %5d Rank %d gonna file_test on %s\n", __LINE__, rank, unique_mk_dir); + VERBOSE(3,5,"will file_test on %s", unique_mk_dir); file_test(j, i, unique_mk_dir, progress); } } @@ -1903,20 +1897,15 @@ mdtest_results_t * mdtest_run(int argc, char **argv, MPI_Comm world_com, FILE * tasksPerNode = CountTasksPerNode(testComm); nodeCount = size / tasksPerNode; - if (rank == 0) { - fprintf(out_logfile, "-- started at %s --\n\n", PrintTimestamp()); - fprintf(out_logfile, "mdtest-%s was launched with %d total task(s) on %d node(s)\n", RELEASE_VERS, size, nodeCount); - fflush(out_logfile); + char cmd_buffer[4096]; + strncpy(cmd_buffer, argv[0], 4096); + for (i = 1; i < argc; i++) { + snprintf(&cmd_buffer[strlen(cmd_buffer)], 4096-strlen(cmd_buffer), " \"%s\"", argv[i]); } - if (rank == 0) { - fprintf(out_logfile, "Command line used: %s", argv[0]); - for (i = 1; i < argc; i++) { - fprintf(out_logfile, " \"%s\"", argv[i]); - } - fprintf(out_logfile, "\n"); - fflush(out_logfile); - } + VERBOSE(0,-1,"-- started at %s --\n", PrintTimestamp()); + VERBOSE(0,-1,"mdtest-%s was launched with %d total task(s) on %d node(s)", RELEASE_VERS, size, nodeCount); + VERBOSE(0,-1,"Command line used: %s", cmd_buffer); /* adjust special variables */ barriers = ! no_barriers; @@ -2082,19 +2071,17 @@ mdtest_results_t * mdtest_run(int argc, char **argv, MPI_Comm world_com, FILE * /* set the shift to mimic IOR and shift by procs per node */ if (nstride > 0) { - if ( packedByNode ) { + if ( nodeCount > 1 && packedByNode ) { nstride *= tasksPerNode; } - if (rank == 0) { - fprintf(out_logfile, "Shifting ranks by %d for each phase.\n", nstride); - } + VERBOSE(0,5,"Shifting ranks by %d for each phase.", nstride); } VERBOSE(3,-1,"main (after display_freespace): testdirpath is \"%s\"", testdirpath ); if (rank == 0) { if (random_seed > 0) { - fprintf(out_logfile, "random seed: %d\n", random_seed); + VERBOSE(0,-1,"random seed: %d", random_seed); } } @@ -2147,16 +2134,16 @@ mdtest_results_t * mdtest_run(int argc, char **argv, MPI_Comm world_com, FILE * items_all *= num_dirs_in_tree_calc; } if (files_only && dirs_only) { - fprintf(out_logfile, "\n%d tasks, "LLU" files/directories\n", i, items_all); + VERBOSE(0,-1,"%d tasks, "LLU" files/directories", i, items_all); } else if (files_only) { if (!shared_file) { - fprintf(out_logfile, "\n%d tasks, "LLU" files\n", i, items_all); + VERBOSE(0,-1,"%d tasks, "LLU" files", i, items_all); } else { - fprintf(out_logfile, "\n%d tasks, 1 file\n", i); + VERBOSE(0,-1,"%d tasks, 1 file", i); } } else if (dirs_only) { - fprintf(out_logfile, "\n%d tasks, "LLU" directories\n", i, items_all); + VERBOSE(0,-1,"%d tasks, "LLU" directories", i, items_all); } } VERBOSE(1,-1,""); From 629ff810b70cd98f8eaec51167154af70dcc3386 Mon Sep 17 00:00:00 2001 From: John Bent Date: Sat, 27 Jul 2019 15:27:20 -0600 Subject: [PATCH 23/50] Got IOR shifting to work regardless of whether node/task mapping is round-robin or contiguous --- src/ior.c | 20 ++++++++++++++++---- src/ior.h | 1 + 2 files changed, 17 insertions(+), 4 deletions(-) diff --git a/src/ior.c b/src/ior.c index 3ef411c..bb2b4c2 100755 --- a/src/ior.c +++ b/src/ior.c @@ -939,6 +939,7 @@ static void InitTests(IOR_test_t *tests, MPI_Comm com) params->testComm = com; params->nodes = params->numTasks / tasksPerNode; params->tasksPerNode = tasksPerNode; + params->packedTasks = QueryNodeMapping(com); if (params->numTasks == 0) { params->numTasks = size; } @@ -1360,7 +1361,13 @@ static void TestIoSys(IOR_test_t *test) } if (params->reorderTasks) { /* move two nodes away from writing node */ - rankOffset = (2 * params->tasksPerNode) % params->numTasks; + int shift = 1; + if (params->packedTasks) { + shift = params->tasksPerNode; + } else { + shift = 1; + } + rankOffset = (2 * shift) % params->numTasks; } // update the check buffer @@ -1395,9 +1402,14 @@ static void TestIoSys(IOR_test_t *test) /* Get rankOffset [file offset] for this process to read, based on -C,-Z,-Q,-X options */ /* Constant process offset reading */ if (params->reorderTasks) { - /* move taskPerNodeOffset nodes[1==default] away from writing node */ - rankOffset = (params->taskPerNodeOffset * - params->tasksPerNode) % params->numTasks; + /* move one node away from writing node */ + int shift = 1; + if (params->packedTasks) { + shift=params->tasksPerNode; + } else { + shift=1; + } + rankOffset = (params->taskPerNodeOffset * shift) % params->numTasks; } /* random process offset reading */ if (params->reorderTasksRandom) { diff --git a/src/ior.h b/src/ior.h index 5c46efe..2ea6c05 100755 --- a/src/ior.h +++ b/src/ior.h @@ -100,6 +100,7 @@ typedef struct int numTasks; /* number of tasks for test */ int nodes; /* number of nodes for test */ int tasksPerNode; /* number of tasks per node */ + int packedTasks; /* are the tasks round-robin across nodes or are they packed tightly*/ int repetitions; /* number of repetitions of test */ int repCounter; /* rep counter */ int multiFile; /* multiple files */ From 168a4077938e29cd46f627612e13b6dc6363ddeb Mon Sep 17 00:00:00 2001 From: John Bent Date: Sun, 28 Jul 2019 09:55:00 -0600 Subject: [PATCH 24/50] Fixed inconsistent spacing that Andreas commented upon --- src/mdtest.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/mdtest.c b/src/mdtest.c index 75558c1..074463e 100644 --- a/src/mdtest.c +++ b/src/mdtest.c @@ -551,12 +551,12 @@ void mdtest_stat(const int random, const int dirs, const long dir_iter, const ch /* create name of file/dir to stat */ if (dirs) { - if ((i%ITEM_COUNT == 0) && (i != 0)) { + if ( (i % ITEM_COUNT == 0) && (i != 0)) { VERBOSE(3,5,"stat dir: "LLU"", i); } sprintf(item, "dir.%s"LLU"", stat_name, item_num); } else { - if ((i%ITEM_COUNT == 0) && (i != 0)) { + if ( (i % ITEM_COUNT == 0) && (i != 0)) { VERBOSE(3,5,"stat file: "LLU"", i); } sprintf(item, "file.%s"LLU"", stat_name, item_num); From b2d486f749c16fe3375dfc4389732bfae08db5f9 Mon Sep 17 00:00:00 2001 From: John Bent Date: Sun, 28 Jul 2019 10:07:03 -0600 Subject: [PATCH 25/50] Followed Andreas suggestion to replace escape double quotes within printf's with single quotes --- src/mdtest.c | 74 ++++++++++++++++++++++++++-------------------------- 1 file changed, 37 insertions(+), 37 deletions(-) diff --git a/src/mdtest.c b/src/mdtest.c index 074463e..e35a20e 100644 --- a/src/mdtest.c +++ b/src/mdtest.c @@ -284,7 +284,7 @@ static void create_remove_dirs (const char *path, bool create, uint64_t itemNum) //create dirs sprintf(curr_item, "%s/dir.%s%" PRIu64, path, create ? mk_name : rm_name, itemNum); - VERBOSE(3,5,"create_remove_items_helper (dirs %s): curr_item is \"%s\"", operation, curr_item); + VERBOSE(3,5,"create_remove_items_helper (dirs %s): curr_item is '%s'", operation, curr_item); if (create) { if (backend->mkdir(curr_item, DIRMODE, ¶m) == -1) { @@ -306,7 +306,7 @@ static void remove_file (const char *path, uint64_t itemNum) { //remove files sprintf(curr_item, "%s/file.%s"LLU"", path, rm_name, itemNum); - VERBOSE(3,5,"create_remove_items_helper (non-dirs remove): curr_item is \"%s\"", curr_item); + VERBOSE(3,5,"create_remove_items_helper (non-dirs remove): curr_item is '%s'", curr_item); if (!(shared_file && rank != 0)) { backend->delete (curr_item, ¶m); } @@ -322,7 +322,7 @@ static void create_file (const char *path, uint64_t itemNum) { //create files sprintf(curr_item, "%s/file.%s"LLU"", path, mk_name, itemNum); - VERBOSE(3,5,"create_remove_items_helper (non-dirs create): curr_item is \"%s\"", curr_item); + VERBOSE(3,5,"create_remove_items_helper (non-dirs create): curr_item is '%s'", curr_item); if (collective_creates) { param.openFlags = IOR_WRONLY; @@ -453,7 +453,7 @@ void create_remove_items(int currDepth, const int dirs, const int create, const memset(dir, 0, MAX_PATHLEN); strcpy(temp_path, path); - VERBOSE(3,5,"create_remove_items (start): temp_path is \"%s\"", temp_path ); + VERBOSE(3,5,"create_remove_items (start): temp_path is '%s'", temp_path ); if (currDepth == 0) { /* create items at this depth */ @@ -479,7 +479,7 @@ void create_remove_items(int currDepth, const int dirs, const int create, const strcat(temp_path, "/"); strcat(temp_path, dir); - VERBOSE(3,5,"create_remove_items (for loop): temp_path is \"%s\"", temp_path ); + VERBOSE(3,5,"create_remove_items (for loop): temp_path is '%s'", temp_path ); /* create the items in this branch */ if (!leaf_only || (leaf_only && currDepth == depth)) { @@ -742,7 +742,7 @@ void collective_create_remove(const int create, const int dirs, const int ntasks } /* Now that everything is set up as it should be, do the create or remove */ - VERBOSE(3,5,"collective_create_remove (create_remove_items): temp is \"%s\"", temp); + VERBOSE(3,5,"collective_create_remove (create_remove_items): temp is '%s'", temp); create_remove_items(0, dirs, create, 1, temp, 0, progress); } @@ -799,7 +799,7 @@ void directory_test(const int iteration, const int ntasks, const char *path, ran sprintf( temp_path, "%s/%s", testdir, path ); } - VERBOSE(3,-1,"directory_test: create path is \"%s\"", temp_path ); + VERBOSE(3,-1,"directory_test: create path is '%s'", temp_path ); /* "touch" the files */ if (collective_creates) { @@ -831,7 +831,7 @@ void directory_test(const int iteration, const int ntasks, const char *path, ran sprintf( temp_path, "%s/%s", testdir, path ); } - VERBOSE(3,5,"stat path is \"%s\"", temp_path ); + VERBOSE(3,5,"stat path is '%s'", temp_path ); /* stat directories */ if (random_seed > 0) { @@ -860,7 +860,7 @@ void directory_test(const int iteration, const int ntasks, const char *path, ran sprintf( temp_path, "%s/%s", testdir, path ); } - VERBOSE(3,5,"directory_test: read path is \"%s\"", temp_path ); + VERBOSE(3,5,"directory_test: read path is '%s'", temp_path ); /* read directories */ if (random_seed > 0) { @@ -888,7 +888,7 @@ void directory_test(const int iteration, const int ntasks, const char *path, ran sprintf( temp_path, "%s/%s", testdir, path ); } - VERBOSE(3,5,"directory_test: remove directories path is \"%s\"", temp_path ); + VERBOSE(3,5,"directory_test: remove directories path is '%s'", temp_path ); /* remove directories */ if (collective_creates) { @@ -913,7 +913,7 @@ void directory_test(const int iteration, const int ntasks, const char *path, ran sprintf( temp_path, "%s/%s", testdir, path ); } - VERBOSE(3,5,"directory_test: remove unique directories path is \"%s\"\n", temp_path ); + VERBOSE(3,5,"directory_test: remove unique directories path is '%s'\n", temp_path ); } if (unique_dir_per_task && !time_unique_dir_overhead) { @@ -1010,7 +1010,7 @@ void file_test(const int iteration, const int ntasks, const char *path, rank_pro - VERBOSE(3,-1,"file_test: create path is \"%s\"", temp_path ); + VERBOSE(3,-1,"file_test: create path is '%s'", temp_path ); /* "touch" the files */ if (collective_creates) { @@ -1077,7 +1077,7 @@ void file_test(const int iteration, const int ntasks, const char *path, rank_pro sprintf( temp_path, "%s/%s", testdir, path ); } - VERBOSE(3,5,"file_test: stat path is \"%s\"", temp_path ); + VERBOSE(3,5,"file_test: stat path is '%s'", temp_path ); /* stat files */ mdtest_stat((random_seed > 0 ? 1 : 0), 0, dir_iter, temp_path, progress); @@ -1102,7 +1102,7 @@ void file_test(const int iteration, const int ntasks, const char *path, rank_pro sprintf( temp_path, "%s/%s", testdir, path ); } - VERBOSE(3,5,"file_test: read path is \"%s\"", temp_path ); + VERBOSE(3,5,"file_test: read path is '%s'", temp_path ); /* read files */ if (random_seed > 0) { @@ -1132,7 +1132,7 @@ void file_test(const int iteration, const int ntasks, const char *path, rank_pro sprintf( temp_path, "%s/%s", testdir, path ); } - VERBOSE(3,5,"file_test: rm directories path is \"%s\"", temp_path ); + VERBOSE(3,5,"file_test: rm directories path is '%s'", temp_path ); if (collective_creates) { if (rank == 0) { @@ -1156,7 +1156,7 @@ void file_test(const int iteration, const int ntasks, const char *path, rank_pro strcpy( temp_path, path ); } - VERBOSE(3,5,"file_test: rm unique directories path is \"%s\"", temp_path ); + VERBOSE(3,5,"file_test: rm unique directories path is '%s'", temp_path ); } if (unique_dir_per_task && !time_unique_dir_overhead) { @@ -1508,9 +1508,9 @@ void display_freespace(char *testdirpath) strcpy(dirpath, "."); } - VERBOSE(3,5,"Before show_file_system_size, dirpath is \"%s\"", dirpath ); + VERBOSE(3,5,"Before show_file_system_size, dirpath is '%s'", dirpath ); show_file_system_size(dirpath); - VERBOSE(3,5, "After show_file_system_size, dirpath is \"%s\"\n", dirpath ); + VERBOSE(3,5, "After show_file_system_size, dirpath is '%s'\n", dirpath ); return; } @@ -1528,16 +1528,16 @@ void create_remove_directory_tree(int create, sprintf(dir, "%s/%s.%d/", path, base_tree_name, dirNum); if (create) { - VERBOSE(2,5,"Making directory \"%s\"", dir); + VERBOSE(2,5,"Making directory '%s'", dir); if (-1 == backend->mkdir (dir, DIRMODE, ¶m)) { - fprintf(out_logfile, "error could not create directory \"%s\"\n", dir); + fprintf(out_logfile, "error could not create directory '%s'\n", dir); } } create_remove_directory_tree(create, ++currDepth, dir, ++dirNum, progress); if (!create) { - VERBOSE(2,5,"Remove directory \"%s\"", dir); + VERBOSE(2,5,"Remove directory '%s'", dir); if (-1 == backend->rmdir(dir, ¶m)) { FAIL("Unable to remove directory"); } @@ -1553,7 +1553,7 @@ void create_remove_directory_tree(int create, strcat(temp_path, dir); if (create) { - VERBOSE(2,5,"Making directory \"%s\"", temp_path); + VERBOSE(2,5,"Making directory '%s'", temp_path); if (-1 == backend->mkdir(temp_path, DIRMODE, ¶m)) { FAIL("Unable to create directory"); } @@ -1564,7 +1564,7 @@ void create_remove_directory_tree(int create, currDepth--; if (!create) { - VERBOSE(2,5,"Remove directory \"%s\"", temp_path); + VERBOSE(2,5,"Remove directory '%s'", temp_path); if (-1 == backend->rmdir(temp_path, ¶m)) { FAIL("Unable to remove directory"); } @@ -1593,7 +1593,7 @@ static void mdtest_iteration(int i, int j, MPI_Group testgroup, mdtest_results_t for (int dir_iter = 0; dir_iter < directory_loops; dir_iter ++){ prep_testdir(j, dir_iter); - VERBOSE(2,5,"main (for j loop): making testdir, \"%s\"", testdir ); + VERBOSE(2,5,"main (for j loop): making testdir, '%s'", testdir ); if ((rank < path_count) && backend->access(testdir, F_OK, ¶m) != 0) { if (backend->mkdir(testdir, DIRMODE, ¶m) != 0) { FAIL("Unable to create test directory"); @@ -1618,7 +1618,7 @@ static void mdtest_iteration(int i, int j, MPI_Group testgroup, mdtest_results_t for (k=0; kitems[9] = num_dirs_in_tree; summary_table->stonewall_last_item[8] = num_dirs_in_tree; VERBOSE(1,-1,"main Tree removal : %14.3f sec, %14.3f ops/sec", (endCreate - startCreate), summary_table->rate[9]); - VERBOSE(2,-1,"main (at end of for j loop): Removing testdir of \"%s\"\n", testdir ); + VERBOSE(2,-1,"main (at end of for j loop): Removing testdir of '%s'\n", testdir ); for (int dir_iter = 0; dir_iter < directory_loops; dir_iter ++){ prep_testdir(j, dir_iter); @@ -1900,7 +1900,7 @@ mdtest_results_t * mdtest_run(int argc, char **argv, MPI_Comm world_com, FILE * char cmd_buffer[4096]; strncpy(cmd_buffer, argv[0], 4096); for (i = 1; i < argc; i++) { - snprintf(&cmd_buffer[strlen(cmd_buffer)], 4096-strlen(cmd_buffer), " \"%s\"", argv[i]); + snprintf(&cmd_buffer[strlen(cmd_buffer)], 4096-strlen(cmd_buffer), " '%s'", argv[i]); } VERBOSE(0,-1,"-- started at %s --\n", PrintTimestamp()); @@ -2064,7 +2064,7 @@ mdtest_results_t * mdtest_run(int argc, char **argv, MPI_Comm world_com, FILE * } /* display disk usage */ - 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); int packedByNode = QueryNodeMapping(testComm); @@ -2077,7 +2077,7 @@ mdtest_results_t * mdtest_run(int argc, char **argv, MPI_Comm world_com, FILE * VERBOSE(0,5,"Shifting ranks by %d for each phase.", nstride); } - VERBOSE(3,-1,"main (after display_freespace): testdirpath is \"%s\"", testdirpath ); + VERBOSE(3,-1,"main (after display_freespace): testdirpath is '%s'", testdirpath ); if (rank == 0) { if (random_seed > 0) { From 0ffec67d2b35f60cd99cfb8307a2f342414c3bcc Mon Sep 17 00:00:00 2001 From: John Bent Date: Sun, 28 Jul 2019 10:25:42 -0600 Subject: [PATCH 26/50] Following Julian's suggestion about better naming --- src/ior.c | 18 +++++++----------- src/ior.h | 2 +- src/mdtest.c | 6 ++++-- 3 files changed, 12 insertions(+), 14 deletions(-) diff --git a/src/ior.c b/src/ior.c index bb2b4c2..64530fd 100755 --- a/src/ior.c +++ b/src/ior.c @@ -939,7 +939,7 @@ static void InitTests(IOR_test_t *tests, MPI_Comm com) params->testComm = com; params->nodes = params->numTasks / tasksPerNode; params->tasksPerNode = tasksPerNode; - params->packedTasks = QueryNodeMapping(com); + params->tasksBlockMapping = QueryNodeMapping(com); if (params->numTasks == 0) { params->numTasks = size; } @@ -1361,11 +1361,9 @@ static void TestIoSys(IOR_test_t *test) } if (params->reorderTasks) { /* move two nodes away from writing node */ - int shift = 1; - if (params->packedTasks) { - shift = params->tasksPerNode; - } else { - shift = 1; + int shift = 1; /* assume a by-node (round-robin) mapping of tasks to nodes */ + if (params->tasksBlockMapping) { + shift = params->tasksPerNode; /* switch to by-slot (contiguous block) mapping */ } rankOffset = (2 * shift) % params->numTasks; } @@ -1403,11 +1401,9 @@ static void TestIoSys(IOR_test_t *test) /* Constant process offset reading */ if (params->reorderTasks) { /* move one node away from writing node */ - int shift = 1; - if (params->packedTasks) { - shift=params->tasksPerNode; - } else { - shift=1; + int shift = 1; /* assume a by-node (round-robin) mapping of tasks to nodes */ + if (params->tasksBlockMapping) { + shift=params->tasksPerNode; /* switch to a by-slot (contiguous block) mapping */ } rankOffset = (params->taskPerNodeOffset * shift) % params->numTasks; } diff --git a/src/ior.h b/src/ior.h index 2ea6c05..e245b08 100755 --- a/src/ior.h +++ b/src/ior.h @@ -100,7 +100,7 @@ typedef struct int numTasks; /* number of tasks for test */ int nodes; /* number of nodes for test */ int tasksPerNode; /* number of tasks per node */ - int packedTasks; /* are the tasks round-robin across nodes or are they packed tightly*/ + int tasksBlockMapping; /* are the tasks in contiguous blocks across nodes or round-robin */ int repetitions; /* number of repetitions of test */ int repCounter; /* rep counter */ int multiFile; /* multiple files */ diff --git a/src/mdtest.c b/src/mdtest.c index e35a20e..0005c0a 100644 --- a/src/mdtest.c +++ b/src/mdtest.c @@ -2067,11 +2067,13 @@ 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 ); if (rank == 0) display_freespace(testdirpath); - int packedByNode = QueryNodeMapping(testComm); + int tasksBlockMapping = QueryNodeMapping(testComm); /* set the shift to mimic IOR and shift by procs per node */ if (nstride > 0) { - if ( nodeCount > 1 && packedByNode ) { + if ( nodeCount > 1 && tasksBlockMapping ) { + /* the user set the stride presumably to get the consumer tasks on a different node than the producer tasks + however, if the mpirun scheduler placed the tasks by-slot (in a contiguous block) then we need to adjust the shift by ppn */ nstride *= tasksPerNode; } VERBOSE(0,5,"Shifting ranks by %d for each phase.", nstride); From a3c37808dadebc12c21ed4bad1ac55de5d25fa31 Mon Sep 17 00:00:00 2001 From: John Bent Date: Sun, 28 Jul 2019 11:17:11 -0600 Subject: [PATCH 27/50] Made FAIL take variable args so we can pass printf like args to it --- src/mdtest.c | 40 +++++++++++++++++++--------------------- src/utilities.c | 12 ++++++++++++ src/utilities.h | 19 +++++-------------- 3 files changed, 36 insertions(+), 35 deletions(-) diff --git a/src/mdtest.c b/src/mdtest.c index 0005c0a..127aa5f 100644 --- a/src/mdtest.c +++ b/src/mdtest.c @@ -288,11 +288,11 @@ static void create_remove_dirs (const char *path, bool create, uint64_t itemNum) if (create) { if (backend->mkdir(curr_item, DIRMODE, ¶m) == -1) { - FAIL("unable to create directory"); + FAIL("unable to create directory %s", curr_item); } } else { if (backend->rmdir(curr_item, ¶m) == -1) { - FAIL("unable to remove directory"); + FAIL("unable to remove directory %s", curr_item); } } } @@ -334,7 +334,7 @@ static void create_file (const char *path, uint64_t itemNum) { else aiori_fh = backend->open (curr_item, ¶m); if (NULL == aiori_fh) { - FAIL("unable to open file"); + FAIL("unable to open file %s", curr_item); } /* @@ -351,7 +351,7 @@ static void create_file (const char *path, uint64_t itemNum) { else aiori_fh = backend->create (curr_item, ¶m); if (NULL == aiori_fh) { - FAIL("unable to create file"); + FAIL("unable to create file %s", curr_item); } } @@ -365,7 +365,7 @@ static void create_file (const char *path, uint64_t itemNum) { param.offset = 0; param.fsyncPerWrite = sync_file; if ( write_bytes != (size_t) backend->xfer (WRITE, aiori_fh, (IOR_size_t *) write_buffer, write_bytes, ¶m)) { - FAIL("unable to write file"); + FAIL("unable to write file %s", curr_item); } } @@ -422,7 +422,7 @@ void collective_helper(const int dirs, const int create, const char* path, uint6 param.openFlags = IOR_WRONLY | IOR_CREAT; aiori_fh = backend->create (curr_item, ¶m); if (NULL == aiori_fh) { - FAIL("unable to create file"); + FAIL("unable to create file %s", curr_item); } backend->close (aiori_fh, ¶m); @@ -586,9 +586,7 @@ void mdtest_stat(const int random, const int dirs, const long dir_iter, const ch /* below temp used to be hiername */ VERBOSE(3,5,"mdtest_stat %4s: %s", (dirs ? "dir" : "file"), item); if (-1 == backend->stat (item, &buf, ¶m)) { - char msg_buf[4096]; - snprintf(msg_buf, 4096, "unable to stat %s %s", dirs ? "directory" : "file", item); - FAIL(msg_buf); + FAIL("unable to stat %s %s", dirs ? "directory" : "file", item); } } } @@ -679,13 +677,13 @@ void mdtest_read(int random, int dirs, const long dir_iter, char *path) { param.openFlags = O_RDONLY; aiori_fh = backend->open (item, ¶m); if (NULL == aiori_fh) { - FAIL("unable to open file"); + FAIL("unable to open file %s", item); } /* read file */ if (read_bytes > 0) { if (read_bytes != (size_t) backend->xfer (READ, aiori_fh, (IOR_size_t *) read_buffer, read_bytes, ¶m)) { - FAIL("unable to read file"); + FAIL("unable to read file %s", item); } } @@ -1342,7 +1340,7 @@ void summarize_results(int iterations) { void valid_tests() { if (((stone_wall_timer_seconds > 0) && (branch_factor > 1)) || ! barriers) { - FAIL( "Error, stone wall timer does only work with a branch factor <= 1 and with barriers\n"); + FAIL( "Error, stone wall timer does only work with a branch factor <= 1 (current is %d) and with barriers\n", branch_factor); } if (!create_only && !stat_only && !read_only && !remove_only) { @@ -1446,7 +1444,7 @@ void show_file_system_size(char *file_system) { ret = backend->statfs (file_system, &stat_buf, ¶m); if (0 != ret) { - FAIL("unable to stat file system"); + FAIL("unable to stat file system %s", file_system); } total_file_system_size = stat_buf.f_blocks * stat_buf.f_bsize; @@ -1469,7 +1467,7 @@ void show_file_system_size(char *file_system) { * 100; if (realpath(file_system, real_path) == NULL) { - FAIL("unable to use realpath()"); + FAIL("unable to use realpath() on file system %s", file_system); } @@ -1539,7 +1537,7 @@ void create_remove_directory_tree(int create, if (!create) { VERBOSE(2,5,"Remove directory '%s'", dir); if (-1 == backend->rmdir(dir, ¶m)) { - FAIL("Unable to remove directory"); + FAIL("Unable to remove directory %s", dir); } } } else if (currDepth <= depth) { @@ -1555,7 +1553,7 @@ void create_remove_directory_tree(int create, if (create) { VERBOSE(2,5,"Making directory '%s'", temp_path); if (-1 == backend->mkdir(temp_path, DIRMODE, ¶m)) { - FAIL("Unable to create directory"); + FAIL("Unable to create directory %s", temp_path); } } @@ -1566,7 +1564,7 @@ void create_remove_directory_tree(int create, if (!create) { VERBOSE(2,5,"Remove directory '%s'", temp_path); if (-1 == backend->rmdir(temp_path, ¶m)) { - FAIL("Unable to remove directory"); + FAIL("Unable to remove directory %s", temp_path); } } @@ -1596,7 +1594,7 @@ static void mdtest_iteration(int i, int j, MPI_Group testgroup, mdtest_results_t VERBOSE(2,5,"main (for j loop): making testdir, '%s'", testdir ); if ((rank < path_count) && backend->access(testdir, F_OK, ¶m) != 0) { if (backend->mkdir(testdir, DIRMODE, ¶m) != 0) { - FAIL("Unable to create test directory"); + FAIL("Unable to create test directory %s", testdir); } } } @@ -1772,7 +1770,7 @@ static void mdtest_iteration(int i, int j, MPI_Group testgroup, mdtest_results_t if ((rank < path_count) && backend->access(testdir, F_OK, ¶m) == 0) { //if (( rank == 0 ) && access(testdir, F_OK) == 0) { if (backend->rmdir(testdir, ¶m) == -1) { - FAIL("unable to remove directory"); + FAIL("unable to remove directory %s", testdir); } } } @@ -2049,7 +2047,7 @@ mdtest_results_t * mdtest_run(int argc, char **argv, MPI_Comm world_com, FILE * if (path_count == 0) { /* special case where no directory path provided with '-d' option */ char *ret = getcwd(testdirpath, MAX_PATHLEN); if (ret == NULL) { - FAIL("Unable to get current working directory"); + FAIL("Unable to get current working directory on %s", testdirpath); } path_count = 1; } else { @@ -2059,7 +2057,7 @@ mdtest_results_t * mdtest_run(int argc, char **argv, MPI_Comm world_com, FILE * /* if directory does not exist, create it */ if ((rank < path_count) && backend->access(testdirpath, F_OK, ¶m) != 0) { if (backend->mkdir(testdirpath, DIRMODE, ¶m) != 0) { - FAIL("Unable to create test directory path"); + FAIL("Unable to create test directory path %s", testdirpath); } } diff --git a/src/utilities.c b/src/utilities.c index 5a3168c..8eb4485 100755 --- a/src/utilities.c +++ b/src/utilities.c @@ -20,6 +20,7 @@ # define _GNU_SOURCE /* Needed for O_DIRECT in fcntl */ #endif /* __linux__ */ +#include #include #include #include @@ -75,6 +76,17 @@ void* safeMalloc(uint64_t size){ return d; } +void FailMessage(int rank, const char *location, char *format, ...) { + char msg[4096]; + va_list args; + va_start(args, format); + vsnprintf(msg, 4096, format, args); + va_end(args); + fprintf(out_logfile, "%s: Process %d: FAILED in %s, %s: %s\n", + PrintTimestamp(), rank, location, msg, strerror(errno)); + fflush(out_logfile); + MPI_Abort(testComm, 1); +} size_t NodeMemoryStringToBytes(char *size_str) { diff --git a/src/utilities.h b/src/utilities.h index d811261..0964169 100755 --- a/src/utilities.h +++ b/src/utilities.h @@ -36,23 +36,14 @@ extern enum OutputFormat_t outputFormat; /* format of the output */ #ifdef __linux__ -#define FAIL(msg) do { \ - fprintf(out_logfile, "%s: Process %d: FAILED in %s, %s: %s\n", \ - PrintTimestamp(), rank, __func__, \ - msg, strerror(errno)); \ - fflush(out_logfile); \ - MPI_Abort(testComm, 1); \ - } while(0) +#define ERROR_LOCATION __func__ #else -#define FAIL(msg) do { \ - fprintf(out_logfile, "%s: Process %d: FAILED at %d, %s: %s\n", \ - PrintTimestamp(), rank, __LINE__, \ - msg, strerror(errno)); \ - fflush(out_logfile); \ - MPI_Abort(testComm, 1); \ - } while(0) +#define ERROR_LOCATION __LINE__ #endif +#define FAIL(...) FailMessage(rank, ERROR_LOCATION, __VA_ARGS__) +void FailMessage(int rank, const char *location, char *format, ...); + void* safeMalloc(uint64_t size); void set_o_direct_flag(int *fd); From 3890b71b54f6bc3b8d931173bb6fb27090ddc652 Mon Sep 17 00:00:00 2001 From: John Bent Date: Thu, 1 Aug 2019 09:42:03 +0900 Subject: [PATCH 28/50] Fixed issues and followed suggestions from Glenn's review of the PR --- src/ior.c | 4 ++-- src/mdtest.c | 4 ++-- src/parse_options.c | 2 +- src/utilities.c | 4 ++-- src/utilities.h | 2 +- 5 files changed, 8 insertions(+), 8 deletions(-) diff --git a/src/ior.c b/src/ior.c index 64530fd..15b1d07 100755 --- a/src/ior.c +++ b/src/ior.c @@ -939,7 +939,7 @@ static void InitTests(IOR_test_t *tests, MPI_Comm com) params->testComm = com; params->nodes = params->numTasks / tasksPerNode; params->tasksPerNode = tasksPerNode; - params->tasksBlockMapping = QueryNodeMapping(com); + params->tasksBlockMapping = QueryNodeMapping(com,false); if (params->numTasks == 0) { params->numTasks = size; } @@ -1223,7 +1223,7 @@ static void TestIoSys(IOR_test_t *test) } if (rank == 0 && params->reorderTasks == TRUE && verbose >= VERBOSE_1) { 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); } params->tasksPerNode = CountTasksPerNode(testComm); diff --git a/src/mdtest.c b/src/mdtest.c index 127aa5f..f65ea7f 100644 --- a/src/mdtest.c +++ b/src/mdtest.c @@ -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, "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, "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}, {'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}, @@ -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 ); 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 */ if (nstride > 0) { diff --git a/src/parse_options.c b/src/parse_options.c index ba72413..af30c36 100755 --- a/src/parse_options.c +++ b/src/parse_options.c @@ -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}, {'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, "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, "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}, diff --git a/src/utilities.c b/src/utilities.c index 8eb4485..99d26e7 100755 --- a/src/utilities.c +++ b/src/utilities.c @@ -229,7 +229,7 @@ void DumpBuffer(void *buffer, 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 */ -int QueryNodeMapping(MPI_Comm comm) { +int QueryNodeMapping(MPI_Comm comm, int print_nodemap) { char localhost[MAX_PATHLEN], roothost[MAX_PATHLEN]; int 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 */ int same_as_root = strcmp(roothost,localhost) == 0; 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: " ); for ( int i = 0; i < num_ranks; i++ ) { fprintf( out_logfile, "%d", node_map[i] ); diff --git a/src/utilities.h b/src/utilities.h index 0964169..d2c9962 100755 --- a/src/utilities.h +++ b/src/utilities.h @@ -56,7 +56,7 @@ void SetHints (MPI_Info *, char *); void ShowHints (MPI_Info *); char *HumanReadable(IOR_offset_t value, int base); int CountTasksPerNode(MPI_Comm comm); -int QueryNodeMapping(MPI_Comm comm); +int QueryNodeMapping(MPI_Comm comm, int print_nodemap); void DelaySecs(int delay); void updateParsedOptions(IOR_param_t * options, options_all_t * global_options); size_t NodeMemoryStringToBytes(char *size_str); From 6c0fadc2a9f82623bbd6016194802e35245daea6 Mon Sep 17 00:00:00 2001 From: "Julian M. Kunkel" Date: Thu, 1 Aug 2019 17:20:01 +0100 Subject: [PATCH 29/50] Include performance when stonewall is hit to output. --- src/ior-output.c | 23 +++++++++++++++++++---- src/ior.c | 6 +----- 2 files changed, 20 insertions(+), 9 deletions(-) diff --git a/src/ior-output.c b/src/ior-output.c index 4bdb37d..7049a97 100644 --- a/src/ior-output.c +++ b/src/ior-output.c @@ -18,8 +18,8 @@ static void PrintNextToken(); void PrintTableHeader(){ if (outputFormat == OUTPUT_DEFAULT){ fprintf(out_resultfile, "\n"); - fprintf(out_resultfile, "access bw(MiB/s) block(KiB) xfer(KiB) open(s) wr/rd(s) close(s) total(s) iter\n"); - fprintf(out_resultfile, "------ --------- ---------- --------- -------- -------- -------- -------- ----\n"); + fprintf(out_resultfile, "access bw(MiB/s) block(KiB) xfer(KiB) open(s) wr/rd(s) close(s) total(s) iter\n"); + fprintf(out_resultfile, "------ --------- ---------- --------- -------- -------- -------- -------- ----\n"); } } @@ -534,10 +534,14 @@ static void PrintLongSummaryOneOperation(IOR_test_t *test, const int access) reps = params->repetitions; double * times = malloc(sizeof(double)* reps); + long long stonewall_avg_data_accessed = 0; + double stonewall_time = 0; for(int i=0; i < reps; i++){ IOR_point_t *point = (access == WRITE) ? &results[i].write : &results[i].read; times[i] = point->time; + stonewall_time += point->stonewall_time; + stonewall_avg_data_accessed += point->stonewall_avg_data_accessed; } bw = bw_values(reps, results, times, access); @@ -558,6 +562,13 @@ static void PrintLongSummaryOneOperation(IOR_test_t *test, const int access) fprintf(out_resultfile, "%10.2f ", ops->mean); fprintf(out_resultfile, "%10.2f ", ops->sd); fprintf(out_resultfile, "%10.5f ", mean_of_array_of_doubles(times, reps)); + if(test->params.stoneWallingWearOut){ + fprintf(out_resultfile, "%10.2f ", stonewall_time / reps); + fprintf(out_resultfile, "%13.2f ", stonewall_avg_data_accessed / stonewall_time / MEBIBYTE); + }else{ + fprintf(out_resultfile, "%10s ", "NA"); + fprintf(out_resultfile, "%13s ", "NA"); + } fprintf(out_resultfile, "%5d ", params->id); fprintf(out_resultfile, "%6d ", params->numTasks); fprintf(out_resultfile, "%3d ", params->tasksPerNode); @@ -603,6 +614,10 @@ static void PrintLongSummaryOneOperation(IOR_test_t *test, const int access) PrintKeyValDouble("OPsMean", ops->mean); PrintKeyValDouble("OPsSD", ops->sd); PrintKeyValDouble("MeanTime", mean_of_array_of_doubles(times, reps)); + if(test->params.stoneWallingWearOut){ + PrintKeyValDouble("StoneWallTime", stonewall_time / reps); + PrintKeyValDouble("StoneWallbwMeanMIB", stonewall_avg_data_accessed / stonewall_time / MEBIBYTE); + } PrintKeyValDouble("xsizeMiB", (double) point->aggFileSizeForBW / MEBIBYTE); PrintEndSection(); }else if (outputFormat == OUTPUT_CSV){ @@ -635,10 +650,10 @@ void PrintLongSummaryHeader() } fprintf(out_resultfile, "\n"); - fprintf(out_resultfile, "%-9s %10s %10s %10s %10s %10s %10s %10s %10s %10s", + fprintf(out_resultfile, "%-9s %10s %10s %10s %10s %10s %10s %10s %10s %10s %10s %13s", "Operation", "Max(MiB)", "Min(MiB)", "Mean(MiB)", "StdDev", "Max(OPs)", "Min(OPs)", "Mean(OPs)", "StdDev", - "Mean(s)"); + "Mean(s)", "Stonewall(s)", "Stonewall(MiB)"); fprintf(out_resultfile, " Test# #Tasks tPN reps fPP reord reordoff reordrand seed" " segcnt "); fprintf(out_resultfile, "%8s %8s %9s %5s", " blksiz", "xsize","aggs(MiB)", "API"); diff --git a/src/ior.c b/src/ior.c index 15b1d07..4cd5571 100755 --- a/src/ior.c +++ b/src/ior.c @@ -1400,7 +1400,7 @@ static void TestIoSys(IOR_test_t *test) /* Get rankOffset [file offset] for this process to read, based on -C,-Z,-Q,-X options */ /* Constant process offset reading */ if (params->reorderTasks) { - /* move one node away from writing node */ + /* move one node away from writing node */ int shift = 1; /* assume a by-node (round-robin) mapping of tasks to nodes */ if (params->tasksBlockMapping) { shift=params->tasksPerNode; /* switch to a by-slot (contiguous block) mapping */ @@ -1944,10 +1944,6 @@ static IOR_offset_t WriteOrRead(IOR_param_t *test, IOR_results_t *results, point->stonewall_min_data_accessed /1024.0 / 1024 / 1024, point->stonewall_avg_data_accessed / 1024.0 / 1024 / 1024 / test->numTasks , point->stonewall_time); point->stonewall_min_data_accessed *= test->numTasks; } - if(pairs_accessed_min == pairCnt){ - point->stonewall_min_data_accessed = 0; - point->stonewall_avg_data_accessed = 0; - } if(pairCnt != point->pairs_accessed){ // some work needs still to be done ! for(; pairCnt < point->pairs_accessed; pairCnt++ ) { From 061b5a860f6ac010ec6cabab54d83ef2a1cad0d7 Mon Sep 17 00:00:00 2001 From: "Julian M. Kunkel" Date: Thu, 1 Aug 2019 17:54:11 +0100 Subject: [PATCH 30/50] Backmerged: New option: print rate AND time; improves debugging. --- src/mdtest.c | 12 ++++++++++-- 1 file changed, 10 insertions(+), 2 deletions(-) diff --git a/src/mdtest.c b/src/mdtest.c index f65ea7f..d2cd068 100644 --- a/src/mdtest.c +++ b/src/mdtest.c @@ -131,6 +131,7 @@ static uint64_t items_per_dir; static uint64_t num_dirs_in_tree_calc; /* this is a workaround until the overal code is refactored */ static int directory_loops; static int print_time; +static int print_rate_and_time; static int random_seed; static int shared_file; static int files_only; @@ -1197,7 +1198,7 @@ void file_test(const int iteration, const int ntasks, const char *path, rank_pro VERBOSE(1,-1," File removal : %14.3f sec, %14.3f ops/sec", t[4] - t[3], summary_table[iteration].rate[7]); } -void summarize_results(int iterations) { +void summarize_results(int iterations, int print_time) { char access[MAX_PATHLEN]; int i, j, k; int start, stop, tableSize = MDTEST_LAST_NUM; @@ -1794,6 +1795,7 @@ void mdtest_init_args(){ items_per_dir = 0; random_seed = 0; print_time = 0; + print_rate_and_time = 0; shared_file = 0; files_only = 0; dirs_only = 0; @@ -1864,6 +1866,7 @@ mdtest_results_t * mdtest_run(int argc, char **argv, MPI_Comm world_com, FILE * {'n', NULL, "every process will creat/stat/read/remove # directories and files", OPTION_OPTIONAL_ARGUMENT, 'l', & items}, {'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, "print rate AND time", OPTION_FLAG, 'd', & print_rate_and_time}, {'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}, {'s', NULL, "stride between the number of tasks for each test", OPTION_OPTIONAL_ARGUMENT, 'd', & stride}, @@ -2154,7 +2157,12 @@ mdtest_results_t * mdtest_run(int argc, char **argv, MPI_Comm world_com, FILE * // keep track of the current status for stonewalling mdtest_iteration(i, j, testgroup, & summary_table[j]); } - summarize_results(iterations); + if (print_rate_and_time){ + summarize_results(iterations, 0); + summarize_results(iterations, 1); + }else{ + summarize_results(iterations, print_time); + } if (i == 1 && stride > 1) { i = 0; } From df8355a9bc755c9c83384fa14d7c128ce6b347b3 Mon Sep 17 00:00:00 2001 From: "Julian M. Kunkel" Date: Thu, 1 Aug 2019 17:57:45 +0100 Subject: [PATCH 31/50] Added output of mdtest stonewall timer. --- src/mdtest.c | 232 +++++++++++++++++++++++++++------------------------ 1 file changed, 123 insertions(+), 109 deletions(-) diff --git a/src/mdtest.c b/src/mdtest.c index d2cd068..1ff204d 100644 --- a/src/mdtest.c +++ b/src/mdtest.c @@ -968,10 +968,10 @@ int updateStoneWallIterations(int iteration, rank_progress_t * progress, double MPI_Reduce(& progress->items_done, & min_accessed, 1, MPI_LONG_LONG_INT, MPI_MIN, 0, testComm); long long sum_accessed = 0; MPI_Reduce(& progress->items_done, & sum_accessed, 1, MPI_LONG_LONG_INT, MPI_SUM, 0, testComm); + summary_table[iteration].stonewall_item_sum[MDTEST_FILE_CREATE_NUM] = sum_accessed; + summary_table[iteration].stonewall_item_min[MDTEST_FILE_CREATE_NUM] = min_accessed * size; if(items != (sum_accessed / size)){ - summary_table[iteration].stonewall_item_sum[MDTEST_FILE_CREATE_NUM] = sum_accessed; - summary_table[iteration].stonewall_item_min[MDTEST_FILE_CREATE_NUM] = min_accessed * size; VERBOSE(0,-1, "Continue stonewall hit min: %lld max: %lld avg: %.1f \n", min_accessed, max_iter, ((double) sum_accessed) / size); hit = 1; } @@ -1193,6 +1193,9 @@ void file_test(const int iteration, const int ntasks, const char *path, rank_pro } VERBOSE(1,-1," File creation : %14.3f sec, %14.3f ops/sec", t[1] - t[0], summary_table[iteration].rate[4]); + if(summary_table[iteration].stonewall_time[MDTEST_FILE_CREATE_NUM]){ + VERBOSE(1,-1," File creation (stonewall): %14.3f sec, %14.3f ops/sec", summary_table[iteration].stonewall_time[MDTEST_FILE_CREATE_NUM], summary_table[iteration].stonewall_item_sum[MDTEST_FILE_CREATE_NUM]); + } VERBOSE(1,-1," File stat : %14.3f sec, %14.3f ops/sec", t[2] - t[1], summary_table[iteration].rate[5]); VERBOSE(1,-1," File read : %14.3f sec, %14.3f ops/sec", t[3] - t[2], summary_table[iteration].rate[6]); VERBOSE(1,-1," File removal : %14.3f sec, %14.3f ops/sec", t[4] - t[3], summary_table[iteration].rate[7]); @@ -1211,129 +1214,141 @@ void summarize_results(int iterations, int print_time) { MPI_Barrier(testComm); for(int i=0; i < iterations; i++){ - if(print_time){ - MPI_Gather(& summary_table[i].time[0], tableSize, MPI_DOUBLE, & all[i*tableSize*size], tableSize, MPI_DOUBLE, 0, testComm); - }else{ - MPI_Gather(& summary_table[i].rate[0], tableSize, MPI_DOUBLE, & all[i*tableSize*size], tableSize, MPI_DOUBLE, 0, testComm); - } + MPI_Gather(& summary_table[i].time[0], tableSize, MPI_DOUBLE, & all[i*tableSize*size], tableSize, MPI_DOUBLE, 0, testComm); + MPI_Gather(& summary_table[i].rate[0], tableSize, MPI_DOUBLE, & all[i*tableSize*size], tableSize, MPI_DOUBLE, 0, testComm); } - if (rank == 0) { + if (rank != 0) { + return; + } - VERBOSE(0,-1,"\nSUMMARY %s: (of %d iterations)", print_time ? "time": "rate", iterations); - VERBOSE(0,-1," Operation Max Min Mean Std Dev"); - VERBOSE(0,-1," --------- --- --- ---- -------"); + VERBOSE(0,-1,"\nSUMMARY %s: (of %d iterations)", print_time ? "time": "rate", iterations); + VERBOSE(0,-1," Operation Max Min Mean Std Dev"); + VERBOSE(0,-1," --------- --- --- ---- -------"); - /* if files only access, skip entries 0-3 (the dir tests) */ - if (files_only && !dirs_only) { - start = 4; - } else { - start = 0; - } + /* if files only access, skip entries 0-3 (the dir tests) */ + if (files_only && !dirs_only) { + start = 4; + } else { + start = 0; + } - /* if directories only access, skip entries 4-7 (the file tests) */ - if (dirs_only && !files_only) { - stop = 4; - } else { - stop = 8; - } + /* if directories only access, skip entries 4-7 (the file tests) */ + if (dirs_only && !files_only) { + stop = 4; + } else { + stop = 8; + } - /* special case: if no directory or file tests, skip all */ - if (!dirs_only && !files_only) { - start = stop = 0; - } + /* special case: if no directory or file tests, skip all */ + if (!dirs_only && !files_only) { + start = stop = 0; + } - for (i = start; i < stop; i++) { - min = max = all[i]; - for (k=0; k < size; k++) { - for (j = 0; j < iterations; j++) { - curr = all[(k*tableSize*iterations) - + (j*tableSize) + i]; - if (min > curr) { - min = curr; - } - if (max < curr) { - max = curr; - } - sum += curr; - } - } - mean = sum / (iterations * size); - for (k=0; k curr) { + min = curr; + } + if (max < curr) { + max = curr; + } + sum += curr; } - - if (min > curr) { - min = curr; - } - if (max < curr) { - max = curr; - } - sum += curr; } - mean = sum / (iterations); - for (j = 0; j < iterations; j++) { - if(print_time){ - curr = summary_table[j].time[i]; - }else{ - curr = summary_table[j].rate[i]; + mean = sum / (iterations * size); + for (k=0; k curr) { + min = curr; + } + if (max < curr) { + max = curr; + } + sum += curr; } + mean = sum / (iterations); + for (j = 0; j < iterations; j++) { + if(print_time){ + curr = summary_table[j].time[i]; + }else{ + curr = summary_table[j].rate[i]; + } + + var += pow((mean - curr), 2); + } + var = var / (iterations); + sd = sqrt(var); + switch (i) { + case 8: strcpy(access, "Tree creation :"); break; + case 9: strcpy(access, "Tree removal :"); break; + default: strcpy(access, "ERR"); break; + } + fprintf(out_logfile, " %s ", access); + fprintf(out_logfile, "%14.3f ", max); + fprintf(out_logfile, "%14.3f ", min); + fprintf(out_logfile, "%14.3f ", mean); + fprintf(out_logfile, "%14.3f\n", sd); + fflush(out_logfile); + sum = var = 0; } } @@ -1474,7 +1489,7 @@ void show_file_system_size(char *file_system) { /* show results */ VERBOSE(0,-1,"Path: %s", real_path); - VERBOSE(0,-1,"FS: %.1f %s Used FS: %2.1f%% Inodes: %.1f %s Used Inodes: %2.1f%%\n", + VERBOSE(0,-1,"FS: %.1f %s Used FS: %2.1f%% Inodes: %.1f %s Used Inodes: %2.1f%%\n", total_file_system_size_hr, file_system_unit_str, used_file_system_percentage, (double)total_inodes / (double)inode_unit_val, inode_unit_str, used_inode_percentage); @@ -1881,7 +1896,6 @@ mdtest_results_t * mdtest_run(int argc, char **argv, MPI_Comm world_com, FILE * {'x', NULL, "StoneWallingStatusFile; contains the number of iterations of the creation phase, can be used to split phases across runs", OPTION_OPTIONAL_ARGUMENT, 's', & stoneWallingStatusFile}, {'y', NULL, "sync file after writing", OPTION_FLAG, 'd', & sync_file}, {'z', NULL, "depth of hierarchical directory structure", OPTION_OPTIONAL_ARGUMENT, 'd', & depth}, - {'Z', NULL, "print time instead of rate", OPTION_FLAG, 'd', & print_time}, LAST_OPTION }; options_all_t * global_options = airoi_create_all_module_options(options); From ce1ae750f6bbe23c915c1c9f034834fe382b51c1 Mon Sep 17 00:00:00 2001 From: "Julian M. Kunkel" Date: Thu, 1 Aug 2019 18:29:32 +0100 Subject: [PATCH 32/50] MDtest: Support to verify the read operation with a default pattern. --- src/mdtest.c | 31 ++++++++++++++++++++++++++++++- 1 file changed, 30 insertions(+), 1 deletion(-) diff --git a/src/mdtest.c b/src/mdtest.c index 1ff204d..d68c86b 100644 --- a/src/mdtest.c +++ b/src/mdtest.c @@ -103,6 +103,7 @@ static char unique_rm_dir[MAX_PATHLEN]; static char unique_rm_uni_dir[MAX_PATHLEN]; static char *write_buffer; static char *read_buffer; +static char *verify_read_buffer; static char *stoneWallingStatusFile; @@ -110,6 +111,8 @@ static int barriers; static int create_only; static int stat_only; static int read_only; +static int verify_read; +static int verification_error; static int remove_only; static int leaf_only; static unsigned branch_factor; @@ -200,6 +203,12 @@ void VerboseMessage (int root_level, int any_level, int line, char * format, ... } } +void generate_memory_pattern(char * buffer, size_t bytes){ + for(int i=0; i < bytes; i++){ + buffer[i] = i + 1; + } +} + void offset_timers(double * t, int tcount) { double toffset; int i; @@ -607,6 +616,14 @@ void mdtest_read(int random, int dirs, const long dir_iter, char *path) { if (read_buffer == NULL) { FAIL("out of memory"); } + + if (verify_read > 0) { + verify_read_buffer = (char *)malloc(read_bytes); + if (verify_read_buffer == NULL) { + FAIL("out of memory"); + } + generate_memory_pattern(verify_read_buffer, read_bytes); + } } uint64_t stop_items = items; @@ -686,6 +703,12 @@ void mdtest_read(int random, int dirs, const long dir_iter, char *path) { if (read_bytes != (size_t) backend->xfer (READ, aiori_fh, (IOR_size_t *) read_buffer, read_bytes, ¶m)) { FAIL("unable to read file %s", item); } + if(verify_read){ + if (memcmp(read_buffer, verify_read_buffer, read_bytes) != 0){ + VERBOSE(2, -1, "Error verifying %s", item); + verification_error++; + } + } } /* close file */ @@ -1803,6 +1826,8 @@ void mdtest_init_args(){ create_only = 0; stat_only = 0; read_only = 0; + verify_read = 0; + verification_error = 0; remove_only = 0; leaf_only = 0; depth = 0; @@ -1894,6 +1919,7 @@ mdtest_results_t * mdtest_run(int argc, char **argv, MPI_Comm world_com, FILE * {'w', NULL, "bytes to write to each file after it is created", OPTION_OPTIONAL_ARGUMENT, 'l', & write_bytes}, {'W', NULL, "number in seconds; stonewall timer, write as many seconds and ensure all processes did the same number of operations (currently only stops during create phase)", OPTION_OPTIONAL_ARGUMENT, 'd', & stone_wall_timer_seconds}, {'x', NULL, "StoneWallingStatusFile; contains the number of iterations of the creation phase, can be used to split phases across runs", OPTION_OPTIONAL_ARGUMENT, 's', & stoneWallingStatusFile}, + {'X', "verify-read", "Verify the data read", OPTION_FLAG, 'd', & verify_read}, {'y', NULL, "sync file after writing", OPTION_FLAG, 'd', & sync_file}, {'z', NULL, "depth of hierarchical directory structure", OPTION_OPTIONAL_ARGUMENT, 'd', & depth}, LAST_OPTION @@ -2057,7 +2083,7 @@ mdtest_results_t * mdtest_run(int argc, char **argv, MPI_Comm world_com, FILE * if (write_buffer == NULL) { FAIL("out of memory"); } - memset(write_buffer, 0x23, write_bytes); + generate_memory_pattern(write_buffer, write_bytes); } /* setup directory path to work in */ @@ -2182,6 +2208,9 @@ mdtest_results_t * mdtest_run(int argc, char **argv, MPI_Comm world_com, FILE * } } + if(verification_error){ + VERBOSE(0, -1, "\nERROR: verifying the data read! Take the performance values with care!\n"); + } VERBOSE(0,-1,"-- finished at %s --\n", PrintTimestamp()); if (random_seed > 0) { From cf56715a5a2ab12f8f4b0bfed7700900e9e3f770 Mon Sep 17 00:00:00 2001 From: "Julian M. Kunkel" Date: Thu, 1 Aug 2019 18:33:44 +0100 Subject: [PATCH 33/50] Make sure that each read buffer contains an invalid first byte. --- src/mdtest.c | 1 + 1 file changed, 1 insertion(+) diff --git a/src/mdtest.c b/src/mdtest.c index d68c86b..00eb57c 100644 --- a/src/mdtest.c +++ b/src/mdtest.c @@ -700,6 +700,7 @@ void mdtest_read(int random, int dirs, const long dir_iter, char *path) { /* read file */ if (read_bytes > 0) { + read_buffer[0] = 42; if (read_bytes != (size_t) backend->xfer (READ, aiori_fh, (IOR_size_t *) read_buffer, read_bytes, ¶m)) { FAIL("unable to read file %s", item); } From b1b66962acc1f1ecfdcd9e89965c5a3a24516f84 Mon Sep 17 00:00:00 2001 From: Osamu Tatebe Date: Fri, 2 Aug 2019 13:03:59 +0900 Subject: [PATCH 34/50] incorrect warning --- src/ior.c | 1 + 1 file changed, 1 insertion(+) diff --git a/src/ior.c b/src/ior.c index 3ef411c..1ebcda8 100755 --- a/src/ior.c +++ b/src/ior.c @@ -1580,6 +1580,7 @@ static void ValidateTests(IOR_param_t * test) && (strcasecmp(test->api, "MPIIO") != 0) && (strcasecmp(test->api, "MMAP") != 0) && (strcasecmp(test->api, "HDFS") != 0) + && (strcasecmp(test->api, "Gfarm") != 0) && (strcasecmp(test->api, "RADOS") != 0)) && test->fsync) WARN_RESET("fsync() not supported in selected backend", test, &defaults, fsync); From f89f33873426fe163661318c1a001e5240590bdf Mon Sep 17 00:00:00 2001 From: Axel Huebl Date: Fri, 2 Aug 2019 19:30:29 -0500 Subject: [PATCH 35/50] Travis CI: Fix HDF5 Build Fix the CI. --- .travis.yml | 9 ++++++--- 1 file changed, 6 insertions(+), 3 deletions(-) diff --git a/.travis.yml b/.travis.yml index 29e091c..7d8202d 100644 --- a/.travis.yml +++ b/.travis.yml @@ -9,7 +9,7 @@ install: # Install MPI - sudo apt-get install -y openmpi-bin libopenmpi-dev # Install HDF5 - - sudo apt-get install -y hdf5-tools libhdf5-mpi-dev + - sudo apt-get install -y hdf5-tools libhdf5-openmpi-dev # Install Lustre # TODO: As far as a i can see it needs to be compiled form source with kernel # module as there is no package. @@ -22,10 +22,13 @@ install: # Install HDFS # TODO: Not sure with which c libray hdfs should be used and if it is in # the ubuntu repos - # Probably hadoop needs to be installed an provides nativ api. + # Probably hadoop needs to be installed an provides native API. # Install Amazon S3 # TODO: The needed library needs to be installed. Follow the instructions in # aiori-S3.c to achive this. # GPFS # NOTE: Think GPFS need a license and is therefore not testable with travis. -script: ./travis-build.sh && CONFIGURE_OPTS="--with-hdf5" ./travis-test.sh +script: + - ./travis-build.sh + - export LD_LIBRARY_PATH=/usr/lib/x86_64-linux-gnu/hdf5/openmpi:${LD_LIBRARY_PATH} + - CONFIGURE_OPTS="--with-hdf5" CFLAGS="-I/usr/include/hdf5/openmpi -L/usr/lib/x86_64-linux-gnu/hdf5/openmpi" ./travis-test.sh From bfff0df8fd99dc53068dc28ab3523bfbf86f95c9 Mon Sep 17 00:00:00 2001 From: Axel Huebl Date: Fri, 2 Aug 2019 19:23:05 -0500 Subject: [PATCH 36/50] Fix Some Memory Leaks Fixing some memory leaks :) --- src/aiori-POSIX.c | 1 + src/mdtest.c | 3 +++ src/test/lib.c | 5 +++++ 3 files changed, 9 insertions(+) diff --git a/src/aiori-POSIX.c b/src/aiori-POSIX.c index d78cd40..0eb663b 100755 --- a/src/aiori-POSIX.c +++ b/src/aiori-POSIX.c @@ -89,6 +89,7 @@ option_help * POSIX_options(void ** init_backend_options, void * init_values){ } *init_backend_options = o; + free(o); option_help h [] = { {0, "posix.odirect", "Direct I/O Mode", OPTION_FLAG, 'd', & o->direct_io}, diff --git a/src/mdtest.c b/src/mdtest.c index 1ff204d..e187a77 100644 --- a/src/mdtest.c +++ b/src/mdtest.c @@ -1901,6 +1901,9 @@ mdtest_results_t * mdtest_run(int argc, char **argv, MPI_Comm world_com, FILE * options_all_t * global_options = airoi_create_all_module_options(options); option_parse(argc, argv, global_options); updateParsedOptions(& param, global_options); + + free(global_options->modules); + free(global_options); backend = param.backend; MPI_Comm_rank(testComm, &rank); diff --git a/src/test/lib.c b/src/test/lib.c index 55ca6f0..c163f54 100644 --- a/src/test/lib.c +++ b/src/test/lib.c @@ -16,6 +16,11 @@ int main(int argc, char ** argv){ fprintf(stderr, "Could not run ior\n"); ret = 1; } + else + { + free(res->params.platform); + free(res); + } } if (rank == 0){ char * param[] = {"./mdtest", "-a", "DUMMY"}; From b72b51be48f52d2deff1e8ad3d111a53d095a90e Mon Sep 17 00:00:00 2001 From: Axel Huebl Date: Fri, 2 Aug 2019 16:43:55 -0500 Subject: [PATCH 37/50] Fix: Heap Buffer Overflow Fix a memory violation when run in serial. --- src/utilities.c | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/src/utilities.c b/src/utilities.c index 99d26e7..cdb090e 100755 --- a/src/utilities.c +++ b/src/utilities.c @@ -257,7 +257,9 @@ int QueryNodeMapping(MPI_Comm comm, int print_nodemap) { } fprintf( out_logfile, "\n" ); } - int ret = node_map[1] == 1; + int ret = 1; + if(num_ranks>1) + ret = node_map[1] == 1; MPI_Bcast(&ret, 1, MPI_INT, 0, comm); free(node_map); return ret; From c4ff3d7c4e35edc4022e81e779d09f38b00f1954 Mon Sep 17 00:00:00 2001 From: "Julian M. Kunkel" Date: Sat, 3 Aug 2019 09:12:48 +0100 Subject: [PATCH 38/50] Trivial fix for #168 --- src/mdtest.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/mdtest.c b/src/mdtest.c index 1ff204d..24f3ec1 100644 --- a/src/mdtest.c +++ b/src/mdtest.c @@ -79,7 +79,7 @@ #define FILEMODE S_IRUSR|S_IWUSR|S_IRGRP|S_IWGRP|S_IROTH #define DIRMODE S_IRUSR|S_IWUSR|S_IXUSR|S_IRGRP|S_IWGRP|S_IXGRP|S_IROTH|S_IXOTH #define RELEASE_VERS META_VERSION -#define TEST_DIR "#test-dir" +#define TEST_DIR "test-dir" #define ITEM_COUNT 25000 #define LLU "%lu" From 361a3261d1f8be2621bce8be8ed41ee9f6d0bf1f Mon Sep 17 00:00:00 2001 From: "Julian M. Kunkel" Date: Sat, 3 Aug 2019 09:15:34 +0100 Subject: [PATCH 39/50] Updated test patterns --- testing/mdtest-patterns/advanced/3.txt | 188 +++++++++++++------------ testing/mdtest-patterns/advanced/4.txt | 102 +++++++------- testing/mdtest-patterns/advanced/5.txt | 154 ++++++++++---------- testing/mdtest-patterns/basic/0.txt | 51 +++---- testing/mdtest-patterns/basic/1.txt | 51 +++---- testing/mdtest-patterns/basic/2.txt | 54 +++---- testing/mdtest-patterns/basic/3.txt | 65 +++++---- 7 files changed, 341 insertions(+), 324 deletions(-) diff --git a/testing/mdtest-patterns/advanced/3.txt b/testing/mdtest-patterns/advanced/3.txt index a51000a..4c45941 100644 --- a/testing/mdtest-patterns/advanced/3.txt +++ b/testing/mdtest-patterns/advanced/3.txt @@ -1,93 +1,95 @@ -V-3: main (before display_freespace): testdirpath is "/dev/shm/mdest" -V-3: testdirpath is "/dev/shm/mdest" -V-3: Before show_file_system_size, dirpath is "/dev/shm" -V-3: After show_file_system_size, dirpath is "/dev/shm" -V-3: main (after display_freespace): testdirpath is "/dev/shm/mdest" -V-3: main (create hierarchical directory loop-!unque_dir_per_task): Calling create_remove_directory_tree with "/dev/shm/mdest/#test-dir.0-0" -V-3: main: Using unique_mk_dir, "mdtest_tree.0" -V-3: main: Copied unique_mk_dir, "mdtest_tree.0", to topdir -V-3: directory_test: create path is "/dev/shm/mdest/#test-dir.0-0/mdtest_tree.0" -V-3: create_remove_items (start): temp_path is "/dev/shm/mdest/#test-dir.0-0/mdtest_tree.0" -V-3: create_remove_items_helper (dirs create): curr_item is "/dev/shm/mdest/#test-dir.0-0/mdtest_tree.0/dir.mdtest.0.0" -V-3: create_remove_items_helper (dirs create): curr_item is "/dev/shm/mdest/#test-dir.0-0/mdtest_tree.0/dir.mdtest.0.1" -V-3: create_remove_items_helper (dirs create): curr_item is "/dev/shm/mdest/#test-dir.0-0/mdtest_tree.0/dir.mdtest.0.2" -V-3: create_remove_items_helper (dirs create): curr_item is "/dev/shm/mdest/#test-dir.0-0/mdtest_tree.0/dir.mdtest.0.3" -V-3: create_remove_items_helper (dirs create): curr_item is "/dev/shm/mdest/#test-dir.0-0/mdtest_tree.0/dir.mdtest.0.4" -V-3: create_remove_items_helper (dirs create): curr_item is "/dev/shm/mdest/#test-dir.0-0/mdtest_tree.0/dir.mdtest.0.5" -V-3: create_remove_items_helper (dirs create): curr_item is "/dev/shm/mdest/#test-dir.0-0/mdtest_tree.0/dir.mdtest.0.6" -V-3: create_remove_items_helper (dirs create): curr_item is "/dev/shm/mdest/#test-dir.0-0/mdtest_tree.0/dir.mdtest.0.7" -V-3: create_remove_items_helper (dirs create): curr_item is "/dev/shm/mdest/#test-dir.0-0/mdtest_tree.0/dir.mdtest.0.8" -V-3: create_remove_items_helper (dirs create): curr_item is "/dev/shm/mdest/#test-dir.0-0/mdtest_tree.0/dir.mdtest.0.9" -V-3: create_remove_items_helper (dirs create): curr_item is "/dev/shm/mdest/#test-dir.0-0/mdtest_tree.0/dir.mdtest.0.10" -V-3: create_remove_items_helper (dirs create): curr_item is "/dev/shm/mdest/#test-dir.0-0/mdtest_tree.0/dir.mdtest.0.11" -V-3: create_remove_items_helper (dirs create): curr_item is "/dev/shm/mdest/#test-dir.0-0/mdtest_tree.0/dir.mdtest.0.12" -V-3: create_remove_items_helper (dirs create): curr_item is "/dev/shm/mdest/#test-dir.0-0/mdtest_tree.0/dir.mdtest.0.13" -V-3: create_remove_items_helper (dirs create): curr_item is "/dev/shm/mdest/#test-dir.0-0/mdtest_tree.0/dir.mdtest.0.14" -V-3: create_remove_items_helper (dirs create): curr_item is "/dev/shm/mdest/#test-dir.0-0/mdtest_tree.0/dir.mdtest.0.15" -V-3: create_remove_items_helper (dirs create): curr_item is "/dev/shm/mdest/#test-dir.0-0/mdtest_tree.0/dir.mdtest.0.16" -V-3: create_remove_items_helper (dirs create): curr_item is "/dev/shm/mdest/#test-dir.0-0/mdtest_tree.0/dir.mdtest.0.17" -V-3: create_remove_items_helper (dirs create): curr_item is "/dev/shm/mdest/#test-dir.0-0/mdtest_tree.0/dir.mdtest.0.18" -V-3: create_remove_items_helper (dirs create): curr_item is "/dev/shm/mdest/#test-dir.0-0/mdtest_tree.0/dir.mdtest.0.19" -V-3: file_test: create path is "/dev/shm/mdest/#test-dir.0-0/mdtest_tree.0" -V-3: create_remove_items (start): temp_path is "/dev/shm/mdest/#test-dir.0-0/mdtest_tree.0" -V-3: create_remove_items_helper (non-dirs create): curr_item is "/dev/shm/mdest/#test-dir.0-0/mdtest_tree.0/file.mdtest.0.0" -V-3: create_remove_items_helper (non-collective, shared): open... -V-3: create_remove_items_helper: close... -V-3: create_remove_items_helper (non-dirs create): curr_item is "/dev/shm/mdest/#test-dir.0-0/mdtest_tree.0/file.mdtest.0.1" -V-3: create_remove_items_helper (non-collective, shared): open... -V-3: create_remove_items_helper: close... -V-3: create_remove_items_helper (non-dirs create): curr_item is "/dev/shm/mdest/#test-dir.0-0/mdtest_tree.0/file.mdtest.0.2" -V-3: create_remove_items_helper (non-collective, shared): open... -V-3: create_remove_items_helper: close... -V-3: create_remove_items_helper (non-dirs create): curr_item is "/dev/shm/mdest/#test-dir.0-0/mdtest_tree.0/file.mdtest.0.3" -V-3: create_remove_items_helper (non-collective, shared): open... -V-3: create_remove_items_helper: close... -V-3: create_remove_items_helper (non-dirs create): curr_item is "/dev/shm/mdest/#test-dir.0-0/mdtest_tree.0/file.mdtest.0.4" -V-3: create_remove_items_helper (non-collective, shared): open... -V-3: create_remove_items_helper: close... -V-3: create_remove_items_helper (non-dirs create): curr_item is "/dev/shm/mdest/#test-dir.0-0/mdtest_tree.0/file.mdtest.0.5" -V-3: create_remove_items_helper (non-collective, shared): open... -V-3: create_remove_items_helper: close... -V-3: create_remove_items_helper (non-dirs create): curr_item is "/dev/shm/mdest/#test-dir.0-0/mdtest_tree.0/file.mdtest.0.6" -V-3: create_remove_items_helper (non-collective, shared): open... -V-3: create_remove_items_helper: close... -V-3: create_remove_items_helper (non-dirs create): curr_item is "/dev/shm/mdest/#test-dir.0-0/mdtest_tree.0/file.mdtest.0.7" -V-3: create_remove_items_helper (non-collective, shared): open... -V-3: create_remove_items_helper: close... -V-3: create_remove_items_helper (non-dirs create): curr_item is "/dev/shm/mdest/#test-dir.0-0/mdtest_tree.0/file.mdtest.0.8" -V-3: create_remove_items_helper (non-collective, shared): open... -V-3: create_remove_items_helper: close... -V-3: create_remove_items_helper (non-dirs create): curr_item is "/dev/shm/mdest/#test-dir.0-0/mdtest_tree.0/file.mdtest.0.9" -V-3: create_remove_items_helper (non-collective, shared): open... -V-3: create_remove_items_helper: close... -V-3: create_remove_items_helper (non-dirs create): curr_item is "/dev/shm/mdest/#test-dir.0-0/mdtest_tree.0/file.mdtest.0.10" -V-3: create_remove_items_helper (non-collective, shared): open... -V-3: create_remove_items_helper: close... -V-3: create_remove_items_helper (non-dirs create): curr_item is "/dev/shm/mdest/#test-dir.0-0/mdtest_tree.0/file.mdtest.0.11" -V-3: create_remove_items_helper (non-collective, shared): open... -V-3: create_remove_items_helper: close... -V-3: create_remove_items_helper (non-dirs create): curr_item is "/dev/shm/mdest/#test-dir.0-0/mdtest_tree.0/file.mdtest.0.12" -V-3: create_remove_items_helper (non-collective, shared): open... -V-3: create_remove_items_helper: close... -V-3: create_remove_items_helper (non-dirs create): curr_item is "/dev/shm/mdest/#test-dir.0-0/mdtest_tree.0/file.mdtest.0.13" -V-3: create_remove_items_helper (non-collective, shared): open... -V-3: create_remove_items_helper: close... -V-3: create_remove_items_helper (non-dirs create): curr_item is "/dev/shm/mdest/#test-dir.0-0/mdtest_tree.0/file.mdtest.0.14" -V-3: create_remove_items_helper (non-collective, shared): open... -V-3: create_remove_items_helper: close... -V-3: create_remove_items_helper (non-dirs create): curr_item is "/dev/shm/mdest/#test-dir.0-0/mdtest_tree.0/file.mdtest.0.15" -V-3: create_remove_items_helper (non-collective, shared): open... -V-3: create_remove_items_helper: close... -V-3: create_remove_items_helper (non-dirs create): curr_item is "/dev/shm/mdest/#test-dir.0-0/mdtest_tree.0/file.mdtest.0.16" -V-3: create_remove_items_helper (non-collective, shared): open... -V-3: create_remove_items_helper: close... -V-3: create_remove_items_helper (non-dirs create): curr_item is "/dev/shm/mdest/#test-dir.0-0/mdtest_tree.0/file.mdtest.0.17" -V-3: create_remove_items_helper (non-collective, shared): open... -V-3: create_remove_items_helper: close... -V-3: create_remove_items_helper (non-dirs create): curr_item is "/dev/shm/mdest/#test-dir.0-0/mdtest_tree.0/file.mdtest.0.18" -V-3: create_remove_items_helper (non-collective, shared): open... -V-3: create_remove_items_helper: close... -V-3: create_remove_items_helper (non-dirs create): curr_item is "/dev/shm/mdest/#test-dir.0-0/mdtest_tree.0/file.mdtest.0.19" -V-3: create_remove_items_helper (non-collective, shared): open... -V-3: create_remove_items_helper: close... -V-3: main: Using testdir, "/dev/shm/mdest/#test-dir.0-0" +V-3: Rank 0 Line 2082 main (before display_freespace): testdirpath is '/dev/shm/mdest' +V-3: Rank 0 Line 1506 Entering display_freespace on /dev/shm/mdest... +V-3: Rank 0 Line 1525 Before show_file_system_size, dirpath is '/dev/shm' +V-3: Rank 0 Line 1527 After show_file_system_size, dirpath is '/dev/shm' +V-3: Rank 0 Line 2097 main (after display_freespace): testdirpath is '/dev/shm/mdest' +V-3: Rank 0 Line 1656 main (create hierarchical directory loop-!unque_dir_per_task): Calling create_remove_directory_tree with '/dev/shm/mdest/test-dir.0-0' +V-3: Rank 0 Line 1683 V-3: main: Using unique_mk_dir, 'mdtest_tree.0' +V-3: Rank 0 Line 1704 V-3: main: Copied unique_mk_dir, 'mdtest_tree.0', to topdir +V-3: Rank 0 Line 801 directory_test: create path is '/dev/shm/mdest/test-dir.0-0/mdtest_tree.0' +V-3: Rank 0 Line 457 create_remove_items (start): temp_path is '/dev/shm/mdest/test-dir.0-0/mdtest_tree.0' +V-3: Rank 0 Line 288 create_remove_items_helper (dirs create): curr_item is '/dev/shm/mdest/test-dir.0-0/mdtest_tree.0/dir.mdtest.0.0' +V-3: Rank 0 Line 288 create_remove_items_helper (dirs create): curr_item is '/dev/shm/mdest/test-dir.0-0/mdtest_tree.0/dir.mdtest.0.1' +V-3: Rank 0 Line 288 create_remove_items_helper (dirs create): curr_item is '/dev/shm/mdest/test-dir.0-0/mdtest_tree.0/dir.mdtest.0.2' +V-3: Rank 0 Line 288 create_remove_items_helper (dirs create): curr_item is '/dev/shm/mdest/test-dir.0-0/mdtest_tree.0/dir.mdtest.0.3' +V-3: Rank 0 Line 288 create_remove_items_helper (dirs create): curr_item is '/dev/shm/mdest/test-dir.0-0/mdtest_tree.0/dir.mdtest.0.4' +V-3: Rank 0 Line 288 create_remove_items_helper (dirs create): curr_item is '/dev/shm/mdest/test-dir.0-0/mdtest_tree.0/dir.mdtest.0.5' +V-3: Rank 0 Line 288 create_remove_items_helper (dirs create): curr_item is '/dev/shm/mdest/test-dir.0-0/mdtest_tree.0/dir.mdtest.0.6' +V-3: Rank 0 Line 288 create_remove_items_helper (dirs create): curr_item is '/dev/shm/mdest/test-dir.0-0/mdtest_tree.0/dir.mdtest.0.7' +V-3: Rank 0 Line 288 create_remove_items_helper (dirs create): curr_item is '/dev/shm/mdest/test-dir.0-0/mdtest_tree.0/dir.mdtest.0.8' +V-3: Rank 0 Line 288 create_remove_items_helper (dirs create): curr_item is '/dev/shm/mdest/test-dir.0-0/mdtest_tree.0/dir.mdtest.0.9' +V-3: Rank 0 Line 288 create_remove_items_helper (dirs create): curr_item is '/dev/shm/mdest/test-dir.0-0/mdtest_tree.0/dir.mdtest.0.10' +V-3: Rank 0 Line 288 create_remove_items_helper (dirs create): curr_item is '/dev/shm/mdest/test-dir.0-0/mdtest_tree.0/dir.mdtest.0.11' +V-3: Rank 0 Line 288 create_remove_items_helper (dirs create): curr_item is '/dev/shm/mdest/test-dir.0-0/mdtest_tree.0/dir.mdtest.0.12' +V-3: Rank 0 Line 288 create_remove_items_helper (dirs create): curr_item is '/dev/shm/mdest/test-dir.0-0/mdtest_tree.0/dir.mdtest.0.13' +V-3: Rank 0 Line 288 create_remove_items_helper (dirs create): curr_item is '/dev/shm/mdest/test-dir.0-0/mdtest_tree.0/dir.mdtest.0.14' +V-3: Rank 0 Line 288 create_remove_items_helper (dirs create): curr_item is '/dev/shm/mdest/test-dir.0-0/mdtest_tree.0/dir.mdtest.0.15' +V-3: Rank 0 Line 288 create_remove_items_helper (dirs create): curr_item is '/dev/shm/mdest/test-dir.0-0/mdtest_tree.0/dir.mdtest.0.16' +V-3: Rank 0 Line 288 create_remove_items_helper (dirs create): curr_item is '/dev/shm/mdest/test-dir.0-0/mdtest_tree.0/dir.mdtest.0.17' +V-3: Rank 0 Line 288 create_remove_items_helper (dirs create): curr_item is '/dev/shm/mdest/test-dir.0-0/mdtest_tree.0/dir.mdtest.0.18' +V-3: Rank 0 Line 288 create_remove_items_helper (dirs create): curr_item is '/dev/shm/mdest/test-dir.0-0/mdtest_tree.0/dir.mdtest.0.19' +V-3: Rank 0 Line 1716 will file_test on mdtest_tree.0 +V-3: Rank 0 Line 990 Entering file_test on mdtest_tree.0 +V-3: Rank 0 Line 1012 file_test: create path is '/dev/shm/mdest/test-dir.0-0/mdtest_tree.0' +V-3: Rank 0 Line 457 create_remove_items (start): temp_path is '/dev/shm/mdest/test-dir.0-0/mdtest_tree.0' +V-3: Rank 0 Line 326 create_remove_items_helper (non-dirs create): curr_item is '/dev/shm/mdest/test-dir.0-0/mdtest_tree.0/file.mdtest.0.0' +V-3: Rank 0 Line 348 create_remove_items_helper (non-collective, shared): open... +V-3: Rank 0 Line 373 create_remove_items_helper: close... +V-3: Rank 0 Line 326 create_remove_items_helper (non-dirs create): curr_item is '/dev/shm/mdest/test-dir.0-0/mdtest_tree.0/file.mdtest.0.1' +V-3: Rank 0 Line 348 create_remove_items_helper (non-collective, shared): open... +V-3: Rank 0 Line 373 create_remove_items_helper: close... +V-3: Rank 0 Line 326 create_remove_items_helper (non-dirs create): curr_item is '/dev/shm/mdest/test-dir.0-0/mdtest_tree.0/file.mdtest.0.2' +V-3: Rank 0 Line 348 create_remove_items_helper (non-collective, shared): open... +V-3: Rank 0 Line 373 create_remove_items_helper: close... +V-3: Rank 0 Line 326 create_remove_items_helper (non-dirs create): curr_item is '/dev/shm/mdest/test-dir.0-0/mdtest_tree.0/file.mdtest.0.3' +V-3: Rank 0 Line 348 create_remove_items_helper (non-collective, shared): open... +V-3: Rank 0 Line 373 create_remove_items_helper: close... +V-3: Rank 0 Line 326 create_remove_items_helper (non-dirs create): curr_item is '/dev/shm/mdest/test-dir.0-0/mdtest_tree.0/file.mdtest.0.4' +V-3: Rank 0 Line 348 create_remove_items_helper (non-collective, shared): open... +V-3: Rank 0 Line 373 create_remove_items_helper: close... +V-3: Rank 0 Line 326 create_remove_items_helper (non-dirs create): curr_item is '/dev/shm/mdest/test-dir.0-0/mdtest_tree.0/file.mdtest.0.5' +V-3: Rank 0 Line 348 create_remove_items_helper (non-collective, shared): open... +V-3: Rank 0 Line 373 create_remove_items_helper: close... +V-3: Rank 0 Line 326 create_remove_items_helper (non-dirs create): curr_item is '/dev/shm/mdest/test-dir.0-0/mdtest_tree.0/file.mdtest.0.6' +V-3: Rank 0 Line 348 create_remove_items_helper (non-collective, shared): open... +V-3: Rank 0 Line 373 create_remove_items_helper: close... +V-3: Rank 0 Line 326 create_remove_items_helper (non-dirs create): curr_item is '/dev/shm/mdest/test-dir.0-0/mdtest_tree.0/file.mdtest.0.7' +V-3: Rank 0 Line 348 create_remove_items_helper (non-collective, shared): open... +V-3: Rank 0 Line 373 create_remove_items_helper: close... +V-3: Rank 0 Line 326 create_remove_items_helper (non-dirs create): curr_item is '/dev/shm/mdest/test-dir.0-0/mdtest_tree.0/file.mdtest.0.8' +V-3: Rank 0 Line 348 create_remove_items_helper (non-collective, shared): open... +V-3: Rank 0 Line 373 create_remove_items_helper: close... +V-3: Rank 0 Line 326 create_remove_items_helper (non-dirs create): curr_item is '/dev/shm/mdest/test-dir.0-0/mdtest_tree.0/file.mdtest.0.9' +V-3: Rank 0 Line 348 create_remove_items_helper (non-collective, shared): open... +V-3: Rank 0 Line 373 create_remove_items_helper: close... +V-3: Rank 0 Line 326 create_remove_items_helper (non-dirs create): curr_item is '/dev/shm/mdest/test-dir.0-0/mdtest_tree.0/file.mdtest.0.10' +V-3: Rank 0 Line 348 create_remove_items_helper (non-collective, shared): open... +V-3: Rank 0 Line 373 create_remove_items_helper: close... +V-3: Rank 0 Line 326 create_remove_items_helper (non-dirs create): curr_item is '/dev/shm/mdest/test-dir.0-0/mdtest_tree.0/file.mdtest.0.11' +V-3: Rank 0 Line 348 create_remove_items_helper (non-collective, shared): open... +V-3: Rank 0 Line 373 create_remove_items_helper: close... +V-3: Rank 0 Line 326 create_remove_items_helper (non-dirs create): curr_item is '/dev/shm/mdest/test-dir.0-0/mdtest_tree.0/file.mdtest.0.12' +V-3: Rank 0 Line 348 create_remove_items_helper (non-collective, shared): open... +V-3: Rank 0 Line 373 create_remove_items_helper: close... +V-3: Rank 0 Line 326 create_remove_items_helper (non-dirs create): curr_item is '/dev/shm/mdest/test-dir.0-0/mdtest_tree.0/file.mdtest.0.13' +V-3: Rank 0 Line 348 create_remove_items_helper (non-collective, shared): open... +V-3: Rank 0 Line 373 create_remove_items_helper: close... +V-3: Rank 0 Line 326 create_remove_items_helper (non-dirs create): curr_item is '/dev/shm/mdest/test-dir.0-0/mdtest_tree.0/file.mdtest.0.14' +V-3: Rank 0 Line 348 create_remove_items_helper (non-collective, shared): open... +V-3: Rank 0 Line 373 create_remove_items_helper: close... +V-3: Rank 0 Line 326 create_remove_items_helper (non-dirs create): curr_item is '/dev/shm/mdest/test-dir.0-0/mdtest_tree.0/file.mdtest.0.15' +V-3: Rank 0 Line 348 create_remove_items_helper (non-collective, shared): open... +V-3: Rank 0 Line 373 create_remove_items_helper: close... +V-3: Rank 0 Line 326 create_remove_items_helper (non-dirs create): curr_item is '/dev/shm/mdest/test-dir.0-0/mdtest_tree.0/file.mdtest.0.16' +V-3: Rank 0 Line 348 create_remove_items_helper (non-collective, shared): open... +V-3: Rank 0 Line 373 create_remove_items_helper: close... +V-3: Rank 0 Line 326 create_remove_items_helper (non-dirs create): curr_item is '/dev/shm/mdest/test-dir.0-0/mdtest_tree.0/file.mdtest.0.17' +V-3: Rank 0 Line 348 create_remove_items_helper (non-collective, shared): open... +V-3: Rank 0 Line 373 create_remove_items_helper: close... +V-3: Rank 0 Line 326 create_remove_items_helper (non-dirs create): curr_item is '/dev/shm/mdest/test-dir.0-0/mdtest_tree.0/file.mdtest.0.18' +V-3: Rank 0 Line 348 create_remove_items_helper (non-collective, shared): open... +V-3: Rank 0 Line 373 create_remove_items_helper: close... +V-3: Rank 0 Line 326 create_remove_items_helper (non-dirs create): curr_item is '/dev/shm/mdest/test-dir.0-0/mdtest_tree.0/file.mdtest.0.19' +V-3: Rank 0 Line 348 create_remove_items_helper (non-collective, shared): open... +V-3: Rank 0 Line 373 create_remove_items_helper: close... +V-3: Rank 0 Line 1723 main: Using testdir, '/dev/shm/mdest/test-dir.0-0' diff --git a/testing/mdtest-patterns/advanced/4.txt b/testing/mdtest-patterns/advanced/4.txt index 8df166a..5d3b7da 100644 --- a/testing/mdtest-patterns/advanced/4.txt +++ b/testing/mdtest-patterns/advanced/4.txt @@ -1,50 +1,52 @@ -V-3: main (before display_freespace): testdirpath is "/dev/shm/mdest" -V-3: testdirpath is "/dev/shm/mdest" -V-3: Before show_file_system_size, dirpath is "/dev/shm" -V-3: After show_file_system_size, dirpath is "/dev/shm" -V-3: main (after display_freespace): testdirpath is "/dev/shm/mdest" -V-3: main: Using unique_mk_dir, "mdtest_tree.0" -V-3: main: Copied unique_mk_dir, "mdtest_tree.0", to topdir -V-3: directory_test: stat path is "/dev/shm/mdest/#test-dir.0-0/mdtest_tree.0" -V-3: mdtest_stat dir : /dev/shm/mdest/#test-dir.0-0/mdtest_tree.0/dir.mdtest.0.0 -V-3: mdtest_stat dir : /dev/shm/mdest/#test-dir.0-0/mdtest_tree.0/dir.mdtest.0.1 -V-3: mdtest_stat dir : /dev/shm/mdest/#test-dir.0-0/mdtest_tree.0/dir.mdtest.0.2 -V-3: mdtest_stat dir : /dev/shm/mdest/#test-dir.0-0/mdtest_tree.0/dir.mdtest.0.3 -V-3: mdtest_stat dir : /dev/shm/mdest/#test-dir.0-0/mdtest_tree.0/dir.mdtest.0.4 -V-3: mdtest_stat dir : /dev/shm/mdest/#test-dir.0-0/mdtest_tree.0/dir.mdtest.0.5 -V-3: mdtest_stat dir : /dev/shm/mdest/#test-dir.0-0/mdtest_tree.0/dir.mdtest.0.6 -V-3: mdtest_stat dir : /dev/shm/mdest/#test-dir.0-0/mdtest_tree.0/dir.mdtest.0.7 -V-3: mdtest_stat dir : /dev/shm/mdest/#test-dir.0-0/mdtest_tree.0/dir.mdtest.0.8 -V-3: mdtest_stat dir : /dev/shm/mdest/#test-dir.0-0/mdtest_tree.0/dir.mdtest.0.9 -V-3: mdtest_stat dir : /dev/shm/mdest/#test-dir.0-0/mdtest_tree.0/dir.mdtest.0.10 -V-3: mdtest_stat dir : /dev/shm/mdest/#test-dir.0-0/mdtest_tree.0/dir.mdtest.0.11 -V-3: mdtest_stat dir : /dev/shm/mdest/#test-dir.0-0/mdtest_tree.0/dir.mdtest.0.12 -V-3: mdtest_stat dir : /dev/shm/mdest/#test-dir.0-0/mdtest_tree.0/dir.mdtest.0.13 -V-3: mdtest_stat dir : /dev/shm/mdest/#test-dir.0-0/mdtest_tree.0/dir.mdtest.0.14 -V-3: mdtest_stat dir : /dev/shm/mdest/#test-dir.0-0/mdtest_tree.0/dir.mdtest.0.15 -V-3: mdtest_stat dir : /dev/shm/mdest/#test-dir.0-0/mdtest_tree.0/dir.mdtest.0.16 -V-3: mdtest_stat dir : /dev/shm/mdest/#test-dir.0-0/mdtest_tree.0/dir.mdtest.0.17 -V-3: mdtest_stat dir : /dev/shm/mdest/#test-dir.0-0/mdtest_tree.0/dir.mdtest.0.18 -V-3: mdtest_stat dir : /dev/shm/mdest/#test-dir.0-0/mdtest_tree.0/dir.mdtest.0.19 -V-3: file_test: stat path is "/dev/shm/mdest/#test-dir.0-0/mdtest_tree.0" -V-3: mdtest_stat file: /dev/shm/mdest/#test-dir.0-0/mdtest_tree.0/file.mdtest.0.0 -V-3: mdtest_stat file: /dev/shm/mdest/#test-dir.0-0/mdtest_tree.0/file.mdtest.0.1 -V-3: mdtest_stat file: /dev/shm/mdest/#test-dir.0-0/mdtest_tree.0/file.mdtest.0.2 -V-3: mdtest_stat file: /dev/shm/mdest/#test-dir.0-0/mdtest_tree.0/file.mdtest.0.3 -V-3: mdtest_stat file: /dev/shm/mdest/#test-dir.0-0/mdtest_tree.0/file.mdtest.0.4 -V-3: mdtest_stat file: /dev/shm/mdest/#test-dir.0-0/mdtest_tree.0/file.mdtest.0.5 -V-3: mdtest_stat file: /dev/shm/mdest/#test-dir.0-0/mdtest_tree.0/file.mdtest.0.6 -V-3: mdtest_stat file: /dev/shm/mdest/#test-dir.0-0/mdtest_tree.0/file.mdtest.0.7 -V-3: mdtest_stat file: /dev/shm/mdest/#test-dir.0-0/mdtest_tree.0/file.mdtest.0.8 -V-3: mdtest_stat file: /dev/shm/mdest/#test-dir.0-0/mdtest_tree.0/file.mdtest.0.9 -V-3: mdtest_stat file: /dev/shm/mdest/#test-dir.0-0/mdtest_tree.0/file.mdtest.0.10 -V-3: mdtest_stat file: /dev/shm/mdest/#test-dir.0-0/mdtest_tree.0/file.mdtest.0.11 -V-3: mdtest_stat file: /dev/shm/mdest/#test-dir.0-0/mdtest_tree.0/file.mdtest.0.12 -V-3: mdtest_stat file: /dev/shm/mdest/#test-dir.0-0/mdtest_tree.0/file.mdtest.0.13 -V-3: mdtest_stat file: /dev/shm/mdest/#test-dir.0-0/mdtest_tree.0/file.mdtest.0.14 -V-3: mdtest_stat file: /dev/shm/mdest/#test-dir.0-0/mdtest_tree.0/file.mdtest.0.15 -V-3: mdtest_stat file: /dev/shm/mdest/#test-dir.0-0/mdtest_tree.0/file.mdtest.0.16 -V-3: mdtest_stat file: /dev/shm/mdest/#test-dir.0-0/mdtest_tree.0/file.mdtest.0.17 -V-3: mdtest_stat file: /dev/shm/mdest/#test-dir.0-0/mdtest_tree.0/file.mdtest.0.18 -V-3: mdtest_stat file: /dev/shm/mdest/#test-dir.0-0/mdtest_tree.0/file.mdtest.0.19 -V-3: main: Using testdir, "/dev/shm/mdest/#test-dir.0-0" +V-3: Rank 0 Line 2082 main (before display_freespace): testdirpath is '/dev/shm/mdest' +V-3: Rank 0 Line 1506 Entering display_freespace on /dev/shm/mdest... +V-3: Rank 0 Line 1525 Before show_file_system_size, dirpath is '/dev/shm' +V-3: Rank 0 Line 1527 After show_file_system_size, dirpath is '/dev/shm' +V-3: Rank 0 Line 2097 main (after display_freespace): testdirpath is '/dev/shm/mdest' +V-3: Rank 0 Line 1683 V-3: main: Using unique_mk_dir, 'mdtest_tree.0' +V-3: Rank 0 Line 1704 V-3: main: Copied unique_mk_dir, 'mdtest_tree.0', to topdir +V-3: Rank 0 Line 833 stat path is '/dev/shm/mdest/test-dir.0-0/mdtest_tree.0' +V-3: Rank 0 Line 588 mdtest_stat dir: /dev/shm/mdest/test-dir.0-0/mdtest_tree.0/dir.mdtest.0.0 +V-3: Rank 0 Line 588 mdtest_stat dir: /dev/shm/mdest/test-dir.0-0/mdtest_tree.0/dir.mdtest.0.1 +V-3: Rank 0 Line 588 mdtest_stat dir: /dev/shm/mdest/test-dir.0-0/mdtest_tree.0/dir.mdtest.0.2 +V-3: Rank 0 Line 588 mdtest_stat dir: /dev/shm/mdest/test-dir.0-0/mdtest_tree.0/dir.mdtest.0.3 +V-3: Rank 0 Line 588 mdtest_stat dir: /dev/shm/mdest/test-dir.0-0/mdtest_tree.0/dir.mdtest.0.4 +V-3: Rank 0 Line 588 mdtest_stat dir: /dev/shm/mdest/test-dir.0-0/mdtest_tree.0/dir.mdtest.0.5 +V-3: Rank 0 Line 588 mdtest_stat dir: /dev/shm/mdest/test-dir.0-0/mdtest_tree.0/dir.mdtest.0.6 +V-3: Rank 0 Line 588 mdtest_stat dir: /dev/shm/mdest/test-dir.0-0/mdtest_tree.0/dir.mdtest.0.7 +V-3: Rank 0 Line 588 mdtest_stat dir: /dev/shm/mdest/test-dir.0-0/mdtest_tree.0/dir.mdtest.0.8 +V-3: Rank 0 Line 588 mdtest_stat dir: /dev/shm/mdest/test-dir.0-0/mdtest_tree.0/dir.mdtest.0.9 +V-3: Rank 0 Line 588 mdtest_stat dir: /dev/shm/mdest/test-dir.0-0/mdtest_tree.0/dir.mdtest.0.10 +V-3: Rank 0 Line 588 mdtest_stat dir: /dev/shm/mdest/test-dir.0-0/mdtest_tree.0/dir.mdtest.0.11 +V-3: Rank 0 Line 588 mdtest_stat dir: /dev/shm/mdest/test-dir.0-0/mdtest_tree.0/dir.mdtest.0.12 +V-3: Rank 0 Line 588 mdtest_stat dir: /dev/shm/mdest/test-dir.0-0/mdtest_tree.0/dir.mdtest.0.13 +V-3: Rank 0 Line 588 mdtest_stat dir: /dev/shm/mdest/test-dir.0-0/mdtest_tree.0/dir.mdtest.0.14 +V-3: Rank 0 Line 588 mdtest_stat dir: /dev/shm/mdest/test-dir.0-0/mdtest_tree.0/dir.mdtest.0.15 +V-3: Rank 0 Line 588 mdtest_stat dir: /dev/shm/mdest/test-dir.0-0/mdtest_tree.0/dir.mdtest.0.16 +V-3: Rank 0 Line 588 mdtest_stat dir: /dev/shm/mdest/test-dir.0-0/mdtest_tree.0/dir.mdtest.0.17 +V-3: Rank 0 Line 588 mdtest_stat dir: /dev/shm/mdest/test-dir.0-0/mdtest_tree.0/dir.mdtest.0.18 +V-3: Rank 0 Line 588 mdtest_stat dir: /dev/shm/mdest/test-dir.0-0/mdtest_tree.0/dir.mdtest.0.19 +V-3: Rank 0 Line 1716 will file_test on mdtest_tree.0 +V-3: Rank 0 Line 990 Entering file_test on mdtest_tree.0 +V-3: Rank 0 Line 1079 file_test: stat path is '/dev/shm/mdest/test-dir.0-0/mdtest_tree.0' +V-3: Rank 0 Line 588 mdtest_stat file: /dev/shm/mdest/test-dir.0-0/mdtest_tree.0/file.mdtest.0.0 +V-3: Rank 0 Line 588 mdtest_stat file: /dev/shm/mdest/test-dir.0-0/mdtest_tree.0/file.mdtest.0.1 +V-3: Rank 0 Line 588 mdtest_stat file: /dev/shm/mdest/test-dir.0-0/mdtest_tree.0/file.mdtest.0.2 +V-3: Rank 0 Line 588 mdtest_stat file: /dev/shm/mdest/test-dir.0-0/mdtest_tree.0/file.mdtest.0.3 +V-3: Rank 0 Line 588 mdtest_stat file: /dev/shm/mdest/test-dir.0-0/mdtest_tree.0/file.mdtest.0.4 +V-3: Rank 0 Line 588 mdtest_stat file: /dev/shm/mdest/test-dir.0-0/mdtest_tree.0/file.mdtest.0.5 +V-3: Rank 0 Line 588 mdtest_stat file: /dev/shm/mdest/test-dir.0-0/mdtest_tree.0/file.mdtest.0.6 +V-3: Rank 0 Line 588 mdtest_stat file: /dev/shm/mdest/test-dir.0-0/mdtest_tree.0/file.mdtest.0.7 +V-3: Rank 0 Line 588 mdtest_stat file: /dev/shm/mdest/test-dir.0-0/mdtest_tree.0/file.mdtest.0.8 +V-3: Rank 0 Line 588 mdtest_stat file: /dev/shm/mdest/test-dir.0-0/mdtest_tree.0/file.mdtest.0.9 +V-3: Rank 0 Line 588 mdtest_stat file: /dev/shm/mdest/test-dir.0-0/mdtest_tree.0/file.mdtest.0.10 +V-3: Rank 0 Line 588 mdtest_stat file: /dev/shm/mdest/test-dir.0-0/mdtest_tree.0/file.mdtest.0.11 +V-3: Rank 0 Line 588 mdtest_stat file: /dev/shm/mdest/test-dir.0-0/mdtest_tree.0/file.mdtest.0.12 +V-3: Rank 0 Line 588 mdtest_stat file: /dev/shm/mdest/test-dir.0-0/mdtest_tree.0/file.mdtest.0.13 +V-3: Rank 0 Line 588 mdtest_stat file: /dev/shm/mdest/test-dir.0-0/mdtest_tree.0/file.mdtest.0.14 +V-3: Rank 0 Line 588 mdtest_stat file: /dev/shm/mdest/test-dir.0-0/mdtest_tree.0/file.mdtest.0.15 +V-3: Rank 0 Line 588 mdtest_stat file: /dev/shm/mdest/test-dir.0-0/mdtest_tree.0/file.mdtest.0.16 +V-3: Rank 0 Line 588 mdtest_stat file: /dev/shm/mdest/test-dir.0-0/mdtest_tree.0/file.mdtest.0.17 +V-3: Rank 0 Line 588 mdtest_stat file: /dev/shm/mdest/test-dir.0-0/mdtest_tree.0/file.mdtest.0.18 +V-3: Rank 0 Line 588 mdtest_stat file: /dev/shm/mdest/test-dir.0-0/mdtest_tree.0/file.mdtest.0.19 +V-3: Rank 0 Line 1723 main: Using testdir, '/dev/shm/mdest/test-dir.0-0' diff --git a/testing/mdtest-patterns/advanced/5.txt b/testing/mdtest-patterns/advanced/5.txt index 300bce6..e87ae0a 100644 --- a/testing/mdtest-patterns/advanced/5.txt +++ b/testing/mdtest-patterns/advanced/5.txt @@ -1,77 +1,77 @@ -V-3: main (before display_freespace): testdirpath is "/dev/shm/mdest" -V-3: testdirpath is "/dev/shm/mdest" -V-3: Before show_file_system_size, dirpath is "/dev/shm" -V-3: After show_file_system_size, dirpath is "/dev/shm" -V-3: main (after display_freespace): testdirpath is "/dev/shm/mdest" -V-3: main (create hierarchical directory loop-!unque_dir_per_task): Calling create_remove_directory_tree with "/dev/shm/mdest/#test-dir.0-0" -V-3: main: Using unique_mk_dir, "mdtest_tree.0" -V-3: main: Copied unique_mk_dir, "mdtest_tree.0", to topdir -V-3: directory_test: create path is "/dev/shm/mdest/#test-dir.0-0/mdtest_tree.0" -V-3: create_remove_items (start): temp_path is "/dev/shm/mdest/#test-dir.0-0/mdtest_tree.0" -V-3: create_remove_items_helper (dirs create): curr_item is "/dev/shm/mdest/#test-dir.0-0/mdtest_tree.0/dir.mdtest.0.0" -V-3: create_remove_items_helper (dirs create): curr_item is "/dev/shm/mdest/#test-dir.0-0/mdtest_tree.0/dir.mdtest.0.1" -V-3: create_remove_items_helper (dirs create): curr_item is "/dev/shm/mdest/#test-dir.0-0/mdtest_tree.0/dir.mdtest.0.2" -V-3: create_remove_items_helper (dirs create): curr_item is "/dev/shm/mdest/#test-dir.0-0/mdtest_tree.0/dir.mdtest.0.3" -V-3: create_remove_items_helper (dirs create): curr_item is "/dev/shm/mdest/#test-dir.0-0/mdtest_tree.0/dir.mdtest.0.4" -V-3: create_remove_items_helper (dirs create): curr_item is "/dev/shm/mdest/#test-dir.0-0/mdtest_tree.0/dir.mdtest.0.5" -V-3: create_remove_items_helper (dirs create): curr_item is "/dev/shm/mdest/#test-dir.0-0/mdtest_tree.0/dir.mdtest.0.6" -V-3: create_remove_items_helper (dirs create): curr_item is "/dev/shm/mdest/#test-dir.0-0/mdtest_tree.0/dir.mdtest.0.7" -V-3: create_remove_items_helper (dirs create): curr_item is "/dev/shm/mdest/#test-dir.0-0/mdtest_tree.0/dir.mdtest.0.8" -V-3: create_remove_items_helper (dirs create): curr_item is "/dev/shm/mdest/#test-dir.0-0/mdtest_tree.0/dir.mdtest.0.9" -V-3: create_remove_items_helper (dirs create): curr_item is "/dev/shm/mdest/#test-dir.0-0/mdtest_tree.0/dir.mdtest.0.10" -V-3: create_remove_items_helper (dirs create): curr_item is "/dev/shm/mdest/#test-dir.0-0/mdtest_tree.0/dir.mdtest.0.11" -V-3: create_remove_items_helper (dirs create): curr_item is "/dev/shm/mdest/#test-dir.0-0/mdtest_tree.0/dir.mdtest.0.12" -V-3: create_remove_items_helper (dirs create): curr_item is "/dev/shm/mdest/#test-dir.0-0/mdtest_tree.0/dir.mdtest.0.13" -V-3: create_remove_items_helper (dirs create): curr_item is "/dev/shm/mdest/#test-dir.0-0/mdtest_tree.0/dir.mdtest.0.14" -V-3: create_remove_items_helper (dirs create): curr_item is "/dev/shm/mdest/#test-dir.0-0/mdtest_tree.0/dir.mdtest.0.15" -V-3: create_remove_items_helper (dirs create): curr_item is "/dev/shm/mdest/#test-dir.0-0/mdtest_tree.0/dir.mdtest.0.16" -V-3: create_remove_items_helper (dirs create): curr_item is "/dev/shm/mdest/#test-dir.0-0/mdtest_tree.0/dir.mdtest.0.17" -V-3: create_remove_items_helper (dirs create): curr_item is "/dev/shm/mdest/#test-dir.0-0/mdtest_tree.0/dir.mdtest.0.18" -V-3: create_remove_items_helper (dirs create): curr_item is "/dev/shm/mdest/#test-dir.0-0/mdtest_tree.0/dir.mdtest.0.19" -V-3: directory_test: stat path is "/dev/shm/mdest/#test-dir.0-0/mdtest_tree.0" -V-3: mdtest_stat dir : /dev/shm/mdest/#test-dir.0-0/mdtest_tree.0/dir.mdtest.0.0 -V-3: mdtest_stat dir : /dev/shm/mdest/#test-dir.0-0/mdtest_tree.0/dir.mdtest.0.1 -V-3: mdtest_stat dir : /dev/shm/mdest/#test-dir.0-0/mdtest_tree.0/dir.mdtest.0.2 -V-3: mdtest_stat dir : /dev/shm/mdest/#test-dir.0-0/mdtest_tree.0/dir.mdtest.0.3 -V-3: mdtest_stat dir : /dev/shm/mdest/#test-dir.0-0/mdtest_tree.0/dir.mdtest.0.4 -V-3: mdtest_stat dir : /dev/shm/mdest/#test-dir.0-0/mdtest_tree.0/dir.mdtest.0.5 -V-3: mdtest_stat dir : /dev/shm/mdest/#test-dir.0-0/mdtest_tree.0/dir.mdtest.0.6 -V-3: mdtest_stat dir : /dev/shm/mdest/#test-dir.0-0/mdtest_tree.0/dir.mdtest.0.7 -V-3: mdtest_stat dir : /dev/shm/mdest/#test-dir.0-0/mdtest_tree.0/dir.mdtest.0.8 -V-3: mdtest_stat dir : /dev/shm/mdest/#test-dir.0-0/mdtest_tree.0/dir.mdtest.0.9 -V-3: mdtest_stat dir : /dev/shm/mdest/#test-dir.0-0/mdtest_tree.0/dir.mdtest.0.10 -V-3: mdtest_stat dir : /dev/shm/mdest/#test-dir.0-0/mdtest_tree.0/dir.mdtest.0.11 -V-3: mdtest_stat dir : /dev/shm/mdest/#test-dir.0-0/mdtest_tree.0/dir.mdtest.0.12 -V-3: mdtest_stat dir : /dev/shm/mdest/#test-dir.0-0/mdtest_tree.0/dir.mdtest.0.13 -V-3: mdtest_stat dir : /dev/shm/mdest/#test-dir.0-0/mdtest_tree.0/dir.mdtest.0.14 -V-3: mdtest_stat dir : /dev/shm/mdest/#test-dir.0-0/mdtest_tree.0/dir.mdtest.0.15 -V-3: mdtest_stat dir : /dev/shm/mdest/#test-dir.0-0/mdtest_tree.0/dir.mdtest.0.16 -V-3: mdtest_stat dir : /dev/shm/mdest/#test-dir.0-0/mdtest_tree.0/dir.mdtest.0.17 -V-3: mdtest_stat dir : /dev/shm/mdest/#test-dir.0-0/mdtest_tree.0/dir.mdtest.0.18 -V-3: mdtest_stat dir : /dev/shm/mdest/#test-dir.0-0/mdtest_tree.0/dir.mdtest.0.19 -V-3: directory_test: read path is "/dev/shm/mdest/#test-dir.0-0/mdtest_tree.0" -V-3: directory_test: remove directories path is "/dev/shm/mdest/#test-dir.0-0/mdtest_tree.0" -V-3: create_remove_items (start): temp_path is "/dev/shm/mdest/#test-dir.0-0/mdtest_tree.0" -V-3: create_remove_items_helper (dirs remove): curr_item is "/dev/shm/mdest/#test-dir.0-0/mdtest_tree.0/dir.mdtest.0.0" -V-3: create_remove_items_helper (dirs remove): curr_item is "/dev/shm/mdest/#test-dir.0-0/mdtest_tree.0/dir.mdtest.0.1" -V-3: create_remove_items_helper (dirs remove): curr_item is "/dev/shm/mdest/#test-dir.0-0/mdtest_tree.0/dir.mdtest.0.2" -V-3: create_remove_items_helper (dirs remove): curr_item is "/dev/shm/mdest/#test-dir.0-0/mdtest_tree.0/dir.mdtest.0.3" -V-3: create_remove_items_helper (dirs remove): curr_item is "/dev/shm/mdest/#test-dir.0-0/mdtest_tree.0/dir.mdtest.0.4" -V-3: create_remove_items_helper (dirs remove): curr_item is "/dev/shm/mdest/#test-dir.0-0/mdtest_tree.0/dir.mdtest.0.5" -V-3: create_remove_items_helper (dirs remove): curr_item is "/dev/shm/mdest/#test-dir.0-0/mdtest_tree.0/dir.mdtest.0.6" -V-3: create_remove_items_helper (dirs remove): curr_item is "/dev/shm/mdest/#test-dir.0-0/mdtest_tree.0/dir.mdtest.0.7" -V-3: create_remove_items_helper (dirs remove): curr_item is "/dev/shm/mdest/#test-dir.0-0/mdtest_tree.0/dir.mdtest.0.8" -V-3: create_remove_items_helper (dirs remove): curr_item is "/dev/shm/mdest/#test-dir.0-0/mdtest_tree.0/dir.mdtest.0.9" -V-3: create_remove_items_helper (dirs remove): curr_item is "/dev/shm/mdest/#test-dir.0-0/mdtest_tree.0/dir.mdtest.0.10" -V-3: create_remove_items_helper (dirs remove): curr_item is "/dev/shm/mdest/#test-dir.0-0/mdtest_tree.0/dir.mdtest.0.11" -V-3: create_remove_items_helper (dirs remove): curr_item is "/dev/shm/mdest/#test-dir.0-0/mdtest_tree.0/dir.mdtest.0.12" -V-3: create_remove_items_helper (dirs remove): curr_item is "/dev/shm/mdest/#test-dir.0-0/mdtest_tree.0/dir.mdtest.0.13" -V-3: create_remove_items_helper (dirs remove): curr_item is "/dev/shm/mdest/#test-dir.0-0/mdtest_tree.0/dir.mdtest.0.14" -V-3: create_remove_items_helper (dirs remove): curr_item is "/dev/shm/mdest/#test-dir.0-0/mdtest_tree.0/dir.mdtest.0.15" -V-3: create_remove_items_helper (dirs remove): curr_item is "/dev/shm/mdest/#test-dir.0-0/mdtest_tree.0/dir.mdtest.0.16" -V-3: create_remove_items_helper (dirs remove): curr_item is "/dev/shm/mdest/#test-dir.0-0/mdtest_tree.0/dir.mdtest.0.17" -V-3: create_remove_items_helper (dirs remove): curr_item is "/dev/shm/mdest/#test-dir.0-0/mdtest_tree.0/dir.mdtest.0.18" -V-3: create_remove_items_helper (dirs remove): curr_item is "/dev/shm/mdest/#test-dir.0-0/mdtest_tree.0/dir.mdtest.0.19" -V-3: directory_test: remove unique directories path is "/dev/shm/mdest/#test-dir.0-0/mdtest_tree.0" -V-3: main: Using testdir, "/dev/shm/mdest/#test-dir.0-0" -V-3: main (remove hierarchical directory loop-!unique_dir_per_task): Calling create_remove_directory_tree with "/dev/shm/mdest/#test-dir.0-0" +V-3: Rank 0 Line 2082 main (before display_freespace): testdirpath is '/dev/shm/mdest' +V-3: Rank 0 Line 1506 Entering display_freespace on /dev/shm/mdest... +V-3: Rank 0 Line 1525 Before show_file_system_size, dirpath is '/dev/shm' +V-3: Rank 0 Line 1527 After show_file_system_size, dirpath is '/dev/shm' +V-3: Rank 0 Line 2097 main (after display_freespace): testdirpath is '/dev/shm/mdest' +V-3: Rank 0 Line 1656 main (create hierarchical directory loop-!unque_dir_per_task): Calling create_remove_directory_tree with '/dev/shm/mdest/test-dir.0-0' +V-3: Rank 0 Line 1683 V-3: main: Using unique_mk_dir, 'mdtest_tree.0' +V-3: Rank 0 Line 1704 V-3: main: Copied unique_mk_dir, 'mdtest_tree.0', to topdir +V-3: Rank 0 Line 801 directory_test: create path is '/dev/shm/mdest/test-dir.0-0/mdtest_tree.0' +V-3: Rank 0 Line 457 create_remove_items (start): temp_path is '/dev/shm/mdest/test-dir.0-0/mdtest_tree.0' +V-3: Rank 0 Line 288 create_remove_items_helper (dirs create): curr_item is '/dev/shm/mdest/test-dir.0-0/mdtest_tree.0/dir.mdtest.0.0' +V-3: Rank 0 Line 288 create_remove_items_helper (dirs create): curr_item is '/dev/shm/mdest/test-dir.0-0/mdtest_tree.0/dir.mdtest.0.1' +V-3: Rank 0 Line 288 create_remove_items_helper (dirs create): curr_item is '/dev/shm/mdest/test-dir.0-0/mdtest_tree.0/dir.mdtest.0.2' +V-3: Rank 0 Line 288 create_remove_items_helper (dirs create): curr_item is '/dev/shm/mdest/test-dir.0-0/mdtest_tree.0/dir.mdtest.0.3' +V-3: Rank 0 Line 288 create_remove_items_helper (dirs create): curr_item is '/dev/shm/mdest/test-dir.0-0/mdtest_tree.0/dir.mdtest.0.4' +V-3: Rank 0 Line 288 create_remove_items_helper (dirs create): curr_item is '/dev/shm/mdest/test-dir.0-0/mdtest_tree.0/dir.mdtest.0.5' +V-3: Rank 0 Line 288 create_remove_items_helper (dirs create): curr_item is '/dev/shm/mdest/test-dir.0-0/mdtest_tree.0/dir.mdtest.0.6' +V-3: Rank 0 Line 288 create_remove_items_helper (dirs create): curr_item is '/dev/shm/mdest/test-dir.0-0/mdtest_tree.0/dir.mdtest.0.7' +V-3: Rank 0 Line 288 create_remove_items_helper (dirs create): curr_item is '/dev/shm/mdest/test-dir.0-0/mdtest_tree.0/dir.mdtest.0.8' +V-3: Rank 0 Line 288 create_remove_items_helper (dirs create): curr_item is '/dev/shm/mdest/test-dir.0-0/mdtest_tree.0/dir.mdtest.0.9' +V-3: Rank 0 Line 288 create_remove_items_helper (dirs create): curr_item is '/dev/shm/mdest/test-dir.0-0/mdtest_tree.0/dir.mdtest.0.10' +V-3: Rank 0 Line 288 create_remove_items_helper (dirs create): curr_item is '/dev/shm/mdest/test-dir.0-0/mdtest_tree.0/dir.mdtest.0.11' +V-3: Rank 0 Line 288 create_remove_items_helper (dirs create): curr_item is '/dev/shm/mdest/test-dir.0-0/mdtest_tree.0/dir.mdtest.0.12' +V-3: Rank 0 Line 288 create_remove_items_helper (dirs create): curr_item is '/dev/shm/mdest/test-dir.0-0/mdtest_tree.0/dir.mdtest.0.13' +V-3: Rank 0 Line 288 create_remove_items_helper (dirs create): curr_item is '/dev/shm/mdest/test-dir.0-0/mdtest_tree.0/dir.mdtest.0.14' +V-3: Rank 0 Line 288 create_remove_items_helper (dirs create): curr_item is '/dev/shm/mdest/test-dir.0-0/mdtest_tree.0/dir.mdtest.0.15' +V-3: Rank 0 Line 288 create_remove_items_helper (dirs create): curr_item is '/dev/shm/mdest/test-dir.0-0/mdtest_tree.0/dir.mdtest.0.16' +V-3: Rank 0 Line 288 create_remove_items_helper (dirs create): curr_item is '/dev/shm/mdest/test-dir.0-0/mdtest_tree.0/dir.mdtest.0.17' +V-3: Rank 0 Line 288 create_remove_items_helper (dirs create): curr_item is '/dev/shm/mdest/test-dir.0-0/mdtest_tree.0/dir.mdtest.0.18' +V-3: Rank 0 Line 288 create_remove_items_helper (dirs create): curr_item is '/dev/shm/mdest/test-dir.0-0/mdtest_tree.0/dir.mdtest.0.19' +V-3: Rank 0 Line 833 stat path is '/dev/shm/mdest/test-dir.0-0/mdtest_tree.0' +V-3: Rank 0 Line 588 mdtest_stat dir: /dev/shm/mdest/test-dir.0-0/mdtest_tree.0/dir.mdtest.0.0 +V-3: Rank 0 Line 588 mdtest_stat dir: /dev/shm/mdest/test-dir.0-0/mdtest_tree.0/dir.mdtest.0.1 +V-3: Rank 0 Line 588 mdtest_stat dir: /dev/shm/mdest/test-dir.0-0/mdtest_tree.0/dir.mdtest.0.2 +V-3: Rank 0 Line 588 mdtest_stat dir: /dev/shm/mdest/test-dir.0-0/mdtest_tree.0/dir.mdtest.0.3 +V-3: Rank 0 Line 588 mdtest_stat dir: /dev/shm/mdest/test-dir.0-0/mdtest_tree.0/dir.mdtest.0.4 +V-3: Rank 0 Line 588 mdtest_stat dir: /dev/shm/mdest/test-dir.0-0/mdtest_tree.0/dir.mdtest.0.5 +V-3: Rank 0 Line 588 mdtest_stat dir: /dev/shm/mdest/test-dir.0-0/mdtest_tree.0/dir.mdtest.0.6 +V-3: Rank 0 Line 588 mdtest_stat dir: /dev/shm/mdest/test-dir.0-0/mdtest_tree.0/dir.mdtest.0.7 +V-3: Rank 0 Line 588 mdtest_stat dir: /dev/shm/mdest/test-dir.0-0/mdtest_tree.0/dir.mdtest.0.8 +V-3: Rank 0 Line 588 mdtest_stat dir: /dev/shm/mdest/test-dir.0-0/mdtest_tree.0/dir.mdtest.0.9 +V-3: Rank 0 Line 588 mdtest_stat dir: /dev/shm/mdest/test-dir.0-0/mdtest_tree.0/dir.mdtest.0.10 +V-3: Rank 0 Line 588 mdtest_stat dir: /dev/shm/mdest/test-dir.0-0/mdtest_tree.0/dir.mdtest.0.11 +V-3: Rank 0 Line 588 mdtest_stat dir: /dev/shm/mdest/test-dir.0-0/mdtest_tree.0/dir.mdtest.0.12 +V-3: Rank 0 Line 588 mdtest_stat dir: /dev/shm/mdest/test-dir.0-0/mdtest_tree.0/dir.mdtest.0.13 +V-3: Rank 0 Line 588 mdtest_stat dir: /dev/shm/mdest/test-dir.0-0/mdtest_tree.0/dir.mdtest.0.14 +V-3: Rank 0 Line 588 mdtest_stat dir: /dev/shm/mdest/test-dir.0-0/mdtest_tree.0/dir.mdtest.0.15 +V-3: Rank 0 Line 588 mdtest_stat dir: /dev/shm/mdest/test-dir.0-0/mdtest_tree.0/dir.mdtest.0.16 +V-3: Rank 0 Line 588 mdtest_stat dir: /dev/shm/mdest/test-dir.0-0/mdtest_tree.0/dir.mdtest.0.17 +V-3: Rank 0 Line 588 mdtest_stat dir: /dev/shm/mdest/test-dir.0-0/mdtest_tree.0/dir.mdtest.0.18 +V-3: Rank 0 Line 588 mdtest_stat dir: /dev/shm/mdest/test-dir.0-0/mdtest_tree.0/dir.mdtest.0.19 +V-3: Rank 0 Line 862 directory_test: read path is '/dev/shm/mdest/test-dir.0-0/mdtest_tree.0' +V-3: Rank 0 Line 890 directory_test: remove directories path is '/dev/shm/mdest/test-dir.0-0/mdtest_tree.0' +V-3: Rank 0 Line 457 create_remove_items (start): temp_path is '/dev/shm/mdest/test-dir.0-0/mdtest_tree.0' +V-3: Rank 0 Line 288 create_remove_items_helper (dirs remove): curr_item is '/dev/shm/mdest/test-dir.0-0/mdtest_tree.0/dir.mdtest.0.0' +V-3: Rank 0 Line 288 create_remove_items_helper (dirs remove): curr_item is '/dev/shm/mdest/test-dir.0-0/mdtest_tree.0/dir.mdtest.0.1' +V-3: Rank 0 Line 288 create_remove_items_helper (dirs remove): curr_item is '/dev/shm/mdest/test-dir.0-0/mdtest_tree.0/dir.mdtest.0.2' +V-3: Rank 0 Line 288 create_remove_items_helper (dirs remove): curr_item is '/dev/shm/mdest/test-dir.0-0/mdtest_tree.0/dir.mdtest.0.3' +V-3: Rank 0 Line 288 create_remove_items_helper (dirs remove): curr_item is '/dev/shm/mdest/test-dir.0-0/mdtest_tree.0/dir.mdtest.0.4' +V-3: Rank 0 Line 288 create_remove_items_helper (dirs remove): curr_item is '/dev/shm/mdest/test-dir.0-0/mdtest_tree.0/dir.mdtest.0.5' +V-3: Rank 0 Line 288 create_remove_items_helper (dirs remove): curr_item is '/dev/shm/mdest/test-dir.0-0/mdtest_tree.0/dir.mdtest.0.6' +V-3: Rank 0 Line 288 create_remove_items_helper (dirs remove): curr_item is '/dev/shm/mdest/test-dir.0-0/mdtest_tree.0/dir.mdtest.0.7' +V-3: Rank 0 Line 288 create_remove_items_helper (dirs remove): curr_item is '/dev/shm/mdest/test-dir.0-0/mdtest_tree.0/dir.mdtest.0.8' +V-3: Rank 0 Line 288 create_remove_items_helper (dirs remove): curr_item is '/dev/shm/mdest/test-dir.0-0/mdtest_tree.0/dir.mdtest.0.9' +V-3: Rank 0 Line 288 create_remove_items_helper (dirs remove): curr_item is '/dev/shm/mdest/test-dir.0-0/mdtest_tree.0/dir.mdtest.0.10' +V-3: Rank 0 Line 288 create_remove_items_helper (dirs remove): curr_item is '/dev/shm/mdest/test-dir.0-0/mdtest_tree.0/dir.mdtest.0.11' +V-3: Rank 0 Line 288 create_remove_items_helper (dirs remove): curr_item is '/dev/shm/mdest/test-dir.0-0/mdtest_tree.0/dir.mdtest.0.12' +V-3: Rank 0 Line 288 create_remove_items_helper (dirs remove): curr_item is '/dev/shm/mdest/test-dir.0-0/mdtest_tree.0/dir.mdtest.0.13' +V-3: Rank 0 Line 288 create_remove_items_helper (dirs remove): curr_item is '/dev/shm/mdest/test-dir.0-0/mdtest_tree.0/dir.mdtest.0.14' +V-3: Rank 0 Line 288 create_remove_items_helper (dirs remove): curr_item is '/dev/shm/mdest/test-dir.0-0/mdtest_tree.0/dir.mdtest.0.15' +V-3: Rank 0 Line 288 create_remove_items_helper (dirs remove): curr_item is '/dev/shm/mdest/test-dir.0-0/mdtest_tree.0/dir.mdtest.0.16' +V-3: Rank 0 Line 288 create_remove_items_helper (dirs remove): curr_item is '/dev/shm/mdest/test-dir.0-0/mdtest_tree.0/dir.mdtest.0.17' +V-3: Rank 0 Line 288 create_remove_items_helper (dirs remove): curr_item is '/dev/shm/mdest/test-dir.0-0/mdtest_tree.0/dir.mdtest.0.18' +V-3: Rank 0 Line 288 create_remove_items_helper (dirs remove): curr_item is '/dev/shm/mdest/test-dir.0-0/mdtest_tree.0/dir.mdtest.0.19' +V-3: Rank 0 Line 915 directory_test: remove unique directories path is '/dev/shm/mdest/test-dir.0-0/mdtest_tree.0' +V-3: Rank 0 Line 1723 main: Using testdir, '/dev/shm/mdest/test-dir.0-0' +V-3: Rank 0 Line 1764 V-3: main (remove hierarchical directory loop-!unique_dir_per_task): Calling create_remove_directory_tree with '/dev/shm/mdest/test-dir.0-0' diff --git a/testing/mdtest-patterns/basic/0.txt b/testing/mdtest-patterns/basic/0.txt index 7ff10fc..ebe0f14 100644 --- a/testing/mdtest-patterns/basic/0.txt +++ b/testing/mdtest-patterns/basic/0.txt @@ -1,24 +1,27 @@ -V-3: main (before display_freespace): testdirpath is "/dev/shm/mdest" -V-3: testdirpath is "/dev/shm/mdest" -V-3: Before show_file_system_size, dirpath is "/dev/shm" -V-3: After show_file_system_size, dirpath is "/dev/shm" -V-3: main (after display_freespace): testdirpath is "/dev/shm/mdest" -V-3: main (create hierarchical directory loop-!unque_dir_per_task): Calling create_remove_directory_tree with "/dev/shm/mdest/#test-dir.0-0" -V-3: main: Using unique_mk_dir, "mdtest_tree.0" -V-3: main: Copied unique_mk_dir, "mdtest_tree.0", to topdir -V-3: directory_test: create path is "/dev/shm/mdest/#test-dir.0-0/mdtest_tree.0" -V-3: create_remove_items (start): temp_path is "/dev/shm/mdest/#test-dir.0-0/mdtest_tree.0" -V-3: directory_test: stat path is "/dev/shm/mdest/#test-dir.0-0/mdtest_tree.0" -V-3: directory_test: read path is "/dev/shm/mdest/#test-dir.0-0/mdtest_tree.0" -V-3: directory_test: remove directories path is "/dev/shm/mdest/#test-dir.0-0/mdtest_tree.0" -V-3: create_remove_items (start): temp_path is "/dev/shm/mdest/#test-dir.0-0/mdtest_tree.0" -V-3: directory_test: remove unique directories path is "/dev/shm/mdest/#test-dir.0-0/mdtest_tree.0" -V-3: file_test: create path is "/dev/shm/mdest/#test-dir.0-0/mdtest_tree.0" -V-3: create_remove_items (start): temp_path is "/dev/shm/mdest/#test-dir.0-0/mdtest_tree.0" -V-3: file_test: stat path is "/dev/shm/mdest/#test-dir.0-0/mdtest_tree.0" -V-3: file_test: read path is "/dev/shm/mdest/#test-dir.0-0/mdtest_tree.0" -V-3: file_test: rm directories path is "/dev/shm/mdest/#test-dir.0-0/mdtest_tree.0" -V-3: create_remove_items (start): temp_path is "/dev/shm/mdest/#test-dir.0-0/mdtest_tree.0" -V-3: file_test: rm unique directories path is "mdtest_tree.0" -V-3: main: Using testdir, "/dev/shm/mdest/#test-dir.0-0" -V-3: main (remove hierarchical directory loop-!unique_dir_per_task): Calling create_remove_directory_tree with "/dev/shm/mdest/#test-dir.0-0" +V-3: Rank 0 Line 2082 main (before display_freespace): testdirpath is '/dev/shm/mdest' +V-3: Rank 0 Line 1506 Entering display_freespace on /dev/shm/mdest... +V-3: Rank 0 Line 1525 Before show_file_system_size, dirpath is '/dev/shm' +V-3: Rank 0 Line 1527 After show_file_system_size, dirpath is '/dev/shm' +V-3: Rank 0 Line 2097 main (after display_freespace): testdirpath is '/dev/shm/mdest' +V-3: Rank 0 Line 1656 main (create hierarchical directory loop-!unque_dir_per_task): Calling create_remove_directory_tree with '/dev/shm/mdest/test-dir.0-0' +V-3: Rank 0 Line 1683 V-3: main: Using unique_mk_dir, 'mdtest_tree.0' +V-3: Rank 0 Line 1704 V-3: main: Copied unique_mk_dir, 'mdtest_tree.0', to topdir +V-3: Rank 0 Line 801 directory_test: create path is '/dev/shm/mdest/test-dir.0-0/mdtest_tree.0' +V-3: Rank 0 Line 457 create_remove_items (start): temp_path is '/dev/shm/mdest/test-dir.0-0/mdtest_tree.0' +V-3: Rank 0 Line 833 stat path is '/dev/shm/mdest/test-dir.0-0/mdtest_tree.0' +V-3: Rank 0 Line 862 directory_test: read path is '/dev/shm/mdest/test-dir.0-0/mdtest_tree.0' +V-3: Rank 0 Line 890 directory_test: remove directories path is '/dev/shm/mdest/test-dir.0-0/mdtest_tree.0' +V-3: Rank 0 Line 457 create_remove_items (start): temp_path is '/dev/shm/mdest/test-dir.0-0/mdtest_tree.0' +V-3: Rank 0 Line 915 directory_test: remove unique directories path is '/dev/shm/mdest/test-dir.0-0/mdtest_tree.0' +V-3: Rank 0 Line 1716 will file_test on mdtest_tree.0 +V-3: Rank 0 Line 990 Entering file_test on mdtest_tree.0 +V-3: Rank 0 Line 1012 file_test: create path is '/dev/shm/mdest/test-dir.0-0/mdtest_tree.0' +V-3: Rank 0 Line 457 create_remove_items (start): temp_path is '/dev/shm/mdest/test-dir.0-0/mdtest_tree.0' +V-3: Rank 0 Line 1079 file_test: stat path is '/dev/shm/mdest/test-dir.0-0/mdtest_tree.0' +V-3: Rank 0 Line 1104 file_test: read path is '/dev/shm/mdest/test-dir.0-0/mdtest_tree.0' +V-3: Rank 0 Line 1134 file_test: rm directories path is '/dev/shm/mdest/test-dir.0-0/mdtest_tree.0' +V-3: Rank 0 Line 1141 gonna create /dev/shm/mdest/test-dir.0-0/mdtest_tree.0 +V-3: Rank 0 Line 457 create_remove_items (start): temp_path is '/dev/shm/mdest/test-dir.0-0/mdtest_tree.0' +V-3: Rank 0 Line 1158 file_test: rm unique directories path is 'mdtest_tree.0' +V-3: Rank 0 Line 1723 main: Using testdir, '/dev/shm/mdest/test-dir.0-0' +V-3: Rank 0 Line 1764 V-3: main (remove hierarchical directory loop-!unique_dir_per_task): Calling create_remove_directory_tree with '/dev/shm/mdest/test-dir.0-0' diff --git a/testing/mdtest-patterns/basic/1.txt b/testing/mdtest-patterns/basic/1.txt index 7ff10fc..ebe0f14 100644 --- a/testing/mdtest-patterns/basic/1.txt +++ b/testing/mdtest-patterns/basic/1.txt @@ -1,24 +1,27 @@ -V-3: main (before display_freespace): testdirpath is "/dev/shm/mdest" -V-3: testdirpath is "/dev/shm/mdest" -V-3: Before show_file_system_size, dirpath is "/dev/shm" -V-3: After show_file_system_size, dirpath is "/dev/shm" -V-3: main (after display_freespace): testdirpath is "/dev/shm/mdest" -V-3: main (create hierarchical directory loop-!unque_dir_per_task): Calling create_remove_directory_tree with "/dev/shm/mdest/#test-dir.0-0" -V-3: main: Using unique_mk_dir, "mdtest_tree.0" -V-3: main: Copied unique_mk_dir, "mdtest_tree.0", to topdir -V-3: directory_test: create path is "/dev/shm/mdest/#test-dir.0-0/mdtest_tree.0" -V-3: create_remove_items (start): temp_path is "/dev/shm/mdest/#test-dir.0-0/mdtest_tree.0" -V-3: directory_test: stat path is "/dev/shm/mdest/#test-dir.0-0/mdtest_tree.0" -V-3: directory_test: read path is "/dev/shm/mdest/#test-dir.0-0/mdtest_tree.0" -V-3: directory_test: remove directories path is "/dev/shm/mdest/#test-dir.0-0/mdtest_tree.0" -V-3: create_remove_items (start): temp_path is "/dev/shm/mdest/#test-dir.0-0/mdtest_tree.0" -V-3: directory_test: remove unique directories path is "/dev/shm/mdest/#test-dir.0-0/mdtest_tree.0" -V-3: file_test: create path is "/dev/shm/mdest/#test-dir.0-0/mdtest_tree.0" -V-3: create_remove_items (start): temp_path is "/dev/shm/mdest/#test-dir.0-0/mdtest_tree.0" -V-3: file_test: stat path is "/dev/shm/mdest/#test-dir.0-0/mdtest_tree.0" -V-3: file_test: read path is "/dev/shm/mdest/#test-dir.0-0/mdtest_tree.0" -V-3: file_test: rm directories path is "/dev/shm/mdest/#test-dir.0-0/mdtest_tree.0" -V-3: create_remove_items (start): temp_path is "/dev/shm/mdest/#test-dir.0-0/mdtest_tree.0" -V-3: file_test: rm unique directories path is "mdtest_tree.0" -V-3: main: Using testdir, "/dev/shm/mdest/#test-dir.0-0" -V-3: main (remove hierarchical directory loop-!unique_dir_per_task): Calling create_remove_directory_tree with "/dev/shm/mdest/#test-dir.0-0" +V-3: Rank 0 Line 2082 main (before display_freespace): testdirpath is '/dev/shm/mdest' +V-3: Rank 0 Line 1506 Entering display_freespace on /dev/shm/mdest... +V-3: Rank 0 Line 1525 Before show_file_system_size, dirpath is '/dev/shm' +V-3: Rank 0 Line 1527 After show_file_system_size, dirpath is '/dev/shm' +V-3: Rank 0 Line 2097 main (after display_freespace): testdirpath is '/dev/shm/mdest' +V-3: Rank 0 Line 1656 main (create hierarchical directory loop-!unque_dir_per_task): Calling create_remove_directory_tree with '/dev/shm/mdest/test-dir.0-0' +V-3: Rank 0 Line 1683 V-3: main: Using unique_mk_dir, 'mdtest_tree.0' +V-3: Rank 0 Line 1704 V-3: main: Copied unique_mk_dir, 'mdtest_tree.0', to topdir +V-3: Rank 0 Line 801 directory_test: create path is '/dev/shm/mdest/test-dir.0-0/mdtest_tree.0' +V-3: Rank 0 Line 457 create_remove_items (start): temp_path is '/dev/shm/mdest/test-dir.0-0/mdtest_tree.0' +V-3: Rank 0 Line 833 stat path is '/dev/shm/mdest/test-dir.0-0/mdtest_tree.0' +V-3: Rank 0 Line 862 directory_test: read path is '/dev/shm/mdest/test-dir.0-0/mdtest_tree.0' +V-3: Rank 0 Line 890 directory_test: remove directories path is '/dev/shm/mdest/test-dir.0-0/mdtest_tree.0' +V-3: Rank 0 Line 457 create_remove_items (start): temp_path is '/dev/shm/mdest/test-dir.0-0/mdtest_tree.0' +V-3: Rank 0 Line 915 directory_test: remove unique directories path is '/dev/shm/mdest/test-dir.0-0/mdtest_tree.0' +V-3: Rank 0 Line 1716 will file_test on mdtest_tree.0 +V-3: Rank 0 Line 990 Entering file_test on mdtest_tree.0 +V-3: Rank 0 Line 1012 file_test: create path is '/dev/shm/mdest/test-dir.0-0/mdtest_tree.0' +V-3: Rank 0 Line 457 create_remove_items (start): temp_path is '/dev/shm/mdest/test-dir.0-0/mdtest_tree.0' +V-3: Rank 0 Line 1079 file_test: stat path is '/dev/shm/mdest/test-dir.0-0/mdtest_tree.0' +V-3: Rank 0 Line 1104 file_test: read path is '/dev/shm/mdest/test-dir.0-0/mdtest_tree.0' +V-3: Rank 0 Line 1134 file_test: rm directories path is '/dev/shm/mdest/test-dir.0-0/mdtest_tree.0' +V-3: Rank 0 Line 1141 gonna create /dev/shm/mdest/test-dir.0-0/mdtest_tree.0 +V-3: Rank 0 Line 457 create_remove_items (start): temp_path is '/dev/shm/mdest/test-dir.0-0/mdtest_tree.0' +V-3: Rank 0 Line 1158 file_test: rm unique directories path is 'mdtest_tree.0' +V-3: Rank 0 Line 1723 main: Using testdir, '/dev/shm/mdest/test-dir.0-0' +V-3: Rank 0 Line 1764 V-3: main (remove hierarchical directory loop-!unique_dir_per_task): Calling create_remove_directory_tree with '/dev/shm/mdest/test-dir.0-0' diff --git a/testing/mdtest-patterns/basic/2.txt b/testing/mdtest-patterns/basic/2.txt index a21f5a3..77f5c78 100644 --- a/testing/mdtest-patterns/basic/2.txt +++ b/testing/mdtest-patterns/basic/2.txt @@ -1,25 +1,29 @@ -V-3: main (before display_freespace): testdirpath is "/dev/shm/mdest" -V-3: testdirpath is "/dev/shm/mdest" -V-3: Before show_file_system_size, dirpath is "/dev/shm" -V-3: After show_file_system_size, dirpath is "/dev/shm" -V-3: main (after display_freespace): testdirpath is "/dev/shm/mdest" -V-3: main (create hierarchical directory loop-!collective_creates): Calling create_remove_directory_tree with "/dev/shm/mdest/#test-dir.0-0" -V-3: main: Copied unique_mk_dir, "mdtest_tree.0.0", to topdir -V-3: file_test: create path is "/dev/shm/mdest/#test-dir.0-0/mdtest_tree.0.0" -V-3: create_remove_items (start): temp_path is "/dev/shm/mdest/#test-dir.0-0/mdtest_tree.0.0" -V-3: create_remove_items (start): temp_path is "/dev/shm/mdest/#test-dir.0-0/mdtest_tree.0.0" -V-3: create_remove_items (for loop): temp_path is "/dev/shm/mdest/#test-dir.0-0/mdtest_tree.0.0/mdtest_tree.0.1/" -V-3: create_remove_items_helper (non-dirs create): curr_item is "/dev/shm/mdest/#test-dir.0-0/mdtest_tree.0.0/mdtest_tree.0.1//file.mdtest.0.1" -V-3: create_remove_items_helper (non-collective, shared): open... -V-3: create_remove_items_helper: close... -V-3: create_remove_items (start): temp_path is "/dev/shm/mdest/#test-dir.0-0/mdtest_tree.0.0/mdtest_tree.0.1/" -V-3: file_test: stat path is "/dev/shm/mdest/#test-dir.0-0/mdtest_tree.0.0" -V-3: mdtest_stat file: /dev/shm/mdest/#test-dir.0-0/mdtest_tree.0.0/mdtest_tree.0.1/file.mdtest.0.1 -V-3: file_test: rm directories path is "/dev/shm/mdest/#test-dir.0-0/mdtest_tree.0.0" -V-3: create_remove_items (start): temp_path is "/dev/shm/mdest/#test-dir.0-0/mdtest_tree.0.0" -V-3: create_remove_items (start): temp_path is "/dev/shm/mdest/#test-dir.0-0/mdtest_tree.0.0" -V-3: create_remove_items (for loop): temp_path is "/dev/shm/mdest/#test-dir.0-0/mdtest_tree.0.0/mdtest_tree.0.1/" -V-3: create_remove_items_helper (non-dirs remove): curr_item is "/dev/shm/mdest/#test-dir.0-0/mdtest_tree.0.0/mdtest_tree.0.1//file.mdtest.0.1" -V-3: create_remove_items (start): temp_path is "/dev/shm/mdest/#test-dir.0-0/mdtest_tree.0.0/mdtest_tree.0.1/" -V-3: file_test: rm unique directories path is "/dev/shm/mdest/#test-dir.0-0/" -V-3: main (remove hierarchical directory loop-!collective): Calling create_remove_directory_tree with "/dev/shm/mdest/#test-dir.0-0" +V-3: Rank 0 Line 2082 main (before display_freespace): testdirpath is '/dev/shm/mdest' +V-3: Rank 0 Line 1506 Entering display_freespace on /dev/shm/mdest... +V-3: Rank 0 Line 1525 Before show_file_system_size, dirpath is '/dev/shm' +V-3: Rank 0 Line 1527 After show_file_system_size, dirpath is '/dev/shm' +V-3: Rank 0 Line 2097 main (after display_freespace): testdirpath is '/dev/shm/mdest' +V-3: Rank 0 Line 1647 main (create hierarchical directory loop-!collective_creates): Calling create_remove_directory_tree with '/dev/shm/mdest/test-dir.0-0' +V-3: Rank 0 Line 1694 i 1 nstride 0 +V-3: Rank 0 Line 1704 V-3: main: Copied unique_mk_dir, 'mdtest_tree.0.0', to topdir +V-3: Rank 0 Line 1716 will file_test on mdtest_tree.0.0 +V-3: Rank 0 Line 990 Entering file_test on mdtest_tree.0.0 +V-3: Rank 0 Line 1012 file_test: create path is '/dev/shm/mdest/test-dir.0-0/mdtest_tree.0.0' +V-3: Rank 0 Line 457 create_remove_items (start): temp_path is '/dev/shm/mdest/test-dir.0-0/mdtest_tree.0.0' +V-3: Rank 0 Line 457 create_remove_items (start): temp_path is '/dev/shm/mdest/test-dir.0-0/mdtest_tree.0.0' +V-3: Rank 0 Line 483 create_remove_items (for loop): temp_path is '/dev/shm/mdest/test-dir.0-0/mdtest_tree.0.0/mdtest_tree.0.1/' +V-3: Rank 0 Line 326 create_remove_items_helper (non-dirs create): curr_item is '/dev/shm/mdest/test-dir.0-0/mdtest_tree.0.0/mdtest_tree.0.1//file.mdtest.0.1' +V-3: Rank 0 Line 348 create_remove_items_helper (non-collective, shared): open... +V-3: Rank 0 Line 373 create_remove_items_helper: close... +V-3: Rank 0 Line 457 create_remove_items (start): temp_path is '/dev/shm/mdest/test-dir.0-0/mdtest_tree.0.0/mdtest_tree.0.1/' +V-3: Rank 0 Line 1079 file_test: stat path is '/dev/shm/mdest/test-dir.0-0/mdtest_tree.0.0' +V-3: Rank 0 Line 588 mdtest_stat file: /dev/shm/mdest/test-dir.0-0/mdtest_tree.0.0/mdtest_tree.0.1/file.mdtest.0.1 +V-3: Rank 0 Line 1134 file_test: rm directories path is '/dev/shm/mdest/test-dir.0-0/mdtest_tree.0.0' +V-3: Rank 0 Line 1141 gonna create /dev/shm/mdest/test-dir.0-0/mdtest_tree.0.0 +V-3: Rank 0 Line 457 create_remove_items (start): temp_path is '/dev/shm/mdest/test-dir.0-0/mdtest_tree.0.0' +V-3: Rank 0 Line 457 create_remove_items (start): temp_path is '/dev/shm/mdest/test-dir.0-0/mdtest_tree.0.0' +V-3: Rank 0 Line 483 create_remove_items (for loop): temp_path is '/dev/shm/mdest/test-dir.0-0/mdtest_tree.0.0/mdtest_tree.0.1/' +V-3: Rank 0 Line 310 create_remove_items_helper (non-dirs remove): curr_item is '/dev/shm/mdest/test-dir.0-0/mdtest_tree.0.0/mdtest_tree.0.1//file.mdtest.0.1' +V-3: Rank 0 Line 457 create_remove_items (start): temp_path is '/dev/shm/mdest/test-dir.0-0/mdtest_tree.0.0/mdtest_tree.0.1/' +V-3: Rank 0 Line 1158 file_test: rm unique directories path is '/dev/shm/mdest/test-dir.0-0/' +V-3: Rank 0 Line 1754 main (remove hierarchical directory loop-!collective): Calling create_remove_directory_tree with '/dev/shm/mdest/test-dir.0-0' diff --git a/testing/mdtest-patterns/basic/3.txt b/testing/mdtest-patterns/basic/3.txt index 3e4aa78..eafadc1 100644 --- a/testing/mdtest-patterns/basic/3.txt +++ b/testing/mdtest-patterns/basic/3.txt @@ -1,31 +1,34 @@ -V-3: main (before display_freespace): testdirpath is "/dev/shm/mdest" -V-3: testdirpath is "/dev/shm/mdest" -V-3: Before show_file_system_size, dirpath is "/dev/shm" -V-3: After show_file_system_size, dirpath is "/dev/shm" -V-3: main (after display_freespace): testdirpath is "/dev/shm/mdest" -V-3: main (create hierarchical directory loop-!collective_creates): Calling create_remove_directory_tree with "/dev/shm/mdest/#test-dir.0-0" -V-3: main: Copied unique_mk_dir, "mdtest_tree.0.0", to topdir -V-3: directory_test: create path is "/dev/shm/mdest/#test-dir.0-0/mdtest_tree.0.0" -V-3: create_remove_items (start): temp_path is "/dev/shm/mdest/#test-dir.0-0/mdtest_tree.0.0" -V-3: create_remove_items_helper (dirs create): curr_item is "/dev/shm/mdest/#test-dir.0-0/mdtest_tree.0.0/dir.mdtest.0.0" -V-3: create_remove_items (start): temp_path is "/dev/shm/mdest/#test-dir.0-0/mdtest_tree.0.0" -V-3: create_remove_items (for loop): temp_path is "/dev/shm/mdest/#test-dir.0-0/mdtest_tree.0.0/mdtest_tree.0.1/" -V-3: create_remove_items_helper (dirs create): curr_item is "/dev/shm/mdest/#test-dir.0-0/mdtest_tree.0.0/mdtest_tree.0.1//dir.mdtest.0.1" -V-3: create_remove_items (start): temp_path is "/dev/shm/mdest/#test-dir.0-0/mdtest_tree.0.0/mdtest_tree.0.1/" -V-3: directory_test: stat path is "/dev/shm/mdest/#test-dir.0-0/mdtest_tree.0.0" -V-3: mdtest_stat dir : /dev/shm/mdest/#test-dir.0-0/mdtest_tree.0.0/dir.mdtest.0.0 -V-3: mdtest_stat dir : /dev/shm/mdest/#test-dir.0-0/mdtest_tree.0.0/mdtest_tree.0.1/dir.mdtest.0.1 -V-3: file_test: create path is "/dev/shm/mdest/#test-dir.0-0/mdtest_tree.0.0" -V-3: create_remove_items (start): temp_path is "/dev/shm/mdest/#test-dir.0-0/mdtest_tree.0.0" -V-3: create_remove_items_helper (non-dirs create): curr_item is "/dev/shm/mdest/#test-dir.0-0/mdtest_tree.0.0/file.mdtest.0.0" -V-3: create_remove_items_helper (non-collective, shared): open... -V-3: create_remove_items_helper: close... -V-3: create_remove_items (start): temp_path is "/dev/shm/mdest/#test-dir.0-0/mdtest_tree.0.0" -V-3: create_remove_items (for loop): temp_path is "/dev/shm/mdest/#test-dir.0-0/mdtest_tree.0.0/mdtest_tree.0.1/" -V-3: create_remove_items_helper (non-dirs create): curr_item is "/dev/shm/mdest/#test-dir.0-0/mdtest_tree.0.0/mdtest_tree.0.1//file.mdtest.0.1" -V-3: create_remove_items_helper (non-collective, shared): open... -V-3: create_remove_items_helper: close... -V-3: create_remove_items (start): temp_path is "/dev/shm/mdest/#test-dir.0-0/mdtest_tree.0.0/mdtest_tree.0.1/" -V-3: file_test: stat path is "/dev/shm/mdest/#test-dir.0-0/mdtest_tree.0.0" -V-3: mdtest_stat file: /dev/shm/mdest/#test-dir.0-0/mdtest_tree.0.0/file.mdtest.0.0 -V-3: mdtest_stat file: /dev/shm/mdest/#test-dir.0-0/mdtest_tree.0.0/mdtest_tree.0.1/file.mdtest.0.1 +V-3: Rank 0 Line 2082 main (before display_freespace): testdirpath is '/dev/shm/mdest' +V-3: Rank 0 Line 1506 Entering display_freespace on /dev/shm/mdest... +V-3: Rank 0 Line 1525 Before show_file_system_size, dirpath is '/dev/shm' +V-3: Rank 0 Line 1527 After show_file_system_size, dirpath is '/dev/shm' +V-3: Rank 0 Line 2097 main (after display_freespace): testdirpath is '/dev/shm/mdest' +V-3: Rank 0 Line 1647 main (create hierarchical directory loop-!collective_creates): Calling create_remove_directory_tree with '/dev/shm/mdest/test-dir.0-0' +V-3: Rank 0 Line 1694 i 1 nstride 0 +V-3: Rank 0 Line 1704 V-3: main: Copied unique_mk_dir, 'mdtest_tree.0.0', to topdir +V-3: Rank 0 Line 801 directory_test: create path is '/dev/shm/mdest/test-dir.0-0/mdtest_tree.0.0' +V-3: Rank 0 Line 457 create_remove_items (start): temp_path is '/dev/shm/mdest/test-dir.0-0/mdtest_tree.0.0' +V-3: Rank 0 Line 288 create_remove_items_helper (dirs create): curr_item is '/dev/shm/mdest/test-dir.0-0/mdtest_tree.0.0/dir.mdtest.0.0' +V-3: Rank 0 Line 457 create_remove_items (start): temp_path is '/dev/shm/mdest/test-dir.0-0/mdtest_tree.0.0' +V-3: Rank 0 Line 483 create_remove_items (for loop): temp_path is '/dev/shm/mdest/test-dir.0-0/mdtest_tree.0.0/mdtest_tree.0.1/' +V-3: Rank 0 Line 288 create_remove_items_helper (dirs create): curr_item is '/dev/shm/mdest/test-dir.0-0/mdtest_tree.0.0/mdtest_tree.0.1//dir.mdtest.0.1' +V-3: Rank 0 Line 457 create_remove_items (start): temp_path is '/dev/shm/mdest/test-dir.0-0/mdtest_tree.0.0/mdtest_tree.0.1/' +V-3: Rank 0 Line 833 stat path is '/dev/shm/mdest/test-dir.0-0/mdtest_tree.0.0' +V-3: Rank 0 Line 588 mdtest_stat dir: /dev/shm/mdest/test-dir.0-0/mdtest_tree.0.0/dir.mdtest.0.0 +V-3: Rank 0 Line 588 mdtest_stat dir: /dev/shm/mdest/test-dir.0-0/mdtest_tree.0.0/mdtest_tree.0.1/dir.mdtest.0.1 +V-3: Rank 0 Line 1716 will file_test on mdtest_tree.0.0 +V-3: Rank 0 Line 990 Entering file_test on mdtest_tree.0.0 +V-3: Rank 0 Line 1012 file_test: create path is '/dev/shm/mdest/test-dir.0-0/mdtest_tree.0.0' +V-3: Rank 0 Line 457 create_remove_items (start): temp_path is '/dev/shm/mdest/test-dir.0-0/mdtest_tree.0.0' +V-3: Rank 0 Line 326 create_remove_items_helper (non-dirs create): curr_item is '/dev/shm/mdest/test-dir.0-0/mdtest_tree.0.0/file.mdtest.0.0' +V-3: Rank 0 Line 348 create_remove_items_helper (non-collective, shared): open... +V-3: Rank 0 Line 373 create_remove_items_helper: close... +V-3: Rank 0 Line 457 create_remove_items (start): temp_path is '/dev/shm/mdest/test-dir.0-0/mdtest_tree.0.0' +V-3: Rank 0 Line 483 create_remove_items (for loop): temp_path is '/dev/shm/mdest/test-dir.0-0/mdtest_tree.0.0/mdtest_tree.0.1/' +V-3: Rank 0 Line 326 create_remove_items_helper (non-dirs create): curr_item is '/dev/shm/mdest/test-dir.0-0/mdtest_tree.0.0/mdtest_tree.0.1//file.mdtest.0.1' +V-3: Rank 0 Line 348 create_remove_items_helper (non-collective, shared): open... +V-3: Rank 0 Line 373 create_remove_items_helper: close... +V-3: Rank 0 Line 457 create_remove_items (start): temp_path is '/dev/shm/mdest/test-dir.0-0/mdtest_tree.0.0/mdtest_tree.0.1/' +V-3: Rank 0 Line 1079 file_test: stat path is '/dev/shm/mdest/test-dir.0-0/mdtest_tree.0.0' +V-3: Rank 0 Line 588 mdtest_stat file: /dev/shm/mdest/test-dir.0-0/mdtest_tree.0.0/file.mdtest.0.0 +V-3: Rank 0 Line 588 mdtest_stat file: /dev/shm/mdest/test-dir.0-0/mdtest_tree.0.0/mdtest_tree.0.1/file.mdtest.0.1 From 70e8b13d1dc9586113f929ba70619fb2089bc7fb Mon Sep 17 00:00:00 2001 From: Axel Huebl Date: Sun, 4 Aug 2019 18:27:20 -0500 Subject: [PATCH 40/50] Fix Last Free --- src/aiori-POSIX.c | 1 - 1 file changed, 1 deletion(-) diff --git a/src/aiori-POSIX.c b/src/aiori-POSIX.c index 0eb663b..d78cd40 100755 --- a/src/aiori-POSIX.c +++ b/src/aiori-POSIX.c @@ -89,7 +89,6 @@ option_help * POSIX_options(void ** init_backend_options, void * init_values){ } *init_backend_options = o; - free(o); option_help h [] = { {0, "posix.odirect", "Direct I/O Mode", OPTION_FLAG, 'd', & o->direct_io}, From de3baf886107f2bff560dbaf3f199dc6be59e2bd Mon Sep 17 00:00:00 2001 From: "Julian M. Kunkel" Date: Thu, 15 Aug 2019 16:21:30 +0100 Subject: [PATCH 41/50] MDTest: Document choice of 42. --- src/mdtest.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/mdtest.c b/src/mdtest.c index 6b5ab46..44a210c 100644 --- a/src/mdtest.c +++ b/src/mdtest.c @@ -700,7 +700,7 @@ void mdtest_read(int random, int dirs, const long dir_iter, char *path) { /* read file */ if (read_bytes > 0) { - read_buffer[0] = 42; + read_buffer[0] = 42; /* use a random value to ensure that the read_buffer is now different from the expected buffer and read isn't sometimes NOOP */ if (read_bytes != (size_t) backend->xfer (READ, aiori_fh, (IOR_size_t *) read_buffer, read_bytes, ¶m)) { FAIL("unable to read file %s", item); } From 0d9f46e980054b9c149448a1203a8196fd8b41ad Mon Sep 17 00:00:00 2001 From: "Julian M. Kunkel" Date: Thu, 15 Aug 2019 16:49:46 +0100 Subject: [PATCH 42/50] MDTest re-added the -Z option for compatibility (for now) and switched back behavior. --- src/mdtest.c | 8 ++++++-- 1 file changed, 6 insertions(+), 2 deletions(-) diff --git a/src/mdtest.c b/src/mdtest.c index 44a210c..77b2759 100644 --- a/src/mdtest.c +++ b/src/mdtest.c @@ -1238,8 +1238,11 @@ void summarize_results(int iterations, int print_time) { MPI_Barrier(testComm); for(int i=0; i < iterations; i++){ - MPI_Gather(& summary_table[i].time[0], tableSize, MPI_DOUBLE, & all[i*tableSize*size], tableSize, MPI_DOUBLE, 0, testComm); - MPI_Gather(& summary_table[i].rate[0], tableSize, MPI_DOUBLE, & all[i*tableSize*size], tableSize, MPI_DOUBLE, 0, testComm); + if(print_time){ + MPI_Gather(& summary_table[i].time[0], tableSize, MPI_DOUBLE, & all[i*tableSize*size], tableSize, MPI_DOUBLE, 0, testComm); + }else{ + MPI_Gather(& summary_table[i].rate[0], tableSize, MPI_DOUBLE, & all[i*tableSize*size], tableSize, MPI_DOUBLE, 0, testComm); + } } if (rank != 0) { @@ -1923,6 +1926,7 @@ mdtest_results_t * mdtest_run(int argc, char **argv, MPI_Comm world_com, FILE * {'X', "verify-read", "Verify the data read", OPTION_FLAG, 'd', & verify_read}, {'y', NULL, "sync file after writing", OPTION_FLAG, 'd', & sync_file}, {'z', NULL, "depth of hierarchical directory structure", OPTION_OPTIONAL_ARGUMENT, 'd', & depth}, + {'Z', NULL, "print time instead of rate", OPTION_FLAG, 'd', & print_time}, LAST_OPTION }; options_all_t * global_options = airoi_create_all_module_options(options); From a4068be551c38e327fb9b054a91cbeb778a9bd76 Mon Sep 17 00:00:00 2001 From: "Julian M. Kunkel" Date: Mon, 26 Aug 2019 15:57:13 +0100 Subject: [PATCH 43/50] Improved help for fsync. --- src/parse_options.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/parse_options.c b/src/parse_options.c index af30c36..47f9920 100755 --- a/src/parse_options.c +++ b/src/parse_options.c @@ -477,7 +477,7 @@ option_help * createGlobalOptions(IOR_param_t * params){ {.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 stoneWallingWearOutIterations=N -- stop after processing this number of iterations, needed for reading data back written with stoneWallingWearOut", .arg = OPTION_OPTIONAL_ARGUMENT}, {.help=" -O stoneWallingStatusFile=FILE -- this file keeps the number of iterations from stonewalling during write and allows to use them for read", .arg = OPTION_OPTIONAL_ARGUMENT}, - {'e', NULL, "fsync -- perform sync operation after each block write", OPTION_FLAG, 'd', & params->fsync}, + {'e', NULL, "fsync -- perform a fsync() operation at the end of each read/write phase", OPTION_FLAG, 'd', & params->fsync}, {'E', NULL, "useExistingTestFile -- do not remove test file before write access", OPTION_FLAG, 'd', & params->useExistingTestFile}, {'f', NULL, "scriptFile -- test script name", OPTION_OPTIONAL_ARGUMENT, 's', & params->testscripts}, {'F', NULL, "filePerProc -- file-per-process", OPTION_FLAG, 'd', & params->filePerProc}, From 4df051bf283675faefcb8523dc034b7f817419c6 Mon Sep 17 00:00:00 2001 From: "Julian M. Kunkel" Date: Mon, 26 Aug 2019 18:57:14 +0100 Subject: [PATCH 44/50] New option -Y to invoke the sync command. --- src/mdtest.c | 47 ++++++++++++++++++++++------------------------- src/utilities.c | 17 ++++++++++++----- src/utilities.h | 1 + 3 files changed, 35 insertions(+), 30 deletions(-) diff --git a/src/mdtest.c b/src/mdtest.c index 77b2759..e07613b 100644 --- a/src/mdtest.c +++ b/src/mdtest.c @@ -148,6 +148,7 @@ static size_t write_bytes; static int stone_wall_timer_seconds; static size_t read_bytes; static int sync_file; +static int call_sync; static int path_count; static int nstride; /* neighbor stride */ static int make_node = 0; @@ -263,6 +264,16 @@ static void prep_testdir(int j, int dir_iter){ pos += sprintf(& testdir[pos], ".%d-%d", j, dir_iter); } +static void phase_end(){ + if (call_sync){ + call_sync_cmd(); + } + + if (barriers) { + MPI_Barrier(testComm); + } +} + /* * This function copies the unique directory name for a given option to * the "to" parameter. Some memory must be allocated to the "to" parameter. @@ -836,9 +847,7 @@ void directory_test(const int iteration, const int ntasks, const char *path, ran } } - if (barriers) { - MPI_Barrier(testComm); - } + phase_end(); t[1] = GetTimeStamp(); /* stat phase */ @@ -864,10 +873,7 @@ void directory_test(const int iteration, const int ntasks, const char *path, ran } } } - - if (barriers) { - MPI_Barrier(testComm); - } + phase_end(); t[2] = GetTimeStamp(); /* read phase */ @@ -894,9 +900,7 @@ void directory_test(const int iteration, const int ntasks, const char *path, ran } } - if (barriers) { - MPI_Barrier(testComm); - } + phase_end(); t[3] = GetTimeStamp(); if (remove_only) { @@ -924,9 +928,7 @@ void directory_test(const int iteration, const int ntasks, const char *path, ran } } - if (barriers) { - MPI_Barrier(testComm); - } + phase_end(); t[4] = GetTimeStamp(); if (remove_only) { @@ -1082,9 +1084,7 @@ void file_test(const int iteration, const int ntasks, const char *path, rank_pro } } - if (barriers) { - MPI_Barrier(testComm); - } + phase_end(); t[1] = GetTimeStamp(); /* stat phase */ @@ -1107,9 +1107,7 @@ void file_test(const int iteration, const int ntasks, const char *path, rank_pro } } - if (barriers) { - MPI_Barrier(testComm); - } + phase_end(); t[2] = GetTimeStamp(); /* read phase */ @@ -1136,9 +1134,7 @@ void file_test(const int iteration, const int ntasks, const char *path, rank_pro } } - if (barriers) { - MPI_Barrier(testComm); - } + phase_end(); t[3] = GetTimeStamp(); if (remove_only) { @@ -1168,9 +1164,7 @@ void file_test(const int iteration, const int ntasks, const char *path, rank_pro } } - if (barriers) { - MPI_Barrier(testComm); - } + phase_end(); t[4] = GetTimeStamp(); if (remove_only) { if (unique_dir_per_task) { @@ -1853,6 +1847,7 @@ void mdtest_init_args(){ stone_wall_timer_seconds = 0; read_bytes = 0; sync_file = 0; + call_sync = 0; path_count = 0; nstride = 0; make_node = 0; @@ -1925,6 +1920,7 @@ mdtest_results_t * mdtest_run(int argc, char **argv, MPI_Comm world_com, FILE * {'x', NULL, "StoneWallingStatusFile; contains the number of iterations of the creation phase, can be used to split phases across runs", OPTION_OPTIONAL_ARGUMENT, 's', & stoneWallingStatusFile}, {'X', "verify-read", "Verify the data read", OPTION_FLAG, 'd', & verify_read}, {'y', NULL, "sync file after writing", OPTION_FLAG, 'd', & sync_file}, + {'Y', NULL, "call the sync command after each phase (included in the timing; note it causes all IO to be flushed from your node)", OPTION_FLAG, 'd', & call_sync}, {'z', NULL, "depth of hierarchical directory structure", OPTION_OPTIONAL_ARGUMENT, 'd', & depth}, {'Z', NULL, "print time instead of rate", OPTION_FLAG, 'd', & print_time}, LAST_OPTION @@ -2008,6 +2004,7 @@ mdtest_results_t * mdtest_run(int argc, char **argv, MPI_Comm world_com, FILE * VERBOSE(1,-1, "unique_dir_per_task : %s", ( unique_dir_per_task ? "True" : "False" )); VERBOSE(1,-1, "write_bytes : "LLU"", write_bytes ); VERBOSE(1,-1, "sync_file : %s", ( sync_file ? "True" : "False" )); + VERBOSE(1,-1, "call_sync : %s", ( call_sync ? "True" : "False" )); VERBOSE(1,-1, "depth : %d", depth ); VERBOSE(1,-1, "make_node : %d", make_node ); diff --git a/src/utilities.c b/src/utilities.c index cdb090e..a2e4b0d 100755 --- a/src/utilities.c +++ b/src/utilities.c @@ -77,15 +77,15 @@ void* safeMalloc(uint64_t size){ } void FailMessage(int rank, const char *location, char *format, ...) { - char msg[4096]; + char msg[4096]; va_list args; va_start(args, format); vsnprintf(msg, 4096, format, args); va_end(args); - fprintf(out_logfile, "%s: Process %d: FAILED in %s, %s: %s\n", - PrintTimestamp(), rank, location, msg, strerror(errno)); - fflush(out_logfile); - MPI_Abort(testComm, 1); + fprintf(out_logfile, "%s: Process %d: FAILED in %s, %s: %s\n", + PrintTimestamp(), rank, location, msg, strerror(errno)); + fflush(out_logfile); + MPI_Abort(testComm, 1); } size_t NodeMemoryStringToBytes(char *size_str) @@ -809,3 +809,10 @@ char *HumanReadable(IOR_offset_t value, int base) } return valueStr; } + +void call_sync_cmd(){ + int ret = system("sync"); + if (ret != 0){ + FAIL("Error executing the sync command, ensure it exists."); + } +} diff --git a/src/utilities.h b/src/utilities.h index d2c9962..b85f957 100755 --- a/src/utilities.h +++ b/src/utilities.h @@ -60,6 +60,7 @@ int QueryNodeMapping(MPI_Comm comm, int print_nodemap); void DelaySecs(int delay); void updateParsedOptions(IOR_param_t * options, options_all_t * global_options); size_t NodeMemoryStringToBytes(char *size_str); +void call_sync_cmd(); /* Returns -1, if cannot be read */ int64_t ReadStoneWallingIterations(char * const filename); From 0bd979637e8b8c340fb7475897c84aa8172d7117 Mon Sep 17 00:00:00 2001 From: Josh Schwartz <52082483+jschwartz-cray@users.noreply.github.com> Date: Fri, 30 Aug 2019 15:11:25 -0600 Subject: [PATCH 45/50] Added some extra debug including ERRF, WARNF, and MPI_CHECKF format string macros. --- src/aiori-MPIIO.c | 14 ++++++------ src/aiori-POSIX.c | 54 +++++++++++++++++++++++++---------------------- src/ior.c | 17 +++++++++------ src/iordef.h | 52 +++++++++++++++++++++++++++++++++------------ 4 files changed, 85 insertions(+), 52 deletions(-) diff --git a/src/aiori-MPIIO.c b/src/aiori-MPIIO.c index 6bf991b..707b3a7 100755 --- a/src/aiori-MPIIO.c +++ b/src/aiori-MPIIO.c @@ -178,8 +178,8 @@ static void *MPIIO_Open(char *testFileName, IOR_param_t * param) fprintf(stdout, "}\n"); } if(! param->dryRun){ - MPI_CHECK(MPI_File_open(comm, testFileName, fd_mode, mpiHints, fd), - "cannot open file"); + MPI_CHECKF(MPI_File_open(comm, testFileName, fd_mode, mpiHints, fd), + "cannot open file: %s", testFileName); } /* show hints actually attached to file handle */ @@ -428,8 +428,8 @@ void MPIIO_Delete(char *testFileName, IOR_param_t * param) { if(param->dryRun) return; - MPI_CHECK(MPI_File_delete(testFileName, (MPI_Info) MPI_INFO_NULL), - "cannot delete file"); + MPI_CHECKF(MPI_File_delete(testFileName, (MPI_Info) MPI_INFO_NULL), + "cannot delete file: %s", testFileName); } /* @@ -504,9 +504,9 @@ IOR_offset_t MPIIO_GetFileSize(IOR_param_t * test, MPI_Comm testComm, comm = testComm; } - MPI_CHECK(MPI_File_open(comm, testFileName, MPI_MODE_RDONLY, - MPI_INFO_NULL, &fd), - "cannot open file to get file size"); + MPI_CHECKF(MPI_File_open(comm, testFileName, MPI_MODE_RDONLY, + MPI_INFO_NULL, &fd), + "cannot open file to get file size: %s", testFileName); MPI_CHECK(MPI_File_get_size(fd, (MPI_Offset *) & aggFileSizeFromStat), "cannot get file size"); MPI_CHECK(MPI_File_close(&fd), "cannot close file"); diff --git a/src/aiori-POSIX.c b/src/aiori-POSIX.c index d78cd40..00e974c 100755 --- a/src/aiori-POSIX.c +++ b/src/aiori-POSIX.c @@ -146,7 +146,7 @@ void gpfs_free_all_locks(int fd) rc = gpfs_fcntl(fd, &release_all); if (verbose >= VERBOSE_0 && rc != 0) { - EWARN("gpfs_fcntl release all locks hint failed."); + EWARNF("gpfs_fcntl(%d, ...) release all locks hint failed.", fd); } } void gpfs_access_start(int fd, IOR_offset_t length, IOR_param_t *param, int access) @@ -169,7 +169,7 @@ void gpfs_access_start(int fd, IOR_offset_t length, IOR_param_t *param, int acce rc = gpfs_fcntl(fd, &take_locks); if (verbose >= VERBOSE_2 && rc != 0) { - EWARN("gpfs_fcntl access range hint failed."); + EWARNF("gpfs_fcntl(fd, ...) access range hint failed.", fd); } } @@ -193,7 +193,7 @@ void gpfs_access_end(int fd, IOR_offset_t length, IOR_param_t *param, int access rc = gpfs_fcntl(fd, &free_locks); if (verbose >= VERBOSE_2 && rc != 0) { - EWARN("gpfs_fcntl free range hint failed."); + EWARNF("gpfs_fcntl(fd, ...) free range hint failed.", fd); } } @@ -260,14 +260,14 @@ bool beegfs_createFilePath(char* filepath, mode_t mode, int numTargets, int chun char* dir = dirname(dirTmp); DIR* parentDirS = opendir(dir); if (!parentDirS) { - ERR("Failed to get directory"); + ERRF("Failed to get directory: %s", dir); } else { int parentDirFd = dirfd(parentDirS); if (parentDirFd < 0) { - ERR("Failed to get directory descriptor"); + ERRF("Failed to get directory descriptor: %s", dir); } else { @@ -319,6 +319,7 @@ bool beegfs_createFilePath(char* filepath, mode_t mode, int numTargets, int chun void *POSIX_Create(char *testFileName, IOR_param_t * param) { int fd_oflag = O_BINARY; + int mode = 0664; int *fd; fd = (int *)malloc(sizeof(int)); @@ -346,9 +347,10 @@ void *POSIX_Create(char *testFileName, IOR_param_t * param) if (!param->filePerProc && rank != 0) { MPI_CHECK(MPI_Barrier(testComm), "barrier error"); fd_oflag |= O_RDWR; - *fd = open64(testFileName, fd_oflag, 0664); + *fd = open64(testFileName, fd_oflag, mode); if (*fd < 0) - ERR("open64() failed"); + ERRF("open64(\"%s\", %d, %#o) failed", + testFileName, fd_oflag, mode); } else { struct lov_user_md opts = { 0 }; @@ -363,7 +365,7 @@ void *POSIX_Create(char *testFileName, IOR_param_t * param) fd_oflag |= O_CREAT | O_EXCL | O_RDWR | O_LOV_DELAY_CREATE; - *fd = open64(testFileName, fd_oflag, 0664); + *fd = open64(testFileName, fd_oflag, mode); if (*fd < 0) { fprintf(stdout, "\nUnable to open '%s': %s\n", testFileName, strerror(errno)); @@ -392,7 +394,7 @@ void *POSIX_Create(char *testFileName, IOR_param_t * param) if (beegfs_isOptionSet(param->beegfs_chunkSize) || beegfs_isOptionSet(param->beegfs_numTargets)) { bool result = beegfs_createFilePath(testFileName, - 0664, + mode, param->beegfs_numTargets, param->beegfs_chunkSize); if (result) { @@ -403,9 +405,10 @@ void *POSIX_Create(char *testFileName, IOR_param_t * param) } #endif /* HAVE_BEEGFS_BEEGFS_H */ - *fd = open64(testFileName, fd_oflag, 0664); + *fd = open64(testFileName, fd_oflag, mode); if (*fd < 0) - ERR("open64() failed"); + ERRF("open64(\"%s\", %d, %#o) failed", + testFileName, fd_oflag, mode); #ifdef HAVE_LUSTRE_LUSTRE_USER_H } @@ -413,7 +416,7 @@ void *POSIX_Create(char *testFileName, IOR_param_t * param) if (param->lustre_ignore_locks) { int lustre_ioctl_flags = LL_FILE_IGNORE_LOCK; if (ioctl(*fd, LL_IOC_SETFLAGS, &lustre_ioctl_flags) == -1) - ERR("ioctl(LL_IOC_SETFLAGS) failed"); + ERRF("ioctl(%d, LL_IOC_SETFLAGS, ...) failed", *fd); } #endif /* HAVE_LUSTRE_LUSTRE_USER_H */ @@ -469,7 +472,7 @@ void *POSIX_Open(char *testFileName, IOR_param_t * param) *fd = open64(testFileName, fd_oflag); if (*fd < 0) - ERR("open64 failed"); + ERRF("open64(\"%s\", %d) failed", testFileName, fd_oflag); #ifdef HAVE_LUSTRE_LUSTRE_USER_H if (param->lustre_ignore_locks) { @@ -479,7 +482,7 @@ void *POSIX_Open(char *testFileName, IOR_param_t * param) "** Disabling lustre range locking **\n"); } if (ioctl(*fd, LL_IOC_SETFLAGS, &lustre_ioctl_flags) == -1) - ERR("ioctl(LL_IOC_SETFLAGS) failed"); + ERRF("ioctl(%d, LL_IOC_SETFLAGS, ...) failed", *fd); } #endif /* HAVE_LUSTRE_LUSTRE_USER_H */ @@ -517,7 +520,7 @@ static IOR_offset_t POSIX_Xfer(int access, void *file, IOR_size_t * buffer, /* seek to offset */ if (lseek64(fd, param->offset, SEEK_SET) == -1) - ERR("lseek64() failed"); + ERRF("lseek64(%d, %lld, SEEK_SET) failed", fd, param->offset); while (remaining > 0) { /* write/read file */ @@ -530,7 +533,8 @@ static IOR_offset_t POSIX_Xfer(int access, void *file, IOR_size_t * buffer, } rc = write(fd, ptr, remaining); if (rc == -1) - ERR("write() failed"); + ERRF("write(%d, %p, %lld) failed", + fd, (void*)ptr, remaining); if (param->fsyncPerWrite == TRUE) POSIX_Fsync(&fd, param); } else { /* READ or CHECK */ @@ -542,9 +546,11 @@ static IOR_offset_t POSIX_Xfer(int access, void *file, IOR_size_t * buffer, } rc = read(fd, ptr, remaining); if (rc == 0) - ERR("read() returned EOF prematurely"); + ERRF("read(%d, %p, %lld) returned EOF prematurely", + fd, (void*)ptr, remaining); if (rc == -1) - ERR("read() failed"); + ERRF("read(%d, %p, %lld) failed", + fd, (void*)ptr, remaining); } if (rc < remaining) { fprintf(stdout, @@ -579,7 +585,7 @@ static IOR_offset_t POSIX_Xfer(int access, void *file, IOR_size_t * buffer, static void POSIX_Fsync(void *fd, IOR_param_t * param) { if (fsync(*(int *)fd) != 0) - EWARN("fsync() failed"); + EWARNF("fsync(%d) failed", *(int *)fd); } /* @@ -590,7 +596,7 @@ void POSIX_Close(void *fd, IOR_param_t * param) if(param->dryRun) return; if (close(*(int *)fd) != 0) - ERR("close() failed"); + ERRF("close(%d) failed", *(int *)fd); free(fd); } @@ -602,10 +608,8 @@ void POSIX_Delete(char *testFileName, IOR_param_t * param) if(param->dryRun) return; if (unlink(testFileName) != 0){ - char errmsg[256]; - sprintf(errmsg, "[RANK %03d]: unlink() of file \"%s\" failed\n", - rank, testFileName); - EWARN(errmsg); + EWARNF("[RANK %03d]: unlink() of file \"%s\" failed\n", + rank, testFileName); } } @@ -621,7 +625,7 @@ IOR_offset_t POSIX_GetFileSize(IOR_param_t * test, MPI_Comm testComm, IOR_offset_t aggFileSizeFromStat, tmpMin, tmpMax, tmpSum; if (stat(testFileName, &stat_buf) != 0) { - ERR("stat() failed"); + ERRF("stat(\"%s\", ...) failed", testFileName); } aggFileSizeFromStat = stat_buf.st_size; diff --git a/src/ior.c b/src/ior.c index 4cd5571..f693321 100755 --- a/src/ior.c +++ b/src/ior.c @@ -822,14 +822,14 @@ static char *PrependDir(IOR_param_t * test, char *rootDir) /* dir doesn't exist, so create */ if (backend->access(dir, F_OK, test) != 0) { if (backend->mkdir(dir, S_IRWXU, test) < 0) { - ERR("cannot create directory"); + ERRF("cannot create directory: %s", dir); } /* check if correct permissions */ } else if (backend->access(dir, R_OK, test) != 0 || backend->access(dir, W_OK, test) != 0 || backend->access(dir, X_OK, test) != 0) { - ERR("invalid directory permissions"); + ERRF("invalid directory permissions: %s", dir); } /* concatenate dir and file names */ @@ -900,6 +900,10 @@ static void RemoveFile(char *testFileName, int filePerProc, IOR_param_t * test) GetTestFileName(testFileName, test); } if (backend->access(testFileName, F_OK, test) == 0) { + if (verbose >= VERBOSE_3) { + fprintf(out_logfile, "task %d removing %s\n", rank, + testFileName); + } backend->delete(testFileName, test); } if (test->reorderTasksRandom == TRUE) { @@ -908,6 +912,10 @@ static void RemoveFile(char *testFileName, int filePerProc, IOR_param_t * test) } } else { if ((rank == 0) && (backend->access(testFileName, F_OK, test) == 0)) { + if (verbose >= VERBOSE_3) { + fprintf(out_logfile, "task %d removing %s\n", rank, + testFileName); + } backend->delete(testFileName, test); } } @@ -1667,11 +1675,8 @@ static void ValidateTests(IOR_param_t * test) #if (H5_VERS_MAJOR > 0 && H5_VERS_MINOR > 5) ; #else - char errorString[MAX_STR]; - sprintf(errorString, - "'no fill' option not available in %s", + ERRF("'no fill' option not available in %s", test->apiVersion); - ERR(errorString); #endif #else WARN("unable to determine HDF5 version for 'no fill' usage"); diff --git a/src/iordef.h b/src/iordef.h index 1d1f216..78cf1d3 100755 --- a/src/iordef.h +++ b/src/iordef.h @@ -151,28 +151,41 @@ typedef long long int IOR_size_t; fflush(stdout); \ } while (0) -/* warning with errno printed */ -#define EWARN(MSG) do { \ + +/* warning with format string and errno printed */ +#define EWARNF(FORMAT, ...) do { \ if (verbose > VERBOSE_2) { \ - fprintf(stdout, "ior WARNING: %s, errno %d, %s (%s:%d).\n", \ - MSG, errno, strerror(errno), __FILE__, __LINE__); \ + fprintf(stdout, "ior WARNING: " FORMAT ", errno %d, %s (%s:%d).\n", \ + __VA_ARGS__, errno, strerror(errno), __FILE__, __LINE__); \ } else { \ - fprintf(stdout, "ior WARNING: %s, errno %d, %s \n", \ - MSG, errno, strerror(errno)); \ + fprintf(stdout, "ior WARNING: " FORMAT ", errno %d, %s \n", \ + __VA_ARGS__, errno, strerror(errno)); \ } \ fflush(stdout); \ } while (0) -/* display error message and terminate execution */ -#define ERR(MSG) do { \ - fprintf(stdout, "ior ERROR: %s, errno %d, %s (%s:%d)\n", \ - MSG, errno, strerror(errno), __FILE__, __LINE__); \ +/* warning with errno printed */ +#define EWARN(MSG) do { \ + EWARNF("%s", MSG); \ +} while (0) + + +/* display error message with format string and terminate execution */ +#define ERRF(FORMAT, ...) do { \ + fprintf(stdout, "ior ERROR: " FORMAT ", errno %d, %s (%s:%d)\n", \ + __VA_ARGS__, errno, strerror(errno), __FILE__, __LINE__); \ fflush(stdout); \ MPI_Abort(MPI_COMM_WORLD, -1); \ } while (0) +/* display error message and terminate execution */ +#define ERR(MSG) do { \ + ERRF("%s", MSG); \ +} while (0) + + /* display a simple error message (i.e. errno is not set) and terminate execution */ #define ERR_SIMPLE(MSG) do { \ fprintf(stdout, "ior ERROR: %s, (%s:%d)\n", \ @@ -184,24 +197,35 @@ typedef long long int IOR_size_t; /******************************************************************************/ /* - * MPI_CHECK will display a custom error message as well as an error string + * MPI_CHECKF will display a custom format string as well as an error string * from the MPI_STATUS and then exit the program */ -#define MPI_CHECK(MPI_STATUS, MSG) do { \ +#define MPI_CHECKF(MPI_STATUS, FORMAT, ...) do { \ char resultString[MPI_MAX_ERROR_STRING]; \ int resultLength; \ \ if (MPI_STATUS != MPI_SUCCESS) { \ MPI_Error_string(MPI_STATUS, resultString, &resultLength); \ - fprintf(stdout, "ior ERROR: %s, MPI %s, (%s:%d)\n", \ - MSG, resultString, __FILE__, __LINE__); \ + fprintf(stdout, "ior ERROR: " FORMAT ", MPI %s, (%s:%d)\n", \ + __VA_ARGS__, resultString, __FILE__, __LINE__); \ fflush(stdout); \ MPI_Abort(MPI_COMM_WORLD, -1); \ } \ } while(0) +/******************************************************************************/ +/* + * MPI_CHECK will display a custom error message as well as an error string + * from the MPI_STATUS and then exit the program + */ + +#define MPI_CHECK(MPI_STATUS, MSG) do { \ + MPI_CHECKF(MPI_STATUS, "%s", MSG); \ +} while(0) + + /******************************************************************************/ /* * System info for Windows. From 4c3d96bfed7f783acd7b2beb7195eee579487257 Mon Sep 17 00:00:00 2001 From: Josh Schwartz <52082483+jschwartz-cray@users.noreply.github.com> Date: Fri, 30 Aug 2019 15:31:23 -0600 Subject: [PATCH 46/50] Fix #179. -u (uniqueDir) will once again use the full file path specified by the client instead of truncating it. This was caused by a broken sprintf which was trying to read/write overlapping buffers. From the glibc sprintf() documentation: "The behavior of this function is undefined if copying takes place between objects that overlap" --- src/ior.c | 17 ++++------------- 1 file changed, 4 insertions(+), 13 deletions(-) diff --git a/src/ior.c b/src/ior.c index 4cd5571..e173807 100755 --- a/src/ior.c +++ b/src/ior.c @@ -785,8 +785,7 @@ void GetTestFileName(char *testFileName, IOR_param_t * test) static char *PrependDir(IOR_param_t * test, char *rootDir) { char *dir; - char fname[MAX_STR + 1]; - char *p; + char *fname; int i; dir = (char *)malloc(MAX_STR + 1); @@ -806,18 +805,10 @@ static char *PrependDir(IOR_param_t * test, char *rootDir) } /* get file name */ - strcpy(fname, rootDir); - p = fname; - while (i > 0) { - if (fname[i] == '\0' || fname[i] == '/') { - p = fname + (i + 1); - break; - } - i--; - } + fname = rootDir + i + 1; /* create directory with rank as subdirectory */ - sprintf(dir, "%s%d", dir, (rank + rankOffset) % test->numTasks); + sprintf(dir + i + 1, "%d", (rank + rankOffset) % test->numTasks); /* dir doesn't exist, so create */ if (backend->access(dir, F_OK, test) != 0) { @@ -834,7 +825,7 @@ static char *PrependDir(IOR_param_t * test, char *rootDir) /* concatenate dir and file names */ strcat(dir, "/"); - strcat(dir, p); + strcat(dir, fname); return dir; } From 10d3db1dc829dd78ea8ac2da97f233e9dc01ec06 Mon Sep 17 00:00:00 2001 From: "Julian M. Kunkel" Date: Sat, 31 Aug 2019 17:28:08 +0100 Subject: [PATCH 47/50] MDTest: fixing the memset() to account for the number of iterations. --- src/mdtest.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/mdtest.c b/src/mdtest.c index 77b2759..96555d2 100644 --- a/src/mdtest.c +++ b/src/mdtest.c @@ -2148,7 +2148,7 @@ mdtest_results_t * mdtest_run(int argc, char **argv, MPI_Comm world_com, FILE * /* setup summary table for recording results */ summary_table = (mdtest_results_t *) malloc(iterations * sizeof(mdtest_results_t)); - memset(summary_table, 0, sizeof(mdtest_results_t)); + memset(summary_table, 0, iterations * sizeof(mdtest_results_t)); for(int i=0; i < iterations; i++){ for(int j=0; j < MDTEST_LAST_NUM; j++){ summary_table[i].rate[j] = 0.0; From 60a641f911bb1b73685a10102b894f3a58341979 Mon Sep 17 00:00:00 2001 From: "Julian M. Kunkel" Date: Sun, 1 Sep 2019 15:29:12 +0100 Subject: [PATCH 48/50] sync help corrected. --- src/parse_options.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/parse_options.c b/src/parse_options.c index af30c36..47f9920 100755 --- a/src/parse_options.c +++ b/src/parse_options.c @@ -477,7 +477,7 @@ option_help * createGlobalOptions(IOR_param_t * params){ {.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 stoneWallingWearOutIterations=N -- stop after processing this number of iterations, needed for reading data back written with stoneWallingWearOut", .arg = OPTION_OPTIONAL_ARGUMENT}, {.help=" -O stoneWallingStatusFile=FILE -- this file keeps the number of iterations from stonewalling during write and allows to use them for read", .arg = OPTION_OPTIONAL_ARGUMENT}, - {'e', NULL, "fsync -- perform sync operation after each block write", OPTION_FLAG, 'd', & params->fsync}, + {'e', NULL, "fsync -- perform a fsync() operation at the end of each read/write phase", OPTION_FLAG, 'd', & params->fsync}, {'E', NULL, "useExistingTestFile -- do not remove test file before write access", OPTION_FLAG, 'd', & params->useExistingTestFile}, {'f', NULL, "scriptFile -- test script name", OPTION_OPTIONAL_ARGUMENT, 's', & params->testscripts}, {'F', NULL, "filePerProc -- file-per-process", OPTION_FLAG, 'd', & params->filePerProc}, From e3db1759b2736aaef826dae756283bfd7e58a1ee Mon Sep 17 00:00:00 2001 From: "Julian M. Kunkel" Date: Sun, 1 Sep 2019 15:47:42 +0100 Subject: [PATCH 49/50] Moded sync() to aiori backend. --- src/aiori-POSIX.c | 12 ++++++++++++ src/aiori.h | 1 + src/mdtest.c | 5 ++++- src/utilities.c | 7 ------- src/utilities.h | 1 - 5 files changed, 17 insertions(+), 9 deletions(-) diff --git a/src/aiori-POSIX.c b/src/aiori-POSIX.c index 00e974c..99a68f1 100755 --- a/src/aiori-POSIX.c +++ b/src/aiori-POSIX.c @@ -71,6 +71,7 @@ static IOR_offset_t POSIX_Xfer(int, void *, IOR_size_t *, IOR_offset_t, IOR_param_t *); static void POSIX_Fsync(void *, IOR_param_t *); +static void POSIX_Sync(IOR_param_t * ); /************************** O P T I O N S *****************************/ typedef struct{ @@ -122,6 +123,7 @@ ior_aiori_t posix_aiori = { .stat = aiori_posix_stat, .get_options = POSIX_options, .enable_mdtest = true, + .sync = POSIX_Sync }; /***************************** F U N C T I O N S ******************************/ @@ -588,6 +590,16 @@ static void POSIX_Fsync(void *fd, IOR_param_t * param) EWARNF("fsync(%d) failed", *(int *)fd); } + +static void POSIX_Sync(IOR_param_t * param) +{ + int ret = system("sync"); + if (ret != 0){ + FAIL("Error executing the sync command, ensure it exists."); + } +} + + /* * Close a file through the POSIX interface. */ diff --git a/src/aiori.h b/src/aiori.h index c2074c2..8a5e207 100755 --- a/src/aiori.h +++ b/src/aiori.h @@ -86,6 +86,7 @@ typedef struct ior_aiori { void (*finalize)(); /* called once per program after MPI is shutdown */ option_help * (*get_options)(void ** init_backend_options, void* init_values); /* initializes the backend options as well and returns the pointer to the option help structure */ bool enable_mdtest; + void (*sync)(IOR_param_t * ); /* synchronize every pending operation for this storage */ } ior_aiori_t; enum bench_type { diff --git a/src/mdtest.c b/src/mdtest.c index e34496a..52efa34 100644 --- a/src/mdtest.c +++ b/src/mdtest.c @@ -266,7 +266,10 @@ static void prep_testdir(int j, int dir_iter){ static void phase_end(){ if (call_sync){ - call_sync_cmd(); + if(! backend->sync){ + FAIL("Error, backend does not provide the sync method, but your requested to use sync."); + } + backend->sync(& param); } if (barriers) { diff --git a/src/utilities.c b/src/utilities.c index a2e4b0d..c7e1c8c 100755 --- a/src/utilities.c +++ b/src/utilities.c @@ -809,10 +809,3 @@ char *HumanReadable(IOR_offset_t value, int base) } return valueStr; } - -void call_sync_cmd(){ - int ret = system("sync"); - if (ret != 0){ - FAIL("Error executing the sync command, ensure it exists."); - } -} diff --git a/src/utilities.h b/src/utilities.h index b85f957..d2c9962 100755 --- a/src/utilities.h +++ b/src/utilities.h @@ -60,7 +60,6 @@ int QueryNodeMapping(MPI_Comm comm, int print_nodemap); void DelaySecs(int delay); void updateParsedOptions(IOR_param_t * options, options_all_t * global_options); size_t NodeMemoryStringToBytes(char *size_str); -void call_sync_cmd(); /* Returns -1, if cannot be read */ int64_t ReadStoneWallingIterations(char * const filename); From c83edfe39b49481db7472dce85f1dbe972e6bfc6 Mon Sep 17 00:00:00 2001 From: "Julian M. Kunkel" Date: Sun, 1 Sep 2019 15:59:52 +0100 Subject: [PATCH 50/50] Extracted check function into aiori. #24. #177 --- src/aiori-DUMMY.c | 5 +++++ src/aiori-S3.c | 21 ++++++++++++++++++++- src/aiori.h | 1 + src/ior.c | 15 ++++++--------- 4 files changed, 32 insertions(+), 10 deletions(-) diff --git a/src/aiori-DUMMY.c b/src/aiori-DUMMY.c index 0494cb4..90fec9a 100755 --- a/src/aiori-DUMMY.c +++ b/src/aiori-DUMMY.c @@ -143,6 +143,10 @@ static int DUMMY_stat (const char *path, struct stat *buf, IOR_param_t * param){ return 0; } +static int DUMMY_check_params(IOR_param_t * test){ + return 1; +} + ior_aiori_t dummy_aiori = { .name = "DUMMY", .name_legacy = NULL, @@ -163,4 +167,5 @@ ior_aiori_t dummy_aiori = { .finalize = NULL, .get_options = DUMMY_options, .enable_mdtest = true, + .check_params = DUMMY_check_params }; diff --git a/src/aiori-S3.c b/src/aiori-S3.c index 3fc1208..2c9a9af 100755 --- a/src/aiori-S3.c +++ b/src/aiori-S3.c @@ -159,6 +159,8 @@ static void S3_Fsync(void*, IOR_param_t*); static IOR_offset_t S3_GetFileSize(IOR_param_t*, MPI_Comm, char*); static void S3_init(); static void S3_finalize(); +static int S3_check_params(IOR_param_t *); + /************************** D E C L A R A T I O N S ***************************/ @@ -177,7 +179,8 @@ ior_aiori_t s3_aiori = { .fsync = S3_Fsync, .get_file_size = S3_GetFileSize, .initialize = S3_init, - .finalize = S3_finalize + .finalize = S3_finalize, + .check_params = S3_check_params }; // "S3", plus EMC-extensions enabled @@ -228,6 +231,22 @@ static void S3_finalize(){ aws_cleanup(); } +static int S3_check_params(IOR_param_t * test){ + /* N:1 and N:N */ + IOR_offset_t NtoN = test->filePerProc; + IOR_offset_t Nto1 = ! NtoN; + IOR_offset_t s = test->segmentCount; + IOR_offset_t t = test->transferSize; + IOR_offset_t b = test->blockSize; + + if (Nto1 && (s != 1) && (b != t)) { + ERR("N:1 (strided) requires xfer-size == block-size"); + return 0; + } + + return 1; +} + /* modelled on similar macros in iordef.h */ #define CURL_ERR(MSG, CURL_ERRNO, PARAM) \ do { \ diff --git a/src/aiori.h b/src/aiori.h index 8a5e207..06f9b31 100755 --- a/src/aiori.h +++ b/src/aiori.h @@ -86,6 +86,7 @@ typedef struct ior_aiori { void (*finalize)(); /* called once per program after MPI is shutdown */ option_help * (*get_options)(void ** init_backend_options, void* init_values); /* initializes the backend options as well and returns the pointer to the option help structure */ bool enable_mdtest; + int (*check_params)(IOR_param_t *); /* check if the provided parameters for the given test and the module options are correct, if they aren't print a message and exit(1) or return 1*/ void (*sync)(IOR_param_t * ); /* synchronize every pending operation for this storage */ } ior_aiori_t; diff --git a/src/ior.c b/src/ior.c index 1e66387..123a4b5 100755 --- a/src/ior.c +++ b/src/ior.c @@ -1677,15 +1677,12 @@ static void ValidateTests(IOR_param_t * test) if (test->useExistingTestFile && test->lustre_set_striping) ERR("Lustre stripe options are incompatible with useExistingTestFile"); - /* N:1 and N:N */ - IOR_offset_t NtoN = test->filePerProc; - IOR_offset_t Nto1 = ! NtoN; - IOR_offset_t s = test->segmentCount; - IOR_offset_t t = test->transferSize; - IOR_offset_t b = test->blockSize; - - if (Nto1 && (s != 1) && (b != t)) { - ERR("N:1 (strided) requires xfer-size == block-size"); + /* allow the backend to validate the options */ + if(test->backend->check_params){ + int check = test->backend->check_params(test); + if (check == 0){ + ERR("The backend returned that the test parameters are invalid."); + } } }