Mirror of the gdb-patches mailing list
 help / color / mirror / Atom feed
* [rfa/doco] FRAME_FP -> read_fp
@ 2002-11-19 12:00 Andrew Cagney
  2002-11-19 21:59 ` Eli Zaretskii
  0 siblings, 1 reply; 5+ messages in thread
From: Andrew Cagney @ 2002-11-19 12:00 UTC (permalink / raw)
  To: gdb-patches

[-- Attachment #1: Type: text/plain, Size: 128 bytes --]

Hello,

This patch updates the doco so that it better reflects GDB's current 
implementation of create_new_frame().

ok?
Andrew

[-- Attachment #2: diffs --]
[-- Type: text/plain, Size: 942 bytes --]

2002-11-19  Andrew Cagney  <ac131313@redhat.com>

	* gdbint.texinfo (Algorithms): Replace FRAME_FP with read_fp.

Index: gdbint.texinfo
===================================================================
RCS file: /cvs/src/src/gdb/doc/gdbint.texinfo,v
retrieving revision 1.107
diff -u -r1.107 gdbint.texinfo
--- gdbint.texinfo	26 Oct 2002 17:19:28 -0000	1.107
+++ gdbint.texinfo	19 Nov 2002 19:58:05 -0000
@@ -234,13 +234,13 @@
 and called functions.
 
 @findex create_new_frame
-@vindex FRAME_FP
-@code{FRAME_FP} in the machine description has no meaning to the
+@vindex read_fp
+@code{read_fp} in the machine description has no meaning to the
 machine-independent part of @value{GDBN}, except that it is used when
 setting up a new frame from scratch, as follows:
 
 @smallexample
-create_new_frame (read_register (FP_REGNUM), read_pc ()));
+create_new_frame (read_fp (), read_pc ()));
 @end smallexample
 
 @cindex frame pointer register

^ permalink raw reply	[flat|nested] 5+ messages in thread

* Re: [rfa/doco] FRAME_FP -> read_fp
  2002-11-19 12:00 [rfa/doco] FRAME_FP -> read_fp Andrew Cagney
@ 2002-11-19 21:59 ` Eli Zaretskii
  2002-11-20  8:26   ` Andrew Cagney
  0 siblings, 1 reply; 5+ messages in thread
From: Eli Zaretskii @ 2002-11-19 21:59 UTC (permalink / raw)
  To: Andrew Cagney; +Cc: gdb-patches


On Tue, 19 Nov 2002, Andrew Cagney wrote:

> This patch updates the doco so that it better reflects GDB's current 
> implementation of create_new_frame().
> 
> ok?

Ahm, what does this mean, exactly, "read_fp in the machine description"?  
Isn't read_fp a function?  If so, how can it be present ``in the machine 
description''?

In case it isn't clear, I refer to this text:

  +@code{read_fp} in the machine description has no meaning


^ permalink raw reply	[flat|nested] 5+ messages in thread

* Re: [rfa/doco] FRAME_FP -> read_fp
  2002-11-19 21:59 ` Eli Zaretskii
@ 2002-11-20  8:26   ` Andrew Cagney
  2002-11-20  9:20     ` Eli Zaretskii
  0 siblings, 1 reply; 5+ messages in thread
From: Andrew Cagney @ 2002-11-20  8:26 UTC (permalink / raw)
  To: Eli Zaretskii; +Cc: gdb-patches

> On Tue, 19 Nov 2002, Andrew Cagney wrote:
> 
> 
>> This patch updates the doco so that it better reflects GDB's current 
>> implementation of create_new_frame().
>> 
>> ok?
> 
> 
> Ahm, what does this mean, exactly, "read_fp in the machine description"?  
> Isn't read_fp a function?  If so, how can it be present ``in the machine 
> description''?

regcache.c contains:

CORE_ADDR
read_fp (void)
{
   return TARGET_READ_FP ();
}

and TARGET_READ_FP() is part of the machine description (a.k.a. 
architecture vector).


> In case it isn't clear, I refer to this text:
> 
>   +@code{read_fp} in the machine description has no meaning

The full text is:

> @findex create_new_frame
> @vindex read_fp
> @code{read_fp} in the machine description has no meaning to the
> machine-independent part of @value{GDBN}, except that it is used when
> setting up a new frame from scratch, as follows:
> 
> @smallexample
> create_new_frame (read_fp (), read_pc ()));
> @end smallexample

