+2005-03-17 Richard Sandiford <rsandifo@redhat.com>
+
+ PR rtl-optimization/19683
+ * reload1.c (choose_reload_regs): Pass the number of bits, not the
+ number of bytes, to smallest_int_for_mode. Fix arguments to
+ REG_CANNOT_CHANGE_MODE_P.
+
2005-03-17 Alan Modra <amodra@bigpond.net.au>
* config/rs6000/linux-unwind.h: New file backported from gcc-4.0.
need_mode = mode;
else
need_mode
- = smallest_mode_for_size (GET_MODE_SIZE (mode) + byte,
+ = smallest_mode_for_size (GET_MODE_BITSIZE (mode)
+ + byte * BITS_PER_UNIT,
GET_MODE_CLASS (mode));
- if (
-#ifdef CANNOT_CHANGE_MODE_CLASS
- (!REG_CANNOT_CHANGE_MODE_P (i, GET_MODE (last_reg),
- need_mode)
- &&
-#endif
- (GET_MODE_SIZE (GET_MODE (last_reg))
+ if ((GET_MODE_SIZE (GET_MODE (last_reg))
>= GET_MODE_SIZE (need_mode))
#ifdef CANNOT_CHANGE_MODE_CLASS
- )
+ /* Verify that the register in "i" can be obtained
+ from LAST_REG. */
+ && !REG_CANNOT_CHANGE_MODE_P (REGNO (last_reg),
+ GET_MODE (last_reg),
+ mode)
#endif
&& reg_reloaded_contents[i] == regno
&& TEST_HARD_REG_BIT (reg_reloaded_valid, i)
+2005-03-17 Richard Sandiford <rsandifo@redhat.com>
+
+ * gcc.dg/torture/pr19683-1.c: New test.
+
2005-03-16 Roger Sayle <roger@eyesopen.com>
PR rtl-optimization/17825