Commit 96c92f47 by Richard Sandiford Committed by Richard Sandiford

read-rtl.c (join_c_conditions): Return the first string if the two strings are equal.

gcc/
	* read-rtl.c (join_c_conditions): Return the first string if the
	two strings are equal.

From-SVN: r135091
parent e663da80
2008-05-08 Richard Sandiford <rsandifo@nildram.co.uk>
* read-rtl.c (join_c_conditions): Return the first string if the
two strings are equal.
2008-05-08 Richard Sandiford <rsandifo@nildram.co.uk>
* gensupport.h (pred_data): Add a "num_codes" field.
(add_predicate_code): Declare.
* gensupport.c (add_predicate_code): New function.
......
......@@ -787,6 +787,9 @@ join_c_conditions (const char *cond1, const char *cond2)
if (cond2 == 0 || cond2[0] == 0)
return cond1;
if (strcmp (cond1, cond2) == 0)
return cond1;
result = concat ("(", cond1, ") && (", cond2, ")", NULL);
obstack_ptr_grow (&joined_conditions_obstack, result);
obstack_ptr_grow (&joined_conditions_obstack, cond1);
......
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