set debug entry point

Joel Sherrill
Sun Apr 7 14:31:00 GMT 2013

On 04/07/2013 09:21 AM, ishare wrote:
>     If one elf has no main , where does gdb start  to trace it ?
Every program has a starting point. main() is just the first
user provided code that runs in a C program.  Set up
and initialization code has run before that.

When the program was linked, it could have used a linker
directive or the ld --entry argument to specify the entry
>     is there mothod to tell gdb start at specified address?
gdb should start the program at the entry address. You
can always set the program counter directly using
something like set $pc XXX but that is architecture
>     tks!

Joel Sherrill, Ph.D.             Director of Research& Development        On-Line Applications Research
Ask me about RTEMS: a free RTOS  Huntsville AL 35806
Support Available               (256) 722-9985

More information about the Gdb mailing list