@sbrass ,
I recommend using a C function for hashing (or C++ with extern C attribute): it’s so much more straightforward given Fortran 2003 and standard interoperability.
Yes, you can jump through hoops in Fortran with bitwise arithmetic with a higher bitness type that will end up being “clever programming” with all its travails. And for this one would be inclined to make use of the additional language support introduced starting Fortran 2008 standard, however robust compiler support was not uniform making the code less portable i.e., until enough compilers had caught up to the standard.