Skip to content

Commit

Permalink
Merge remote-tracking branch 'origin/develop' into threading_updates
Browse files Browse the repository at this point in the history
  • Loading branch information
qkoziol committed Mar 20, 2024
2 parents 889f3fd + 4c0f146 commit ed1e66a
Show file tree
Hide file tree
Showing 3 changed files with 52 additions and 16 deletions.
25 changes: 25 additions & 0 deletions .github/workflows/release-files.yml
Original file line number Diff line number Diff line change
Expand Up @@ -178,6 +178,7 @@ jobs:
- name: PreRelease tag
id: create_prerelease
if: ${{ (inputs.use_environ == 'snapshots') }}
uses: softprops/action-gh-release@de2c0eb89ae2a093876385947365aca7b0e5f844 # v1
with:
tag_name: "${{ inputs.use_tag }}"
Expand All @@ -200,6 +201,30 @@ jobs:
sha256sums.txt
if-no-files-found: error # 'warn' or 'ignore' are also available, defaults to `warn`
- name: Release tag
id: create_release
if: ${{ (inputs.use_environ == 'release') }}
uses: softprops/action-gh-release@de2c0eb89ae2a093876385947365aca7b0e5f844 # v1
with:
tag_name: "${{ inputs.use_tag }}"
prerelease: false
body_path: description.txt
files: |
${{ steps.get-file-base.outputs.FILE_BASE }}.doxygen.zip
${{ steps.get-file-base.outputs.FILE_BASE }}.tar.gz
${{ steps.get-file-base.outputs.FILE_BASE }}.zip
${{ steps.get-file-base.outputs.FILE_BASE }}-osx12.tar.gz
${{ steps.get-file-base.outputs.FILE_BASE }}-ubuntu-2204_gcc.tar.gz
${{ steps.get-file-base.outputs.FILE_BASE }}-ubuntu-2204_gcc.deb
${{ steps.get-file-base.outputs.FILE_BASE }}-ubuntu-2204_gcc.rpm
${{ steps.get-file-base.outputs.FILE_BASE }}-ubuntu-2204_gcc_s3.tar.gz
${{ steps.get-file-base.outputs.FILE_BASE }}-win-vs2022_cl.zip
${{ steps.get-file-base.outputs.FILE_BASE }}-ubuntu-2204_intel.tar.gz
${{ steps.get-file-base.outputs.FILE_BASE }}-win-vs2022_intel.zip
${{ steps.get-file-base.outputs.FILE_BASE }}.html.abi.reports
sha256sums.txt
if-no-files-found: error # 'warn' or 'ignore' are also available, defaults to `warn`
- name: List files for the space (Linux)
run: |
ls -l ${{ github.workspace }}
Expand Down
2 changes: 1 addition & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -89,7 +89,7 @@ are tentative.
| Release | New Features |
| ------- | ------------ |
| 1.14.4 | native float16 support, cloud-optimized HDF5 improvements |
| 1.14.5 | TBD |
| 1.14.5 | Complex number support |
| TBD | VFD SWMR |
| 2.0.0 | TBD |

Expand Down
41 changes: 26 additions & 15 deletions test/dtypes.c
Original file line number Diff line number Diff line change
Expand Up @@ -6051,6 +6051,7 @@ test__Float16(void)
{
#ifdef H5_HAVE__FLOAT16
H5T_path_t *path = NULL;
const char *env_h5_driver;
hsize_t dims[1];
htri_t is_little_endian;
H5T_t *native_dtype = NULL;
Expand All @@ -6064,6 +6065,10 @@ test__Float16(void)

TESTING("_Float16 datatype");

env_h5_driver = getenv(HDF5_DRIVER);
if (env_h5_driver == NULL)
env_h5_driver = "nomatch";

/* Check that native macro maps to a valid type */
if (0 == H5Tget_size(H5T_NATIVE_FLOAT16)) {
H5_FAILED();
Expand Down Expand Up @@ -6397,24 +6402,30 @@ test__Float16(void)
if (H5Fclose(fid) < 0)
TEST_ERROR;

{
h5_stat_size_t file_size = h5_get_file_size(filename, H5P_DEFAULT);
if (!h5_driver_uses_multiple_files(env_h5_driver, H5_EXCLUDE_NON_MULTIPART_DRIVERS)) {
bool is_default_vfd_compat = false;

if (file_size < 0)
if (h5_driver_is_default_vfd_compatible(H5P_DEFAULT, &is_default_vfd_compat) < 0)
TEST_ERROR;
if ((size_t)file_size < dims[0] * sizeof(H5__Float16)) {
H5_FAILED();
AT();
printf("File size value was too small\n");
goto error;
}
if (is_default_vfd_compat) {
h5_stat_size_t file_size = h5_get_file_size(filename, H5P_DEFAULT);

/* 4096 bytes is arbitrary, but should suffice for now */
if ((size_t)file_size > (dims[0] * sizeof(H5__Float16)) + 4096) {
H5_FAILED();
AT();
printf("File size value was too large\n");
goto error;
if (file_size < 0)
TEST_ERROR;
if ((size_t)file_size < dims[0] * sizeof(H5__Float16)) {
H5_FAILED();
AT();
printf("File size value was too small\n");
goto error;
}

/* 4096 bytes is arbitrary, but should suffice for now */
if ((size_t)file_size > (dims[0] * sizeof(H5__Float16)) + 4096) {
H5_FAILED();
AT();
printf("File size value was too large\n");
goto error;
}
}
}

Expand Down

0 comments on commit ed1e66a

Please sign in to comment.