4 ms·
I don't know how you compiled it, but you can often cut down by using the '-O3' command line option when you are compiling. Then you can use the 'strip a.out' (
by ktRolster 10y ago
I don't know how you compiled it, but you can often cut down by using the '-O3' command line option when you are compiling. Then you can use the 'strip a.out' (or whatever your executable name is) to cut it down further.
Then if you open it in a hex editor (or use od -x), I'll bet you'll see pages and pages of zeroes, which are used for aligning it appropriately in RAM when it loads.
At least, those are all things that work on some systems, can't be sure about yours.
- aexaey 10y agoThere is also an sstrip tool [1], written by the same Brian Raiter already mentioned here. It strips a bit more eagerly: $ gcc tiny.c -O3 -o tiny; wc -c tiny 8456 tiny $ strip tiny; wc -c tiny 6224 tiny $ sstrip tiny; wc -c tiny 4140 tiny [1] http://www.muppetlabs.com/~breadbox/software/elfkickers.html http://www.muppetlabs.com/~breadbox/software/elfkickers.html