| United States-English |
|
|
|
![]() |
HP-UX 64-bit Porting and Transition Guide: HP 9000 Computers > Chapter 2 Summary of Changes Run Time Differences |
|
Applications compiled and linked in 64-bit mode use a run-time dynamic loading model similar to other SVR4 systems. There are two main areas where program start-up changes in 64-bit mode:
It is recommended that you use the standard SVR4 linking option (+std, which is on by default) when linking 64-bit applications. If there are circumstances during the transition when you need 32-bit compatible linking behavior, use the +compat option. This option forces the linker to use 32-bit linking and dynamic loading behavior. The following table summarizes the dynamic loader differences between 32-bit and 64-bit mode: Table 2-10 Dynamic Loading Differences
For More Information:Dynamic path searching is the process that allows the location of shared libraries to be specified at run time. In 32-bit mode, you can enable run-time dynamic path searching of shared libraries in two ways:
If +s or +b path_list is enabled, all shared libraries specified with the -llibrary or -l:library linker options are subject to a dynamic path lookup at run time. In 64-bit mode, the dynamic path searching behavior has changed:
The following are examples of specifying library paths in 32-bit and 64-bit mode:
In 64-bit mode, the dynamic loader searches shared libraries using a breadth-first search order. Breadth-first symbol searching is used on all SVR4 platforms. In 32-bit mode, the dynamic loader searches shared libraries using a depth-first search order. Figure 2-1 “Search Order of Dependent Libraries” shows an example program with shared libraries and compares the two search methods: The commands to build the libraries and the executable in Figure 2-1 “Search Order of Dependent Libraries” are shown:
In 32-bit mode, if a procedure called same_name() is defined in both lib3.sl and lib2.sl, main calls the procedure defined in lib3.sl. In 64-bit mode, main calls the procedure in lib2.sl. |
|||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
|
|||||||||||||||