This is the mail archive of the gcc@gcc.gnu.org mailing list for the GCC project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

Re: asking for __attribute__((aligned()) clarification


On Wed, 21 Aug 2019 at 17:50, Paul Koning <paulkoning@comcast.net> wrote:
>
>
>
> > On Aug 21, 2019, at 10:57 AM, Alexander Monakov <amonakov@ispras.ru> wrote:
> >
> > On Wed, 21 Aug 2019, Paul Koning wrote:
> >
> >> I agree, but if the new approach generates a warning for code that was written
> >> to the old rules, that would be unfortunate.
> >
> > FWIW I don't know which GCC versions accepted 'packed' on a scalar type.
>
> That wasn't what I meant; I was talking about the packed and aligned attributes on struct members.  I thought you were saying that ((packed,aligned(2))) is now a warning.  That doesn't appear to be the case, though; it's accepted without complaint as it always was.

Right, nobody's suggesting that should be a warning. The warning is
for trying to pack a scalar variable, which is (and always was)
meaningless.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]