https://gcc.gnu.org/bugzilla/show_bug.cgi?id=116885

--- Comment #10 from Jaroslav Fojtík <JaFojtik at seznam dot cz> ---
I can call 8x fwrite with 1 byte to camouflage this. It will produce slower and
longer code and type punning will be only hidden. I cannot avoid this shuffle.


           // Needed to store double in LoEndian format
     case 'e':{const double e = va_arg(ap,double);
#ifdef LO_ENDIAN
              writed += fwrite(&e,1,8,F);  // LO endian native machine
#else
              writed+=WrQWORD_LoEnd(*(QWORD_*)&e,F);
#endif
              break;}

           // Needed to store double in HiEndian format
     case 'E':{const double e = va_arg(ap,double);
#ifdef HI_ENDIAN
              writed += fwrite(&e,1,8,F);  // HI endian native machine
#else
              writed+=WrQWORD_HiEnd(*(QWORD_*)&e,F);
#endif
              break;}

Reply via email to