Intel® Fortran Compiler
Build applications that can scale for the future with optimized code designed for Intel® Xeon® and compatible processors.

debug module variables

wstephens
Einsteiger
2.319Aufrufe
I just upgraded to 2011.3.175

Now in debug mode, when I watch a variable declared in a module I have to use the modname::varname syntax in the watch window. And the value doesn't pop up when I hover over varname.

Wasn't there a fix for this?
0 Kudos
13 Antworten
Steven_L_Intel1
Mitarbeiter
2.319Aufrufe
Yes, it should work. Did you do a full rebuild of the project?
wstephens
Einsteiger
2.319Aufrufe
Yes, a full rebuild.

Perhaps I'll try to re-create the project from scratch.

Or any other ideas?
Steven_L_Intel1
Mitarbeiter
2.319Aufrufe
If you still can't make it work, attach a ZIP of a small test project that shows the problem.
wstephens
Einsteiger
2.319Aufrufe
Well, I just noticed that in debug mode it shows me some of those other module variables, but not all of them.

There must be some pattern to it, but it is unclear. It's like some of the names got on a 'hit' list and disappeared.

Any ideas?
Steven_L_Intel1
Mitarbeiter
2.319Aufrufe
No idea. The variable has to be used in the current source to be active, but otherwise it should work. Again, if you can attach a test case that shows a problem, we'll be glad to look.

Are the module variables actually PARAMETER constants, perhaps? For that you have to enable debug info for PARAMETER constants.
wstephens
Einsteiger
2.319Aufrufe
They are not PARAMETER constants.

This is taking a good deal of effort to reduce the program to isolate the issue.

One of the two variables did "appear" when debugging in Module "F" after I moved an assignment for the variable to the main program's file from Module "D". The variable is still defined in Module "D".

The other variable, declared right next the first one in Module "D", is still an "Undefined variable" in the watch window when debugging Module "F".
mecej4
Geehrter Beitragender III
2.319Aufrufe
You have described behavior that we agree "shouldn't be so". However, we need the small example that Steve Lionel asked for to move forward with a fix.

Do note that "undefined" and "declared" are different states. You can have a declared variable (known type, shape, size, and other attributes) that is undefined (no value(s) assigned to some or all components). Conversely, you can have a variable that is undeclared (i.e., declared implicitly) that is defined at a particular line of code.

Finally, the optimizer can cause variables that exist in the source code to have no counterpart in the compiled code. Debugging such code is quite difficult, and often needs working at the assembly level.

wstephens
Einsteiger
2.319Aufrufe
The debugger says "Undefined variable".

I assume that this is different than what the compiler refers to as "undefined".

It must be different because the debugger shows the correct value using the modulename::varname syntax in the watch window.
wstephens
Einsteiger
2.319Aufrufe
Did anyone get a chance to look at my previously attached project showing the problem?
Steven_L_Intel1
Mitarbeiter
2.319Aufrufe
I can reproduce this and can't explain it. I will ask the developers.
Steven_L_Intel1
Mitarbeiter
2.319Aufrufe
Escalated as issue DPD200216582.
Steven_L_Intel1
Mitarbeiter
2.319Aufrufe
This problem has been fixed in our sources. The fix will appear in a future update or version.
Steven_L_Intel1
Mitarbeiter
2.319Aufrufe
I expect the fix to appear in Update 7 of Intel Visual Fortran Composer XE 2011.
Antworten