gharris999;318448 Wrote: 
> Thanks for all this info.  
> 
> Which sort of executable (statically linked or dynamic) would be
> preferable to use on a relatively low-horsepower linux box: (e.g. Via
> C7 with 1gig of ram)?  Dynamic, because of a potentially smaller memory
> footprint, or static...which I assume requires less work at run-time
> from the OS' loader?

Hard to say without more information I think. Dynamic is only smaller
if is actually able to share. If lame is the only executable pulling in
some library nothing is saved... unless you run several lame processes
in which case... or unless lame is linked to a bunch of libraries and
it only pulls a subset of those... Also the overhead of loading
obviously not a problem if it is already used by some other process.

In the static case it can be the "opposite" in some case. E.g. if you
run several lame processes everything must be loaded for each process,
whereas its in memory in the dynamic case if used by lame (or some
other process). Also the executable could have lots of libraries linked
in that you actually never use. That said with static linking one could
apply some of the more unsafe optimizations to the compiler without
risk of braking all kinds of stuff. I also think that some
optimizations are only possible with static linking. 

So the sum of the pros and cons depends on the rest of the system and
usage patterns. Anyway, I do not really have deep knowledge of this
stuff and would personally just do some tests for the two cases, and
make a decision based on that. For example use 'time' to see how long
it takes to encode a file, and of course 'top' to see memory usage.


-- 
bhaagensen
------------------------------------------------------------------------
bhaagensen's Profile: http://forums.slimdevices.com/member.php?userid=7418
View this thread: http://forums.slimdevices.com/showthread.php?t=49619

_______________________________________________
unix mailing list
[email protected]
http://lists.slimdevices.com/lists/listinfo/unix

Reply via email to