Re: [Fractdev] Xfractint compiler optimizations
Tim,
I have looked into using indent. It's fine for new development or situations when you are willing to redo all the comments. It's bad for legacy code created by many people, because almost invariably careful formatting of comments gets messed up.
Currently, the default style of indent is the GNU style. I used it on video.c and the comments were virtually untouched. I like the results. As expected, the file size increased (from 16216 bytes to 17049 bytes). Don't try this at home, I have already modified the file to clear up the -Wall warnings. Unfortunately, the object file size also increased (from 49984 bytes to 50080 bytes). Not much, but I'm a little uneasy about it. I looked at the before and after C files and couldn't see any obvious reason for the different object file sizes. Jonathan
I used it on video.c and the comments were virtually untouched.
You were lucky! :-) I am all for using indent. Our mishmash of coding styles is a nuisance. I have similar issues at work. If one cleans up the indenting, then the diff gets big, and at work, we have to have a code walkthrough of all the changes, so one tends not to be motivated to clean up other's indenting. As a result, older code has inconsistencies. In our case, indent will work fine. But I guarantee you won't be so lucky with the comments in other cases ... I also favor expanding tabs to spaces. Tim
Jonathan, I may be completely off the mark here, but some optimizations involve code unrolling and duplication so this could be the caso for the object size. And I assume you're talking about the stripped binary in both cases. And by the way why are you worried about the code size increase in xfractint? Regs HB
-----Mensaje original----- De: fractdev-admin@mailman.xmission.com [mailto:fractdev-admin@mailman.xmission.com]En nombre de Jonathan Osuch Enviado el: MiƩrcoles, 19 de Diciembre de 2001 23:21 Para: fractdev@mailman.xmission.com Asunto: Re: [Fractdev] Xfractint compiler optimizations
Tim,
I have looked into using indent. It's fine for new development or situations when you are willing to redo all the comments. It's bad for legacy code created by many people, because almost invariably careful formatting of comments gets messed up.
Currently, the default style of indent is the GNU style. I used it on video.c and the comments were virtually untouched. I like the results. As expected, the file size increased (from 16216 bytes to 17049 bytes). Don't try this at home, I have already modified the file to clear up the -Wall warnings. Unfortunately, the object file size also increased (from 49984 bytes to 50080 bytes). Not much, but I'm a little uneasy about it. I looked at the before and after C files and couldn't see any obvious reason for the different object file sizes.
Jonathan
_______________________________________________ Fractdev mailing list Fractdev@mailman.xmission.com http://mailman.xmission.com/cgi-bin/mailman/listinfo/fractdev
On Wed, Dec 19, 2001 at 08:20:49PM -0600, Jonathan Osuch wrote:
Currently, the default style of indent is the GNU style. I used it on video.c and the comments were virtually untouched. I like the results. As expected, the file size increased (from 16216 bytes to 17049 bytes). Don't try this at home, I have already modified the file to clear up the -Wall warnings. Unfortunately, the object file size also increased (from 49984 bytes to 50080 bytes). Not much, but I'm a little uneasy about it. I
If you have more lines of text source, you have more line infos embeded in the object file. I think... Th.
participants (4)
-
Humberto R. Baptista -
Jonathan Osuch -
Thierry B. -
Tim Wegner