This is the mail archive of the dwarf2@corp.sgi.com mailing list for the dwarf2 project.


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

Re: REVISED PROPOSAL 000519.1 re Factored Offsets [joint with Keith]



>Note that the first two of these, DW_CFA_offset and DW_CFA_offset_extended,
>use the phrase "factored offset" in their description while the latter two,
>DW_CFA_def_cfa and DW_CFA_def_cfa_offset, use only "offset" (omitting
>the word "factored").
>
>This difference in wording has lead to divergent implementations.
>
>   - Some implementions treat all four instructions as using factored
>     offsets. Known examples are ARM's compiler for ARM, TI's compiler
>     for ARM, SGI's compiler(s) for MIPS, Aonix's ObjectAda compiler.

	SGI's compilers for MIPS do *not* fit in the above category.

>   - Some implementation treat only DW_CFA_offset and DW_CFA_offset_extended
>     as using factored offsets, which unfactored offsets are used for
>     DW_CFA_def_cfa and DW_CFA_def_cfa_offset. Know examples are gcc
>     and Compaq's compilers for Alpha.

	SGI's compilers for MIPS fit in this second category with gcc.

>At issue is whether the difference in wording is intentional and intended
>to define different handling or whether the difference in wording is
>accidental and there should be no difference in handling.

SGI/gcc are *using* the fact that the DW_CFA_def_cfa_offset and
DW_CFA_def_cfa is positive and the factor is negative.  Without
this the existing offsets and cfa setups on MIPS don't work
because sgi uses a positive DW_CFA_def_cfa_offset (from the sp
register value) and a negative (before factoring out a -4)
DW_CFA_offset (from the CFA value).

These comments should not be construed as an argument in favor
of the sgi/gcc interpretation but simply as clarification.

davea@sgi.com

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