This is the mail archive of the gdb-prs@sources.redhat.com mailing list for the GDB project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

breakpoints/1425: problem with stepping on IA64


>Number:         1425
>Category:       breakpoints
>Synopsis:       problem with stepping on IA64
>Confidential:   no
>Severity:       serious
>Priority:       medium
>Responsible:    unassigned
>State:          open
>Class:          sw-bug
>Submitter-Id:   net
>Arrival-Date:   Wed Oct 22 06:38:00 UTC 2003
>Closed-Date:
>Last-Modified:
>Originator:     sana@stl.sarov.ru
>Release:        unknown-1.0
>Organization:
>Environment:
64 bit Linux, United Linux 1.0
>Description:
There is no problem on IA32.
There is no problem with IDB on IA64 also.

Test is very simple 
! test array pointer in main scope (whole array target)
        program test
        integer, pointer :: ip(:,:)
        integer, target :: i(1,5),j(1,4)
        i = reshape((/(10*k,k=1,5)/), (/1,5/))
        ip => i
        print *,'ip: ',ip
        j = reshape((/(k,k=1,4)/), (/1,4/))
        ip => j
        print *,'ip: ',ip
        end

But there are some problem for GDB with lines 7,8,9,10.

When user sets breakpoint to all these lines then it is Ok:
(gdb) r
Starting program: /home/sana/tmp/gdbF/opt_none_debug_64/tr36532.exe 
[New Thread 1024 (LWP 27514)]
[Switching to Thread 1024 (LWP 27514)]

Breakpoint 1, test () at tr36532.f:5
5               i = reshape((/(10*k,k=1,5)/), (/1,5/))
Current language:  auto; currently fortran
(gdb) b 7
Breakpoint 2 at 0x4000000000004001: file tr36532.f, line 7.
(gdb) c
Continuing.

Breakpoint 2, test () at tr36532.f:7
7               print *,'ip: ',ip
(gdb) b 8
Breakpoint 3 at 0x40000000000049f0: file tr36532.f, line 8.
(gdb) b 9
Breakpoint 4 at 0x4000000000004f00: file tr36532.f, line 9.
(gdb) b 10
Breakpoint 5 at 0x40000000000050e1: file tr36532.f, line 10.
(gdb) b 11
Breakpoint 6 at 0x4000000000005ad0: file tr36532.f, line 11.
(gdb) c
Continuing.
 ip:            1           2           3           4

Breakpoint 6, test () at tr36532.f:11
11              end

(gdb) n
 ip:           10          20          30          40          50

Breakpoint 3, test () at tr36532.f:8
8               j = reshape((/(k,k=1,4)/), (/1,4/))
(gdb) n

Breakpoint 4, test () at tr36532.f:9
9               ip => j


But if user steps line by line then program exits after line 7:

(gdb) b test
Breakpoint 1 at 0x40000000000038b1: file tr36532.f, line 5.
(gdb) r
Starting program: /home/sana/tmp/gdbF/opt_none_debug_64/tr36532.exe 
[New Thread 1024 (LWP 27642)]
[Switching to Thread 1024 (LWP 27642)]

Breakpoint 1, test () at tr36532.f:5
5               i = reshape((/(10*k,k=1,5)/), (/1,5/))
Current language:  auto; currently fortran
(gdb) b 7
Breakpoint 2 at 0x4000000000004001: file tr36532.f, line 7.
(gdb) c
Continuing.

Breakpoint 2, test () at tr36532.f:7
7               print *,'ip: ',ip
(gdb) n
 ip:           10          20          30          40          50
 ip:            1           2           3           4

Program exited normally.
(gdb) q   

IDB works correctly with the same executable file in both cases.
>How-To-Repeat:
It is necessary to use Intel Compiler 8.0.
Command line is 'ifort -g test.f90'.
Regression test is:
! test array pointer in main scope (whole array target)
        program test
        integer, pointer :: ip(:,:)
        integer, target :: i(1,5),j(1,4)
        i = reshape((/(10*k,k=1,5)/), (/1,5/))
        ip => i
        print *,'ip: ',ip
        j = reshape((/(k,k=1,4)/), (/1,4/))
        ip => j
        print *,'ip: ',ip
        end
>Fix:

>Release-Note:
>Audit-Trail:
>Unformatted:


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]