And the only change I made was to update things to refer to read_fp() 
instead of FRAME_FP().  The description is correct.  As far as the 
machine independant code is concerned, read_fp() returns a magic number.

The text then goes on to mention:

> @cindex frame pointer register
> Other than that, all the meaning imparted to @code{FP_REGNUM} is
> imparted by the machine-dependent code.  So, @code{FP_REGNUM} can have
> any value that is convenient for the code that creates new frames.
> (@code{create_new_frame} calls @code{INIT_EXTRA_FRAME_INFO} if it is
> defined; that is where you should use the @code{FP_REGNUM} value, if
> your frames are nonstandard.)

Hmm, I guess this could do with a similar s/FP_REGNUM/read_fp/ 
transformation?

Andrew



^ permalink raw reply	[flat|nested] 5+ messages in thread

* Re: [rfa/doco] FRAME_FP -> read_fp
  2002-11-20  8:26   ` Andrew Cagney
@ 2002-11-20  9:20     ` Eli Zaretskii
  2003-01-29 15:49       ` Andrew Cagney
  0 siblings, 1 reply; 5+ messages in thread
From: Eli Zaretskii @ 2002-11-20  9:20 UTC (permalink / raw)
  To: ac131313; +Cc: gdb-patches

> Date: Wed, 20 Nov 2002 11:25:43 -0500
> From: Andrew Cagney <ac131313@redhat.com>
> > 
> > Ahm, what does this mean, exactly, "read_fp in the machine description"?  
> > Isn't read_fp a function?  If so, how can it be present ``in the machine 
> > description''?
> 
> regcache.c contains:
> 
> CORE_ADDR
> read_fp (void)
> {
>    return TARGET_READ_FP ();
> }
> 
> and TARGET_READ_FP() is part of the machine description (a.k.a. 
> architecture vector).

Yes, but still I find it confusing to tell that a function is in the
machine description.  A machine description is a bunch of macros and
machine-specific functions, right?  And read_fp is neither of these,
right?

> Hmm, I guess this could do with a similar s/FP_REGNUM/read_fp/ 
> transformation?

Probably.


^ permalink raw reply	[flat|nested] 5+ messages in thread

* Re: [rfa/doco] FRAME_FP -> read_fp
  2002-11-20  9:20     ` Eli Zaretskii
@ 2003-01-29 15:49       ` Andrew Cagney
  0 siblings, 0 replies; 5+ messages in thread
From: Andrew Cagney @ 2003-01-29 15:49 UTC (permalink / raw)
  To: Eli Zaretskii; +Cc: gdb-patches

Really old thread:

Eli, I'm dropping this patch.  Instead, I'm doing the full rewrite.

Andrew

>> Date: Wed, 20 Nov 2002 11:25:43 -0500
>> From: Andrew Cagney <ac131313@redhat.com>
> 
>> > 
>> > Ahm, what does this mean, exactly, "read_fp in the machine description"?  
>> > Isn't read_fp a function?  If so, how can it be present ``in the machine 
>> > description''?
> 
>> 
>> regcache.c contains:
>> 
>> CORE_ADDR
>> read_fp (void)
>> {
>>    return TARGET_READ_FP ();
>> }
>> 
>> and TARGET_READ_FP() is part of the machine description (a.k.a. 
>> architecture vector).
> 
> 
> Yes, but still I find it confusing to tell that a function is in the
> machine description.  A machine description is a bunch of macros and
> machine-specific functions, right?  And read_fp is neither of these,
> right?
> 
> 
>> Hmm, I guess this could do with a similar s/FP_REGNUM/read_fp/ 
>> transformation?
> 
> 
> Probably.
> 



^ permalink raw reply	[flat|nested] 5+ messages in thread

end of thread, other threads:[~2003-01-29 15:49 UTC | newest]

Thread overview: 5+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2002-11-19 12:00 [rfa/doco] FRAME_FP -> read_fp Andrew Cagney
2002-11-19 21:59 ` Eli Zaretskii
2002-11-20  8:26   ` Andrew Cagney
2002-11-20  9:20     ` Eli Zaretskii
2003-01-29 15:49       ` Andrew Cagney

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox