On 12/04/13 11:01, Richard Sandiford wrote:
Ping for this patch, which is the only one of the series that hasn't
been approved.

Thanks,
Richard

Richard Sandiford <rdsandif...@googlemail.com> writes:
I have a patch to upgrade most genrecog warnings into errors.  This patch
fixes those for tilegx.  There seemed to be two sources of warnings:

- the intrinsics often used matched pointer_operands in an addition,
   so that the destination accepted constant pointers.  I think the
   direct translation would be pmode_register_operand, but since these
   additions have a specific mode, I think a modeful register_operand
   is more natural.

- some instructions used reg_or_0_operand as a destination.

Tested by building tilegx-elf with the warnings turned to errors, and by
comparing the before and after assembly output at -O2 for gcc.c-torture,
gcc.dg and g++.dg.  OK to install?

Thanks,
Richard


gcc/
        * config/tilegx/tilegx.md (insn_ld_add<bitsuffix>): Use
        register_operand rather than pointer_operand.  Add modes to the
        operands.
        (insn_ldna_add<bitsuffix>): Likewise.
        (insn_ld<I124MODE:n><s>_add<I48MODE:bitsuffix>): Likewise.
        (insn_ldnt_add<bitsuffix>): Likewise.
        (insn_ldnt<I124MODE:n><s>_add<I48MODE:bitsuffix>): Likewise.
        (insn_ld_add_L2<bitsuffix>): Likewise.
        (insn_ldna_add_L2<bitsuffix>): Likewise.
        (insn_ld<I124MODE:n><s>_add_L2<I48MODE:bitsuffix>): Likewise.
        (insn_ldnt_add_L2<bitsuffix>): Likewise.
        (insn_ldnt<I124MODE:n><s>_add_L2<I48MODE:bitsuffix>): Likewise.
        (insn_ld_add_miss<bitsuffix>): Likewise.
        (insn_ldna_add_miss<bitsuffix>): Likewise.
        (insn_ld<I124MODE:n><s>_add_miss<I48MODE:bitsuffix>): Likewise.
        (insn_ldnt_add_miss<bitsuffix>): Likewise.
        (insn_ldnt<I124MODE:n><s>_add_miss<I48MODE:bitsuffix>): Likewise.
        (insn_st_add<bitsuffix>): Likewise.
        (insn_st<I124MODE:n>_add<I48MODE:bitsuffix>): Likewise.
        (*insn_st<I124MODE:n>_add<I48MODE:bitsuffix>): Likewise.
        (insn_stnt_add<bitsuffix>): Likewise.
        (insn_stnt<I124MODE:n>_add<I48MODE:bitsuffix>): Likewise.
        (*insn_stnt<I124MODE:n>_add<I48MODE:bitsuffix>): Likewise.
        (vec_pack_<pack_optab>_v4hi): Use register_operand rather than
        reg_or_0_operand for operand 0.
        (insn_v2<pack_insn>): Likewise.
        (vec_pack_hipart_v4hi): Likewise.
        (insn_v2packh): Likewise.
        (vec_pack_ssat_v2si): Likewise.
        (insn_v4packsc): Likewise.
This looks pretty mechanical. Hopefully there wasn't a compelling reason to use pointer_operand instead of either register_operand or other alternatives.

Let's give Walt a bit more time to chime in just in case there was a particular reason for the prior choice of pointer_operand. Perhaps Monday morning. If you haven't heard from Walt by then, consider the patch approved by me.

jeff


Reply via email to