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]

[lto] PATCH: CALL_EXPR changes to gcc/tree-vrp.c


Already committed as "obvious".

-Sandra

2006-07-12  Sandra Loosemore  <sandra@codesourcery.com>

	* gcc/tree-vrp.c (stmt_interesting_for_vrp, vrp_visit_stmt):  Use
	new CALL_EXPR accessors.

Index: gcc/tree-vrp.c
===================================================================
*** gcc/tree-vrp.c	(revision 115346)
--- gcc/tree-vrp.c	(working copy)
*************** stmt_interesting_for_vrp (tree stmt)
*** 3337,3345 ****
  	  && (INTEGRAL_TYPE_P (TREE_TYPE (lhs))
  	      || POINTER_TYPE_P (TREE_TYPE (lhs)))
  	  && ((TREE_CODE (rhs) == CALL_EXPR
! 	       && TREE_CODE (TREE_OPERAND (rhs, 0)) == ADDR_EXPR
! 	       && DECL_P (TREE_OPERAND (TREE_OPERAND (rhs, 0), 0))
! 	       && DECL_IS_BUILTIN (TREE_OPERAND (TREE_OPERAND (rhs, 0), 0)))
  	      || ZERO_SSA_OPERANDS (stmt, SSA_OP_ALL_VIRTUALS)))
  	return true;
      }
--- 3337,3345 ----
  	  && (INTEGRAL_TYPE_P (TREE_TYPE (lhs))
  	      || POINTER_TYPE_P (TREE_TYPE (lhs)))
  	  && ((TREE_CODE (rhs) == CALL_EXPR
! 	       && TREE_CODE (CALL_EXPR_FN (rhs)) == ADDR_EXPR
! 	       && DECL_P (TREE_OPERAND (CALL_EXPR_FN (rhs), 0))
! 	       && DECL_IS_BUILTIN (TREE_OPERAND (CALL_EXPR_FN (rhs), 0)))
  	      || ZERO_SSA_OPERANDS (stmt, SSA_OP_ALL_VIRTUALS)))
  	return true;
      }
*************** vrp_visit_stmt (tree stmt, edge *taken_e
*** 3817,3825 ****
  	 for deriving ranges, with the obvious exception of calls to
  	 builtin functions.  */
        if ((TREE_CODE (rhs) == CALL_EXPR
! 	   && TREE_CODE (TREE_OPERAND (rhs, 0)) == ADDR_EXPR
! 	   && DECL_P (TREE_OPERAND (TREE_OPERAND (rhs, 0), 0))
! 	   && DECL_IS_BUILTIN (TREE_OPERAND (TREE_OPERAND (rhs, 0), 0)))
  	  || ZERO_SSA_OPERANDS (stmt, SSA_OP_ALL_VIRTUALS))
  	return vrp_visit_assignment (stmt, output_p);
      }
--- 3817,3825 ----
  	 for deriving ranges, with the obvious exception of calls to
  	 builtin functions.  */
        if ((TREE_CODE (rhs) == CALL_EXPR
! 	   && TREE_CODE (CALL_EXPR_FN (rhs)) == ADDR_EXPR
! 	   && DECL_P (TREE_OPERAND (CALL_EXPR_FN (rhs), 0))
! 	   && DECL_IS_BUILTIN (TREE_OPERAND (CALL_EXPR_FN (rhs), 0)))
  	  || ZERO_SSA_OPERANDS (stmt, SSA_OP_ALL_VIRTUALS))
  	return vrp_visit_assignment (stmt, output_p);
      }

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