Fast way to swap endianness using opencl
问题 I'm reading and writing lots of FITS and DNG images which may contain data of an endianness different from my platform and/or opencl device. Currently I swap the byte order in the host's memory if necessary which is very slow and requires an extra step. Is there a fast way to pass a buffer of int/float/short having wrong endianess to an opencl-kernel? Using an extra kernel run just for fixing the endianess would be ok; using some overheadless auto-fixing-read/-write operation would be perfect