View Full Version : How 'safe' is compiling program for SSE/SSE2 these days?
SassBot
14th June 2012, 15:23
Obviously this question is purely to elicit opinions, but what do you all think about compiling programs assuming a baseline of SSE or SSE2? Is the group of people running processors not supporting at least SSE big enough to trade off not compiling for SSE? This is all related to getting ready to compile a Windows executable to release and wondering if I should compile using GCC's autovectorization. Or is it still better to do SSE and non-SSE executables? Thanks.
mariush
14th June 2012, 15:47
In my opinion, pretty much everything released in the last 5-10 years or so supports SSE... SSE2 I'm not sure.
According to the Steam hardware survey, about 90% of the processors are dual core or higher and 99.68% support SSE2 : http://store.steampowered.com/hwsurvey (click on Physical CPUs and Other Settings)
Now this is a bit biased towards more powerful computers (which run games and Steam implicitly) so it may not be a good statistics if your software is for let's say office use.
Atak_Snajpera
14th June 2012, 15:49
don't look back to pentium 3 era. besides who these days uses single core cpu without sse2 instructions.
turab
14th June 2012, 16:21
You can safely assume that 64-bit CPUs support SSE2, so if you're releasing a 64-bit version, you don't need two separate executables. As for a 32-bit version, I personally wouldn't unless it makes a significant difference, in which case I'd have two executables -- one with auto-vectorization and one without.
_xxl
15th June 2012, 06:10
... I should compile using GCC's autovectorization....
Please be careful with autovectorization, I remember from compiling ffdshow with MinGW that some parts got broken. I don't know if latest GCC is better. U shoud test your app and see if SSE or SSE2 gives a good speed gain.
Casca
18th June 2012, 14:53
SSE+ in gcc is fairly safe in my experience, although it can occasionally break stuff (as any compiler generated optimization). Any way don't expect some magic boost. It can cut some overhead but SIMD stuff usually really comes in a handy when you're putting it yourself, on your own homemade implementations.
vBulletin® v3.8.11, Copyright ©2000-2026, vBulletin Solutions Inc.