https://gcc.gnu.org/bugzilla/show_bug.cgi?id=71514
Richard Biener <rguenth at gcc dot gnu.org> changed:
What |Removed |Added
----------------------------------------------------------------------------
Status|NEW |ASSIGNED
Assignee|unassigned at gcc dot gnu.org |rguenth at gcc dot
gnu.org
--- Comment #3 from Richard Biener <rguenth at gcc dot gnu.org> ---
gimplification:
case VIEW_CONVERT_EXPR:
if (is_gimple_reg_type (TREE_TYPE (*expr_p))
&& is_gimple_reg_type (TREE_TYPE (TREE_OPERAND (*expr_p, 0))))
{
ret = gimplify_expr (&TREE_OPERAND (*expr_p, 0), pre_p,
post_p, is_gimple_val, fb_rvalue);
recalculate_side_effects (*expr_p);
break;
}
fix:
Index: gcc/gimple-expr.h
===================================================================
--- gcc/gimple-expr.h (revision 237372)
+++ gcc/gimple-expr.h (working copy)
@@ -72,7 +72,7 @@ types_compatible_p (tree type1, tree typ
static inline bool
is_gimple_reg_type (tree type)
{
- return !AGGREGATE_TYPE_P (type);
+ return !AGGREGATE_TYPE_P (type) && !FUNC_OR_METHOD_TYPE_P (type);
}
/* Return true if T is a variable. */
might eventually be worth to speeed up the type check by ordering tcc_type
entries in a particular way ...