auto vectorization observations

Bruce Carneal bcarneal at gmail.com
Fri Jun 10 01:25:08 UTC 2022


On Thursday, 9 June 2022 at 23:35:11 UTC, user1234 wrote:
> On Thursday, 9 June 2022 at 20:32:44 UTC, Bruce Carneal wrote:
>
> Thanks for the precision, I wondered the same as Siarhei.
> gdc options "-O3 -mavx512bw" produceq the same output as your.
> With no surprise LDC does not do better with -mattr=+avx512bw.

Turns out gdc can vectorize it with the much more widely 
available x86-64-v3 target if your data elements are 4 bytes or 
larger.  Unfortunately ldc still can not.

Your avx512bw discovery prompted me to give the larger types a 
try.  Thanks for digging into it.

Here's the link:
https://godbolt.org/z/ajjjj8vfY



More information about the Digitalmars-d mailing list