Intel® C++ Compiler
Community support and assistance for creating C++ code that runs on platforms based on Intel® processors.

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

pradeepit
Beginner
2,110 Views
Hi,

I am compiling my code, I am getting the following warning in release mode.

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



I changed "project properties->c/c++ compiler->code generation->basic runtime checks" to "default" from "Both (/RTC1, equiv. to /RTCsu)"



Now I am getting the following error.

1>ipo: warning #11021: unresolved __CrtDbgReportW
1> Referenced in ipo_37885obj.obj
1>ipo: warning #11021: unresolved ?npos@?$basic_string@DU?$char_traits@D@std@@V?$_DebugHeapAllocator@D@2@@std@@2IB
1> Referenced in ipo_37885obj.obj
1>ipo: error #11023: Not all components required for linking are present on command line



I am not understanding what is this error nor able to resolve it.

Please provide me with some solution

Regards

Pradeep
0 Kudos
9 Replies
Hubert_H_Intel
Employee
2,110 Views
Pradeep,
The warning indicates that you have set 'Configuration Properties > Intel Debugging > Parallel Debug Environment: Enabled' additionally to the standard optimizations (e.g. /O2).
If you don't want to use the Data Sharing Detection option with the Intel Parallel Debugger Extension in Visual Studio you should 'Disable' the Parallel Debug Environment.
Regards, Hubert.
0 Kudos
SergeyKostrov
Valued Contributor II
2,110 Views
>>...icl: warning #10182: disabling optimization; runtime debug checks enabled

A C Runtime library 'msvcrtd.lib' could be needed even if your configuration is Release.

>>...I changed "project properties->c/c++ compiler->code generation->basic runtime checks" to "default"
from "Both (/RTC1, equiv. to /RTCsu)"...

It is not clear why you did it? You had just a warning #10182 and it wasn't an error, right?

Also, C Runtime functions 'CrtDbgReportW' and 'DebugHeapAllocator' are referenced in acouple of
C Runtime librarieslike 'msv*d.lib' and 'lib*d.lib' located in a folder '..\VC\Lib'.

Best regards,
Sergey
0 Kudos
pradeepit
Beginner
2,110 Views

HiSergey,

The warning description says that the optimization is disabled. Because of which, the time taken in debug and release mode are almost same.

i needed the optimization levels tobe enabled.

regards

pradeep

0 Kudos
pradeepit
Beginner
2,110 Views

hi hubert,

I tried disabling the parallel debug environment. still the warning 10182 pops up. As i see, its affecting the optimization levels evedently.

This warning disappears, when Basic runtime checks are kept at default level. But I am getting the error11023 as above.

Regards

pradeep

0 Kudos
Hubert_H_Intel
Employee
2,110 Views
Pradeep,

Is that the full message? Didn't you get also a fatal linker error? If not, please check if you set option /Qipo ("Configuration properties > C/C++ > Optimization Intel > Interprocedural Optimization). If yes, switch it (temporarily) off to see if the error disappears.
Hubert.

0 Kudos
pradeepit
Beginner
2,110 Views

Hi hubert,

/Qipo option was set, when I disabled it, i got the following linker errors

1>Linking... (Intel C++ Environment)
1>xilink: executing 'link'
1>libcmt.lib(_file.obj) : error LNK2005: ___iob_func already defined in MSVCRT.lib(MSVCR90.dll)
1>libcmt.lib(fwrite.obj) : error LNK2005: _fwrite already defined in MSVCRT.lib(MSVCR90.dll)
1>libcmt.lib(crtheap.obj) : error LNK2005: __malloc_crt already defined in MSVCRT.lib(MSVCR90.dll)
1>libcmt.lib(crt0dat.obj) : error LNK2005: __amsg_exit already defined in MSVCRT.lib(MSVCR90.dll)
1>libcmt.lib(crt0dat.obj) : error LNK2005: __initterm_e already defined in MSVCRT.lib(MSVCR90.dll)
1>libcmt.lib(tidtable.obj) : error LNK2005: __encode_pointer already defined in MSVCRT.lib(MSVCR90.dll)
1>libcmt.lib(tidtable.obj) : error LNK2005: __encoded_null already defined in MSVCRT.lib(MSVCR90.dll)
1>libcmt.lib(tidtable.obj) : error LNK2005: __decode_pointer already defined in MSVCRT.lib(MSVCR90.dll)
1>libcmt.lib(crt0init.obj) : error LNK2005: ___xi_a already defined in MSVCRT.lib(cinitexe.obj)
1>libcmt.lib(crt0init.obj) : error LNK2005: ___xi_z already defined in MSVCRT.lib(cinitexe.obj)
1>libcmt.lib(crt0init.obj) : error LNK2005: ___xc_a already defined in MSVCRT.lib(cinitexe.obj)
1>libcmt.lib(crt0init.obj) : error LNK2005: ___xc_z already defined in MSVCRT.lib(cinitexe.obj)
1>libcmt.lib(hooks.obj) : error LNK2005: "void __cdecl terminate(void)" (?terminate@@YAXXZ) already defined in MSVCRT.lib(MSVCR90.dll)
1>libcmt.lib(winxfltr.obj) : error LNK2005: ___CppXcptFilter already defined in MSVCRT.lib(MSVCR90.dll)
1>libcmt.lib(mlock.obj) : error LNK2005: __unlock already defined in MSVCRT.lib(MSVCR90.dll)
1>libcmt.lib(mlock.obj) : error LNK2005: __lock already defined in MSVCRT.lib(MSVCR90.dll)
1>MSVCRT.lib(MSVCR90.dll) : error LNK2005: __write already defined in libcmt.lib(write.obj)
1> Creating library D:\semipl\ImageProcessingLibrary\SEMIPL\Common\Lib\SEMIPL.lib and object D:\semipl\ImageProcessingLibrary\SEMIPL\Common\Lib\SEMIPL.exp
1>LINK : warning LNK4098: defaultlib 'MSVCRT' conflicts with use of other libs; use /NODEFAULTLIB:library
1>MSVCRT.lib(cinitexe.obj) : warning LNK4098: defaultlib 'libcmt.lib' conflicts with use of other libs; use /NODEFAULTLIB:library
1>libcmt.lib(crt0.obj) : error LNK2019: unresolved external symbol _main referenced in function ___tmainCRTStartup
1>.\Lib\\SEMIPL.dll : fatal error LNK1120: 1 unresolved externals
1>Project : warning PRJ0018 : The following environment variables were not found:
1>$(INTEL_PE111_67_INSTALL_DIR)

