Intel® C++ Compiler
Support and discussions for creating C++ code that runs on platforms based on Intel® processors.
7646 Discussions

Also for SIMD-enabled functions it is not allowed to have side effects except writes by their ...

mikeitexpert
New Contributor II
218 Views

Hi Everybody,

I am new to vector programming and I am studying here and there just to better understand the details ...

There is a statement which isn't clear to me enough saying ... "Also for SIMD-enabled functions it is not allowed to have side effects except writes by their arguments. This rule can be violated by non-vector function calls, so be careful executing such calls in SIMD-enabled functions."

What does the above mean by "side effects except writes by their arguments. "?

I would appreciate any comments / elaboration.

Regards

 

https://software.intel.com/content/www/us/en/develop/documentation/cpp-compiler-developer-guide-and-...

 

mikeitexpert_0-1617360854476.png

 

0 Kudos
1 Solution
RahulV_intel
Moderator
185 Views

Hi,


Side-effect basically means that that a  SIMD-enabled function cannot change any state outside of the function. (Like modifying a variable outside its local environment is not permitted)


Thanks,

Rahul


View solution in original post

2 Replies
RahulV_intel
Moderator
186 Views

Hi,


Side-effect basically means that that a  SIMD-enabled function cannot change any state outside of the function. (Like modifying a variable outside its local environment is not permitted)


Thanks,

Rahul


RahulV_intel
Moderator
170 Views

Hi,


Thanks for accepting the solution. Intel will no longer monitor this thread. Further discussions on this thread will be considered community only.


Regards,

Rahul


Reply