This is the mail archive of the gcc@gcc.gnu.org mailing list for the GCC 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: Proposed doc update for Explicit Reg Vars 2/3


On 10/12/2015 05:07 PM, David Wohlferd wrote:

- There are unsourced, unsubstantiated reports that on some platforms,
certain things might or might not work.
Back when this was written (circa 1996), this would have been considered helpful information -- having a system routine clobber a register unexpectedly actually did happen. Been there, done the debugging, want to forget.

Since then, system software as gotten better. And the details of what may have failed on some version of SunOS/Solaris or on the 3b1 just aren't that important anymore. So I don't mind losing that information.

- Eventually the compiler may work differently than it does now.
That is helpful. It's a way signaling that things may change and that depending on the precise syntax and semantics may be unwise.

From time to time, particularly with GCC extensions, it has been necessary to declare certain usage as invalid or to change the implementation is significantly visible ways.

We never like doing that, but it is sometimes unavoidable. As a general rule, the more an extension exposes how GCC works internally, the more likely it has been to need significant changes over time. (asms being the easiest example to cite).

So please consider keeping something which signals the semantics might change.


As for the review, perhaps reading the html is easier than reading the
patch
:-0  I think reviewing the HTML is easier.  Thanks for providing a link.

So for the example, "a5" is a particularly bad choice these days on the m68k as it's the PIC register. It may be advisable to just use r<N> for some value of N and try to be processor agnostic here.

Segher's comments are valuable as well. I think if you integrate his and mine the result ought to be ready to commit.

jeff



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