aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorJeffrey A Law <law@cygnus.com>1999-02-06 09:41:08 +0000
committerJeff Law <law@gcc.gnu.org>1999-02-06 02:41:08 -0700
commit54ca6ffa139060575be8487db82d2cb551638eb5 (patch)
treed249beba76b9a8b8cfd5d3f7caa6cb2e6fc8d9d1
parentbdc1937ed9b8094c8fcb835b594d67812883003f (diff)
downloadgcc-54ca6ffa139060575be8487db82d2cb551638eb5.zip
gcc-54ca6ffa139060575be8487db82d2cb551638eb5.tar.gz
gcc-54ca6ffa139060575be8487db82d2cb551638eb5.tar.bz2
reload1.c (reload_combine_note_store): Be more careful with STRICT_LOW_PART, ZERO_EXTRACT and SIGN_EXTRACT.
* reload1.c (reload_combine_note_store): Be more careful with STRICT_LOW_PART, ZERO_EXTRACT and SIGN_EXTRACT. (move2add_note_store): Likewise. From-SVN: r25055
-rw-r--r--gcc/ChangeLog6
-rw-r--r--gcc/reload1.c21
2 files changed, 25 insertions, 2 deletions
diff --git a/gcc/ChangeLog b/gcc/ChangeLog
index a6576cb..a2439de 100644
--- a/gcc/ChangeLog
+++ b/gcc/ChangeLog
@@ -1,3 +1,9 @@
+Sat Feb 6 10:31:35 1999 Jeffrey A Law (law@cygnus.com)
+
+ * reload1.c (reload_combine_note_store): Be more careful with
+ STRICT_LOW_PART, ZERO_EXTRACT and SIGN_EXTRACT.
+ (move2add_note_store): Likewise.
+
Sat Feb 6 10:18:01 1999 Kaveh R. Ghazi <ghazi@caip.rutgers.edu>
* cppfiles.c (read_and_prescan): Cast the result of `xrealloc' to
diff --git a/gcc/reload1.c b/gcc/reload1.c
index cfacc78..f2cb20d 100644
--- a/gcc/reload1.c
+++ b/gcc/reload1.c
@@ -9732,9 +9732,15 @@ reload_combine_note_store (dst, set)
if (GET_CODE (dst) != REG)
return;
regno += REGNO (dst);
+
/* note_stores might have stripped a STRICT_LOW_PART, so we have to be
- careful with registers / register parts that are not full words. */
- if (size < (unsigned) UNITS_PER_WORD)
+ careful with registers / register parts that are not full words.
+
+ Similarly for ZERO_EXTRACT and SIGN_EXTRACT. */
+ if (GET_CODE (set) != SET
+ || GET_CODE (SET_DEST (set)) == ZERO_EXTRACT
+ || GET_CODE (SET_DEST (set)) == SIGN_EXTRACT
+ || GET_CODE (SET_DEST (set)) == STRICT_LOW_PART)
{
reg_state[regno].use_index = -1;
reg_state[regno].store_ruid = reload_combine_ruid;
@@ -10056,6 +10062,17 @@ move2add_note_store (dst, set)
{
rtx src = SET_SRC (set);
+ /* Indicate that this register has been recently written to,
+ but the exact contents are not available. */
+ if (GET_CODE (SET_DEST (set)) == ZERO_EXTRACT
+ || GET_CODE (SET_DEST (set)) == SIGN_EXTRACT
+ || GET_CODE (SET_DEST (set)) == STRICT_LOW_PART)
+ {
+ reg_set_luid[regno] = move2add_luid;
+ reg_offset[regno] = dst;
+ return;
+ }
+
reg_mode[regno] = mode;
switch (GET_CODE (src))
{