This is the mail archive of the gdb-prs@sources.redhat.com 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: gdb/1799: $fp is not a left value, would be useful to be


The following reply was made to PR gdb/1799; it has been noted by GNATS.

From: Samuel Thibault <samuel.thibault@ens-lyon.org>
To: Daniel Jacobowitz <drow@false.org>
Cc: gdb-gnats@sources.redhat.com
Subject: Re: gdb/1799: $fp is not a left value, would be useful to be
Date: Sat, 27 Nov 2004 18:22:28 +0100

 Le ven 29 oct 2004 à 22:12:14 -0400, Daniel Jacobowitz a tapoté sur son clavier :
 > On Wed, Oct 27, 2004 at 12:16:40PM -0000, samuel.thibault@ens-lyon.org wrote:
 > > I'm writing some context-switching functions, and can't get a way to
 > > arch-independantly write in $fp register:
 > 
 > Could you explain a little better what it is that you are trying to do?
 
 I am trying to debug a user-level thread library which stores contextes
 in a jmp_buf structure. Gdb's info threads command isn't aware of
 such threads of course, but by altering registers by hand (esp,
 eip and ebp on x86), one can be able to switch between different
 user-level threads (though in practice it doesn't work really well, gdb
 almost always crashes on the second switch).
 
 > $fp doesn't have an architecture-independant meaning; in many cases it
 > is computed, not a register at all.
 
 Hum, indeed.
 Could there be any architecture-independant way of achieving context
 switches by hand ? (sort of longjmp, but without actually continuing the
 program)
 
 Regards,
 Samuel Thibault


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