[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <aa329b6fa5764e03ad6891142c2311fc@AcuMS.aculab.com>
Date: Thu, 6 Oct 2022 08:12:04 +0000
From: David Laight <David.Laight@...LAB.COM>
To: 'Nick Desaulniers' <ndesaulniers@...gle.com>,
YingChi Long <me@...lyc.cn>
CC: "bp@...en8.de" <bp@...en8.de>,
"chang.seok.bae@...el.com" <chang.seok.bae@...el.com>,
"dave.hansen@...ux.intel.com" <dave.hansen@...ux.intel.com>,
"hpa@...or.com" <hpa@...or.com>,
"linux-kernel@...r.kernel.org" <linux-kernel@...r.kernel.org>,
"mingo@...hat.com" <mingo@...hat.com>,
"pbonzini@...hat.com" <pbonzini@...hat.com>,
"tglx@...utronix.de" <tglx@...utronix.de>,
"x86@...nel.org" <x86@...nel.org>,
"peterz@...radead.org" <peterz@...radead.org>
Subject: RE: [PATCH v2] x86/fpu: use _Alignof to avoid UB in TYPE_ALIGN
From: Nick Desaulniers
> Sent: 05 October 2022 19:58
...
> https://www.open-std.org/jtc1/sc22/wg14/www/docs/n3054.pdf
> Section 6.2.8 "Alignment of objects" refers to "fundamental alignment"
> and "extended alignment."
>
> I wonder if it would be precise to say that "_Alignof evaluates to the
> fundamental alignment while __alignof__ evaluates to the extended
> alignment (which is implementation defined, typically by the machine
> specific ABI)." Though even that seems imprecise since it sounds like
> a fundamental alignment could be less than or equal to what alignof
> evaluates to.
Except that neither of those terms makes any sense to most
people.
Something like "__alignof__() is the preferred alignment and
_Alignof() the minimal alignment. For 'long long' on x86 these
are 8 and 4 respectively."
David
-
Registered Address Lakeside, Bramley Road, Mount Farm, Milton Keynes, MK1 1PT, UK
Registration No: 1397386 (Wales)
Powered by blists - more mailing lists