On 11/09/18 23:42, Jeff Law wrote:
This feels like you're papering over a problem in regrename and/or the
GCN port.. regrename should be checking the predicate and constraints
when it makes changes. And I think that you're still allowed to refer
to a fixed register in alternatives.
I think you're allowed to use a constraint to match an already-present
hardreg, fixed or otherwise, but my understanding is that LRA will never
convert a pseudoreg to a fixed hardreg, no matter what the constraint says.
Just to make sure, I just tried to fix EXEC (the only register matching
the "e" constraint, and one of the "special" ones), and as expected the
compiler blows up with "unable to generate reloads for ...".
Anyway, back to the issue of SPECIAL_REGNO_P ...
I've just retested the motivating example that we had, and that no
longer fails in regrename. That could be because the problem is fixed,
or simply that the compiler no longer generates the exact instruction
sequence that demonstrates the problem.
If I can't reproduce the issue then this macro becomes just a small
compile-time optimization and we can remove it safely.
I'll report back when I've done more testing.
Andrew