Commit b94970bc by Richard Biener Committed by Richard Biener

re PR tree-optimization/60849 (bogus comparison result type)

2014-04-17  Richard Biener  <rguenther@suse.de>

	PR middle-end/60849
	* tree-ssa-propagate.c (valid_gimple_rhs_p): Allow vector
	comparison results and add clarifying comment.

From-SVN: r209486
parent 92f0f3ec
2014-04-17 Richard Biener <rguenther@suse.de>
PR middle-end/60849
* tree-ssa-propagate.c (valid_gimple_rhs_p): Allow vector
comparison results and add clarifying comment.
2014-04-17 Jakub Jelinek <jakub@redhat.com>
* genmodes.c (struct mode_data): Add need_bytesize_adj field.
......
......@@ -572,9 +572,13 @@ valid_gimple_rhs_p (tree expr)
break;
case tcc_comparison:
if (!INTEGRAL_TYPE_P (TREE_TYPE (expr))
|| (TREE_CODE (TREE_TYPE (expr)) != BOOLEAN_TYPE
&& TYPE_PRECISION (TREE_TYPE (expr)) != 1))
/* GENERIC allows comparisons with non-boolean types, reject
those for GIMPLE. Let vector-typed comparisons pass - rules
for GENERIC and GIMPLE are the same here. */
if (!(INTEGRAL_TYPE_P (TREE_TYPE (expr))
&& (TREE_CODE (TREE_TYPE (expr)) == BOOLEAN_TYPE
|| TYPE_PRECISION (TREE_TYPE (expr)) == 1))
&& ! VECTOR_TYPE_P (TREE_TYPE (expr)))
return false;
/* Fallthru. */
......
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