Commit fe8b1e83 by Doug Gilmore Committed by Matthew Fortune

re PR tree-optimization/77808 (ICE in duplicate_ssa_name_ptr_info, at…

re PR tree-optimization/77808 (ICE in duplicate_ssa_name_ptr_info, at tree-ssanames.c:630 starting with r240439)

Fix PR tree-optimization/77808

gcc/
	PR tree-optimization/77808
	* tree-ssa-loop-prefetch.c (issue_prefetch_ref): Check base_addr
	and addr are different before copying points-to information.

gcc/testsuite/
	PR tree-optimization/77808
	* gcc.dg/tree-ssa/pr77808.c: New testcase.

From-SVN: r240749
parent 9f06db14
2016-10-04 Doug Gilmore <doug.gilmore@imgtec.com>
PR tree-optimization/77808
* tree-ssa-loop-prefetch.c (issue_prefetch_ref): Check base_addr
and addr are different before copying points-to information.
2016-10-04 Uros Bizjak <ubizjak@gmail.com> 2016-10-04 Uros Bizjak <ubizjak@gmail.com>
* config/i386/x86-tune.def (X86_TUNE_VECTORIZE_DOUBLE): Remove. * config/i386/x86-tune.def (X86_TUNE_VECTORIZE_DOUBLE): Remove.
......
2016-10-04 Doug Gilmore <doug.gilmore@imgtec.com>
PR tree-optimization/77808
* gcc.dg/tree-ssa/pr77808.c: New testcase.
2016-10-04 Richard Biener <rguenther@suse.de> 2016-10-04 Richard Biener <rguenther@suse.de>
PR tree-optimization/77399 PR tree-optimization/77399
......
/* PR tree-optimization/77808 */
/* { dg-options "-O2 -fprefetch-loop-arrays --param prefetch-latency=0 -w" } */
void
daxpy(int n, double da, double * __restrict dx, double * __restrict dy)
{
int i;
for (i = 0;i < n; i++)
dy[i] = dy[i] + da*dx[i];
}
...@@ -1162,7 +1162,8 @@ issue_prefetch_ref (struct mem_ref *ref, unsigned unroll_factor, unsigned ahead) ...@@ -1162,7 +1162,8 @@ issue_prefetch_ref (struct mem_ref *ref, unsigned unroll_factor, unsigned ahead)
NULL, true, GSI_SAME_STMT); NULL, true, GSI_SAME_STMT);
} }
if (TREE_CODE (addr_base) == SSA_NAME if (addr_base != addr
&& TREE_CODE (addr_base) == SSA_NAME
&& TREE_CODE (addr) == SSA_NAME) && TREE_CODE (addr) == SSA_NAME)
{ {
duplicate_ssa_name_ptr_info (addr, SSA_NAME_PTR_INFO (addr_base)); duplicate_ssa_name_ptr_info (addr, SSA_NAME_PTR_INFO (addr_base));
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment