Intel® Fortran Compiler
Build applications that can scale for the future with optimized code designed for Intel® Xeon® and compatible processors.
Announcements
FPGA community forums and blogs on community.intel.com are migrating to the new Altera Community and are read-only. For urgent support needs during this transition, please visit the FPGA Design Resources page or contact an Altera Authorized Distributor.
29280 Discussions

Dwarf debug info missing for variable used in contained routine

Sagan__David
Beginner
1,202 Views

Consider the following test  program:

program test
implicit none
call bmad_parserx ()
end program

!------------------------------
subroutine bmad_parserx ()
implicit none
integer zzz, kk
zzz = 2
call parser_end_stuff (.false.)
print *, zzz

!------------
contains

subroutine parser_end_stuff (do_dealloc)
logical, optional :: do_dealloc
integer i, j
zzz = 7
end subroutine parser_end_stuff 

end subroutine bmad_parserx

Compiling with debug "ifort -g test.f90 and then looking at the dwarf debug info gives:

> readelf -w a.out |grep DW_AT_name
    <10>   DW_AT_name        : (indirect string, offset: 0x22): test.f90
    <35>   DW_AT_name        : (indirect string, offset: 0x9d): test
    <4f>   DW_AT_name        : (indirect string, offset: 0xa2): bmad_parserx
    <6a>   DW_AT_name        : kk
    <78>   DW_AT_name        : (indirect string, offset: 0xba): parser_end_stuff
    <97>   DW_AT_name        : (indirect string, offset: 0xd6): do_dealloc
    <a2>   DW_AT_name        : j
    <ae>   DW_AT_name        : i
    <bc>   DW_AT_name        : (indirect string, offset: 0xaf): INTEGER(4)
    <c3>   DW_AT_name        : (indirect string, offset: 0xcb): LOGICAL(4)
    DW_AT_name         DW_FORM_strp
    DW_AT_name         DW_FORM_strp
    DW_AT_name         DW_FORM_strp
    DW_AT_name         DW_FORM_string
    DW_AT_name         DW_FORM_strp
    DW_AT_name         DW_FORM_strp
    DW_AT_name         DW_FORM_strp
 

The debug information for the variable "zzz" is missing which means that it is not possible to look at the value of zzz with a debugger. Is there any way around this? I am using ifort version 19.0.1.144 20181018. 

0 Kudos
4 Replies
Sagan__David
Beginner
1,202 Views

One year later and latest version of ifort 19.1.1.217 still has the bug. Anyone have any idea when this will be addressed?

0 Kudos
Steve_Lionel
Honored Contributor III
1,202 Views

Have you reported this using the Online Service Center? Just posting here isn't a reliable way of bringing problems to Intel's attention.

0 Kudos
Sagan__David
Beginner
1,202 Views

Yes it has been reported directly to Intel.

0 Kudos
Steve_Lionel
Honored Contributor III
1,202 Views

Good - you can use that to ask for updates.

0 Kudos
Reply