[PATCH 1/2] RISC-V: Describe correct USEs for gpr_save pattern [PR95252]

Kito Cheng kito.cheng@sifive.com
Mon Jun 15 04:08:50 GMT 2020


Hi Andreas:

Thanks for your reminder, fixed on trunk:

https://gcc.gnu.org/git/?p=gcc.git;a=commit;h=82a3008e56c620008b4575a97e459e2769df54db


On Sat, Jun 13, 2020 at 4:58 PM Andreas Schwab <schwab@linux-m68k.org> wrote:
>
> On Jun 10 2020, Kito Cheng wrote:
>
> >  - Verified on rv32emc/rv32gc/rv64gc bare-metal target and rv32gc/rv64gc
> >    linux target with qemu.
>
> Obviously not:
>
> ../../gcc/config/riscv/riscv.c:5190:21: error: comparison of integer expressions of different signedness: 'int' and 'unsigned int' [-Werror=sign-compare]
>  5190 |   for (int i = 1; i < veclen; ++i)
>       |                   ~~^~~~~~~~
> In file included from ../../gcc/config/riscv/riscv.c:26:
> ../../gcc/config/riscv/riscv.c: In function 'bool riscv_gpr_save_operation_p(rtx)':
> ../../gcc/config/riscv/riscv.c:5219:19: error: comparison of integer expressions of different signedness: 'long int' and 'long unsigned int' [-Werror=sign-compare]
>  5219 |   gcc_assert (len <= ARRAY_SIZE (gpr_save_reg_order));
> ../../gcc/system.h:748:14: note: in definition of macro 'gcc_assert'
>   748 |    ((void)(!(EXPR) ? fancy_abort (__FILE__, __LINE__, __FUNCTION__), 0 : 0))
>       |              ^~~~
>
> Andreas.
>
> --
> Andreas Schwab, schwab@linux-m68k.org
> GPG Key fingerprint = 7578 EB47 D4E5 4D69 2510  2552 DF73 E780 A9DA AEC1
> "And now for something completely different."


More information about the Gcc-patches mailing list