increase in object code size

Thomas Koenig ig25@mvmap66.ciw.uni-karlsruhe.de
Tue Sep 23 10:05:00 GMT 1997


Warner Losh wrote:
>In message < 199709231418.QAA27370@mvmap66.ciw.uni-karlsruhe.de > Thomas Koenig writes:
>: Any idea what's causing this?  Are the options wrong?
>
>What does size say for these modules?

egcs, with -fno-exceptions:

$ size 3c59x.o
text    data    bss     dec     hex     filename
14367   264     0       14631   3927    3c59x.o
$ ls -l 3c59x.o
-rw-r--r--   1 root     root        20260 Sep 23 18:40 3c59x.o

$ size ipv4.o
text    data    bss     dec     hex     filename
89979   3680    192     93851   16e9b   ipv4.o
$ ls -l ipv4.o
-rw-r--r--   1 root     root       128099 Sep 23 18:49 ipv4.o

egcs, without -fno-exceptions:

$ size 3c59x.o
text    data    bss     dec     hex     filename
14367   5836    0       20203   4eeb    3c59x.o
$ ls -l 3c59x.o
-rw-r--r--   1 root     root        26308 Sep 23 18:53 3c59x.o

$ size ipv4.o
text    data    bss     dec     hex     filename
89979   50308   192     140479  224bf   ipv4.o
$ ls -l ipv4.o
-rw-r--r--   1 root     root       179663 Sep 23 18:55 ipv4.o

gcc 2.7.2.1:

$ size 3c59x.o
text    data    bss     dec     hex     filename
14460   264     0       14724   3984    3c59x.o
$ ls -l 3c59x.o
-rw-r--r--   1 root     root        20344 Sep 23 18:57 3c59x.o

$ size ipv4.o
text    data    bss     dec     hex     filename
89503   3680    192     93375   16cbf   ipv4.o
$ ls -l ipv4.o
-rw-r--r--   1 root     root       126775 Sep 23 18:58 ipv4.o

So... looks like the data section being stuffed by exception handling.
Is there any reason to keep this for C?
-- 
Thomas Koenig, Thomas.Koenig@ciw.uni-karlsruhe.de, ig25@dkauni2.bitnet.
The joy of engineering is to find a straight line on a double
logarithmic diagram.



More information about the Gcc mailing list