public inbox for gcc-patches@gcc.gnu.org
 help / color / mirror / Atom feed
From: Jeff Law <jeffreyalaw@gmail.com>
To: "gcc-patches@gcc.gnu.org" <gcc-patches@gcc.gnu.org>
Subject: [committed] Fix bug in register move costing on H8/300
Date: Sat, 15 Oct 2022 21:41:42 -0600	[thread overview]
Message-ID: <81e45aaf-7e44-fa07-35df-f66d988879ae@gmail.com> (raw)

[-- Attachment #1: Type: text/plain, Size: 288 bytes --]


Spotted while looking at a regression on the H8/300.   We used MAC_REG 
rather than MAC_REGS when referring to a register class. This caused 
code quality regressions while looking into Paul K's suggestion for 
fixing the auto-increment issue on the H8.


Pushed to the trunk,

Jeff



[-- Attachment #2: P --]
[-- Type: text/plain, Size: 716 bytes --]

commit 6c3da5ca84ded7c5754183f8d2cad0d01e1562ff
Author: Jeff Law <jeffreyalaw@gmail.com>
Date:   Sat Oct 15 23:38:20 2022 -0400

    Fix bug in register move costing on H8/300
    
    gcc/
            * config/h8300/h8300.cc (h8300_register_move_cost): Fix typo.

diff --git a/gcc/config/h8300/h8300.cc b/gcc/config/h8300/h8300.cc
index 78cf15f15c7..be3e385c91e 100644
--- a/gcc/config/h8300/h8300.cc
+++ b/gcc/config/h8300/h8300.cc
@@ -1140,7 +1140,7 @@ static int
 h8300_register_move_cost (machine_mode mode ATTRIBUTE_UNUSED,
                          reg_class_t from, reg_class_t to)
 {
-  if (from == MAC_REGS || to == MAC_REG)
+  if (from == MAC_REGS || to == MAC_REGS)
     return 6;
   else
     return 3;

                 reply	other threads:[~2022-10-16  3:41 UTC|newest]

Thread overview: [no followups] expand[flat|nested]  mbox.gz  Atom feed

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=81e45aaf-7e44-fa07-35df-f66d988879ae@gmail.com \
    --to=jeffreyalaw@gmail.com \
    --cc=gcc-patches@gcc.gnu.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).