Re: [PATCH 2/2] validate_subreg before call gen_lowpart to avoid ICE.

2021-09-13 Thread Richard Biener via Gcc-patches
On Mon, Sep 13, 2021 at 1:14 PM Hongtao Liu wrote: > > On Mon, Sep 13, 2021 at 5:15 PM Richard Biener > wrote: > > > > On Mon, Sep 13, 2021 at 8:26 AM Hongtao Liu wrote: > > > > > > On Mon, Sep 13, 2021 at 2:11 PM Richard Biener via Gcc-patches > > > wrote: > > > > > > > > On Fri, Sep 10, 2021

Re: [PATCH 2/2] validate_subreg before call gen_lowpart to avoid ICE.

2021-09-13 Thread Tobias Burnus
On 13.09.21 13:14, Hongtao Liu via Gcc-patches wrote: Yes, update patch bootstrapped and regtested on x86_64-linux-gnu{-m32,}. Ok for trunk? If that patch gets approved, can you add PR bootstrap/102302 to the commit changelog ? cf. https://gcc.gnu.org/PR102302 Thanks, Tobias gcc/Chang

Re: [PATCH 2/2] validate_subreg before call gen_lowpart to avoid ICE.

2021-09-13 Thread Hongtao Liu via Gcc-patches
On Mon, Sep 13, 2021 at 5:15 PM Richard Biener wrote: > > On Mon, Sep 13, 2021 at 8:26 AM Hongtao Liu wrote: > > > > On Mon, Sep 13, 2021 at 2:11 PM Richard Biener via Gcc-patches > > wrote: > > > > > > On Fri, Sep 10, 2021 at 2:58 PM liuhongt wrote: > > > > > > > > gcc/ChangeLog: > > > > > > >

Re: [PATCH 2/2] validate_subreg before call gen_lowpart to avoid ICE.

2021-09-13 Thread Richard Biener via Gcc-patches
On Mon, Sep 13, 2021 at 8:26 AM Hongtao Liu wrote: > > On Mon, Sep 13, 2021 at 2:11 PM Richard Biener via Gcc-patches > wrote: > > > > On Fri, Sep 10, 2021 at 2:58 PM liuhongt wrote: > > > > > > gcc/ChangeLog: > > > > > > * expmed.c (extract_bit_field_using_extv): validate_subreg > > >

Re: [PATCH 2/2] validate_subreg before call gen_lowpart to avoid ICE.

2021-09-12 Thread Hongtao Liu via Gcc-patches
On Mon, Sep 13, 2021 at 2:11 PM Richard Biener via Gcc-patches wrote: > > On Fri, Sep 10, 2021 at 2:58 PM liuhongt wrote: > > > > gcc/ChangeLog: > > > > * expmed.c (extract_bit_field_using_extv): validate_subreg > > before call gen_lowpart. > > --- > > gcc/expmed.c | 6 +- > >

Re: [PATCH 2/2] validate_subreg before call gen_lowpart to avoid ICE.

2021-09-12 Thread Richard Biener via Gcc-patches
On Fri, Sep 10, 2021 at 2:58 PM liuhongt wrote: > > gcc/ChangeLog: > > * expmed.c (extract_bit_field_using_extv): validate_subreg > before call gen_lowpart. > --- > gcc/expmed.c | 6 +- > 1 file changed, 5 insertions(+), 1 deletion(-) > > diff --git a/gcc/expmed.c b/gcc/expmed

Re: [PATCH 2/2] validate_subreg before call gen_lowpart to avoid ICE.

2021-09-11 Thread Hongtao Liu via Gcc-patches
On Sat, Sep 11, 2021 at 5:51 PM Hongtao Liu wrote: > > On Sat, Sep 11, 2021 at 4:25 PM Richard Biener via Gcc-patches > wrote: > > > > On September 10, 2021 11:27:16 PM GMT+02:00, Segher Boessenkool > > wrote: > > >On Fri, Sep 10, 2021 at 08:36:12PM +0200, Richard Biener wrote: > > >> On Septem

Re: [PATCH 2/2] validate_subreg before call gen_lowpart to avoid ICE.

2021-09-11 Thread Hongtao Liu via Gcc-patches
On Sat, Sep 11, 2021 at 4:25 PM Richard Biener via Gcc-patches wrote: > > On September 10, 2021 11:27:16 PM GMT+02:00, Segher Boessenkool > wrote: > >On Fri, Sep 10, 2021 at 08:36:12PM +0200, Richard Biener wrote: > >> On September 10, 2021 6:24:50 PM GMT+02:00, Segher Boessenkool > >> wrote:

Re: [PATCH 2/2] validate_subreg before call gen_lowpart to avoid ICE.

