[PATCH][RTL-ifcvt] PR rtl-optimization/67465: Handle pairs of complex+simple blocks and empty blocks more gracefully
Kyrill Tkachov
kyrylo.tkachov@arm.com
Thu Sep 10 14:52:00 GMT 2015
On 10/09/15 12:43, Rainer Orth wrote:
> Hi Kyrill,
>
>> Rainer, could you please check that this patch still fixes the SPARC
>> regressions?
> unfortunately, it breaks sparc-sun-solaris2.10 bootstrap: compiling
> stage2 libiberty/regex.c FAILs:
>
>
Thanks for providing the preprocessed file.
I've reproduced and fixed the ICE in this version of the patch.
The problem was that I was taking the mode of x before the check
of whether a and b are MEMs, after which we would change x to an address_mode reg,
thus confusing emit_move_insn.
The fix is to take the mode of x and perform the can_conditionally_move_p check
after that transformation.
Bootstrapped and tested on aarch64 and x86_64.
The preprocessed regex.i that Rainer provided now compiles successfully for me
on a sparc-sun-solaris2.10 stage-1 cross-compiler.
Rainer, thanks for your help so far, could you please try out this patch?
Thanks,
Kyrill
2015-09-10 Kyrylo Tkachov <kyrylo.tkachov@arm.com>
PR rtl-optimization/67456
PR rtl-optimization/67464
PR rtl-optimization/67465
PR rtl-optimization/67481
* ifcvt.c (noce_try_cmove_arith): Bail out if cannot conditionally
move in the mode of x. Handle combination of complex and simple
block pairs as well as the case when one is empty.
2015-09-10 Kyrylo Tkachov <kyrylo.tkachov@arm.com>
* gcc.dg/pr67465.c: New test.
-------------- next part --------------
A non-text attachment was scrubbed...
Name: ifcvt-bug-fix.patch
Type: text/x-patch
Size: 2383 bytes
Desc: not available
URL: <http://gcc.gnu.org/pipermail/gcc-patches/attachments/20150910/8d7c21ad/attachment.bin>
More information about the Gcc-patches
mailing list