https://gcc.gnu.org/bugzilla/show_bug.cgi?id=88085

--- Comment #11 from Petro Karashchenko <petro.karashchenko at gmail dot com> 
---
Sorry but based on

@cindex @code{aligned} variable attribute
@item aligned
@itemx aligned (@var{alignment})
The @code{aligned} attribute specifies a MINIMUM alignment for the variable
or structure field, measured in bytes.  When specified, @var{alignment} must
be an integer constant power of 2.  Specifying no @var{alignment} argument
implies the maximum alignment for the target, which is often, but by no
means always, 8 or 16 bytes.

I do not see any statement saying that giving a lower alignment is invalid.
I see "attribute specifies a MINIMUM alignment" so "int i
__attribute__((aligned(1)));" specifies that between 1 and 4 the 1 should be
chosen as a "MINIMUM".

The statement "must be an integer constant power of 2" is also valid because 1
is a 0 power of 2. So no questions here.

"Thus IMHO this bug is invalid." -- I do not see any strong argument on this.
All prerequisites from a description are met, so this is a pure bug.

Reply via email to