netcdf-c: nc_test fails when optimization greater than -O0 is invoked.
A failure in nc_test/nc_test was initially reported on the ppc64le platform as part of the tests for conda-forge/libnetcdf-feedstock release of 4.8.0. Subsequent testing has revealed an issue with some, but not all, compilers. More details to follow, opening an issue to capture this.
Update 1
Issue has been observed on M1 hardware, both in OSX, and emulated ppc64le (via qemu). Issue does not manifest on M1 hardware in virtualized ubuntu, or on intel-based OSX. I’ll update with compiler versions (which is a big piece of the puzzle).
About this issue
- Original URL
- State: closed
- Created 3 years ago
- Comments: 17 (14 by maintainers)
Commits related to this issue
- Fixing issues uncovered by compiling with '-fsanitize=undefined' and running nc_test/nc_test, in support of https://github.com/Unidata/netcdf-c/issues/1983, amongst others. The cast as was being used... — committed to WardF/netcdf-c by WardF a year ago
- Merge branch 'main' into hdf5_swmr * main: (1776 commits) Invert solution as discussed at https://github.com/Unidata/netcdf-c/pull/2618 Correct a potential null pointer dereference. Fix a logic... — committed to ZedThree/netcdf-c by ZedThree a year ago
- netcdf: Autospec creation for update from version 4.9.1 to version 4.9.2 Dennis Heimbigner (9): Modify H5FDhttp.c to work with HDF5 1.14.0 update release notes Enable ACCEPT_ENCODIN... — committed to clearlinux-pkgs/netcdf by fenrus75 a year ago
Thanks to the renewed interest, some additional info/reading provided by @dopplershift, and an expanded knowledge of
-fsanitize, I think we have a fix for this. It also looks like we have a lot of additional work to do cleaning up some operations that are undefined, but consistent. But first things first. I’ll be testing the potential fix for this shortly.Some relevant build env information from over there. Host env:
Build env:
I can confirm that replacing
-O3with-O0over in conda-forge/libnetcdf-feedstock#119 allowed the failing test to pass.