zahiraam wrote:

> > MSVC always uses 64-bit `long double`. I don't know anything about attempts 
> > to use 80-bit `long double` on Windows except that they're asking for tons 
> > of complexity.
> 
> Right, that was what I thought (a few years ago I was _very_ jealous of win64 
> making that choice).
> 
> To understand what clang might be doing wrong, what happens if someone were 
> to do something along the lines of (stealing from original failure) this?
> 
> ```c++
> #include <array>                                                              
>           
> struct Klass { some_overaligned_type_t field; };
>                                                                               
>           
> void test() {                                                                 
>           
>   std::array<Klass, 16> matrix;
>   matrix.fill({}); 
> } 
> ```
> 
> would that be expected to work?

 Yes, with this patch, `std::array<Klass, overaligned_type>` works correctly 
and gets the proper alignment  
  even with `#pragma pack`.

https://github.com/llvm/llvm-project/pull/208256
_______________________________________________
cfe-commits mailing list
[email protected]
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

Reply via email to