2021-09-11 Thread Richard Biener via Gcc-patches
On September 10, 2021 11:27:16 PM GMT+02:00, Segher Boessenkool wrote: >On Fri, Sep 10, 2021 at 08:36:12PM +0200, Richard Biener wrote: >> On September 10, 2021 6:24:50 PM GMT+02:00, Segher Boessenkool >> wrote: >> >Yes, we should not call TRULY_NOOP_TRUNCATION_MODES_P for any random two >> >mo

Re: [PATCH 2/2] validate_subreg before call gen_lowpart to avoid ICE.

2021-09-10 Thread Hongtao Liu via Gcc-patches
On Sat, Sep 11, 2021 at 8:29 AM Hongtao Liu wrote: > > On Sat, Sep 11, 2021 at 5:21 AM Segher Boessenkool > wrote: > > > > On Fri, Sep 10, 2021 at 10:25:45PM +0800, Hongtao Liu wrote: > > > Updated patch. > > > > > > Bootstrapped and regtested on x86_64-linux-gnu{-m32,}, do I need to > > > run

Re: [PATCH 2/2] validate_subreg before call gen_lowpart to avoid ICE.

2021-09-10 Thread Hongtao Liu via Gcc-patches
On Sat, Sep 11, 2021 at 5:21 AM Segher Boessenkool wrote: > > On Fri, Sep 10, 2021 at 10:25:45PM +0800, Hongtao Liu wrote: > > Updated patch. > > > > Bootstrapped and regtested on x86_64-linux-gnu{-m32,}, do I need to > > run this patch on other targets machine, or the patch is supposed to > >

Re: [PATCH 2/2] validate_subreg before call gen_lowpart to avoid ICE.

2021-09-10 Thread Segher Boessenkool
On Fri, Sep 10, 2021 at 08:36:12PM +0200, Richard Biener wrote: > On September 10, 2021 6:24:50 PM GMT+02:00, Segher Boessenkool > wrote: > >Yes, we should not call TRULY_NOOP_TRUNCATION_MODES_P for any random two > >modes: such a truncation needs to have a meaning at all, for the > >question to

Re: [PATCH 2/2] validate_subreg before call gen_lowpart to avoid ICE.

