+2008-07-28 Richard Guenther <rguenther@suse.de>
+
+ PR tree-optimization/36957
+ * tree-flow.h (tree_ssa_useless_type_conversion): Remove.
+ (useless_type_conversion_p): Remove.
+ (types_compatible_p): Remove.
+ * gimple.h (tree_ssa_useless_type_conversion): Declare.
+ (useless_type_conversion_p): Declare.
+ (types_compatible_p): Declare.
+ (gimple_expr_type): Return the base type only if it is
+ trivially convertible to the subtype.
+
2008-07-28 Andreas Tobler <a.tobler@schweiz.org>
* configure.ac: Use the m4_do macro to concatenate the warnings into
/* In tree-ssa-operands.c */
extern void gimple_add_to_addresses_taken (gimple, tree);
+/* In tree-ssa.c */
+extern bool tree_ssa_useless_type_conversion (tree);
+extern bool useless_type_conversion_p (tree, tree);
+extern bool types_compatible_p (tree, tree);
+
/* Return the code for GIMPLE statement G. */
static inline enum gimple_code
convertible to one of its sub-types. So always return
the base type here. */
if (INTEGRAL_TYPE_P (type)
- && TREE_TYPE (type))
+ && TREE_TYPE (type)
+ /* But only if they are trivially convertible. */
+ && useless_type_conversion_p (type, TREE_TYPE (type)))
type = TREE_TYPE (type);
return type;
}
extern edge ssa_redirect_edge (edge, basic_block);
extern void flush_pending_stmts (edge);
-extern bool tree_ssa_useless_type_conversion (tree);
-extern bool useless_type_conversion_p (tree, tree);
-extern bool types_compatible_p (tree, tree);
extern void verify_ssa (bool);
extern void delete_tree_ssa (void);
extern void walk_use_def_chains (tree, walk_use_def_chains_fn, void *, bool);