From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 27938 invoked by alias); 11 Apr 2013 23:56:44 -0000 Mailing-List: contact gdb-prs-help@sourceware.org; run by ezmlm Precedence: bulk List-Id: List-Subscribe: List-Archive: List-Post: List-Help: , Sender: gdb-prs-owner@sourceware.org Received: (qmail 27913 invoked by uid 48); 11 Apr 2013 23:56:44 -0000 From: "dje at google dot com" To: gdb-prs@sourceware.org Subject: [Bug breakpoints/15360] can't step into function Date: Thu, 11 Apr 2013 23:56:00 -0000 X-Bugzilla-Reason: CC X-Bugzilla-Type: changed X-Bugzilla-Watch-Reason: None X-Bugzilla-Product: gdb X-Bugzilla-Component: breakpoints X-Bugzilla-Keywords: X-Bugzilla-Severity: normal X-Bugzilla-Who: dje at google dot com X-Bugzilla-Status: NEW X-Bugzilla-Priority: P2 X-Bugzilla-Assigned-To: unassigned at sourceware dot org X-Bugzilla-Target-Milestone: --- X-Bugzilla-Changed-Fields: Message-ID: In-Reply-To: References: X-Bugzilla-URL: http://sourceware.org/bugzilla/ Auto-Submitted: auto-generated Content-Type: text/plain; charset="UTF-8" MIME-Version: 1.0 X-SW-Source: 2013-q2/txt/msg00041.txt.bz2 http://sourceware.org/bugzilla/show_bug.cgi?id=15360 --- Comment #1 from dje at google dot com 2013-04-11 23:56:44 UTC --- gdb is putting the step-resume bkpt at the wrong place. (gdb) disas function Dump of assembler code for function function(): 0x00000000004004b4 <+0>: push %rbp 0x00000000004004b5 <+1>: mov %rsp,%rbp 0x00000000004004b8 <+4>: push %r12 0x00000000004004ba <+6>: push %rbx 0x00000000004004bb <+7>: sub $0x10,%rsp 0x00000000004004bf <+11>: jmp 0x4004c2 0x00000000004004c1 <+13>: nop 0x00000000004004c2 <+14>: movl $0x0,-0x18(%rbp) 0x00000000004004c9 <+21>: mov -0x18(%rbp),%eax 0x00000000004004cc <+24>: add $0x4,%eax 0x00000000004004cf <+27>: mov %eax,-0x14(%rbp) 0x00000000004004d2 <+30>: mov $0x1,%r12d 0x00000000004004d8 <+36>: mov $0x1,%ebx 0x00000000004004dd <+41>: lea -0x20(%rbp),%rax 0x00000000004004e1 <+45>: mov %rax,%rdi 0x00000000004004e4 <+48>: callq 0x400514 0x00000000004004e9 <+53>: test %ebx,%ebx 0x00000000004004eb <+55>: je 0x4004c1 0x00000000004004ed <+57>: mov %r12d,%eax 0x00000000004004f0 <+60>: add $0x10,%rsp 0x00000000004004f4 <+64>: pop %rbx 0x00000000004004f5 <+65>: pop %r12 0x00000000004004f7 <+67>: pop %rbp 0x00000000004004f8 <+68>: retq End of assembler dump. ... Temporary breakpoint 2, main (argc=1, argv=0x7fffffffe848) at foo.c:23 23 function(); (gdb) s infrun: clear_proceed_status_thread (process 20005) infrun: proceed (addr=0xffffffffffffffff, signal=144, step=1) infrun: resume (step=1, signal=0), trap_expected=0, current thread [process 20005] at 0x400508 infrun: wait_for_inferior () infrun: target_wait (-1, status) = infrun: 20005 [process 20005], infrun: status->kind = stopped, signal = SIGTRAP infrun: infwait_normal_state infrun: TARGET_WAITKIND_STOPPED infrun: stop_pc = 0x4004b4 infrun: stepped into subroutine infrun: inserting step-resume breakpoint at 0x4004c1 infrun: resume (step=0, signal=0), trap_expected=0, current thread [process 20005] at 0x4004b4 infrun: prepare_to_wait infrun: target_wait (-1, status) = infrun: 20005 [process 20005], infrun: status->kind = exited, status = 0 infrun: infwait_normal_state infrun: TARGET_WAITKIND_EXITED [Inferior 1 (process 20005) exited normally] infrun: stop_stepping -- Configure bugmail: http://sourceware.org/bugzilla/userprefs.cgi?tab=email ------- You are receiving this mail because: ------- You are on the CC list for the bug.