HP MLIB for PA-RISC and Itanium2 HP-UX Version 9.5 Release Note

HP MLIB for PA-RISC and Itanium® 2 HP-UX Version 9.5 Release Note
Known Problems and Workarounds
16
subprograms to be called from Fortran and C programs. For example, the MLIB BLAS error
handler XERBLA has entry points xerbla and xerbla_. Table 2 shows the Fortran 90 compiler
defaults.
Different compiler defaults can cause duplicate symbol definitions at link time as the
following examples illustrate.
PA-RISC processors
Suppose you write your own Fortran version of the XERBLA subroutine. You compile on
PA-RISC with +DA2.0W and the compiler turns on +ppu (See Table 1-2), so your xerbla.o
object file has an entry point xerbla_. However, the PA-RISC MLIB libraries were compiled
with +noppu and the entry points with underbars were added as synonyms to the entry points
without underbars. Hence, the various MLIB subprograms that call XERBLA reference them
as xerbla (without the postpended underbar). Therefore, your xerbla_ does not satisfy their
CALL XERBLA, so the linker accesses xerbla.o from the library. This file includes both entry
points xerbla and xerbla_, and xerbla_ conflicts with your XERBLA subroutine.
Use one of the following workarounds on PA-RISC if you are compiling your own Fortran
version of XERBLA:
Compile your XERBLA with +noppu. This implies that you also compile any of your
program that calls XERBLA with +noppu, and that you apply this rule recursively.
Use f90 ALIAS directives:
% !$HP$ ALIAS xerbla='xerbla'
This prevents the compiler from postpending the underbar onto the entry point and
external references for XERBLA.
This problem is not confined to the XERBLA subroutine. It occurs on PA-RISC when the
following conditions are met:
Any subprogram with the same name as a user-visible MLIB subprogram is compiled in
your program with +ppu
Another MLIB subprogram used by your program also calls that subprogram
Table 2 Compiler Defaults
32-bit
Addressing
64-bit
Addressing
PA-RISC +noppu +ppu
Itanium® +ppu +ppu