0

I have one process in Linux server, am setting 1gb virtual memory for that process using setrlimit() function and openmp is used in the code base. During execution process got crashed, core file is generated. I have debugged the core file and found that crash is happening in the #pragma omp parallel for line. I think virtual memory is exceeded in openmp statement and bad_alloc exception is raised and not it handled. I have tried to add this #pragma omp parallel for line in inside try block and added catch block with bad_alloc exception but it is not catching. Even I tired with catch(...) but no luck.

Can you all share your suggestion to how to handle exceptions which is raised by omp statement.

Srinu
  • 1
  • 1

0 Answers0