Commit 820410e0 by Zdenek Dvorak Committed by Zdenek Dvorak

re PR tree-optimization/29516 (gfortran miscompiled)

	PR tree-optimization/29516
	* tree-ssa-address.c (tree_mem_ref_addr, add_to_parts,
	most_expensive_mult_to_index, addr_to_parts,
	create_mem_ref, maybe_fold_tmr): Make the type of
	fields of TARGET_MEM_REF sizetype.
	(move_fixed_address_to_symbol, move_pointer_to_base):
	New functions.
	* tree.def (TARGET_MEM_REF): Add comment on types of
	the operands.
	* gcc.dg/tree-ssa/loop-20.c: New test.

From-SVN: r120695
parent 2d3cb33a
2007-01-11 Zdenek Dvorak <dvorakz@suse.cz>
PR tree-optimization/29516
* tree-ssa-address.c (tree_mem_ref_addr, add_to_parts,
most_expensive_mult_to_index, addr_to_parts,
create_mem_ref, maybe_fold_tmr): Make the type of
fields of TARGET_MEM_REF sizetype.
(move_fixed_address_to_symbol, move_pointer_to_base):
New functions.
* tree.def (TARGET_MEM_REF): Add comment on types of
the operands.
* gcc.dg/tree-ssa/loop-20.c: New test.
2007-01-11 Joseph Myers <joseph@codesourcery.com>
* c-common.c (vector_types_convertible_p): Treat opaque types as
......
/* PR tree-optimization/29516 */
/* { dg-do compile { target fpic } } */
/* { dg-options "-O -ftree-vrp -fPIC -fdump-tree-ivopts" } */
typedef struct gfc_se { int pre; } gfc_se;
typedef struct gfc_ss_info { int dim[7]; } gfc_ss_info;
int gfc_rank_cst[7 + 1];
gfc_conv_array_transpose (gfc_se * se) {
int dest, src, dest_index, src_index;
gfc_ss_info *dest_info;
int n;
for (n = 0; n < 2; n++) {
dest_info->dim[n] = n;
src_index = gfc_rank_cst[1 - n];
a (se->pre, b (dest, dest_index), c (src, src_index));
}
}
/* Ivopts should not produce multiplication by a pointer constant. */
/* { dg-final { scan-tree-dump-times "\\* \[0-9\]*B;" 0 "ivopts" } } */
/* { dg-final { cleanup-tree-dump "ivopts" } } */
......@@ -937,6 +937,9 @@ DEFTREECODE (REALIGN_LOAD_EXPR, "realign_load", tcc_expression, 3)
OFFSET (integer constant). Corresponding address is
SYMBOL + BASE + STEP * INDEX + OFFSET. Only variations and values valid on
the target are allowed.
The type of STEP, INDEX and OFFSET is sizetype. The type of BASE is
sizetype or a pointer type (if SYMBOL is NULL).
The sixth argument is the reference to the original memory access, which
is preserved for the purposes of the RTL alias analysis. The seventh
......
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