3 ms·
and often performance as well BS. Nothing can be faster than a read()/write() (or even mmap()) into a struct, because everything else would need to do more wor
by userbinator 8mo ago
and often performance as well
BS. Nothing can be faster than a read()/write() (or even mmap()) into a struct, because everything else would need to do more work.
- pjc50 8mo agoSure, if your structure doesn't contain any pointers and you only ever want to support one endianness and you trust your compiler to fix the machine layout of the struct forever.
- zadikian 8mo agoMainly the first thing. If your struct is already serial, of course serialization will be easy.
- userbinator 8mo ago...which is true for 99.999% of the time anyway, so it's not worth worrying about.