This is the mail archive of the gcc-patches@gcc.gnu.org mailing list for the GCC project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

[patch] tree-vrp.c: Use build_int_cst instead of fold_convert.


Hi,

Attached is a patch to use build_int_cst instead of fold_convert.

Tested on x86_64-pc-linux-gnu.  Committed as obvious.

Kazu Hirata

2005-12-27  Kazu Hirata  <kazu@codesourcery.com>

	* tree-vrp.c (extract_range_from_binary_expr): Use
	build_int_cst instead of fold_convert.

Index: tree-vrp.c
===================================================================
--- tree-vrp.c	(revision 109064)
+++ tree-vrp.c	(working copy)
@@ -1421,7 +1421,7 @@ extract_range_from_binary_expr (value_ra
 	  && tree_expr_nonnegative_p (vr0.max)
 	  && TREE_CODE (vr0.max) == INTEGER_CST)
 	{
-	  min = fold_convert (TREE_TYPE (expr), integer_zero_node);
+	  min = build_int_cst (TREE_TYPE (expr), 0);
 	  max = vr0.max;
 	}
       else if (vr1.type == VR_RANGE
@@ -1430,7 +1430,7 @@ extract_range_from_binary_expr (value_ra
 	  && TREE_CODE (vr1.max) == INTEGER_CST)
 	{
 	  type = VR_RANGE;
-	  min = fold_convert (TREE_TYPE (expr), integer_zero_node);
+	  min = build_int_cst (TREE_TYPE (expr), 0);
 	  max = vr1.max;
 	}
       else


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]