This is the mail archive of the
gcc-patches@gcc.gnu.org
mailing list for the GCC project.
Re: [PING] [PATCH] Fix asm X constraint (PR inline-asm/59155)
- From: Jakub Jelinek <jakub at redhat dot com>
- To: Jeff Law <law at redhat dot com>
- Cc: Vladimir Makarov <vmakarov at redhat dot com>, Bernd Edlinger <bernd dot edlinger at hotmail dot de>, "gcc-patches at gcc dot gnu dot org" <gcc-patches at gcc dot gnu dot org>, Richard Biener <rguenther at suse dot de>
- Date: Mon, 6 Jun 2016 20:01:28 +0200
- Subject: Re: [PING] [PATCH] Fix asm X constraint (PR inline-asm/59155)
- Authentication-results: sourceware.org; auth=none
- References: <AM4PR07MB157116B6325547B97D4C148CE4400 at AM4PR07MB1571 dot eurprd07 dot prod dot outlook dot com> <AM4PR07MB157148DEF55A9C540991A296E45C0 at AM4PR07MB1571 dot eurprd07 dot prod dot outlook dot com> <5755AD05 dot 4010608 at redhat dot com> <b143b78e-688d-b1b4-4094-9c8ebd50b1ea at redhat dot com>
- Reply-to: Jakub Jelinek <jakub at redhat dot com>
On Mon, Jun 06, 2016 at 11:54:04AM -0600, Jeff Law wrote:
> >As for recog.c, I can not approve this as I am not a maintainer of it.
> >I only can say that the code looks questionable to me.
> I think the question on the recog part is a matter of how we choose to
> interpret what the "X" constraint means.
>
> Does it literally mean accept anything, or accept some subset expressions?
>
> I tend to think the former, which means that things like
> reg_overlap_mentioned_p or its callers have to be bullet-proofed.
I think it is a bad idea to accept really anything, even for debug insns,
which initially accepted arbitrarily large RTL expressions (and still accept
stuff like subregs otherwise considered invalid etc.) we found it is highly
undesirable, as it is not very good idea for the compile time complexity
etc., so now we are trying to limit the complexity of the expressions there
by splitting up more complex expressions into smaller ones using temporaries.
So, even accept anything should always be accept anything reasonable,
because most of the RTL passes don't really expect arbitrarily deep
expressions, or expressions where the same reg can appear thousands of times
etc.
Jakub