https://gcc.gnu.org/bugzilla/show_bug.cgi?id=65476
Bug ID: 65476 Summary: Long_Float array does not byte swap correctly when set to Scalar_Storage_Order with High Order First Product: gcc Version: 5.0 Status: UNCONFIRMED Severity: normal Priority: P3 Component: ada Assignee: unassigned at gcc dot gnu.org Reporter: daniel.merrill at psware dot com CC: ebotcazou at gcc dot gnu.org Created attachment 35067 --> https://gcc.gnu.org/bugzilla/attachment.cgi?id=35067&action=edit code to reproduce the issue. When an array of Long_Floats is set to a scalar_storage_order of High_Order_First, only the two 32 bit words that make up the 64 bit value are swapped with each other but the bytes under those words are not swapped properly. Attached is a simple program that reproduces the behavior. If you examine the stored values you could get the right value by performing a byte swap on the underlying 32 bit value.