Diagnostic 10182: disabling optimization; runtime debug checks enabled

Problem : The compiler issues the message if runtime checks are enabled with /RTCx or /GZ(deprecated) and an optimization option are used together. Runtime checks are only performed on unoptimized code, so the compiler will disable all optimization options.

#include <iostream>
using namespace std;

void main(){
   cout << "Hello World" << endl;
>icl /RTC1 /fast hello.cpp
Intel® C++ Compiler XE for applications running on IA-32, Version Build 20110427
Copyright (C) 1985-2011 Intel Corporation. All rights reserved.

icl: warning #10182: disabling optimization; runtime debug checks enabled

Resolution : Runtime checks should only be used in development state. For release builds the option should not be used. Because of the included runtime checks the code will be larger and slower than a build with only /Od.

So use for release builds:
>icl /fast hello.cpp
and for development builds:
>icl /RTC1 hello.cpp
For more complete information about compiler optimizations, see our Optimization Notice.