aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorJeff Law <law@redhat.com>2015-02-05 22:34:00 -0700
committerJeff Law <law@gcc.gnu.org>2015-02-05 22:34:00 -0700
commitd00f6ca670050d56c3ed5ef0c8ccdcce346e1cf2 (patch)
tree9ef29be806c0975046cf22e5b44f8a54e6b3bc3b
parent8c5c44aa7ebe78bf12dc7b9a2f5e71f94feacc30 (diff)
downloadgcc-d00f6ca670050d56c3ed5ef0c8ccdcce346e1cf2.zip
gcc-d00f6ca670050d56c3ed5ef0c8ccdcce346e1cf2.tar.gz
gcc-d00f6ca670050d56c3ed5ef0c8ccdcce346e1cf2.tar.bz2
re PR target/43264 (Arithmetic expression error)
PR target/43264 * config/h8300/h8300.c (get_shift_alg): Fix ASHIFTRT by 24 to 28 bits for the H8/300. From-SVN: r220471
-rw-r--r--gcc/ChangeLog6
-rw-r--r--gcc/config/h8300/h8300.c2
2 files changed, 7 insertions, 1 deletions
diff --git a/gcc/ChangeLog b/gcc/ChangeLog
index 90cee313..2bbfeb3 100644
--- a/gcc/ChangeLog
+++ b/gcc/ChangeLog
@@ -1,3 +1,9 @@
+2015-02-05 Jeff Law <law@redhat.com>
+
+ PR target/43264
+ * config/h8300/h8300.c (get_shift_alg): Fix ASHIFTRT by
+ 24 to 28 bits for the H8/300.
+
2015-02-06 Alan Modra <amodra@gmail.com>
PR target/64876
diff --git a/gcc/config/h8300/h8300.c b/gcc/config/h8300/h8300.c
index 5968e55..4bd4787 100644
--- a/gcc/config/h8300/h8300.c
+++ b/gcc/config/h8300/h8300.c
@@ -4384,7 +4384,7 @@ get_shift_alg (enum shift_type shift_type, enum shift_mode shift_mode,
info->cc_inline = CC_SET_ZNV;
goto end;
case SHIFT_ASHIFTRT:
- info->special = "mov.b\t%z0,%w0\n\tbld\t#7,%w0\n\tsubx\t%x0,%x0\n\tsubx\t%x0,%x0\n\tsubx\t%x0,%x0";
+ info->special = "mov.b\t%z0,%w0\n\tbld\t#7,%w0\n\tsubx\t%x0,%x0\n\tsubx\t%y0,%y0\n\tsubx\t%z0,%z0";
info->shift1 = "shar.b\t%w0";
info->cc_inline = CC_SET_ZNV;
goto end;