internal error: 0_1204 when openmp used with try-catch

Reference Number : Q625172

Version : 12.0 update 1 & 2

Product : Intel® C++ Compiler XE 12.0 update 1 & 2

Operating System : Windows*

Problem Description : 
The below code was reduced from a big customer project, that uses Qt. The bug is in Intel compiler,
when openmp pragma/option is used, and exception-handling is used in a particular manner, though not in other cases. The workaround is to use /Od , instead of /O2. Or, do not use openmp pragma. Also, enable /EHsc since C++ exception handling mechanism is used.

Command-line for the bug:--
icl /c /Qopenmp /EHsc qterror.cpp

compile Error :-- internal error: 0_1204

Sometimes, during parallel compilation (using /MP), when such compile errors are generated, the below error message also comes in the output.
icl: error #10298: problem during post processing of parallel object compilation

Below sample code generates the error:--

#include <iostream>
using namespace std;
#include <vector>

class myclass{};
vector<myclass>					myvec;
template <typename T>
const T &mymin(const T &a, const T &b) { if (a < b) return a; return b; }
void func(const char* ch, const char* FILE, int LINE)
	cout << ch << " in file: " << __FILE__ << " in line: " << __LINE__ << "n";
bool Do()
		myclass *j=&myvec[100];
		int lines = mymin(10,100);

			#pragma omp parallel for //num_threads(komp_num_threads) schedule(guided)
			for (int y = 0; y <= 100; y++)
			try {
			func( "Openmp error",__FILE__, __LINE__ );		
			}catch(std::exception e) { };
		return 1;

Resolution Status : This bug has been resolved in Intel Composer 12.0 XE update 3 , 4
