diff options
author | Richard Henderson <rth@cygnus.com> | 2000-03-02 22:20:53 -0800 |
---|---|---|
committer | Richard Henderson <rth@gcc.gnu.org> | 2000-03-02 22:20:53 -0800 |
commit | e68c380c8fd70d9c056b13175e0f380e50b31c07 (patch) | |
tree | 000f83ded41f7a37577d1008d3e556b3864aa6b0 | |
parent | c1b5b92ce85988906e0f0bde8100cc41ebc05fb0 (diff) | |
download | gcc-e68c380c8fd70d9c056b13175e0f380e50b31c07.zip gcc-e68c380c8fd70d9c056b13175e0f380e50b31c07.tar.gz gcc-e68c380c8fd70d9c056b13175e0f380e50b31c07.tar.bz2 |
* alpha.c (alpha_emit_set_const_1): Also try c + small constant.
From-SVN: r32304
-rw-r--r-- | gcc/ChangeLog | 4 | ||||
-rw-r--r-- | gcc/config/alpha/alpha.c | 8 |
2 files changed, 12 insertions, 0 deletions
diff --git a/gcc/ChangeLog b/gcc/ChangeLog index d0eee38..dc32f5e 100644 --- a/gcc/ChangeLog +++ b/gcc/ChangeLog @@ -1,3 +1,7 @@ +2000-03-02 Richard Henderson <rth@cygnus.com> + + * alpha.c (alpha_emit_set_const_1): Also try c + small constant. + 2000-03-02 Mark Mitchell <mark@codesourcery.com> * tree.h (TYPE_ALIGN_UNIT): New macro. diff --git a/gcc/config/alpha/alpha.c b/gcc/config/alpha/alpha.c index 17a55a9..7b6eca3 100644 --- a/gcc/config/alpha/alpha.c +++ b/gcc/config/alpha/alpha.c @@ -1400,6 +1400,14 @@ alpha_emit_set_const_1 (target, mode, c, n) target, 0, OPTAB_WIDEN); } + /* Next, see if, minus some low bits, we've an easy load of high bits. */ + + new = ((c & 0xffff) ^ 0x8000) - 0x8000; + if (new != 0 + && (temp = alpha_emit_set_const (subtarget, mode, c - new, n - 1)) != 0) + return expand_binop (mode, add_optab, temp, GEN_INT (new), + target, 0, OPTAB_WIDEN); + return 0; } |