public inbox for gcc-patches@gcc.gnu.org
 help / color / mirror / Atom feed
* [PATCH] Fix PR88019
@ 2018-11-14 11:10 Richard Biener
  0 siblings, 0 replies; only message in thread
From: Richard Biener @ 2018-11-14 11:10 UTC (permalink / raw)
  To: gcc-patches


Bootstrapped and tested on x86_64-unknown-linux-gnu, applied.

Richard.

2018-11-14  Richard Biener  <rguenther@suse.de>

	PR tree-optimization/88019
	* graphite-isl-ast-to-gimple.c (ternary_op_to_tree): Rewrite
	COND_EXPR arguments to non-trapping overflow.

diff --git a/gcc/graphite-isl-ast-to-gimple.c b/gcc/graphite-isl-ast-to-gimple.c
index 0d8960c6bb2..e2dbf6fbf9d 100644
--- a/gcc/graphite-isl-ast-to-gimple.c
+++ b/gcc/graphite-isl-ast-to-gimple.c
@@ -411,7 +411,9 @@ ternary_op_to_tree (tree type, __isl_take isl_ast_expr *expr, ivs_params &ip)
   if (codegen_error_p ())
     return NULL_TREE;
 
-  return fold_build3 (COND_EXPR, type, a, b, c);
+  return fold_build3 (COND_EXPR, type, a,
+		      rewrite_to_non_trapping_overflow (b),
+		      rewrite_to_non_trapping_overflow (c));
 }
 
 /* Converts a unary isl_ast_expr_op expression E to a GCC expression tree of

^ permalink raw reply	[flat|nested] only message in thread

only message in thread, other threads:[~2018-11-14 11:10 UTC | newest]

Thread overview: (only message) (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2018-11-14 11:10 [PATCH] Fix PR88019 Richard Biener

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).