Hi all,

    I don't know is here right place for sharing ideas, but I don't have idea, where I can send it. I have simple idea. When I turned on OpenMP, for parallelly execute simple for it's enough when I add line like this before loop:
#pragma omp parallel for
for (size_t i = 0; i < 1000000; i++)
   vec_c[i] = vec_a[i] * vec_b[i];

Why don't use similar idea for show compiler that, it can by done by SIMD CPU extension? e.g.
#pragma simd for

Maybe I'm wrong and there is better way for do it, and I don't know how. If I'm right, maybe it could be idea for extend C/C++ in this way.
Best regards,
Jakub

Reply via email to