I want help to figure out automatic parallelization with error - Loop not parallelized: may not be beneficial. I want to test this code for parallelization, but I don't know, how to make the code effective for compiler to parallelizie it.
Here is the code:
for (i = 0; i < piece_length; i++) {
x=(i/(double)piece_length)+piece/(float)2;
// if(x<=1.0){
integral=4/(1+x*x);
sum=sum+integral;
// }
}
Loop not parallelized: may not be beneficial
Do you know how to make this loop more time demanding to be able to accept automatic parallelization?
Thx