A recent RTX cost commit has changed the costs for ARC700 leading to
errors in slsr-13.c test.  This commit fixes this issue by reverting
the cost computation for short instructions.

2019-06-28  Claudiu Zissulescu  <[email protected]>

        * config/arc/arc.c (arc_rtx_costs): All short instructions are
        having a lower cost regardless of the speed option.
---
 gcc/ChangeLog        | 5 +++++
 gcc/config/arc/arc.c | 2 +-
 2 files changed, 6 insertions(+), 1 deletion(-)

diff --git a/gcc/ChangeLog b/gcc/ChangeLog
index 35c5163da27..6f028eee3cc 100644
--- a/gcc/ChangeLog
+++ b/gcc/ChangeLog
@@ -1,3 +1,8 @@
+2019-06-28  Claudiu Zissulescu  <[email protected]>
+
+       * config/arc/arc.c (arc_rtx_costs): All short instructions are
+       having a lower cost regardless of the speed option.
+
 2019-06-28  Jan Beulich  <[email protected]>
 
        * config/i386/sse.md (sse2_cvtpd2pi, sse2_cvttpd2pi): Use
diff --git a/gcc/config/arc/arc.c b/gcc/config/arc/arc.c
index ff82c9f7136..5decf916884 100644
--- a/gcc/config/arc/arc.c
+++ b/gcc/config/arc/arc.c
@@ -5590,7 +5590,7 @@ arc_rtx_costs (rtx x, machine_mode mode, int outer_code,
                break;
              }
          }
-       if (nolimm && !speed)
+       if (nolimm)
          {
            *total = 0;
            return true;
-- 
2.21.0

Reply via email to