public inbox for gcc@gcc.gnu.org
 help / color / mirror / Atom feed
* call frame instruction encodings ?
@ 2003-01-18 17:32 Andreas Tobler
  2003-01-18 17:32 ` David Edelsohn
  0 siblings, 1 reply; 5+ messages in thread
From: Andreas Tobler @ 2003-01-18 17:32 UTC (permalink / raw)
  To: GCC

Can anyone point me or explain me the meaning of the following snippet 
from libffi/src/powerpc/sysv.S?

       .byte     0x2f     /*  DW_CFA_GNU_negative_offset_extended */
       .byte     0x41     /*  uleb128 0x41 */
       .byte     0x1      /*  uleb128 0x1 */

I found the dwarf document explaining the DW_CFA and what they mean. But 
nothing about DW_CFA_GNU?

Any pointer would be great since I'm stuck in understanding this.

Thanks,
Andreas

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

* Re: call frame instruction encodings ?
  2003-01-18 17:32 call frame instruction encodings ? Andreas Tobler
@ 2003-01-18 17:32 ` David Edelsohn
  2003-01-18 17:57   ` Andreas Tobler
  0 siblings, 1 reply; 5+ messages in thread
From: David Edelsohn @ 2003-01-18 17:32 UTC (permalink / raw)
  To: Andreas Tobler; +Cc: GCC

>>>>> Andreas Tobler writes:


Andreas> Can anyone point me or explain me the meaning of the following snippet 
Andreas> from libffi/src/powerpc/sysv.S?

Andreas> .byte     0x2f     /*  DW_CFA_GNU_negative_offset_extended */
Andreas> .byte     0x41     /*  uleb128 0x41 */
Andreas> .byte     0x1      /*  uleb128 0x1 */

Andreas> I found the dwarf document explaining the DW_CFA and what they mean. But 
Andreas> nothing about DW_CFA_GNU?

Andreas> Any pointer would be great since I'm stuck in understanding this.

	See gcc/unwind-dw2.c:execute_cfa_program().

David

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

* Re: call frame instruction encodings ?
  2003-01-18 17:32 ` David Edelsohn
@ 2003-01-18 17:57   ` Andreas Tobler
  2003-01-18 21:13     ` Andrew Haley
  2003-01-21  7:13     ` Richard Henderson
  0 siblings, 2 replies; 5+ messages in thread
From: Andreas Tobler @ 2003-01-18 17:57 UTC (permalink / raw)
  To: David Edelsohn; +Cc: GCC

David Edelsohn wrote:
>>>>>>Andreas Tobler writes:
> 
> 
> 
> Andreas> Can anyone point me or explain me the meaning of the following snippet 
> Andreas> from libffi/src/powerpc/sysv.S?
> 
> Andreas> .byte     0x2f     /*  DW_CFA_GNU_negative_offset_extended */
> Andreas> .byte     0x41     /*  uleb128 0x41 */
> Andreas> .byte     0x1      /*  uleb128 0x1 */
> 
> Andreas> I found the dwarf document explaining the DW_CFA and what they mean. But 
> Andreas> nothing about DW_CFA_GNU?
> 
> Andreas> Any pointer would be great since I'm stuck in understanding this.
> 
> 	See gcc/unwind-dw2.c:execute_cfa_program().

case DW_CFA_GNU_negative_offset_extended:
           /* Obsoleted by DW_CFA_offset_extended_sf, but used by
              older PowerPC code.  */

In other words I should not use it when writing eh-frame info for darwin?

Is the 2.1 draft available on the net as well? I only have 2.0.0 93

Thanks,
Andreas



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

* Re: call frame instruction encodings ?
  2003-01-18 17:57   ` Andreas Tobler
@ 2003-01-18 21:13     ` Andrew Haley
  2003-01-21  7:13     ` Richard Henderson
  1 sibling, 0 replies; 5+ messages in thread
From: Andrew Haley @ 2003-01-18 21:13 UTC (permalink / raw)
  To: Andreas Tobler; +Cc: David Edelsohn, GCC

Andreas Tobler writes:
 > David Edelsohn wrote:
 > >>>>>>Andreas Tobler writes:
 > > 
 > > 
 > > 
 > > Andreas> Can anyone point me or explain me the meaning of the following snippet 
 > > Andreas> from libffi/src/powerpc/sysv.S?
 > > 
 > > Andreas> .byte     0x2f     /*  DW_CFA_GNU_negative_offset_extended */
 > > Andreas> .byte     0x41     /*  uleb128 0x41 */
 > > Andreas> .byte     0x1      /*  uleb128 0x1 */
 > > 
 > > Andreas> I found the dwarf document explaining the DW_CFA and what they mean. But 
 > > Andreas> nothing about DW_CFA_GNU?
 > > 
 > > Andreas> Any pointer would be great since I'm stuck in understanding this.
 > > 
 > > 	See gcc/unwind-dw2.c:execute_cfa_program().
 > 
 > case DW_CFA_GNU_negative_offset_extended:
 >            /* Obsoleted by DW_CFA_offset_extended_sf, but used by
 >               older PowerPC code.  */

It's a nonstandard DWARF extension invented at Cygnus.

  4.4.3 DW_CFA_GNU_negative_offset_extended (0x2f)

  This opcode takes two unsigned LEB128 operands representing a
  register number and a factored offset. This instruction is identical
  to DW_CFA_offset_extended except that the delta is in the opposite
  direction. This opcode was used on some PowerPC targets, but is
  replaced by DW_CFA_offset_extended_sf.

 > In other words I should not use it when writing eh-frame info for
 > darwin?
 
It'll still be supported for a while.  I still don't know a reason not
to copy the sysv version as long as the stack is the same.

Andrew.

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

* Re: call frame instruction encodings ?
  2003-01-18 17:57   ` Andreas Tobler
  2003-01-18 21:13     ` Andrew Haley
@ 2003-01-21  7:13     ` Richard Henderson
  1 sibling, 0 replies; 5+ messages in thread
From: Richard Henderson @ 2003-01-21  7:13 UTC (permalink / raw)
  To: Andreas Tobler; +Cc: David Edelsohn, GCC

On Sat, Jan 18, 2003 at 05:32:39PM +0100, Andreas Tobler wrote:
> case DW_CFA_GNU_negative_offset_extended:
>           /* Obsoleted by DW_CFA_offset_extended_sf, but used by
>              older PowerPC code.  */
> 
> In other words I should not use it when writing eh-frame info for darwin?

Well, I imagine we'll support it forever in the unwinder.  But there's
probably no reason _not_ to change to DW_CFA_offset_extended_sf in the
PPC backend.  We've supported DW_CFA_offset_extended_sf since gcc 3.0,
and the current unwind info isn't portable back to gcc 2.95 at all.

> Is the 2.1 draft available on the net as well? I only have 2.0.0 93

The readings page has a link.  Do recall that it's now dwarf3,
not 2.1.


r~

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

end of thread, other threads:[~2003-01-20 22:47 UTC | newest]

Thread overview: 5+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2003-01-18 17:32 call frame instruction encodings ? Andreas Tobler
2003-01-18 17:32 ` David Edelsohn
2003-01-18 17:57   ` Andreas Tobler
2003-01-18 21:13     ` Andrew Haley
2003-01-21  7:13     ` Richard Henderson

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).