Checks
Commit Message
From: Ju-Zhe Zhong <juzhe.zhong@rivai.ai>
This patch fix bug: https://gcc.gnu.org/bugzilla/show_bug.cgi?id=109092.
gcc/ChangeLog:
* config/riscv/riscv.md: Fix subreg bug.
---
gcc/config/riscv/riscv.md | 6 +++---
1 file changed, 3 insertions(+), 3 deletions(-)
Comments
On 3/13/23 08:17, juzhe.zhong@rivai.ai wrote:
> From: Ju-Zhe Zhong <juzhe.zhong@rivai.ai>
>
> This patch fix bug: https://gcc.gnu.org/bugzilla/show_bug.cgi?id=109092.
>
> gcc/ChangeLog:
>
> * config/riscv/riscv.md: Fix subreg bug.
LGTM. Do you have write access now? If so, go ahead and commit this patch.
Do you have any interest in fixing up a similar bug in peephole.md?
Jeff
Yes, I have write access. However, I am new to commit patch to GCC trunk.
I didn't figure out how to commit patch to GCC trunk.
And I am afraid of producing a potential risk to GCC trunk during stage 4 in GCC 13.
So I am gonna learn to commit codes when GCC 14 is open.
And currently, I let Kito commit patch for me.
juzhe.zhong@rivai.ai
From: Jeff Law
Date: 2023-03-15 02:13
To: juzhe.zhong; gcc-patches
CC: kito.cheng
Subject: Re: [PATCH] RISC-V: Fix Bug 109092
On 3/13/23 08:17, juzhe.zhong@rivai.ai wrote:
> From: Ju-Zhe Zhong <juzhe.zhong@rivai.ai>
>
> This patch fix bug: https://gcc.gnu.org/bugzilla/show_bug.cgi?id=109092.
>
> gcc/ChangeLog:
>
> * config/riscv/riscv.md: Fix subreg bug.
LGTM. Do you have write access now? If so, go ahead and commit this patch.
Do you have any interest in fixing up a similar bug in peephole.md?
Jeff
Committed with commit log tweak:
https://gcc.gnu.org/git/?p=gcc.git;a=commit;h=02880e7803b19c357718abd2f0d567b4a761f318
On Wed, Mar 15, 2023 at 11:06 AM juzhe.zhong@rivai.ai
<juzhe.zhong@rivai.ai> wrote:
>
> Yes, I have write access. However, I am new to commit patch to GCC trunk.
> I didn't figure out how to commit patch to GCC trunk.
> And I am afraid of producing a potential risk to GCC trunk during stage 4 in GCC 13.
>
> So I am gonna learn to commit codes when GCC 14 is open.
> And currently, I let Kito commit patch for me.
>
>
> juzhe.zhong@rivai.ai
>
> From: Jeff Law
> Date: 2023-03-15 02:13
> To: juzhe.zhong; gcc-patches
> CC: kito.cheng
> Subject: Re: [PATCH] RISC-V: Fix Bug 109092
>
>
> On 3/13/23 08:17, juzhe.zhong@rivai.ai wrote:
> > From: Ju-Zhe Zhong <juzhe.zhong@rivai.ai>
> >
> > This patch fix bug: https://gcc.gnu.org/bugzilla/show_bug.cgi?id=109092.
> >
> > gcc/ChangeLog:
> >
> > * config/riscv/riscv.md: Fix subreg bug.
> LGTM. Do you have write access now? If so, go ahead and commit this patch.
>
> Do you have any interest in fixing up a similar bug in peephole.md?
>
> Jeff
>
@@ -1364,8 +1364,8 @@
(zero_extend:DI
(match_operand:SI 1 "nonimmediate_operand" " r,m")))]
"TARGET_64BIT && !TARGET_ZBA
- && !(REG_P (operands[1])
- && REGNO (operands[1]) == VL_REGNUM)"
+ && !(register_operand (operands[1], SImode)
+ && reg_or_subregno (operands[1]) == VL_REGNUM)"
"@
#
lwu\t%0,%1"
@@ -1747,7 +1747,7 @@
"(register_operand (operands[0], SImode)
|| reg_or_0_operand (operands[1], SImode))
&& !(register_operand (operands[1], SImode)
- && REGNO (operands[1]) == VL_REGNUM)"
+ && reg_or_subregno (operands[1]) == VL_REGNUM)"
{ return riscv_output_move (operands[0], operands[1]); }
[(set_attr "move_type" "move,const,load,store,mtc,fpload,mfc,fpstore,rdvlenb")
(set_attr "mode" "SI")