Software Archive
Read-only legacy content
17060 Discussions

Re: Compiler settings for debug

Steven_L_Intel1
Employee
728 Views
The defaults under a Debug configuration work pretty well, though I'd also suggest turning on "Variables default to AUTOMATIC" as a debugging aid. You can also turn on overflow checking, and under Floating Point, set the Floating Point Exception behavior to 0 instead of the default 3. There is no option for memory leak checking.

Steve
0 Kudos
2 Replies
Intel_C_Intel
Employee
728 Views
Steve,

What is the advantage of "variables default to AUTOMATIC" as a debug option. I have done a lot of probing around in the help files for exasctly what this accomplishes, but have never been able to really understand what is going on. Thanks,

Tom
0 Kudos
Steven_L_Intel1
Employee
728 Views
This option removes the assumed static semantics for local variables that the compiler uses by default for compatibility with "dusty deck" code that assumes all variables are statically allocated. The side effect of the option is that such variables are not considered initially defined, and hence the compiler is better able to give warnings for uninitialized variables.

Steve
0 Kudos
Reply