This is the mail archive of the
gcc-patches@gcc.gnu.org
mailing list for the GCC project.
Re: define_constraints patch, revised
- From: Joern RENNECKE <joern dot rennecke at st dot com>
- To: Bernd Schmidt <bernds_cb1 at t-online dot de>
- Cc: Zack Weinberg <zackw at panix dot com>, GCC Patches <gcc-patches at gcc dot gnu dot org>
- Date: Wed, 22 Feb 2006 17:35:47 +0000
- Subject: Re: define_constraints patch, revised
In http://gcc.gnu.org/ml/gcc-patches/2006-02/msg01723.html, you wrote:
>> Hmm, do you mean the situation where one constraint name is a proper
>> prefix of another, or where there's an actual ambiguous operand
constraint?
> The former would be nice, but the latter would be wonderful. I admit
> I haven't actually thought much about how difficult it would be to
> implement - there must be Well Known Algorithms for this kind of thing.
Yes, this can be reduced to the problem of determining if a context-free
grammer is in LR(k), where k could be chosen as the longest
define_constraint
matching string length.
However, that is a rather costly test:
http://portal.acm.org/citation.cfm?id=361227.361232