4 ms·
In practice I just hton[sl] it for both - it's the great equalizer and will get optimized out when not needed at even modest -O levels. If I'm going to crack o
by kristopolous 3y ago
In practice I just hton[sl] it for both - it's the great equalizer and will get optimized out when not needed at even modest -O levels.
If I'm going to crack open an int32, it's htonl all day long and ntohl it back when I'm done.