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

How to get source info into VTune?

croucher1
Beginner
909 Views

I'm cross-posting this because I realized people here would be more likely to know!

I've been up and down the Fortran and VTune support, and I just can't figure out what I'm doing wrong. No Fortran examples in the VTune support, and nobody posting that they'd done it recently...

All I ever get is "Line information is not available"

I just signed up for refactoring 100K lines of code, and I haven't done assembly language since the PDP-8. So if I don't get source info then I can't do the job.

I have a PDB file, and I've turned the map file off just to be safe. (Why does Intel add /mapinfo:lines if the linker doesn't support that command?)

Vtune 9.0 build 719

Intel Fortran 10.1.011

via Visual Studio

Current compiler command:

/nologo /Zi /Od /include:"Debug/" /warn:all /debug-parameters:all /Qauto /fpe:0 /iface:cvf /module:"Debug/" /object:"Debug/" /asmattr:source /asmfile:"Debug/" /traceback /check:bounds /libs:qwin /c

Link command:

/OUT:"Debug/cass_v4.exe" /INCREMENTAL:NO /NOLOGO /NODEFAULTLIB:"dfconsol.lib" /MANIFEST /MANIFESTFILE:"C:cass41acass-v4.1cdcass_v4cass_v4debugcass_v4.exe.intermediate.manifest" /DEBUG /PDB:"C:cass41acass-v4.1cdcass_v4cass_v4debugcass_v4.pdb" /SUBSYSTEM:WINDOWS /STACK:184549376,184549376 /ENTRY:"WinMainCRTStartup" kernel32.lib

0 Kudos
5 Replies
TimP
Honored Contributor III
909 Views
Did your link step actually create the .pdb you need? Normally, you would use /Zi in the link step as well as in the compiler step. If the final .pdb isn't in the places where VTune normally looks, you should get a pop-up window inviting you to browse to it.
It's unusual to attempt VTune on a build with so many debug and check options, as the results would have no relationship to performance of a release build.
0 Kudos
croucher1
Beginner
909 Views

Thanks for helping.

Yes, the PDB was created in the same directory as the EXE. (same timestamp)

VTune did not ask anything about where the symbol info was.

The commands I wound up with were the result of trying to figure out what flag was causing the problem, using the Help and KB information from IVF,VTune, and MS linker. Itain't what I started with ;-)

I'd love to see any example of commands that leads to source info in VTune. Steve promised us one back in November (hint,hint)

0 Kudos
Steven_L_Intel1
Employee
909 Views
Sorry for not getting around to this before, but now I have.

Software combination:
  • Intel Visual Fortran 10.1.014 with VSPPE
  • Intel VTune Performance Analyzer 9.0.010
I created a Console application using the int_sin.f90 source provided under samplesoptimization. Switched to a Release configuration. Changed the Fortran debug setting to "Full" and the Linker Debug setting to "Yes". Built the project.

Then in VS, I selected Tuning > Create new activity > Quick Performance Analysis Wizard. I took the defaults and told it to Go.

When it had finished, I was presented with the bar chart naming the EXE. I double-clicked on that and then on the INTEG_FUNC routine where the work was done. I was brought to the annotated source. See attached screen capture.

What happens when you follow these steps?
0 Kudos
croucher
Beginner
909 Views

Test case worked as advertised.

I was working in VS 2005..

Picking back through, I found out that I had been assuming changes made to the Startup Project were inherited by the other projects within the solution, and I'd been looking at the compiler command only from the Startup Project. Thisinheritence didn't exist, so source code was available only from the handful of startup routines in the one project I had been telling to generate debug info and not in any of theimportant routines. Going back into the project and turning on debug info for each project fixed the problem.

The nice thing about being an idiot is that all your problems have simple solutions ;-)

Thanks,

Art

0 Kudos
Steven_L_Intel1
Employee
909 Views
Glad to hear it.
0 Kudos
Reply