Commit 6c9fbfa7 by Richard Guenther Committed by Richard Biener

re PR tree-optimization/50698 (pretending to create versioning for alias when not required)

2011-10-13  Richard Guenther  <rguenther@suse.de>

	PR tree-optimization/50698
	* tree-data-ref.c (split_constant_offset_1): Also process
	offsets of &MEM.

	* g++.dg/vect/pr50698.cc: New testcase.

From-SVN: r179895
parent ee9488e6
2011-10-13 Richard Guenther <rguenther@suse.de>
PR tree-optimization/50698
* tree-data-ref.c (split_constant_offset_1): Also process
offsets of &MEM.
2011-10-12 David S. Miller <davem@davemloft.net>
* config/sparc/sparc.h: Do not force TARGET_VIS3 and TARGET_FMAF
2011-10-13 Richard Guenther <rguenther@suse.de>
PR tree-optimization/50698
* g++.dg/vect/pr50698.cc: New testcase.
2011-10-12 Janis Johnson <janisjo@codesourcery.com>
* gcc.target/powerpc/warn-1.c: Skip if not powerpc_vsx_ok.
......
// { dg-do compile }
// { dg-require-effective-target vect_float }
float mem[4096];
const int N=1024;
struct XYZ {
float * mem;
int n;
float * x() { return mem;}
float * y() { return x()+n;}
float * z() { return y()+n;}
};
inline
void sum(float * x, float * y, float * z, int n) {
for (int i=0;i!=n; ++i)
x[i]=y[i]+z[i];
}
void sumS() {
XYZ xyz; xyz.mem=mem; xyz.n=N;
sum(xyz.x(),xyz.y(),xyz.z(),xyz.n);
}
// { dg-final { scan-tree-dump-not "run-time aliasing" "vect" } }
// { dg-final { cleanup-tree-dump "vect" } }
......@@ -589,9 +589,6 @@ split_constant_offset_1 (tree type, tree op0, enum tree_code code, tree op1,
int punsignedp, pvolatilep;
op0 = TREE_OPERAND (op0, 0);
if (!handled_component_p (op0))
return false;
base = get_inner_reference (op0, &pbitsize, &pbitpos, &poffset,
&pmode, &punsignedp, &pvolatilep, false);
......
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