summaryrefslogtreecommitdiffstats
path: root/src/H5Dchunk.c
Commit message (Collapse)AuthorAgeFilesLines
* Fixes for various warnings/alignment with develop branch (#1755)jhendersonHDF2022-05-081-3/+3
|
* [1.10 Merge] Hdf5 1 10 warnings merge (#1754)jhendersonHDF2022-05-081-57/+59
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | * Warnings fixes (#1680) * Clean stack size warnings in sio_engine (#1687) * Fixes stack size warnings in tcoords.c (#1688) * Address some warnings from casting away of const (#1684) * Fixes stack size warnings in dtransform (#1696) * Fixes stack size warnings in set_extent test (#1698) * Be a bit safer with signed arithmetic, thus quieting some signed-overflow warnings from GCC (#1706) * Avoid a signed overflow: check the range of `entry_ptr->age` before increasing it instead of increasing it and then checking the range. This quiets a GCC warning. * Avoid the potential for signed overflow by rewriting expressions `MAX(0, fwidth - n)` as `MAX(n, fwidth) - n` for various `n`. This change quiets some GCC warnings. * Change some local variables that cannot take sensible negative values from signed to unsigned. This quiets GCC warnings about potential signed overflow. * In a handful of instances, check the range of a signed integer before increasing/decreasing it, just in case the increase/decrease overflows. This quiets a handful of GCC signed-overflow warnings. * Committing clang-format changes Co-authored-by: github-actions <41898282+github-actions[bot]@users.noreply.github.com> * Fix object size warnings in cache.c test (#1701) * Fix some const cast and stack/static object size warnings (#1700) * Fix various warnings * Move HDfree_const to H5private.h for wider use * Print output from all ranks in parallel tests on allocation failure * Move const pointer freeing macro to h5test.h for now * Fixes a bug where t_cache fails due to a string size being too small (#1720) * Fixes a bug where t_cache fails due to a string size being too small Recent warning reductions led to an incorrect string size being passed to h5_fileaccess, causing the test to silently fail. In addition to fixing the bug, the test will now fail noisily on setup failures. * Updates the t_cache test to fail noisily on setup errors * Fix a few Clang sanitizer warnings (#1727) * Stop lying about H5S_t const-ness (#1209) Hyperslabs can be reworked inside several H5S callbacks, making H5S_t non-const in some places where it is marked const. This change switches these incorrectly const H5S_t pointer parameters and variables to non-const where appropriate. * Fix a few warnings after recent H5S const-related changes (#1225) * Adjustments for HDF5 1.10 * Hdf5 1 12 Miscellaneous warnings fixes (#1718) * Fixes const issues in the version 2 B-trees (#1172) The operations that were changed are fundamentally not const since the shadow operation can modify the node structure when SWMR is in use. * Quiets const warning in H5RS code (#1181) * Avoid calling H5Ropen_object with a misaligned H5R_ref_t: copy the (#1171) * Avoid calling H5Ropen_object with a misaligned H5R_ref_t: copy the raw H5R_ref_t bytes to a heap buffer that's known to have the right alignment. * Committing clang-format changes * Use an automatic H5R_ref_t instead of malloc'ing one. Go ahead and initialize the H5R_ref_t to all-0s so that arbitrary stack content doesn't foul things up. Bail out with an error if `size` exceeds `sizeof(H5R_ref_t)`. * Committing clang-format changes Co-authored-by: github-actions <41898282+github-actions[bot]@users.noreply.github.com> * Miscellaneous warnings fixes Co-authored-by: Dana Robinson <43805+derobins@users.noreply.github.com> Co-authored-by: David Young <dyoung@hdfgroup.org> Co-authored-by: github-actions <41898282+github-actions[bot]@users.noreply.github.com> * Fix several warnings (#747) Co-authored-by: Dana Robinson <43805+derobins@users.noreply.github.com> Co-authored-by: David Young <dyoung@hdfgroup.org> Co-authored-by: github-actions <41898282+github-actions[bot]@users.noreply.github.com>
* Hdf5 1 10 parallel comp (#1644)jhendersonHDF2022-04-141-103/+288
| | | | | * Hdf5 1 10 parallel compression merge
* Unify handling of collective metadata reads status (#1206) (#1418)jhendersonHDF2022-02-041-8/+9
|
* Remove duplicate memcpy in chunk_file_cb (#1291)jhendersonHDF2021-12-131-1/+0
|
* Re-enable collective metadata reads after disabling for chunk lookup (#1175)jhendersonHDF2021-11-121-7/+21
|
* Partial merge issue #642 develop branch PRs to Hdf5 1 10 (#718)Larry Knox2021-06-031-4/+2
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | * Revert addition of & to 2 parameters in DSetCreatPropList::setVirtual to maintain binary compatibility. * Fix H5Eget_auto2/H5Eauto_is_v2 to not clear error stack (#625) * Removes gratuitous (double)x.yF casts (#632) * Committing clang-format changes * Removes gratuitous (double)x.yF casts * Committing clang-format changes Co-authored-by: github-actions <41898282+github-actions[bot]@users.noreply.github.com> * Cleans up a const warning left over from previous constification (#633) * Committing clang-format changes * Adds consts to a few global variables * Cleans up a const warning left over from previous constification Co-authored-by: github-actions <41898282+github-actions[bot]@users.noreply.github.com> * Purges UFAIL from the library (#637) * Committing clang-format changes * Purges UFAIL from the library * H5HL_insert change requested in PR Co-authored-by: github-actions <41898282+github-actions[bot]@users.noreply.github.com> * Bmr dev hdffv 11223 (#640) * Fixed HDFFV-11223 (CVE-2018-14460) Description - Added checks against buffer size to prevent segfault, in case of data corruption, for sdim->size and sdim->max. - Renamed data files in an existing test to shorten their length as agreed with other developers previously. Platforms tested: Linux/64 (jelly) * Committing clang-format changes * Updated for test files * Updated for HDFFV-11223 Co-authored-by: github-actions <41898282+github-actions[bot]@users.noreply.github.com> * Committing clang-format changes * Restore "error:" in line 2666. * Revert "Fix H5Eget_auto2/H5Eauto_is_v2 to not clear error stack (#625)" This reverts commit 426b50484841118cf633fd6147302a63a30fd746. Co-authored-by: jhendersonHDF <jhenderson@hdfgroup.org> Co-authored-by: Dana Robinson <43805+derobins@users.noreply.github.com> Co-authored-by: github-actions <41898282+github-actions[bot]@users.noreply.github.com> Co-authored-by: bmribler <39579120+bmribler@users.noreply.github.com>
* Hdf5 1 10 merge of printf specifiers and VS2015 min changes (#612)Allen Byrne2021-04-301-3/+4
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | * HDFFV-10865 - merge from dev, HDFArray perf fix. * Remove duplicate setting * Whitespace changes after clang format * Undo version 11 clang format changes * Merge CMake changes from develop * test testing script merge from develop * Update supported platforms * PR#3 merge from develop * Merge gcc 10 diagnostics option from develop * Merge #318 OSX changes from develop * Merge small changes from develop * Minor non-space formatting changes * #386 copyright corrections for java folder * Merges from develop #358 patches from vtk #361 fix header guard spelling * Merge updates #358 patches from vtk #361 fix header guard spelling * format fix * Fix missing underscore and make H5public.h closer to dev * Merges from develop #340 clang -Wformat-security warnings #360 Fixed uninitialized warnings header guard underscore cleanup JNI cleanup * format alignment * Add missing test ref file * Merge #380 from develop * Finish java merges from develop * Fix java issues with tests and javadoc * Correct use of attribute access plist * Remove debug code * Remove unused variable * Change file access to read only for java tests * Split clang format operations. * More javadoc comments * Remove pre-split setting * format source * Change windows TS to use older VS. * Mostly all javadoc fixes, one argument rename. * synch file * Merge of long double fix and compiler flags * HDFFV-11229 merge changes from develop * HDFFV-11229 correct test script * HDFFV-11229 update autotools test script for two ref files * HDFFV-11229 merge dev changes for long double display in tools * Committing clang-format changes * minor whitespace * remove unneeded macro * Committing clang-format changes * Add "option" command for clang options * Rework CMake add_custom to use the BYPRODUCTS argument Update pkgconfig scripts for parallel builds. Fix install COPYING file reference. Remove unused round defines. Change CMake default setting of BUILD_CPP to off. * Fortran target depends * Remove incorrect source attribute * Revert define removal * printf specifiers and VS2015 min changes * Committing clang-format changes * Add time struct Co-authored-by: github-actions <41898282+github-actions[bot]@users.noreply.github.com>
* Hdf5 merge issue 458 v110 (#465)Larry Knox2021-03-121-1/+1
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | * close #195. (#196) * Update HDF5PluginMacros.cmake * Update HDF5PluginMacros.cmake * Modify temporary rpath for testing in java example scripts. (#230) * Fix undefined left shifting of negative numbers (#338) Undefined Bahavior Sanitizer errored here about left shifting negative numbers. * Update license url (#332) * Modify temporary rpath for testing in java example scripts. * Update URL in source file Copyright headers for web copy of COPYING file - src and test directories. * Applied clang-tidy readability-non-const-parameter warning fixes auto… (#429) * Automatically applied clang-tidy readability-avoid-const-params-in-decls fixes Removes useless const declarations. * Fixed most readability-non-const-parameter warnings These changes were made automatically by clang-tidy, but I manually reverted the changes related to the H5Z_func_t signature. * Reformat source with clang v10.0.1. Co-authored-by: Larry Knox <lrknox@hdfgroup.org> * Added C++11 override keyword where appropriate (#433) Added H5_OVERRIDE macro for compatibility with both C++11 and older. * Various clang tidy warning fixes (#448) * Fixed clang-tidy bugprone-reserved-identifier warnings * Fixed clang-tidy bugprone-assert-side-effect warnings * Fixed clang-tidy bugprone-copy-constructor-init warning * Fixed clang-tidy readability-redundant-preprocessor warning For error_test.c the removed code was already dead, because it was in the else of an `#if H5_USE_16_API` block. Based on H5Location.h, I think p_get_ref_obj_type was meant to be in `#ifndef DOXYGEN_SHOULD_SKIP_THIS` and an `#endif` was missing. Similarly, in the header, getObjTypeByIdx is only in H5_NO_DEPRECATED_SYMBOLS, not DOXYGEN_SHOULD_SKIP_THIS. * Fixed clang-tidy readability-redundant-string-init warnings * Fixed some clang-tidy performance-type-promotion-in-math-fn warnings * Fixed clang-tidy performance-unnecessary-value-param warnings * Reformat source with clang v10.0.1. Co-authored-by: Larry Knox <lrknox@hdfgroup.org> * Removed checks/workarounds for pre-C++89 compatibility (#449) After 30+ years, just assume that the following exist: - extension-less includes - namespaces - std:: - static_cast - bool * Fixed all clang-tidy bugprone-suspicious-string-compare warnings (#451) * Fixed all clang-tidy bugprone-suspicious-string-compare warnings This change was generated entirely by clang-tidy itself. * Reformat code with clang v10.0.1. Co-authored-by: Larry Knox <lrknox@hdfgroup.org> * Fix clang-tidy suspicious string compare in H5A.c missed in merge. Co-authored-by: H. Joe Lee <hyoklee@hdfgroup.org> Co-authored-by: Sean McBride <sean@rogue-research.com>
* 1 10 Merges from develop (#424)Allen Byrne2021-03-041-3/+3
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | * HDFFV-10865 - merge from dev, HDFArray perf fix. * Remove duplicate setting * Whitespace changes after clang format * Undo version 11 clang format changes * Merge CMake changes from develop * test testing script merge from develop * Update supported platforms * PR#3 merge from develop * Merge gcc 10 diagnostics option from develop * Merge #318 OSX changes from develop * Merge small changes from develop * Minor non-space formatting changes * #386 copyright corrections for java folder * Merges from develop #358 patches from vtk #361 fix header guard spelling * Merge updates #358 patches from vtk #361 fix header guard spelling * format fix * Fix missing underscore and make H5public.h closer to dev * Merges from develop #340 clang -Wformat-security warnings #360 Fixed uninitialized warnings header guard underscore cleanup JNI cleanup * format alignment * Add missing test ref file
* Hdf5 1 10 Update license url (#403)Larry Knox2021-03-011-1/+1
| | | | | | | | | | | | | | | | | | | | | | | * close #195. (#196) * Update HDF5PluginMacros.cmake * Update HDF5PluginMacros.cmake * Modify temporary rpath for testing in java example scripts. (#230) * Fix undefined left shifting of negative numbers (#338) Undefined Bahavior Sanitizer errored here about left shifting negative numbers. * Update license url (#332) * Modify temporary rpath for testing in java example scripts. * Update URL in source file Copyright headers for web copy of COPYING file - src and test directories. Co-authored-by: H. Joe Lee <hyoklee@hdfgroup.org> Co-authored-by: Sean McBride <sean@rogue-research.com>
* Source formattedAllen Byrne2020-10-011-2000/+1964
|
* Brings the MPI datatype fixes from developDana Robinson2020-08-221-54/+60
|
* Minor normalizations with developDana Robinson2020-08-161-72/+69
|
* Merge of dataspace improvements from develop.Dana Robinson2020-07-161-140/+439
|
* Misc normalizations with develop.Dana Robinson2020-07-091-50/+47
|
* Continued normalization of H5S with develop.Dana Robinson2020-07-091-27/+25
|
* Further normalization of H5S with developDana Robinson2020-07-081-2/+1
|
* Many normalizations with develop.Dana Robinson2020-05-301-41/+35
|
* Moved H5MM_memcpy and H5MM_xfree_const from developDana Robinson2020-05-151-22/+22
|
* Reduce casts of HDcalloc()/HDmalloc() that -Wc++-compat required.David Young2020-05-051-54/+50
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Reduce gratuitous casts---e.g., (size_t)1. Use the right format string for a pointer. In the H5C sanity checks, change a "size increase" variable from ssize_t (too narrow) to int64_t (wide enough). Parenthesize every appearance of `storage` in the macro `H5D_CHUNK_STORAGE_INDEX_CHK(storage)` so that you can pass in an expression like &sc and it works properly. Disallow re-assignment of the `dset` parameter to H5D__chunk_init() because it helped assure me that it's safe to replace the repeating expression `&dset->shared->layout.storage.u.chunk` with `sc` throughout. Replace lengthy expressions such as `&dset->shared->layout.storage.u.chunk` with `sc` throughout several functions in H5Dchunk.c ISTR that the compiler warned that `sc` was declared but unused in a couple of functions, and then I found that `sc` could be used in many places. Maybe the disused `sc` appeared because a bunch of code was copied and pasted, I don't know. Anyway, it's a lot tighter code now that I use `sc`. In H5D__chunk_update_old_edge_chunks() and H5D__chunk_delete() I actually expand `sc` and another temporary variable, `pline`, because they're used only in !defined(NDEBUG) code. This squashes unused-variable warnings in the defined(NDEBUG) configuration. Don't drop the `volatile` qualification with a cast in tools/src/h5import/h5import.c.
* Merged HDFFV-10792 parallel compression fix from develop.Dana Robinson2020-04-301-3/+47
| | | | This was a manual cherry pick.
* merge intel warning fixKimmy Mu2020-01-091-7/+6
|
* OESS-29 Update HD prefix and compare against developAllen Byrne2019-08-231-586/+586
|
* Address daily test failure for hdf5_1_10:Vailin Choi2019-05-161-1/+1
| | | | Fix the testhdf5 failing test in the selection code which segfaults.
* Fix issue with direct chunk write not updating the "last chunk" indexNeil Fortner2019-03-191-3/+37
| | | | | cache. Fix issues involving datasets being "no allocated" when they contain cached raw data.
* Merge pull request #1536 in HDFFV/hdf5 from ~JHENDERSON/hdf5:hdf5_1_10 to ↵Jordan Henderson2019-02-121-16/+6
|\ | | | | | | | | | | | | | | hdf5_1_10 * commit '2e44998a70924b77f186f6cb60924035fd24441d': Add RELEASE.txt note for collective metadata read fixes Fix some collective metadata read issues
| * Fix some collective metadata read issuesJordan Henderson2019-02-121-16/+6
| |
* | I'm bringing the fixes for the following Jira issues from the develop branch ↵Songyu Lu2019-02-121-12/+13
|/ | | | | | | | | to 1.10 branch: HDFFV-10571: Divided by Zero vulnerability. HDFFV-10601: Issues with chunk cache hash value calcuation. HDFFV-10607: Patches for warnings in the core libraries. HDFFV-10635: HDF5 library segmentation fault with H5Sselect_element.
* Merge branch 'hdf5_1_10' of ↵Binh-Minh Ribler2019-01-041-4/+4
|\ | | | | | | https://bitbucket.hdfgroup.org/scm/~bmribler/hdf5_1_10_bmr into hdf5_1_10
| * Removed 'VOL' versions of FUNC_ENTER macros as well as empty functionsDana Robinson2018-12-311-4/+4
| | | | | | | | orginally intended to support the full SWMR feature (from develop).
* | Fixed CVE division-by-zero issuesBinh-Minh Ribler2019-01-041-4/+26
|/ | | | | | | | | | | | | | | | | | | Description: Fixed HDFFV-10577 and similar issues found in H5Dchunk.c. All the occurrences are in: H5D__create_chunk_map_single H5D__create_chunk_file_map_hyper H5D__chunk_allocate H5D__chunk_update_old_edge_chunks H5D__chunk_prune_by_extent H5D__chunk_copy_cb H5D__chunk_collective_fill Also updated RELEASE.txt for the chunk query functions and removed some blank lines in chunk_info.c. Platforms tested: Linux/64 (jelly) Linux/64 (platypus) Darwin (osx1010test)
* Fixed typos.Binh-Minh Ribler2018-12-071-8/+7
| | | | | Platforms tested: Linux/64 (jelly)
* Updated new API functionsBinh-Minh Ribler2018-11-061-29/+18
| | | | | | | | | | | Description: - Addressed additional review comments - Moved the test function test_get_chunk_info from dsets.c to chunk_info.c because chunk_info.c was created for the purpose of testing chunk information. Platforms tested: Linux/64 (jelly) Linux/64 (platypus) Darwin (osx1011test)
* Updated new API functionsBinh-Minh Ribler2018-11-051-67/+159
| | | | | | | | | | | | | | Description: - Per Vailin's review, revised H5Dget_chunk_info_by_coord to handle non-existing chunk and H5Dget_num_chunks and H5Dget_chunk_info to handle dataset with no data. - Addressed other review comments - Note that additional tests will be added as we need to send users these functions asap for feedback. Platforms tested: Linux/64 (jelly) Linux/64 (platypus) Darwin (osx1011test)
* New API functionsBinh-Minh Ribler2018-10-291-0/+309
| | | | | | | | | | | | | | | | | | | | | | | | | | | Description: Added functions to query chunk information: H5Dget_num_chunks(dset_id, fspace_id, *nchunks) Gets the number of written chunks that intersect with the given dataspace. However, in this version, the intersection is not yet completed. Thus, the number of all written chunks will be returned. H5Dget_chunk_info_by_coord(dset_id, *coord, *filter_mask, *addr, *size) Given a chunk's coordinates, returns the chunk's filter, address, and size. H5Dget_chunk_info(dset_id, fspace_id, index, *coord, *filter_mask, *addr, *size) Given a chunk's index, returns the chunk's coordinates, filter, address, and size. The chunk belongs to a set of chunks that have nonempty intersection with the specified dataspace. However, in this version, the intersection is not yet completed, and the index is of all the written chunks. Platforms tested: Linux/64 (jelly) Linux/64 (platypus) Darwin (osx1011test)
* Combined macro lines as Dana commentedBinh-Minh Ribler2018-07-261-2/+1
| | | | | Platforms tested: Linux/64 (jelly) (very minor)
* Fixed division-by-zero issuesBinh-Minh Ribler2018-07-261-0/+3
| | | | | | | | | | | Description: Fixed HDFFV-10481 and HDFFV-10477, division by 0. Fixed another occurrence beside what were reported. Also, changed a local variable to avoid an unnecessary cast. Platforms tested: Linux/64 (jelly) Linux/32 (jam) Darwin (osx1010test)
* Fixed HDFFV-10404Binh-Minh Ribler2018-07-261-4/+4
| | | | | | | | | Description: Applied the typo fixes from user's report. The previous pull request couldn't be merged because it was too old, and it was too complicated for me to resolve conflicts. Platform tested: Linux/64 (jelly) - very minor
* Add note about single chunk caching and serial libraryJordan Henderson2018-07-261-1/+7
|
* Add check for actually using the MPI file driver when caching one chunkJordan Henderson2018-07-261-1/+15
| | | Better explain rationale behind chunk caching issue fix
* Fix for HDFFV-10509Jordan Henderson2018-07-261-2/+15
|
* Merge branch 'develop' into hdf5_1_10.syncM. Scot Breitenfeld2018-05-081-317/+194
|\
| * Merge branch 'develop' of https://bitbucket.hdfgroup.org/scm/hdffv/hdf5 into ↵Quincey Koziol2018-04-291-343/+547
| |\ | | | | | | | | | merge_hyperslab_updates
| | * Merge remote-tracking branch 'origin/develop' into merge_func_enter_volQuincey Koziol2018-03-211-1/+1
| | |\
| | * | Add API context interface and use it throughout the library.Quincey Koziol2018-03-151-306/+187
| | | |
| * | | Merge branch 'develop' of https://bitbucket.hdfgroup.org/scm/hdffv/hdf5 into ↵Quincey Koziol2017-04-111-5/+5
| |\ \ \ | | | | | | | | | | | | | | | merge_hyperslab_updates
| * | | | Further minor cleanupsQuincey Koziol2017-03-281-2/+2
| | | | |
| * | | | Checkpoint normalization against incoming hyperslab / selection / dataspaceQuincey Koziol2017-03-281-11/+7
| | | | | | | | | | | | | | | | | | | | improvements.
* | | | | Merge pull request #983 in HDFFV/hdf5 from develop to hdf5_1_10Larry Knox2018-03-201-1/+1
|\ \ \ \ \ | | |_|_|/ | |/| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | * commit '6a1627f2967099039e11b9e86cf347f6482bdf3c': Fix for HDFFV-10425 test failure with H5DOwrite_chunk and latest format Fix date. Correct the date in RELEASE.txt for H5DOread_chunk. Add release info for H5DOread_chunk. Updated RELEASE.txt Description: Wrappers for H5Tencode and H5Tdecode No code change. Fixed HDFFV-10151 Description: Added a document to the HDF5 C++ API Reference Manual to show the mapping from a C API to C++ wrappers. Fix memory leak simply by capturing allocation in var Change max value Chnage values so test will fail when new latest is added Exception changed Exception type changed Correct constant var names Java constants for new lib verbounds values