This is the mail archive of the ecos-discuss@sources.redhat.com mailing list for the eCos 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: help using GDB


Ecos Temp wrote:
> 
> questions on gdb:
> - why is there 2 threads?
> 0x00013c38 in ?? ()
> (gdb) info threads
>   2 Thread 2 ( Name: main, State: ready, Priority: 10 )  0x00011650 in ?? ()
> * 1 Thread 1 ( Name: Idle Thread, State: running, Priority: 31 )  0x00013c38
> in
> ?? ()
> (gdb)

The main thread is a thread created to call main() - the normal entry point
of a standard C program. If you haven't supplied a main(), it will just
exit straight away. You can turn it off in the libc startup package.

The idle thread is a special kernel thread that exists so that the kernel
always has something to do. It simplifies the code.


> Also I load a program hello and use cont, nothing displays ie "Hello", but I
> control C out from gdb, and start a terminal session over com1, and the
> redboot prompt appears.  Any clues?
> - Loading section .rom_vectors, size 0x40 lma 0x40000
> Loading section .text, size 0xc7d0 lma 0x40040
> Loading section .rodata, size 0x459 lma 0x4c810
> Loading section .data, size 0x484 lma 0x4cc6c
> Start address 0x40040, load size 53485
> Transfer rate: 25169 bits/sec, 303 bytes/write.
> (gdb) cont
> Continuing.

You'll need to show the code you used and how you compiled it!

Jifl
-- 
Red Hat, Rustat House, Clifton Road, Cambridge, UK. Tel: +44 (1223) 271062
--[ "You can complain because roses have thorns, or you ]--
--[  can rejoice because thorns have roses." -Lincoln   ]-- Opinions==mine

-- 
Before posting, please read the FAQ: http://sources.redhat.com/fom/ecos
and search the list archive: http://sources.redhat.com/ml/ecos-discuss


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