Community
cancel
Showing results for 
Search instead for 
Did you mean: 
TyMac
Beginner
57 Views

Questions on AVX backwards compatability (SSE)

Will code that was formerly complied in a generic format for SSE run with out modification on AVX?

0 Kudos
12 Replies
Kittur_G_Intel
Employee
57 Views

Hi,

Yes and ensure that the target system you run that compiled application contains the SSE version you compiled the app with.

-Kittur

TyMac
Beginner
57 Views

What if the linux verison does not have support for AVX in the kernel? Will the application still be able to see and use them?

Kittur_G_Intel
Employee
57 Views

Hi,

SIMD extensions and SSE thereof require support from the operating system (kernel of course) so the registers are handled properly by the OS. That said, as long as the OS supports the SSE you've compiled the application for it should run fine even if that kernel has no support for AVX. If you compile the application for avx, then you'll need to have a minimum kernel version to support avx instructions for that matter.

You can run "%cat /proc/cpuinfo" on your system and check the flags settings in the output. If it says avx then that system supports avx and likewise you can check for sse versions too.

Does that answer your question?

_Kittur

TyMac
Beginner
57 Views

Thanks :) Yes that make sense - I geuss too much sense :) Thanks for your time!

Kittur_G_Intel
Employee
57 Views

Thanks :-)

Bernard
Black Belt
57 Views

On Windows OS handling (saving ) SSE and AVX floating point context is done by the kernel.

Kittur_G_Intel
Employee
57 Views

Good point Iliayapolak, yes whenever there's context switching from one process to another the simd registers will have to be saved while whatever was saved before for the new active process needs to be restored.....:-)

_Kittur

TimP
Black Belt
57 Views

iliyapolak wrote:

On Windows OS handling (saving ) SSE and AVX floating point context is done by the kernel.

That's the point on which running AVX on an OS which doesn't support it (XP or Win7 without SP) could prove unreliable or insecure even if it appears to work.
Kittur_G_Intel
Employee
57 Views

Tim, that's something a user using AVX or SSE should be aware of, thanks.

TyMac
Beginner
57 Views

I think in older linux kernels the user to kernel context switch could not be handled by SSE. In other words the registers would loose / over write their data. I am not sure if this has been fixed.... I would be interested to know at what kernel revision it was.

TimP
Black Belt
57 Views

You would go back more than 15 years to find a kernel without sse support.  Red hat and centos 5.x are still in use while lacking avx support.

Bernard
Black Belt
57 Views

Tim Prince wrote:

Quote:

iliyapolak wrote:

On Windows OS handling (saving ) SSE and AVX floating point context is done by the kernel.

 


That's the point on which running AVX on an OS which doesn't support it (XP or Win7 without SP) could prove unreliable or insecure even if it appears to work.

Regarding Win 7 if I remember correctly KeSaveFloatingPointState() function was responsible for saving YMM register context,but I need to check it.