Re: [PATCH] Fix x86/56337 : 1<<28 alignment is broken

2021-08-30 Thread Richard Biener via Gcc-patches
On Mon, Aug 30, 2021 at 11:38 PM Andrew Pinski via Gcc-patches wrote: > > On Fri, Jul 23, 2021 at 1:33 PM apinski--- via Gcc-patches > wrote: > > > > From: Andrew Pinski > > > > The problem here is the x86_64 back-end uses a signed integer > > for alignment and then divides by BITS_PER_UNIT so i

Re: [PATCH] Fix x86/56337 : 1<<28 alignment is broken

2021-08-30 Thread Andrew Pinski via Gcc-patches
On Fri, Jul 23, 2021 at 1:33 PM apinski--- via Gcc-patches wrote: > > From: Andrew Pinski > > The problem here is the x86_64 back-end uses a signed integer > for alignment and then divides by BITS_PER_UNIT so if we had > INT_MIN (which is what 1<<28*8 is), we would get the wrong result. > > This

[PATCH] Fix x86/56337 : 1<<28 alignment is broken

2021-07-23 Thread apinski--- via Gcc-patches
From: Andrew Pinski The problem here is the x86_64 back-end uses a signed integer for alignment and then divides by BITS_PER_UNIT so if we had INT_MIN (which is what 1<<28*8 is), we would get the wrong result. This fixes the problem by using unsigned for the argument to x86_output_aligned_bss an