2020-01-09 Richard Biener <rguenther@suse.de>
PR middle-end/93054
* gimplify.c (gimplify_expr): Deal with NOP definitions.
* gcc.dg/pr93054.c: New testcase.
From-SVN: r280039
+2020-01-09 Richard Biener <rguenther@suse.de>
+
+ PR middle-end/93054
+ * gimplify.c (gimplify_expr): Deal with NOP definitions.
+
2020-01-09 Richard Biener <rguenther@suse.de>
PR tree-optimization/93040
{
/* Avoid the extra copy if possible. */
*expr_p = create_tmp_reg (TREE_TYPE (name));
- gimple_set_lhs (SSA_NAME_DEF_STMT (name), *expr_p);
+ if (!gimple_nop_p (SSA_NAME_DEF_STMT (name)))
+ gimple_set_lhs (SSA_NAME_DEF_STMT (name), *expr_p);
release_ssa_name (name);
}
}
+2020-01-09 Richard Biener <rguenther@suse.de>
+
+ PR middle-end/93054
+ * gcc.dg/pr93054.c: New testcase.
+
2020-01-09 Richard Biener <rguenther@suse.de>
PR tree-optimization/93040
--- /dev/null
+/* { dg-do compile } */
+
+__attribute__ ((returns_twice)) int
+bp (int);
+
+__attribute__ ((noreturn)) int
+cb (void)
+{
+ return bp (cb ()); /* { dg-warning "declared .noreturn." } */
+}