diff options
Diffstat (limited to 'gcc/cse.c')
-rw-r--r-- | gcc/cse.c | 6 |
1 files changed, 5 insertions, 1 deletions
@@ -3786,8 +3786,12 @@ equiv_constant (rtx x) } } - /* Otherwise see if we already have a constant for the inner REG. */ + /* Otherwise see if we already have a constant for the inner REG, + and if that is enough to calculate an equivalent constant for + the subreg. Note that the upper bits of paradoxical subregs + are undefined, so they cannot be said to equal anything. */ if (REG_P (SUBREG_REG (x)) + && GET_MODE_SIZE (mode) <= GET_MODE_SIZE (imode) && (new_rtx = equiv_constant (SUBREG_REG (x))) != 0) return simplify_subreg (mode, new_rtx, imode, SUBREG_BYTE (x)); |