Community
cancel
Showing results for 
Search instead for 
Did you mean: 
newport_j
Beginner
64 Views

icc compiler questions



Is this the area for asking Intel compiler questions? I was referred to that area by the Intel Cilk Plus forum whenI started askng questions about the icc compiler.I need to ask some icc questions; soifI am in the correct place please let me know, ifI am not then direct me.

AmI in the icc compiler forum?

Thanks in advance.

Newport_j
0 Kudos
4 Replies
JenniferJ
Moderator
64 Views

yes, this is the right forum for Intel C++ compiler questions.

Jennifer
newport_j
Beginner
64 Views

Well, my quetion is really a c source code question. i read in a c tutorial book that a while loopcan be considered a for loop without an idex and a stopping criterion. This of course applies to gcc, but does it apply to icc?

Also, in C and its descendants, a while loop is a for loop with no initialization or counting expressions, i.e.,

for ( ; condition; )

{

statements;

}

Is this true for icc?I want to replace while loops with for loops. If this works in icc great.

Thanks in advance.

Newport_j

JenniferJ
Moderator
64 Views

This is C language feature, icc supports it. icc is compatible with gcc.

Jennifer

TimP
Black Belt
64 Views

Yes, the syntax is equivalent. It isn't likely to help with optimization; unless the compiler can pick up a trip count to make the loop countable, neither gcc nor icc will be able to vectorize, and _Cilk_for probably won't work.
Reply