libtool
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: Fwd: curious...


From: Eric Blake
Subject: Re: Fwd: curious...
Date: Fri, 20 Oct 2006 19:29:37 -0600
User-agent: Mozilla/5.0 (Windows; U; Windows NT 5.1; en-US; rv:1.8.0.7) Gecko/20060909 Thunderbird/1.5.0.7 Mnenhy/0.7.4.666

-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1

According to Kyle Sallee on 10/20/2006 4:48 PM:

Thanks for your concerns.  Yes, libtool developers are aware of the pain
of slow scripts, and have made efforts recently to speed things up, but
there are still lurking corners that could use improvements.  One speed
factor comes if you use bash 3.1 or newer, where libtool takes advantage
of the new += assignment operator to make variable concatenation faster
than the quadratic behavior of older shells.

> 
> Is it out of the question to keep lists separated by line feeds
> instead of spaces and then use the sort and uniq instead
> of case statements?

Yes - invoking external processes is noticeably slower than keeping
execution limited within shell builtins.

> 
> And for the for loop inside, perhaps that could be done
> with utilities?
> 
> specialdeplibs="$( echo "$deplibs" | tr ' ' '\n' | sort | uniq -d )"
> libs="$( echo "$deplibs" | tr ' ' '\n' | sort -u )"

This is actually slower on platforms with noticeable fork penalties.

> 
> 
> The above example was not from a part of libtool that
> was necessarily snowballing signifigantly on that invocation.
> But there is probably some slowing down involving loops
> that assign newdependency_libs=
> 
> Does the use of backticks or $( subshells break portability of libtool?

$() is out of the question - it is not portable.  Using `` is the same
speed as $() (both versions invoke a subshell), just slightly different
syntax.

> 
> Would you like me to hack a little on libtool just to
> increase it's execution speed or are such changes
> trivial to accomplish now that I mentioned it?

You would not be the first to be making such contributions, and if your
copyright assignment is in place, your contributions would certainly be
appreciated.

- --
Life is short - so eat dessert first!

Eric Blake             address@hidden
-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.4.2.1 (Cygwin)
Comment: Public key at home.comcast.net/~ericblake/eblake.gpg
Comment: Using GnuPG with Mozilla - http://enigmail.mozdev.org

iD8DBQFFOXgB84KuGfSFAYARAp5NAJ9fpV+wkHif1CU/1PeSSvBWBNkJ8QCcD5wU
Z9W781a20aGPnwx3wJdRP0Q=
=N9ou
-----END PGP SIGNATURE-----




reply via email to

[Prev in Thread] Current Thread [Next in Thread]