This is the mail archive of the
gcc-patches@gcc.gnu.org
mailing list for the GCC project.
Re: [PING] Target hook for rewriting inline asm constraints
- From: Tom Tromey <tromey at redhat dot com>
- To: "Andreas Krebbel" <Andreas dot Krebbel at de dot ibm dot com>
- Cc: gcc-patches at gcc dot gnu dot org
- Date: Wed, 31 Oct 2007 08:57:15 -0600
- Subject: Re: [PING] Target hook for rewriting inline asm constraints
- References: <20071030115424.GA6864@homer.boeblingen.de.ibm.com>
- Reply-to: tromey at redhat dot com
>>>>> "Andreas" == Andreas Krebbel <Andreas.Krebbel@de.ibm.com> writes:
Andreas> could a C front end and/or middle end maintainer please have
Andreas> a look at this one:
Andreas> http://gcc.gnu.org/ml/gcc-patches/2007-10/msg01407.html
I'm not an FE or ME maintainer but I took a look anyway.
I only looked at the mechanics of the change, since I really don't
know whether it is desirable or not.
Wouldn't the C++ FE need a similar patch? And, if so, why do this
work in the front ends rather than somewhere more generic? Or, if the
FE is really the way to go, perhaps a helper function in c-common.c
would be better.
I saw a few coding standard violations in the code.
* Repeated use of strlen in the loop (use an output index)
* Assignments in conditional expressions (frowned on by GNU standards;
in any case the comma operators seemed gratuitous to me)
* No braces around body of do-while.
* Hard-coded lengths without bounds checking (this one is questionable
I suppose)
Tom