+2003-03-29 Glen Nakamura <glen@imodulo.com>
+
+ PR c/8224
+ * fold-const.c (extract_muldiv_1): Don't pass through type conversions
+ when signedness changes for division or modulus.
+
2003-03-29 Alan Modra <amodra@bigpond.net.au>
* reload1.c (reload_as_needed): Allow a USE in asm reloads.
/* ...and its type is larger than ctype,
then we cannot pass through this truncation. */
|| (GET_MODE_SIZE (TYPE_MODE (ctype))
- < GET_MODE_SIZE (TYPE_MODE (TREE_TYPE (op0))))))
+ < GET_MODE_SIZE (TYPE_MODE (TREE_TYPE (op0))))
+ /* ... or signedness changes for division or modulus,
+ then we cannot pass through this conversion. */
+ || (code != MULT_EXPR
+ && (TREE_UNSIGNED (ctype)
+ != TREE_UNSIGNED (TREE_TYPE (op0))))))
break;
/* Pass the constant down and see if we can make a simplification. If
+2003-03-29 Mikulas Patocka <mikulas@artax.karlin.mff.cuni.cz>
+
+ * gcc.dg/20030323-1.c: New test.
+
2003-03-28 Eric Botcazou <ebotcazou@libertysurf.fr>
* gcc.dg/ultrasp8.c: New test.