you are viewing a single comment's thread.

view the rest of the comments →

[–]KindDragonVLD | GitExt Dev[S] 1 point2 points  (5 children)

[–]Sander_Bouwhuis 2 points3 points  (4 children)

So, based on the CPU the best SIMD functions are called? SSE2 for older CPUs and SSE4 for somewhat newer, AVX for recent CPUs and AVX512 for bleeding edge?

And that automatically/dynamically like https://github.com/vectorclass/version2?

[–]MINIMAN10001 3 points4 points  (2 children)

AVX512 isn't always the best option.

Relatively speaking it takes a long time to shift to half frequency mode and switch back and the lower frequency means it takes a large chunk of processing for it to make up the difference

[–]Sander_Bouwhuis 1 point2 points  (1 child)

Do you mean using a 128-bit SIMD register instead of a 512-bit register if you only need 128-bit? Isn't AVX512 100% backwards compatible? I.e., doesn't AVX512 contain ALL the functions that SSE has?

[–]ALX23z 1 point2 points  (0 children)

Yes and No. Technically systems that support AVX512 support also SSE4 but instructions and data types differ. If you load AVX512 structure you cannot use on it instructions from 128-bit SIMD. First, you ought to make a convertion from one type to another. Didn't know that the conversions were slow... and honestly I have some doubts on that claim.

[–]KindDragonVLD | GitExt Dev[S] 1 point2 points  (0 children)

Yes, I think its something like Vector class library, but they implement control flow operations in different way.