This is the mail archive of the gdb@sourceware.org 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]

Re: Why does gdb implement 'next' command with a series of "vCont;s"?


On Mon, Jul 30, 2007 at 01:37:33PM +0800, congli wrote:
>  My question is, when I issue the 'next' command, gdb already
>  know the 'step_range_end' is 0x804836f, why not implement the
>  'next' command by set a breakpoint at 0x804836f and then issue
>  "vCont;c"? When the program meet the breakpoint at 0x804836f,
>  we can do a single "vCont;s" to the first instruction of
>  line 7, 0x8048372.

GDB does not know what the instructions between here and there do.
One of them might be a branch or a function call.

-- 
Daniel Jacobowitz
CodeSourcery


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