Commit 9a658585 by Jakub Jelinek Committed by Jakub Jelinek

re PR tree-optimization/88044 (gfortran.dg/transfer_intrinsic_3.f90 hangs after r266171)

	PR tree-optimization/88044
	* tree-ssa-loop-niter.c (number_of_iterations_cond): If condition
	is false in the first iteration, but !every_iteration, return false
	instead of true with niter->niter zero.

From-SVN: r268143
parent 4293cd6e
2019-01-22 Jakub Jelinek <jakub@redhat.com>
PR tree-optimization/88044
* tree-ssa-loop-niter.c (number_of_iterations_cond): If condition
is false in the first iteration, but !every_iteration, return false
instead of true with niter->niter zero.
PR rtl-optimization/88904
* cfgcleanup.c (thread_jump): Verify cond2 doesn't mention
any nonequal registers before processing BB_END (b).
......
......@@ -1824,6 +1824,8 @@ number_of_iterations_cond (struct loop *loop,
tree tem = fold_binary (code, boolean_type_node, iv0->base, iv1->base);
if (tem && integer_zerop (tem))
{
if (!every_iteration)
return false;
niter->niter = build_int_cst (unsigned_type_for (type), 0);
niter->max = 0;
return true;
......
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