public inbox for gcc-cvs@sourceware.org
help / color / mirror / Atom feed
From: Jeff Law <law@gcc.gnu.org>
To: gcc-cvs@gcc.gnu.org
Subject: [gcc(refs/vendors/riscv/heads/gcc-13-with-riscv-opts)] RISC-V: Elimilate warning in class vcreate
Date: Mon, 18 Sep 2023 18:24:59 +0000 (GMT)	[thread overview]
Message-ID: <20230918182459.3079E3857703@sourceware.org> (raw)

https://gcc.gnu.org/g:971b3709ffd413d2380aa03f888fc9149f428f59

commit 971b3709ffd413d2380aa03f888fc9149f428f59
Author: xuli <xuli1@eswincomputing.com>
Date:   Tue Sep 12 05:45:24 2023 +0000

    RISC-V: Elimilate warning in class vcreate
    
    The following is the content of class vcreate:
    class vcreate : public function_base
    {
    public:
      gimple *fold (gimple_folder &f) const override
      {
        ....
      }
    
      rtx expand (function_expander &e) const override
      {
        return NULL_RTX;
      }
    };
    
    The warning caused is:
    ./riscv-gcc/gcc/config/riscv/riscv-vector-builtins-bases.cc:1719:34:
      warning: unused parameter 'e' [-Wunused-parameter]
      rtx expand (function_expander &e) const override
                                     ^
    
    gcc/ChangeLog:
    
            * config/riscv/riscv-vector-builtins-bases.cc: remove unused
                    parameter e and replace NULL_RTX with gcc_unreachable.
    
    (cherry picked from commit b90a4c3dd502974f352084c23a6cdfd767e1340b)

Diff:
---
 gcc/config/riscv/riscv-vector-builtins-bases.cc | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)

diff --git a/gcc/config/riscv/riscv-vector-builtins-bases.cc b/gcc/config/riscv/riscv-vector-builtins-bases.cc
index be3df2c1ea2..ee218a03017 100644
--- a/gcc/config/riscv/riscv-vector-builtins-bases.cc
+++ b/gcc/config/riscv/riscv-vector-builtins-bases.cc
@@ -1856,9 +1856,9 @@ public:
     return clobber;
   }
 
-  rtx expand (function_expander &e) const override
+  rtx expand (function_expander &) const override
   {
-    return NULL_RTX;
+    gcc_unreachable ();
   }
 };

                 reply	other threads:[~2023-09-18 18:24 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=20230918182459.3079E3857703@sourceware.org \
    --to=law@gcc.gnu.org \
    --cc=gcc-cvs@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).