summaryrefslogtreecommitdiff
path: root/gcc/combine.c
diff options
context:
space:
mode:
authorsayle <sayle@138bc75d-0d04-0410-961f-82ee72b054a4>2003-07-16 19:36:38 +0000
committersayle <sayle@138bc75d-0d04-0410-961f-82ee72b054a4>2003-07-16 19:36:38 +0000
commit4224b0b901e9952fbc63790ac1dba71cddd75816 (patch)
tree8cd2a805d5074f26437994d27344930d76a91b43 /gcc/combine.c
parentfccafeb4ff0ce234b4e7135ef968152ce4e3224a (diff)
downloadgcc-4224b0b901e9952fbc63790ac1dba71cddd75816.tar.gz
* combine.c (subst): Also handle (subreg (const_double ...)) case
if created by a substitution, by using the original inner mode. git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@69476 138bc75d-0d04-0410-961f-82ee72b054a4
Diffstat (limited to 'gcc/combine.c')
-rw-r--r--gcc/combine.c4
1 files changed, 3 insertions, 1 deletions
diff --git a/gcc/combine.c b/gcc/combine.c
index 3c3172b0835..5a752014873 100644
--- a/gcc/combine.c
+++ b/gcc/combine.c
@@ -3476,7 +3476,9 @@ subst (rtx x, rtx from, rtx to, int in_dest, int unique_copy)
if (GET_CODE (new) == CLOBBER && XEXP (new, 0) == const0_rtx)
return new;
- if (GET_CODE (new) == CONST_INT && GET_CODE (x) == SUBREG)
+ if (GET_CODE (x) == SUBREG
+ && (GET_CODE (new) == CONST_INT
+ || GET_CODE (new) == CONST_DOUBLE))
{
enum machine_mode mode = GET_MODE (x);