probably the command line options of linker and compiler would give you more details on the options selected in my project environ ment. below is the compiler options

/c /O3 /Oi /Ot /I "..\Inc" /I "..\..\libTiff\Inc" /I "..\..\ASM" /I "..\..\CIPL" /I "..\..\IP" /I "..\..\CPPIPL" /I "..\..\RTools" /I "..\..\Verbosity" /I "IPP\ia32\Include" /D "WIN32" /D "_DEBUG" /D "_WINDOWS" /D "_USRDLL" /D "IPL_EXPORTS" /D "_CRT_SECURE_NO_WARNINGS" /D "_CRT_NONSTDC_NO_DEPRECATE" /D "INTEL_SUITE_VERSION=PE111_67" /D "_WINDLL" /D "_UNICODE" /D "UNICODE" /EHsc /MD /GS /Gy /fp:fast /Fo".\Lib\/" /Fd".\Lib\/vc90.pdb" /W3 /nologo /ZI /Qopenmp /QxSSE2 /Qopt-matmul

here is the linker options

libTiff.lib ippvm.lib ippvc.lib ippsc.lib ippr.lib ippm.lib ippj.lib ippdi.lib ippcv.lib ippch.lib ippcc.lib ippac.lib ippdc.lib ippi.lib ipps.lib ippcore.lib kernel32.lib user32.lib gdi32.lib winspool.lib comdlg32.lib advapi32.lib shell32.lib ole32.lib oleaut32.lib uuid.lib odbc32.lib odbccp32.lib /OUT:".\Lib\\IPL.dll" /INCREMENTAL:NO /nologo /LIBPATH:".\Lib\" /LIBPATH:"IPP\ia32\stublib" /MANIFEST /MANIFESTFILE:".\Lib\\IPL.dll.intermediate.manifest" /MANIFESTUAC:"level='asInvoker' uiAccess='false'" /TLBID:1 /DEBUG /PDB:"D:\ipl\Common\Lib\SEMIPL.pdb" /SUBSYSTEM:WINDOWS /OPT:REF /OPT:ICF /DYNAMICBASE /NXCOMPAT /IMPLIB:"D:\ipl\Common\Lib\SEMIPL.lib" /MACHINE:X86 /DLL

Regards

pradeep

0 Kudos
SergeyKostrov
Valued Contributor II
2,110 Views
Hi Pradeep,

>>...i needed the optimization levels to be enabled...

Try to understand why the optimization was disabled by commenting some parts of the source codes. You
need to find a piece of code that is "responsible" for this. This is what I would do first.

By changing some project setting you're simply "escalating" another problems at the linker stage, it takes
your time, and it doesn't solve the problem.

So, try to find a root cause ofthe problem in your source codes.

Best regards,
Sergey
0 Kudos
Royi
Novice
2,110 Views

Did you solve this issue?

I'm experiencing the same thing which makes the performance worse than vanilla MSVC.
I can't find the reason for that no matter what I have done.

I found this:

https://software.intel.com/en-us/articles/cdiag10182

Yet not sure this is the issue I'm having.

0 Kudos
talmi__amos
Beginner
2,110 Views

I had the same error message, #10182.  The fix was very simple: Turned out, that the ACTIVE configuration was debug.

It seems the change from 'debug' to 'release' should be done both in project>properties and the build>configuration manager..

 

0 Kudos
Reply