+2009-04-01 Eric Botcazou <ebotcazou@adacore.com>
+
+ PR rtl-optimization/39588
+ * combine.c (merge_outer_ops): Do not set the constant when this
+ is not necessary.
+ (simplify_shift_const_1): Do not modify it either in this case.
+
2009-03-26 Ben Elliston <bje@au.ibm.com>
Backport from mainline:
&& op0 == AND)
op0 = UNKNOWN;
+ *pop0 = op0;
+
/* ??? Slightly redundant with the above mask, but not entirely.
Moving this above means we'd have to sign-extend the mode mask
for the final test. */
- const0 = trunc_int_for_mode (const0, mode);
-
- *pop0 = op0;
- *pconst0 = const0;
+ if (op0 != UNKNOWN && op0 != NEG)
+ *pconst0 = trunc_int_for_mode (const0, mode);
return 1;
}
if (outer_op != UNKNOWN)
{
- if (GET_MODE_BITSIZE (result_mode) < HOST_BITS_PER_WIDE_INT)
+ if (GET_RTX_CLASS (outer_op) != RTX_UNARY
+ && GET_MODE_BITSIZE (result_mode) < HOST_BITS_PER_WIDE_INT)
outer_const = trunc_int_for_mode (outer_const, result_mode);
if (outer_op == AND)
+2009-04-01 Eric Botcazou <ebotcazou@adacore.com>
+
+ * gcc.c-torture/compile/20090401-1.c: New test.
+
2009-03-26 Ben Elliston <bje@au.ibm.com>
Backport from mainline:
--- /dev/null
+/* PR rtl-optimization/39588 */
+/* Testcase by Olivier ROUSSEL <olivier.roussel@cril.univ-artois.fr> */
+
+#define lit_from_int(in) ((in<0)?(((-in)<<1)|1):(in<<1))
+
+void init_clause(int *literals, int size, int *lits)
+{
+ int i;
+ for(i=0; i < size; i++)
+ lits[i] = lit_from_int(literals[i]);
+}