Forum Jump

Select Group :
Select Forum :
Sorted By :
Sort Order :
From The :
 
Thread Tools  Search this thread 
satheesan
Total Points:
35
Registered User
July 3, 2009 1:25 AM PDT
Can assembly function written with AVX instructions be built for running on corei7?
If I use AVX instructions in my assembly function I can built and I can run it on a Sandy Bridge based processor which will be launching in the marker in 2010. My question is , is it possible for me to build the same assembly code without any change to run on an existing corei7 architecture processor?(may be by using any assembler switch?). The reason for this question is, I don't want to have a  performance compramise when I move from corei7 to Sandy Bridge, and at the same time I don't want to put additional effort to build two variance, one for corei7 and another for Sandy Bridge. Thanks in advance.
Igor Levicki
Total Points:
10,855
Status Points:
10,855
Black Belt
July 4, 2009 9:08 AM PDT
Rate
 
|Best Answer
#1
Quoting - satheesan
If I use AVX instructions in my assembly function I can built and I can run it on a Sandy Bridge based processor which will be launching in the marker in 2010. My question is , is it possible for me to build the same assembly code without any change to run on an existing corei7 architecture processor?(may be by using any assembler switch?). The reason for this question is, I don't want to have a  performance compramise when I move from corei7 to Sandy Bridge, and at the same time I don't want to put additional effort to build two variance, one for corei7 and another for Sandy Bridge. Thanks in advance.

You can do one of the following:

1. Use Intel compiler which supports AVX code generation and generate two code paths by using proper switches.
2. Write two versions of the performance critical function, one for SSE4.2, one for AVX.

You cannot write assembler code which uses AVX, and make it run on Core i7 (except in AVX emulator which is not optimal).


--------
If you find my post helpfull, please rate it and/or select it as a best answer where applies. Thank you.


satheesan
Total Points:
35
Registered User
July 5, 2009 9:29 PM PDT
Rate
 
#2 Reply to #1
Quoting - Igor Levicki

You can do one of the following:

1. Use Intel compiler which supports AVX code generation and generate two code paths by using proper switches.
2. Write two versions of the performance critical function, one for SSE4.2, one for AVX.

You cannot write assembler code which uses AVX, and make it run on Core i7 (except in AVX emulator which is not optimal).


Thank you very much Igor Levicki.




Intel Software Network Forums Statistics

8290 users have contributed to 31236 threads and 99111 posts to date.
In the past 24 hours, we have 7 new thread(s) 20 new posts(s), and 30 new user(s).

In the past 3 days, the most popular thread for everyone has been comparison cilk++, openmp, pthreads first results The most posts were made to comparison cilk++, openmp, pthreads first results The post with the most views is Very amusing...  Escalated as

Please welcome our newest member zq.x