118 Chapter 4
Linker Tools
Improving Program Start-up with fastbind(1)
Improving Program Start-up with
fastbind(1)
The fastbind(1) command prepare an incomplete executable for faster
program start-up. It can improve the start-up time of programs that use
shared libraries (incomplete executables) by storing information about
needed shared library symbols in the executable file.
fastbind performs analysis on the symbols used to bind an executable
and all of its dependent shared libraries, and stores this information in
the executable file. The next time the executable is run, the dynamic
loader (/usr/lib/dld.sl for 32-bit mode or
/usr/lib/pa20_64/dld.sl for 64-bit mode) detects that this
information is available, and uses it to bind the executable instead of
using the standard search method for binding the symbols.
Because fastbind writes the fastbind information in the executable file,
you must have write permission on the executable file. If the executable
file being analyzed is being run as another process or the file is locked
against modifications by the kernel, the fastbind command fails.
If the shared libraries that an executable is dependent on are modified
after the fastbind information is created, the dynamic loader silently
reverts to standard search method for binding the symbols. The fastbind
information can be re–created by running fastbind on the executable
again. fastbind automatically erases the old fastbind information and
generate the new one.
To do this
Use this
option
Remove the fastbind information from the executable,
returning it to the same state it as was in before you
ran fastbind on it.
-n
Normally, if fastbind detects any unsatisfied symbols
while building the fastbind information, it generates an
error message and does not modify the executable file.
When you invoke fastbind with the -u option
however, it allows unresolved symbols.
-u