[PATCH GCC]Try harder to find base object by expanding base address

Bin Cheng Bin.Cheng@arm.com
Fri Oct 13 15:05:00 GMT 2017


Hi,
I ran into this when investigating PR82369 which we failed to find base object.
This simple patch tries harder to find base object by expanding base address
in alloc_iv.  In general, we don't want to do aggressive expansion, but this
case is fine because finding base object means reduction happened during the
expansion.  And it's good to have base object for address type iv_uses.
Bootstrap and test on x86_64 and AArch64.  Is it OK?

Thanks,
bin
2017-10-12  Bin Cheng  <bin.cheng@arm.com>

	* tree-scalar-evolution.c (alloc_iv): New parameter controlling
	base expansion for finding base object.
	(find_interesting_uses_address): Adjust call to alloc_iv.

gcc/testsuite
2017-10-12  Bin Cheng  <bin.cheng@arm.com>

	* gcc.dg/tree-ssa/ivopt_6.c: New test.
-------------- next part --------------
An embedded and charset-unspecified text was scrubbed...
Name: expand-address-for-base-object.txt
URL: <http://gcc.gnu.org/pipermail/gcc-patches/attachments/20171013/100672a9/attachment.txt>


More information about the Gcc-patches mailing list