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

Unexpected results in Release build

greekgoddj
Beginner
383 Views
Greetings,

I have searched through the forum and noticed that this topic has come up before, unfortunately without a clean solution. The problem once again is as follows:

VS2003 Compiler Debug = OK
VS2003 Compiler Release = OK
Intel C++ 9 Compiler Debug = OK
Intel C++ 9 Compiler Release = UNEXPECTED BEHAVIOUR

As some of the previous threads on this topic suggested I tried to change some of the flags in the optimization settings. Some of the unexpected behaviour actually dissapears when setting the "floating point precision improvement" to "Max(/0p)." Unfortunately it does not solve all the unexpected results. It seems that the only way to get rid of the unexpected results is to turn the "Optimizations" to "Disabled (/0d)" which ofcourse defeats the point of having a Release mode in the first place.

Any suggestions ofcourse are welcome! My system is a P4, WinXP, VS2003, Intel C++ 9.0.


Thanks in advance,

Aristotel
0 Kudos
4 Replies
JenniferJ
Moderator
383 Views
Did you try /Ob0 plus /Op?
It sounds a bug, could you file an issue report to Premier Support?
Jennifer
0 Kudos
TimP
Honored Contributor III
383 Views
Uninitialized data also could explain this.
0 Kudos
greekgoddj
Beginner
383 Views
I have looked for unitialized variables, both manually and by setting the compiler warning level to 4. So I don't think the problem is uninitialized variables this time.

I have tried to use the Premier Support but the website doesn't work, it gives a "403 Forbidden: Access Denied" message.

What is the /Ob0 flag? I cannot find it in the documentation. Only /Ob1



Aristotel
0 Kudos
JenniferJ
Moderator
383 Views
/Ob0 is to disable inlining. Because of it, some other optimizations may not happen. It's usually a work around to move forward. You can add "/Ob0" to the project property under "C/C++->Command Line->Additional Options".
But we still need to root cause the problem. I'll try to create an issue report at Premier Support for you.
Jennifer
0 Kudos
Reply