<div dir="ltr">Me too. I agree with Vaclav that we are already using features of 1.8. Its hard to make truly useful things without those features. Also, I don't think anyone using their own old HDF5 also uses our HDF5, so we would not have to break them.<div><br></div><div> Thanks,</div><div><br></div><div> Matt</div></div><br><div class="gmail_quote"><div dir="ltr">On Fri, Dec 7, 2018 at 9:48 AM Jed Brown via petsc-dev <<a href="mailto:petsc-dev@mcs.anl.gov">petsc-dev@mcs.anl.gov</a>> wrote:<br></div><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">I'm in favor of requiring >=1.8.0.<br>
<br>
Hapla Vaclav via petsc-dev <<a href="mailto:petsc-dev@mcs.anl.gov" target="_blank">petsc-dev@mcs.anl.gov</a>> writes:<br>
<br>
> I wanted to add support for HDF5 attributes of groups (currently only datasets).<br>
><br>
> But I already feel like held back by supporting HDF5 older than 1.8.0. Do we still need that?<br>
><br>
> My arguments to get rid of that support:<br>
> 1) It seems we already use some 1.8.0+ functions anyway (might be my fault, though).<br>
> 2) We could get rid of all those #if<br>
> 3) There were quite some useful API functions introduced in that release which would make the code simpler. For instance, H5O* functions allow handling groups and datasets the same way.<br>
><br>
> Ad 2,3 consider this<br>
><br>
> /* OLD */<br>
> #if (H5_VERS_MAJOR * 10000 + H5_VERS_MINOR * 100 + H5_VERS_RELEASE >= 10800)<br>
> if (dataset) {<br>
> PetscStackCallHDF5Return(object, H5Dopen2, (h5, parent, H5P_DEFAULT));<br>
> } else if (type == H5O_TYPE_GROUP) {<br>
> PetscStackCallHDF5Return(object, H5Gopen2, (h5, parent, H5P_DEFAULT));<br>
> }<br>
> #else<br>
> if (dataset) {<br>
> PetscStackCallHDF5Return(object, H5Dopen, (h5, parent));<br>
> } else if (type == H5O_TYPE_GROUP) {<br>
> PetscStackCallHDF5Return(object, H5Gopen, (h5, parent));<br>
> }<br>
> #endif<br>
> ...<br>
> if (dataset) {<br>
> PetscStackCallHDF5Return(err, H5Dclose, (object));<br>
> } else if (type == H5O_TYPE_GROUP) {<br>
> PetscStackCallHDF5Return(err, H5Gclose, (object));<br>
> }<br>
><br>
><br>
> /* NEW */<br>
> PetscStackCallHDF5Return(object, H5Oopen, (h5, parent, H5P_DEFAULT));<br>
> ...<br>
> PetscStackCallHDF5Return(err, H5Oclose, (object));<br>
><br>
><br>
> Additionally, function H5Oget_info() which can say whether the object is group or dataset was also introduced only in 1.8.0. So the dataset flag above would have to be set by a user it seems...<br>
><br>
> So I personally think it's already about time to leave the old HDF5 API behind... Objections? If no, I would make a PR which would clean the code from the #ifs and forbid the older versions already in configure.<br>
><br>
> Vaclav<br>
</blockquote></div><br clear="all"><div><br></div>-- <br><div dir="ltr" class="gmail_signature" data-smartmail="gmail_signature"><div dir="ltr"><div><div dir="ltr"><div><div dir="ltr"><div>What most experimenters take for granted before they begin their experiments is infinitely more interesting than any results to which their experiments lead.<br>-- Norbert Wiener</div><div><br></div><div><a href="http://www.cse.buffalo.edu/~knepley/" target="_blank">https://www.cse.buffalo.edu/~knepley/</a><br></div></div></div></div></div></div></div>