Re: [PATCH] small _BitInt tweaks

2023-09-12 Thread Joseph Myers
On Tue, 12 Sep 2023, Jakub Jelinek via Gcc-patches wrote: > And by ensuring we never create 1-bit signed BITINT_TYPE e.g. the backends > don't need to worry about them. > > But I admit I don't feel strongly about that. > > Joseph, what do you think about this? I think it's appropriate to avoid

Re: [PATCH] small _BitInt tweaks

2023-09-12 Thread Jakub Jelinek via Gcc-patches
On Tue, Sep 12, 2023 at 10:27:18AM +, Richard Biener wrote: > On Mon, 11 Sep 2023, Jakub Jelinek wrote: > > And, also I think it is undesirable when being asked for signed_type_for > > of unsigned _BitInt(1) (which is valid) to get signed _BitInt(1) (which is > > invalid, the standard only allo

Re: [PATCH] small _BitInt tweaks

2023-09-12 Thread Richard Biener via Gcc-patches
On Mon, 11 Sep 2023, Jakub Jelinek wrote: > Hi! > > When discussing PR111369 with Andrew Pinski, I've realized that > I haven't added BITINT_TYPE handling to range_check_type. Right now > (unsigned) max + 1 == (unsigned) min for signed _BitInt,l so I think we > don't need to do the extra hops fo

[PATCH] small _BitInt tweaks

2023-09-11 Thread Jakub Jelinek via Gcc-patches
Hi! When discussing PR111369 with Andrew Pinski, I've realized that I haven't added BITINT_TYPE handling to range_check_type. Right now (unsigned) max + 1 == (unsigned) min for signed _BitInt,l so I think we don't need to do the extra hops for BITINT_TYPE (though possibly we don't need them for I