A fix is available
APAR status
Closed as program error.
Error description
When compiling the test case with xlf, xlf90 etc, the executable segfaults at runtime. ===== COMPILE COMMAND: xlf -g xlfbug.f90 ===== TESTCASE: $cat xlfbug.f90 module sub public :: xlfbug contains subroutine xlfbug(my_optarg) implicit none integer, optional, intent(in) :: my_optarg call xlfbug2(my_optarg) contains subroutine xlfbug2(my_optarg) implicit none integer, optional, intent(in) :: my_optarg write(*,*) "Hello World" end subroutine xlfbug2 end subroutine xlfbug end module sub program xlf_optarg use sub call xlfbug end program xlf_optarg $ ===== ACTUAL OUTPUT: $./a.out Memory fault(coredump) $ ===== EXPECTED OUTPUT: $ ./a.out Hello World $
Local fix
Temporary workaround: remove intent(in)
Problem summary
USERS AFFECTED: Users of XL Fortran on Linux may be affected by this issue. PROBLEM DESCRIPTION: Procedures passing a non-present optional argument to an internal procedure expecting an intent(in) optional dummy argument will fail with a segmentation fault on Linux.
Problem conclusion
The compiler has been fixed to address the above case.
Temporary fix
Comments
APAR Information
APAR number
LI75629
Reported component name
XL FORTRAN SLES
Reported component ID
5724S7400
Reported release
B10
Status
CLOSED PER
PE
NoPE
HIPER
NoHIPER
Special Attention
NoSpecatt
Submitted date
2010-07-30
Closed date
2011-02-23
Last modified date
2011-02-23
APAR is sysrouted FROM one or more of the following:
APAR is sysrouted TO one or more of the following:
LI75732 IZ86233 IZ88698 LI75789 LI75825 IZ91511 LI75929 LI75940
LI76017
Fix information
Fixed component name
XL FORTRAN SLES
Fixed component ID
5724S7400
Applicable component levels
RB10 PSY
UP
[{"Business Unit":{"code":"BU058","label":"IBM Infrastructure w\/TPS"},"Product":{"code":"SSB259","label":"XL Fortran Advanced Edition for Linux"},"Platform":[{"code":"PF025","label":"Platform Independent"}],"Version":"B.1","Line of Business":{"code":"LOB57","label":"Power"}}]
Document Information
Modified date:
24 February 2022