3 ms·
This one never gets old! While it's debatable whether it makes a whole lot of sense to compare compiled code to (completely) unrelated things, it's pretty shock
by mivanchev 9y ago
This one never gets old! While it's debatable whether it makes a whole lot of sense to compare compiled code to (completely) unrelated things, it's pretty shocking that touch on Mac OS Lion is that large in size (haven't verified myself though). Perhaps someone could quickly explain how that particular version of touch operates.
- gilgoomesh 9y agotouch in macOS Sierra is down to 23kB since the 32-bit version is no longer part of the binary. If you open it up, it's about 2/3rds zeros, maybe 10% Apple signing certificate, a whole bunch of dynamic linking data and according to otool, the (__TEXT,__text) section – normal code – is a mere 3kb in size.
- mivanchev 9y agoThanks for taking your time to analyze the binary. I know we are not constrained by expensive hard drives these days, but this sure is some wasted space.
- yjftsjthsd-h 9y agoWhy all the 0s? Required padding?
- fancy_pantser 9y agoMach-O files are usually padded to 4096 byte aligned segments. You can inspect the segments with otool, pagestuff, and nm. NB: UPX compresses it from 23312 -> 12904 bytes (55.35%) using UCL.