OSDN Git Service

* emit-rtl-c (gen_lowpart_common): Accept non-paradoxical SUBREG when
authorrth <rth@138bc75d-0d04-0410-961f-82ee72b054a4>
Mon, 25 Sep 2000 17:44:09 +0000 (17:44 +0000)
committerrth <rth@138bc75d-0d04-0410-961f-82ee72b054a4>
Mon, 25 Sep 2000 17:44:09 +0000 (17:44 +0000)
        UNITS_PER_WORD is small.

git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@36625 138bc75d-0d04-0410-961f-82ee72b054a4

gcc/ChangeLog
gcc/emit-rtl.c

index 0c08c8e..b4d4ba5 100644 (file)
@@ -1,3 +1,8 @@
+2000-09-24  Alan Lehotsky  <alehotsky@cygnus.com>
+
+       * emit-rtl-c (gen_lowpart_common): Accept non-paradoxical SUBREG when
+       UNITS_PER_WORD is small.
+
 2000-09-25  Joseph S. Myers  <jsm28@cam.ac.uk>
 
        * c-common.c (format_char_info): Add flags2; update comments.
index ac5e965..2a4bdb9 100644 (file)
@@ -707,7 +707,8 @@ gen_lowpart_common (mode, x)
        return gen_rtx_fmt_e (GET_CODE (x), mode, XEXP (x, 0));
     }
   else if (GET_CODE (x) == SUBREG
-          && (GET_MODE_SIZE (mode) <= UNITS_PER_WORD
+          && (GET_MODE_SIZE (mode) <= GET_MODE_SIZE (GET_MODE (SUBREG_REG (x)))
+              || GET_MODE_SIZE (mode) <= UNITS_PER_WORD
               || GET_MODE_SIZE (mode) == GET_MODE_UNIT_SIZE (GET_MODE (x))))
     return (GET_MODE (SUBREG_REG (x)) == mode && SUBREG_WORD (x) == 0
            ? SUBREG_REG (x)