From: Christoph Müllner Date: Mon, 17 Jul 2023 08:59:15 +0000 (+0200) Subject: riscv: Fix warning in riscv_regno_ok_for_index_p X-Git-Tag: basepoints/gcc-15~7578 X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=c29584fc29df0c5075ad57cce5bea447b1d061a3;p=thirdparty%2Fgcc.git riscv: Fix warning in riscv_regno_ok_for_index_p The variable `regno` is currently not used in riscv_regno_ok_for_index_p(), which triggers a compiler warning. Let's address this. Fixes: 423604278ed5 ("riscv: Prepare backend for index registers") Reported-by: Juzhe Zhong Reported-by: Andreas Schwab Signed-off-by: Christoph Müllner gcc/ChangeLog: * config/riscv/riscv.cc (riscv_regno_ok_for_index_p): Remove parameter name from declaration of unused parameter. Signed-off-by: Christoph Müllner --- diff --git a/gcc/config/riscv/riscv.cc b/gcc/config/riscv/riscv.cc index 6ed735d69832..ae3c034e76e6 100644 --- a/gcc/config/riscv/riscv.cc +++ b/gcc/config/riscv/riscv.cc @@ -861,7 +861,7 @@ riscv_index_reg_class () but extensions might support that. */ int -riscv_regno_ok_for_index_p (int regno) +riscv_regno_ok_for_index_p (int) { return 0; }