diff options
author | kenner <kenner@138bc75d-0d04-0410-961f-82ee72b054a4> | 2001-02-06 12:39:15 +0000 |
---|---|---|
committer | kenner <kenner@138bc75d-0d04-0410-961f-82ee72b054a4> | 2001-02-06 12:39:15 +0000 |
commit | bc17f7a49bf238d7a6fb3c07e70f221afd14f27c (patch) | |
tree | ef948bedc788321fdca09d6b2f508f386ee213d9 /gcc/explow.c | |
parent | 73a7dbdd334650e4c456b3871bf6be04eb2f35c8 (diff) | |
download | gcc-bc17f7a49bf238d7a6fb3c07e70f221afd14f27c.tar.gz |
* combine.c (nonzero_bits, case PLUS): If pointers extend unsigned
and this is the sum of a pointer and a constant, we know the result
did not overflow.
(num_sign_bit_copies, case PLUS): Likewise.
* explow.c (convert_memory_address): Remove opposite SUBREG.
* function.c (instantiate_new_reg): New function (from common code).
(instantiate_virtual_regs_1): Call it.
For PLUS, handle if (plus (subreg (virt-reg) (const_int))
if pointers sign- or zero-extend.
* simplify-rtx.c (simplify_unary_operation, case ZERO_EXTEND):
If pointers extend unsigned, use inside of SUBREG.
(simplify_unary_operation, case SIGN_EXTEND): Likewise, if sign extend.
git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@39489 138bc75d-0d04-0410-961f-82ee72b054a4
Diffstat (limited to 'gcc/explow.c')
-rw-r--r-- | gcc/explow.c | 5 |
1 files changed, 5 insertions, 0 deletions
diff --git a/gcc/explow.c b/gcc/explow.c index d36ceffa440..b7c0bb9f6d9 100644 --- a/gcc/explow.c +++ b/gcc/explow.c @@ -386,6 +386,11 @@ convert_memory_address (to_mode, x) case CONST_DOUBLE: return x; + case SUBREG: + if (GET_MODE (SUBREG_REG (x)) == to_mode) + return SUBREG_REG (x); + break; + case LABEL_REF: temp = gen_rtx_LABEL_REF (to_mode, XEXP (x, 0)); LABEL_REF_NONLOCAL_P (temp) = LABEL_REF_NONLOCAL_P (x); |