This thread has been locked.

If you have a related question, please click the "Ask a related question" button in the top right corner. The newly created question will be automatically linked to this question.

  • Resolved

OpenMP 4.0 Issues when compiling on EVMK2H

Prodigy 60 points

Replies: 4

Views: 6246

Hi guys!

 I'm researching how OpenMP 4.0 examples works in order to understand the basics of OpenMP in heterogeneous platforms.

All of the MCSDK-HPC packge out of the box examples works, but when i started modifying an OpenCL example (matmpy) to use OpenMP instead of OpenCL things changed.  

I have modified OpenCL matmpy example to use OpenCL using veccadd OpenMP example. Apparently the modification is not to complex, but when i try to compile target code and host code files clacc gives me an error saying:  

"INTERNAL ERROR: omps2s6x experienced a segmentation fault while processing function (unknown or file scope) file (unknown) line 0"

I have tried to modify OpenMP pragmas to simplify them, but the error persists and it's kind ambigous so i can't figure out what's happening. Have anyone any idea about what is happening? 

I have attached Makefile, target and host files as a zip file.

Thanks in advance, Pablo.

mat_mpy_openmp.zip

  • Hi Pablo,

     

    I am investigating this crash.  Hopefully, will have an answer for you soon.

    Eric

  • In reply to EricStotzer:

    The bug is caused by the variable length array (VLA) b_col.  you can workaround this issue by changing b_col as I've done below.

    I will file a bug report.

     

    #pragma omp parallel for

       for (col = 0; col < mat_M; ++col)

       {

           float b_col[15];

           for (row = 0; row < mat_K; ++row)

               b_col[row] = B[row*mat_M+col];

           for (row = 0; row < mat_N; ++row)

               C[row*mat_M+col] = dotprod(A + (row * mat_K), b_col, mat_K);

       }

  • In reply to EricStotzer:

    Thank you! This workaround solve it!

  • Hello, I will be purchasing a EVMK2H soon. Can you please tell me where I can download OpenMP 4.0? Thanks

This thread has been locked.

If you have a related question, please click the "Ask a related question" button in the top right corner. The newly created question will be automatically linked to this question.