[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: [csmith-dev] Pragma pack clang/gcc difference
Thanks Pascal. In any case, definitely not something we want to test.
On 08/14/2011 01:48 PM, Pascal Cuoq wrote:
On Sun, Aug 14, 2011 at 9:00 PM, John Regehr <email@example.com
Clang and GCC have different layouts when using #pragma pack
together with size 0 bitfields!
This is interesting. I wonder if it's intended, a bug, or just
something that nobody cares about?
This does not answer your question completely, but I understand that the
pack pragma was originally a feature of Microsoft compilers. GCC
implemented it, and when later Clang implementors noticed that there
were differences between the GCC implementation and the original
Microsoft one, they decided to retain compatibility with the Microsoft
version, dropping compatibility with GCC. So at least Clang implementors
know about this subtlety.