This is the mail archive of the rda@sources.redhat.com mailing list for the rda 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 required on rda [FRV]


Vinu Dev <vinudev@gmail.com> writes:
> Dear JimB,
>  Thanks for your reply,iam using LinuxThreads,its my requirement to
> use linuxthreads.
>    Even i was surprised by the delay factor,is there any other way to
> measure the thread creation time more precise than using
> gettimeofday() system call,if u could advice me on this,i would be
> very much thankfull to you.
>   The delay is around 4-5 secs for each thread creation via rda.
>  Is there any article or technical documents or could u guide me to
> know  the cause for this delay?

4-5 seconds sounds about right.  If I remember correctly, it's due to
libthread_db's need to read huge amounts of memory from the program
being debugged each time it stops.

Take a look at rda/unix/linux-target.c:linux_process_rcmd.  That's the
function that gets called when you give GDB the "monitor" command.  So

        (gdb) monitor 1

(I think) should turn on debugging output in RDA, and

        (gdb) monitor 0

should turn it off.  If you'd like to be able to do other things to
RDA, you can add more stuff to linux_process_rcmd.

In any case, after 'monitor 1', RDA will print messages describing
all the ptrace calls it makes.  If I'm right, you'll see a *lot* of
ptrace traffic during those 4-5 seconds.

You might also try changing the initialization of thread_db_noisy to
1, to see more of what thread_db.c is doing.

Good luck!


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