public inbox for gcc-patches@gcc.gnu.org
 help / color / mirror / Atom feed
From: Jeff Law <jeffreyalaw@gmail.com>
To: Sergei Lewis <slewis@rivosinc.com>, gcc-patches@gcc.gnu.org
Subject: Re: [PATCH v2 1/3] RISC-V: movmem for RISCV with V extension
Date: Mon, 13 May 2024 17:36:52 -0600	[thread overview]
Message-ID: <6157777f-1584-47da-93c6-66ccaf135a3e@gmail.com> (raw)
In-Reply-To: <5098d3c3-845f-4b71-ba8f-751b03b73240@gmail.com>



On 12/19/23 10:28 PM, Jeff Law wrote:
> 
> 
> On 12/19/23 02:53, Sergei Lewis wrote:
>> gcc/ChangeLog
>>
>>      * config/riscv/riscv.md (movmem<mode>): Use 
>> riscv_vector::expand_block_move,
>>      if and only if we know the entire operation can be performed 
>> using one vector
>>      load followed by one vector store
>>
>> gcc/testsuite/ChangeLog
>>
>>      PR target/112109
>>      * gcc.target/riscv/rvv/base/movmem-1.c: New test
> So this needs to be regression tested.  Given that it only affects RVV, 
> I would suggest testing rv64gcv or rv32gcv.
> 
> 
> 
>> +(define_expand "movmem<mode>"
>> +  [(parallel [(set (match_operand:BLK 0 "general_operand")
>> +   (match_operand:BLK 1 "general_operand"))
>> +    (use (match_operand:P 2 "const_int_operand"))
>> +    (use (match_operand:SI 3 "const_int_operand"))])]
>> +  "TARGET_VECTOR"
>> +{
>> +  if ((INTVAL (operands[2]) >= TARGET_MIN_VLEN/8)
>> +    && (INTVAL (operands[2]) <= TARGET_MIN_VLEN)
>> +    && riscv_vector::expand_block_move (operands[0], operands[1],
>> +         operands[2]))
>> +    DONE;
>> +  else
>> +    FAIL;
>> +})
> Just a formatting nit.  A space on each side of the '/' operator above.
So I've fixed the formatting nit and tested on rv64gc and rv32gcv.  I 
hadn't planned to push it, but muscle memory kicked in and 1/3 has been 
pushed.

I'll be looking at 2/3 and 3/3 tomorrow (or possibly a bit tonight to 
take advantage of overnight CI runs).

jeff


  parent reply	other threads:[~2024-05-13 23:36 UTC|newest]

Thread overview: 12+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2023-12-19  9:53 [PATCH v2 0/3] RISC-V: vectorised memory operations Sergei Lewis
2023-12-19  9:53 ` [PATCH v2 1/3] RISC-V: movmem for RISCV with V extension Sergei Lewis
2023-12-20  5:28   ` Jeff Law
2023-12-20  9:44     ` Sergei Lewis
2024-05-13 23:36     ` Jeff Law [this message]
2023-12-19  9:53 ` [PATCH v2 2/3] RISC-V: setmem " Sergei Lewis
2023-12-20  5:38   ` Jeff Law
2023-12-20  9:48     ` Sergei Lewis
2023-12-20 16:02       ` Jeff Law
2024-06-24 20:22   ` Jeff Law
2023-12-19  9:53 ` [PATCH v2 3/3] RISC-V: cmpmem " Sergei Lewis
2024-06-25 21:28   ` Jeff Law

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=6157777f-1584-47da-93c6-66ccaf135a3e@gmail.com \
    --to=jeffreyalaw@gmail.com \
    --cc=gcc-patches@gcc.gnu.org \
    --cc=slewis@rivosinc.com \
    /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).