Iñaki: Static libs on every platform need to have this dependency info.
Robert -----Original Message----- From: Iñaki García Etxebarria [mailto:[EMAIL PROTECTED] Sent: Friday, September 19, 2003 9:22 AM To: [EMAIL PROTECTED] Subject: Link performance: some numbers and a hack Hi, Is there any need for dependency_libs (in .la files, that is) in linux, or other platforms where you can put dependency info into the lib itself? I ask because I have been trying to improve the abysmal link time for some gnome apps[1], and come to a simple "worksforme fix" (aka horrible kludge ;-)), which consists on simple removing all dependency_libs from the relevant .la files. Yes, you can hate me now :-) I'm by no means a libtool or ld expert, but everything seems to work well, and the resulting improvement is huge: Linking the nautilus executable without the "fix" ------------------------------------------------- real 3m46.171s user 3m39.790s sys 0m2.200s Linking with it --------------- real 0m12.858s user 0m10.640s sys 0m1.890s You can further reduce the link time to around 3 seconds if you perform dependency analysis on the command line and pass to libtool only the minimum set of libraries. That is, suppose libfoo depends on libbar and the command line says: '-lfoo -lbar'. You shave off some seconds if you just pass -lfoo to libtool[2]. I'm aware that this is naïve and will fail in many architectures, but would it be possible to special case architectures where it works? Assuming any exist, of course :-) Thanks for your attention, Iñaki [1] Which use tons of libraries, most of them with corresponding .la files with more deps inside. [2] For those wondering, I don't do this all by hand, all analysis and .la dependency removing is done at link time by some wrapper python scripts available upon request. _______________________________________________ Libtool mailing list [EMAIL PROTECTED] http://mail.gnu.org/mailman/listinfo/libtool - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - This e-mail and any files transmitted with it are confidential and intended solely for the use of the individual or entity to whom they are addressed.If you have received this e-mail in error please notify the sender immediately and delete this e-mail from your system.Please note that any views or opinions presented in this e-mail are solely those of the author and do not necessarily represent those of Ricardo (save for reports and other documentation formally approved and signed for release to the intended recipient).Only Directors are authorised to enter into legally binding obligations on behalf of Ricardo. Ricardo may monitor outgoing and incoming e-mails and other telecommunications systems. By replying to this e-mail you give consent to such monitoring.The recipient should check e-mail and any attachments for the presence of viruses. Ricardo accepts no liability for any damage caused by any virus transmitted by this e-mail. "Ricardo" means Ricardo plc and its subsidiary companies. Ricardo plc is a public limited company registered in England with registered number 00222915. The registered office of Ricardo plc is Bridge Works, Shoreham-by Sea, West Sussex, BN43 5FG. - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - _______________________________________________ Libtool mailing list [EMAIL PROTECTED] http://mail.gnu.org/mailman/listinfo/libtool