This is the mail archive of the
gcc-patches@gcc.gnu.org
mailing list for the GCC project.
Re: asm constraint rule change
- To: Andi Kleen <ak at muc dot de>
- Subject: Re: asm constraint rule change
- From: Horst von Brand <vonbrand at sleipnir dot valparaiso dot cl>
- Date: Sun, 18 Oct 1998 18:31:14 -0400
- cc: law at cygnus dot com, Richard Henderson <rth at cygnus dot com>, crux at pool dot informatik dot rwth-aachen dot de, egcs-patches at cygnus dot com
Andi Kleen <ak@muc.de> said:
> In article <17150.908609572@hurl.cygnus.com>,
> Jeffrey A Law <law@cygnus.com> writes:
> > In message <19981016193609.A4141@dot.cygnus.com>you write:
> >> The recent asm checking patches have tightened the rules such that output
> >> constraints like "r=" are no longer valid. The problem is that there is
> >> a largish body of code that writes things that way. More to the point,
> >> despite all the examples running about the documentation, it does not ever
> >> come out and specify this as a rule. It merely says
> >>
> >> ... all output operands' constraints must use `='.
> >>
> >> So this change is gonna piss some folks off, and with reason.
> >>
> >> I suggest we adopt the following patch to loosen this rule again.
> >> * stmt.c (expand_asm_operands): Accept `=' or `+' at any position.
> > How about let's make it a warning instead of a hard error.
> > I wouldn't be suprised if some code handles them wrong if the '=' or
> > '+' are not first. We need to get folks to fix their code.
> Richard's patch moves them automagically to the beginning (with the bcopy).
> Don't you think that is enough, why bother the programmer with another
> warning if the compiler can fix it without problems? Also the requirement
> wasn't documented.
Better force people to do it _right_ than add "just another tiny special
case fix" to gcc. Note that many people are turned away from gcc as it
stands, claiming it's just a gigantic mess.
Just my 2 cents.
--
Horst von Brand vonbrand@sleipnir.valparaiso.cl
Casilla 9G, Viņa del Mar, Chile +56 32 672616