This is the mail archive of the mailing list for the Archer 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]

froggy/archer -- 2009-02-24

Well, there's good news and there's bad news.

The good news is that the re-write I've been doing to more efficiently
incorporate froggy into gdb is done.

The bad news is that I've hit a brick wall.

Here's the deal:

utrace provides two classes of capabilities.  One is a subset of the
standard ptrace() stuff attaching/detaching processes, stopping and
continuing them, and examining/setting registers.  The other is a
waitpid()-like capability of reacting to various events in attached
processes--life-cycle changes like clone, exit and death; the arrival of
signals; and entry into and exit from syscalls.  All of that is
asynchronous and froggy deals with the asynchronicity by being
explicitly dual-threaded, one thread for the ptrace()-like capabilities,
the other spinning on a blocking waitpid()-like thing and reporting
stuff to the application via callbacks.

The problem is that there's no way to fit that dual-thread/callback
paradigm into existing gdb--I've been tearing my hair out for a couple
of weeks trying to make it happen.  The result of all this is that while
I can replace ptrace() calls with froggy calls, I'm stuck with the
existing waitpid() stuff in gdb, and that's pretty much useless.  Under
the covers, ptrace() is already utrace-based--part of Roland's utrace
kernel patch does that.  So, without being able to use froggy's
event-catching capability, all I'm left with is the same capabilities as
utrace-under-ptrace, but a lot less efficiently--the ptrace() syscall
vs. froggy's /sys/kernel/debug pseudo-file i/o.

(All this, by the way, is exactly the problem I ran into in frysk and
neither Andrew Cagney or I could make it work.  I was kinda hoping that,
since gdb is better structured than frysk was, the problem would be less
intractable.  It wasn't.)

I'm going to back off and think about this some more--maybe something
will occur to me--but meanwhile I'll return to what I was doing a couple
of months ago, stuffing IBM's user-breakpoint code, ubp, into froggy.

Chris Moller

  I know that you believe you understand what you think I said, but
  I'm not sure you realize that what you heard is not what I meant.
      -- Robert McCloskey

Attachment: signature.asc
Description: OpenPGP digital signature

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