Peter Bergner wrote:
> On Fri, 2009-06-26 at 18:15 +0400, Maxim Kuvyrkov wrote:
>> The attached patch fixes PR37053
>> (
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=37053#c5).
>>
>> The problem was introduced by patch for PR28690
>> (
http://gcc.gnu.org/ml/gcc-patches/2006-12/msg00268.html, rtlanal.c
>> hunk); this hunk causes ICE on m68k (and, possibly, other) architectures.
> [snip]
>> My first impulse was to remove the pointer tweak; but, well, if PowerPC
>> really benefits from it,
>
> I will say we worked for a long time coming up with the patch we did so
> that it didn't affect other arches. In particular, HJ ran a lot of
> performance tests to make sure it didn't degrade performance on x86.
I cannot say I like Maxim's patch and he knows, but unfortunately, m68k
apparently implements 2-address arithmetic in a different way than x86
(or with other constraint) and we're talking about a lot of ICEs there. :-(
Another possibility, which you would have to try on PowerPC, could be to
limit the change of precedence to before reload. That would be a
simpler patch and one that does not risk slowing down the compiler that
tiny 0.1% that sums up quickly. But it would also be pretty magical...
Paolo