summaryrefslogtreecommitdiffstats
Commit message (Collapse)AuthorAgeFilesLines
* Make these scripts relocatable again: derive a relative path for theDavid Young2020-05-204-4/+97
| | | | | | | original installation prefix from the examples prefix. Use that relative path to locate the current installation prefix, always. Fall back to an absolute installation prefix if the relative path cannot be derived.
* Get the path to prefix right: needs a ../ to back out of subdirectoryDavid Young2020-05-201-1/+1
| | | | c/.
* Make this script relocatable again: derive a relative path for theDavid Young2020-05-201-2/+25
| | | | | | | original installation prefix from the examples prefix. Use that relative path to locate the current installation prefix, always. Fall back to an absolute installation prefix if the relative path cannot be derived.
* Let us override the examples directory using --with-examplesdir=DIR.David Young2020-05-201-0/+22
| | | | | | | | | This is handy for NetBSD where HDF5 examples are installed by convention in $prefix/share/examples/hdf5/ rather than in ${prefix}/share/hdf5_examples/, which is the HDF5 default. Place hdf5_examples/ under ${datarootdir} which on most systems will be ${prefix}/share/, anyway.
* Partial fix for HDFFV-10792Jordan Henderson2020-05-202-4/+58
|
* Add missing newline to dbgf() statement.David Young2020-05-151-1/+1
|
* Make `-q` actually quiet the program.David Young2020-05-151-1/+1
|
* Make the personality detection more robust like I did forDavid Young2020-05-151-4/+11
| | | | vfd_swmr_zoo_writer, previously.
* Let us change the chunk size with command-line options, -r rows and -cDavid Young2020-05-151-84/+152
| | | | | | columns. If the number of datasets is greater than the number of steps, then only pause between steps, do not pause between individual datasets written/verified. Otherwise, pause between each dataset written/verified.
* Fix inverted logic: report "soft" errors if there were *not* 0 of them.David Young2020-05-131-1/+1
|
* This test doesn't need to log/modify traps in the global heap, so don'tDavid Young2020-05-131-11/+0
| | | | provide a H5HG_trap() routine.
* In H5FD_vfd_swmr_read(), do not verify checksums on shadow entriesDavid Young2020-05-131-157/+63
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | that are longer than the buffer that the caller supplied: the checksum usually will fail, but that's not actually a fatal condition, and usually we will have another opportunity to verify the checksum. In H5FD_vfd_swmr_read(), remove a bunch of disused code. In H5FD_vfd_swmr_read(), do not re-read a shadow image that has a bad checksum, because a bad checksum indicates a serious problem (writer outran reader, OS defect, hardware failure) from which H5FD_vfd_swmr_read() cannot recover. Rationale: the writer write(2)s new shadow images before the new index, and the new index before the new header. In H5FD_vfd_swmr_read(), the reader has read(2) both the index and the header in full. POSIX semantics indicate that in these circumstances, the last shadow image write(2) MUST be completely visible when we read(2). That is, the index write(2) & read(2) and the header write(2) & read(2) pair cannot divide a preceding shadow-image write(2). The reader may see a "torn" image at this juncture if, for example, the writer got max_lag ticks ahead of it and reused the storage for this shadow image. Even if the reader "recovers" by re-reading the image until its checksum is correct, it cannot be sure that the image thus read is the right one for the HDF5 address passed to H5FD_vfd_swmr_read(), and it cannot be sure that the image thus read is not stale, because it's operating with an out-of-date shadow index. Add log outlets swmr_read, swmr_read_exception, and swmr_read_err. Log to `swmr_read` on entry to H5FD_vfd_swmr_read(), log to `swmr_read_exception` when checksums are skipped for exceptional conditions (page buffer not configured, buffer shorter than shadow image), and log to `swmr_read_err` when the checksum fails.
* When an entry changes size, remove it from the tick list and add it backDavid Young2020-05-111-0/+10
| | | | | to keep the cumulative bytes in the tick list up-to-date. That prevents an assertion, later.
* Don't initialize `seed` without need. NFCI.David Young2020-05-111-1/+1
|
* Look for the personality in the program name *suffix*, because onDavid Young2020-05-111-2/+4
| | | | `jelly` libtool adds an `lt-` prefix to the program name.
* In H5MF__xfree_impl(), always invalidate the page-table entriesDavid Young2020-05-111-20/+53
| | | | | overlapped by the freed region. Previously, the page-table entries were only freed on one success path through _xfree_impl().
* Split VFD_SWMR_TEST_FOR_END_OF_TICK() into VFD_SWMR_ENTER() andDavid Young2020-05-091-12/+25
| | | | | | VFD_SWMR_LEAVE() for use by FUNC_ENTER_API/_LEAVE_API macros. In the macros, don't HGOTO_ERROR(), since that will jump back to the `out` label, but HDONE_ERROR() on error, instead.
* Extend VFD SWMR tick length and maximum lag parameters.David Young2020-05-091-2/+2
|
* Delete extra line. NFCI.David Young2020-05-091-1/+0
|
* Add missing return-value check.David Young2020-05-091-0/+3
|
* Take care not to leak property lists or data spaces.David Young2020-05-091-8/+12
|
* Fix bugs in the dataset dimensions checks.David Young2020-05-071-4/+6
|
* Create a reader for the extensible datasets tests.David Young2020-05-072-26/+236
|
* Add my work-in-progress dataset test. It writes a handful of datasetsDavid Young2020-05-062-1/+405
| | | | | that expand in one or two dimensions, depending on the setting of the -d option argument.
* Add esnprintf that prints to the given buffer, observing the givenDavid Young2020-05-062-0/+18
| | | | | buffer size, using vsnprintf(3), but exits with err(3)/errx(3) if the buffer is too small or if vsnprintf returns < 0.
* Insert a random delay between zoo-writer test steps. Let us controlDavid Young2020-04-304-7/+75
| | | | | the random seed with an environment variable, H5_ZOO_STEP_SEED, and the maximum delay in milliseconds with a command-line option, `-m ms`.
* Use a one-character buffer to send/receive messages to/fromDavid Young2020-04-301-7/+11
| | | | | writer/reader, since that's all we need. Avoid deadlock by flushing the file before waiting for the reader's message.
* Avoid deadlock of reader and writer: make the writer flush file contentDavid Young2020-04-301-0/+6
| | | | before waiting for the reader's message.
* In fetch_env_ulong(), report a parse that consumes fewer than allDavid Young2020-04-301-1/+5
| | | | characters differently than other parse failures.
* Add a rudimentary zoo test to the VFD SWMR test script.David Young2020-04-281-1/+55
| | | | Briefly describe the variable-length test with a comment.
* Change some fprintf callss to dbgf calls, and increase the debug levelDavid Young2020-04-281-12/+10
| | | | of several dbgf statements from 1 to 2 so that `-q` quiets them.
* Let catch_out_err_and_rc() callers redirect the standard input andDavid Young2020-04-281-2/+2
| | | | | | | | | output streams using STDIN_PATH and STDOUT_PATH. I will use that for the zoo reader and writer. Move redirection of standard error output to the standard output stream outside of the curly braces, since usually I want to save the `echo` and `wait` output, too, and it makes the redirection of the supervised program a little easier to follow, I think.
* Move fetch_env_ulong() from vfd_swmr.c to vfd_swmr_common.c for eventualDavid Young2020-04-283-29/+32
| | | | reuse by the zoo writer.
* To avoid name clashes, rename FILENAME -> COMMON_FILENAME inDavid Young2020-04-279-18/+26
| | | | test/vfd_swmr_common.h and in all files that #include it. Now I can
* Implement the remainder of the delete/validate-delete cases.David Young2020-04-231-28/+35
|
* Flesh out the delete/validate-deletion tests. Extract a sharedDavid Young2020-04-231-14/+29
| | | | subroutine.
* Delete dead code. Re-enable the coordination between reader and writer:David Young2020-04-231-30/+3
| | | | | the writer expects to read a character on its standard input stream when the reader is ready for it to delete the zoo content.
* Let the reader-side tick instrumentation know about the first tick readDavid Young2020-04-231-0/+2
| | | | from the shadow file.
* Relax an assertion condition.David Young2020-04-231-1/+1
|
* Bug fix: in the freespace manager, use a new routine,David Young2020-04-233-5/+55
| | | | | H5PB_remove_entries(), to remove *all* pages overlapped by the freed space, instead of just the first one.
* Delete an assertion that doesn't hold true for multipage entries.David Young2020-04-211-3/+0
|
* Add a `skip compact` configuration for skipping the "zoo" tests forDavid Young2020-04-214-102/+472
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | compact datasets. Bundle the zoo-test configuration into a new type, zoo_config_t. Add a couple new "zoo" test phases, "delete" and "validate-deletion", to the existing "create" and "verify" phases. Give names and numbers to all phases with the new `enum`, `phase_t`, and refactor so that tend_zoo runs a selection of phases at each step. Stub the "delete" and "validate-deletion" phases for most test steps. Actually implement for compact dataset (ds_cpt_i) test. In tend_zoo(), delay for 50 milliseconds after running all steps. Really, this should delay after each step.... Implement vfd_swmr_writer_may_increase_tick_to() and vfd_swmr_reader_did_increase_tick_to() with a file that reader and writer share. The reader saves its current tick number in the shared file. The writer does not advance its tick number past the reader's. Collect some statistics in vfd_swmr_writer_may_increase_tick_to() and print them before the writer exits. Add option flags for skipping compact dataset tests (-C) and for printing error stacks (-e). Update the usage message, which was stale before the new options were added. Delete some dead code. Add #if 0'd-out code for the reader to wait for the writer before running "delete" and "validate-deletion" steps.
* Make await_signal() await any signal instead of just SIGINT. Add aDavid Young2020-04-211-4/+20
| | | | | (commented out) private version of strsignal(3), just in case we need one on some platform.
* Prevent a spurious assertion by using the correct index, oops!David Young2020-04-211-1/+1
|
* Delete an empty line. NFCI.David Young2020-04-211-1/+0
|
* Straggler from last: provide stub implementationsDavid Young2020-04-211-0/+27
| | | | | of vfd_swmr_writer_may_increase_tick_to() and vfd_swmr_reader_did_increase_tick_to().
* Add a second bool argument to H5F_vfd_swmr_writer_end_of_tick() thatDavid Young2020-04-217-17/+31
| | | | | | | | | | | | | | | tells whether the call may wait for the reader tick to catch up. Add stub routines vfd_swmr_writer_may_increase_tick_to() and vfd_swmr_reader_did_increase_tick_to() for tests---e.g., vfd_swmr_zoo_writer/_reader---to use to coordinate their tick numbers. vfd_swmr_writer_may_increase_tick_to(new_tick, wait_for_reader) returns true if the writer may increase its tick number to `new_tick` without overrunning the reader. A reader uses vfd_swmr_reader_did_increase_tick_to() to tell a writer that its tick number has increased.
* Condense H5F_vfd_swmr_close_or_flush() for readability: removeDavid Young2020-04-211-25/+14
| | | | | | unnecessary comments and trim whitespace. Remove unnecessary backslash line continuations and add semicolons to HGOTO_ERROR() statements. NFCI.
* Quiet some used-before-initialized warnings.David Young2020-04-201-4/+4
|
* Straggler from last: retire vfd_swmr_writer_g.David Young2020-04-201-2/+2
|