2021-09-10 Thread Segher Boessenkool
On Fri, Sep 10, 2021 at 10:25:45PM +0800, Hongtao Liu wrote: > Updated patch. > > Bootstrapped and regtested on x86_64-linux-gnu{-m32,}, do I need to > run this patch on other targets machine, or the patch is supposed to > have minimal impact on other targets? > Then, ok for trunk? [-- Attac

Re: [PATCH 2/2] validate_subreg before call gen_lowpart to avoid ICE.

2021-09-10 Thread Richard Biener via Gcc-patches
On September 10, 2021 6:24:50 PM GMT+02:00, Segher Boessenkool wrote: >On Fri, Sep 10, 2021 at 03:58:47PM +0200, Richard Biener wrote: >> On September 10, 2021 3:30:10 PM GMT+02:00, Segher Boessenkool >> wrote: >> >TRULY_NOOP_TRUNCATION does not make sense to ask if changing mode class. >> >>

Re: [PATCH 2/2] validate_subreg before call gen_lowpart to avoid ICE.

2021-09-10 Thread Segher Boessenkool
On Fri, Sep 10, 2021 at 03:58:47PM +0200, Richard Biener wrote: > On September 10, 2021 3:30:10 PM GMT+02:00, Segher Boessenkool > wrote: > >TRULY_NOOP_TRUNCATION does not make sense to ask if changing mode class. > > OK, so there's a mode class comparison missing here which should be a better

Re: [PATCH 2/2] validate_subreg before call gen_lowpart to avoid ICE.

2021-09-10 Thread Hongtao Liu via Gcc-patches
On Fri, Sep 10, 2021 at 9:44 PM Hongtao Liu wrote: > > On Fri, Sep 10, 2021 at 9:32 PM Richard Biener > wrote: > > > > On September 10, 2021 3:27:09 PM GMT+02:00, Hongtao Liu > > wrote: > > >On Fri, Sep 10, 2021 at 9:16 PM Richard Biener via Gcc-patches > > > wrote: > > >> > > >> On Fri, Sep 10

Re: [PATCH 2/2] validate_subreg before call gen_lowpart to avoid ICE.

2021-09-10 Thread Richard Biener via Gcc-patches
On September 10, 2021 3:30:10 PM GMT+02:00, Segher Boessenkool wrote: >On Fri, Sep 10, 2021 at 03:15:56PM +0200, Richard Biener wrote: >> On Fri, Sep 10, 2021 at 2:58 PM liuhongt wrote: >> >if (REG_P (target) >> > - && TRULY_NOOP_TRUNCATION_MODES_P (GET_MODE (target), ext_mode))

Re: [PATCH 2/2] validate_subreg before call gen_lowpart to avoid ICE.

2021-09-10 Thread Hongtao Liu via Gcc-patches
On Fri, Sep 10, 2021 at 9:32 PM Richard Biener wrote: > > On September 10, 2021 3:27:09 PM GMT+02:00, Hongtao Liu > wrote: > >On Fri, Sep 10, 2021 at 9:16 PM Richard Biener via Gcc-patches > > wrote: > >> > >> On Fri, Sep 10, 2021 at 2:58 PM liuhongt wrote: > >> > > >> > gcc/ChangeLog: > >> > >

Re: [PATCH 2/2] validate_subreg before call gen_lowpart to avoid ICE.

2021-09-10 Thread Hongtao Liu via Gcc-patches
On Fri, Sep 10, 2021 at 9:32 PM Richard Biener wrote: > > On September 10, 2021 3:27:09 PM GMT+02:00, Hongtao Liu > wrote: > >On Fri, Sep 10, 2021 at 9:16 PM Richard Biener via Gcc-patches > > wrote: > >> > >> On Fri, Sep 10, 2021 at 2:58 PM liuhongt wrote: > >> > > >> > gcc/ChangeLog: > >> > >

Re: [PATCH 2/2] validate_subreg before call gen_lowpart to avoid ICE.

2021-09-10 Thread Hongtao Liu via Gcc-patches
On Fri, Sep 10, 2021 at 9:27 PM Hongtao Liu wrote: > > On Fri, Sep 10, 2021 at 9:16 PM Richard Biener via Gcc-patches > wrote: > > > > On Fri, Sep 10, 2021 at 2:58 PM liuhongt wrote: > > > > > > gcc/ChangeLog: > > > > > > * expmed.c (extract_bit_field_using_extv): validate_subreg > > >

Re: [PATCH 2/2] validate_subreg before call gen_lowpart to avoid ICE.

2021-09-10 Thread Richard Biener via Gcc-patches
On September 10, 2021 3:27:09 PM GMT+02:00, Hongtao Liu wrote: >On Fri, Sep 10, 2021 at 9:16 PM Richard Biener via Gcc-patches > wrote: >> >> On Fri, Sep 10, 2021 at 2:58 PM liuhongt wrote: >> > >> > gcc/ChangeLog: >> > >> > * expmed.c (extract_bit_field_using_extv): validate_subreg >> >

Re: [PATCH 2/2] validate_subreg before call gen_lowpart to avoid ICE.

2021-09-10 Thread Segher Boessenkool
On Fri, Sep 10, 2021 at 03:15:56PM +0200, Richard Biener wrote: > On Fri, Sep 10, 2021 at 2:58 PM liuhongt wrote: > >if (REG_P (target) > > - && TRULY_NOOP_TRUNCATION_MODES_P (GET_MODE (target), ext_mode)) > > ^^^ > > I wonder if herein lies the problem in that the HFmode "trunca

Re: [PATCH 2/2] validate_subreg before call gen_lowpart to avoid ICE.

2021-09-10 Thread Hongtao Liu via Gcc-patches
On Fri, Sep 10, 2021 at 9:16 PM Richard Biener via Gcc-patches wrote: > > On Fri, Sep 10, 2021 at 2:58 PM liuhongt wrote: > > > > gcc/ChangeLog: > > > > * expmed.c (extract_bit_field_using_extv): validate_subreg > > before call gen_lowpart. > > --- > > gcc/expmed.c | 6 +- > >

Re: [PATCH 2/2] validate_subreg before call gen_lowpart to avoid ICE.

2021-09-10 Thread Richard Biener via Gcc-patches
On Fri, Sep 10, 2021 at 2:58 PM liuhongt wrote: > > gcc/ChangeLog: > > * expmed.c (extract_bit_field_using_extv): validate_subreg > before call gen_lowpart. > --- > gcc/expmed.c | 6 +- > 1 file changed, 5 insertions(+), 1 deletion(-) > > diff --git a/gcc/expmed.c b/gcc/expmed

[PATCH 2/2] validate_subreg before call gen_lowpart to avoid ICE.

2021-09-10 Thread liuhongt via Gcc-patches
gcc/ChangeLog: * expmed.c (extract_bit_field_using_extv): validate_subreg before call gen_lowpart. --- gcc/expmed.c | 6 +- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/gcc/expmed.c b/gcc/expmed.c index 3143f38e057..10d62d857a8 100644 --- a/gcc/expmed.c +++ b/g