[MITgcm-devel] C byteswap routines for FIZHI integers
Andrea Molod
molod at ocean.mit.edu
Thu May 12 10:28:51 EDT 2005
hi ed,
> Hi Andrea & Jean-Michel,
>
> Attached is the alternate C byte-swap for integers that we discussed
> today. I've tested it with verification/fizhi-gridalt-hs and it
> compiles and runs (though I'm not certain that its used to produce any
> output in that example).
>
> I've also tested it independently with the attached self-contained
> "hi.f" example and it compiles, runs, and produces the correct results
> with g77.
>
> So take a look, verify that it works for you, and then we can check it
> into the model.
>
> Ed
>
> ps - In the fizhi-gridalt-hs test, I added the "-DHAVE_C_BSWAP" flag
> to the Makefile per:
>
> DEFINES = -D_BYTESWAPIO -DHAVE_C_BSWAP -DWORDLENGTH=4 ...
unfortunately, the fizhi-gridalt-hs verfication experiment does not use
any of this byteswapping stuff for integers, so it is not a test of the
new code. i wish you had asked me which experiment to use to test this
out. and i took a quick look at your hi.f to test it offline. it seems
to write and then byteswap the integer, but we don't know whether it
byteswapped anything or not..... but thanks for the effort.
andrea
More information about the MITgcm-devel
mailing list