summaryrefslogtreecommitdiff
path: root/gcc/rtlhooks.c
diff options
context:
space:
mode:
authorbstarynk <bstarynk@138bc75d-0d04-0410-961f-82ee72b054a4>2008-03-25 13:36:19 +0000
committerbstarynk <bstarynk@138bc75d-0d04-0410-961f-82ee72b054a4>2008-03-25 13:36:19 +0000
commite0f97db9eb84d304602eb35815ba9d188cd69e46 (patch)
tree84bddb2ec09b31241a95c5b1ded74d60cdff6239 /gcc/rtlhooks.c
parentf80df6b2af919960ad08a6f1901ddebb654f981b (diff)
downloadgcc-e0f97db9eb84d304602eb35815ba9d188cd69e46.tar.gz
2008-03-24 Basile Starynkevitch <basile@starynkevitch.net>
MELT branch merged with trunk r133512 git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/branches/melt-branch@133515 138bc75d-0d04-0410-961f-82ee72b054a4
Diffstat (limited to 'gcc/rtlhooks.c')
-rw-r--r--gcc/rtlhooks.c8
1 files changed, 3 insertions, 5 deletions
diff --git a/gcc/rtlhooks.c b/gcc/rtlhooks.c
index 8939b21bdb5..432b286c1d8 100644
--- a/gcc/rtlhooks.c
+++ b/gcc/rtlhooks.c
@@ -43,11 +43,9 @@ gen_lowpart_general (enum machine_mode mode, rtx x)
if (result)
return result;
- /* If it's a REG, it must be a hard reg that's not valid in MODE. */
- else if (REG_P (x)
- /* Or we could have a subreg of a floating point value. */
- || (GET_CODE (x) == SUBREG
- && FLOAT_MODE_P (GET_MODE (SUBREG_REG (x)))))
+ /* Handle SUBREGs and hard REGs that were rejected by
+ simplify_gen_subreg. */
+ else if (REG_P (x) || GET_CODE (x) == SUBREG)
{
result = gen_lowpart_common (mode, copy_to_reg (x));
gcc_assert (result != 0);